[lld] r363144 - Share /machine: handling code with llvm-cvtres too

Nico Weber via llvm-commits llvm-commits at lists.llvm.org
Wed Jun 12 04:32:43 PDT 2019


Author: nico
Date: Wed Jun 12 04:32:43 2019
New Revision: 363144

URL: http://llvm.org/viewvc/llvm-project?rev=363144&view=rev
Log:
Share /machine: handling code with llvm-cvtres too

r363016 let lld-link and llvm-lib share the /machine: parsing code.
This lets llvm-cvtres share it as well.

Making llvm-cvtres depend on llvm-lib seemed a bit strange (it doesn't
need llvm-lib's dependencies on BinaryFormat and BitReader) and I
couldn't find a good place to put this code. Since it's just a few
lines, put it in lib/Object for now.

Differential Revision: https://reviews.llvm.org/D63120

Modified:
    lld/trunk/COFF/Driver.cpp
    lld/trunk/COFF/SymbolTable.cpp

Modified: lld/trunk/COFF/Driver.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/COFF/Driver.cpp?rev=363144&r1=363143&r2=363144&view=diff
==============================================================================
--- lld/trunk/COFF/Driver.cpp (original)
+++ lld/trunk/COFF/Driver.cpp Wed Jun 12 04:32:43 2019
@@ -6,9 +6,9 @@
 //
 //===----------------------------------------------------------------------===//
 
-#include "DebugTypes.h"
 #include "Driver.h"
 #include "Config.h"
+#include "DebugTypes.h"
 #include "ICF.h"
 #include "InputFiles.h"
 #include "MarkLive.h"
@@ -30,6 +30,7 @@
 #include "llvm/Object/ArchiveWriter.h"
 #include "llvm/Object/COFFImportFile.h"
 #include "llvm/Object/COFFModuleDefinition.h"
+#include "llvm/Object/WindowsMachineFlag.h"
 #include "llvm/Option/Arg.h"
 #include "llvm/Option/ArgList.h"
 #include "llvm/Option/Option.h"

Modified: lld/trunk/COFF/SymbolTable.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/COFF/SymbolTable.cpp?rev=363144&r1=363143&r2=363144&view=diff
==============================================================================
--- lld/trunk/COFF/SymbolTable.cpp (original)
+++ lld/trunk/COFF/SymbolTable.cpp Wed Jun 12 04:32:43 2019
@@ -16,9 +16,9 @@
 #include "lld/Common/Memory.h"
 #include "lld/Common/Timer.h"
 #include "llvm/IR/LLVMContext.h"
+#include "llvm/Object/WindowsMachineFlag.h"
 #include "llvm/Support/Debug.h"
 #include "llvm/Support/raw_ostream.h"
-#include "llvm/ToolDrivers/llvm-lib/LibDriver.h"
 #include <utility>
 
 using namespace llvm;




More information about the llvm-commits mailing list