[LTO] Move cl::opt inside llvm:: after D53294
authorFangrui Song <i@maskray.me>
Thu, 24 Nov 2022 07:22:26 +0000 (23:22 -0800)
committerFangrui Song <i@maskray.me>
Thu, 24 Nov 2022 07:22:26 +0000 (23:22 -0800)
llvm/include/llvm/LTO/legacy/LTOCodeGenerator.h
llvm/lib/LTO/LTO.cpp

index 203f56d..a55dc31 100644 (file)
@@ -51,9 +51,6 @@
 #include <string>
 #include <vector>
 
-/// Enable global value internalization in LTO.
-extern llvm::cl::opt<bool> EnableLTOInternalization;
-
 namespace llvm {
 template <typename T> class ArrayRef;
   class LLVMContext;
@@ -66,6 +63,9 @@ template <typename T> class ArrayRef;
   class raw_ostream;
   class raw_pwrite_stream;
 
+/// Enable global value internalization in LTO.
+extern cl::opt<bool> EnableLTOInternalization;
+
 //===----------------------------------------------------------------------===//
 /// C++ class which implements the opaque lto_code_gen_t type.
 ///
index 81219cd..6e7fde6 100644 (file)
@@ -69,10 +69,12 @@ static cl::opt<bool>
     DumpThinCGSCCs("dump-thin-cg-sccs", cl::init(false), cl::Hidden,
                    cl::desc("Dump the SCCs in the ThinLTO index's callgraph"));
 
+namespace llvm {
 /// Enable global value internalization in LTO.
 cl::opt<bool> EnableLTOInternalization(
     "enable-lto-internalization", cl::init(true), cl::Hidden,
     cl::desc("Enable global value internalization in LTO"));
+}
 
 // Computes a unique hash for the Module considering the current list of
 // export/import and other global analysis results.