]> granicus.if.org Git - llvm/commitdiff
Remove an unnecessary duplicate initialization of TLOF from the Mips
authorEric Christopher <echristo@gmail.com>
Thu, 29 Sep 2016 02:03:52 +0000 (02:03 +0000)
committerEric Christopher <echristo@gmail.com>
Thu, 29 Sep 2016 02:03:52 +0000 (02:03 +0000)
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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@282675 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/Mips/MipsAsmPrinter.cpp

index 7519c309e44a3904a330954c822ba040f08c3c11..8dab262ac2569fa8f4c7d484fe1941e7bedc8c64 100644 (file)
@@ -60,10 +60,6 @@ MipsTargetStreamer &MipsAsmPrinter::getTargetStreamer() const {
 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<