From 34ac7a7ac1a382d3170ab5728b288018b06f98d1 Mon Sep 17 00:00:00 2001
From: Nico Weber <thakis@chromium.org>
Date: Thu, 26 Aug 2021 22:03:26 -0400
Subject: [PATCH] [lld/COFF] Ignore /LTCG, /LTCG:, /LTCGOUT:, /ILK: flags

We currently complain "could not open /LTCG: no such file or directory",
which isn't very useful.  We could emit a warning when we see this flag, but
just ignoring it seems fine.

Final missing part of PR38799.

Differential Revision: https://reviews.llvm.org/D108799
---
 lld/COFF/Options.td | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/lld/COFF/Options.td b/lld/COFF/Options.td
index 940d96c39e99..387865faa35a 100644
--- a/lld/COFF/Options.td
+++ b/lld/COFF/Options.td
@@ -279,6 +279,7 @@ def summary : F<"summary">;
 //==============================================================================
 
 def ignoreidl : F<"ignoreidl">;
+def ltcg : F<"ltcg">;
 def nologo : F<"nologo">;
 def throwingnew : F<"throwingnew">;
 def editandcontinue : F<"editandcontinue">;
@@ -287,6 +288,9 @@ def fastfail : F<"fastfail">;
 def delay : P_priv<"delay">;
 def errorreport : P_priv<"errorreport">;
 def idlout : P_priv<"idlout">;
+def ilk : P_priv<"ilk">;
+def ltcg_opt : P_priv<"ltcg">;
+def ltcgout : P_priv<"ltcgout">;
 def maxilksize : P_priv<"maxilksize">;
 def tlbid : P_priv<"tlbid">;
 def tlbout : P_priv<"tlbout">;