[llvm] r282675 - Remove an unnecessary duplicate initialization of TLOF from the Mips

Eric Christopher via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 28 19:03:52 PDT 2016


Author: echristo
Date: Wed Sep 28 21:03:52 2016
New Revision: 282675

URL: http://llvm.org/viewvc/llvm-project?rev=282675&view=rev
Log:
Remove an unnecessary duplicate initialization of TLOF from the Mips
AsmPrinter. This was reinitializing the Mangler after we moved the
Mangler down to TLOF and causing us to have two different unnamed
global values accessed with the same name.

This should fix the problems on the ubsan tests here:
http://lab.llvm.org:8011/builders/clang-cmake-mips/builds/15307

Modified:
    llvm/trunk/lib/Target/Mips/MipsAsmPrinter.cpp

Modified: llvm/trunk/lib/Target/Mips/MipsAsmPrinter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/Mips/MipsAsmPrinter.cpp?rev=282675&r1=282674&r2=282675&view=diff
==============================================================================
--- llvm/trunk/lib/Target/Mips/MipsAsmPrinter.cpp (original)
+++ llvm/trunk/lib/Target/Mips/MipsAsmPrinter.cpp Wed Sep 28 21:03:52 2016
@@ -60,10 +60,6 @@ MipsTargetStreamer &MipsAsmPrinter::getT
 bool MipsAsmPrinter::runOnMachineFunction(MachineFunction &MF) {
   Subtarget = &MF.getSubtarget<MipsSubtarget>();
 
-  // Initialize TargetLoweringObjectFile.
-  const_cast<TargetLoweringObjectFile &>(getObjFileLowering())
-      .Initialize(OutContext, TM);
-
   MipsFI = MF.getInfo<MipsFunctionInfo>();
   if (Subtarget->inMips16Mode())
     for (std::map<




More information about the llvm-commits mailing list