[cfe-commits] r135612 - /cfe/trunk/tools/driver/cc1as_main.cpp

Evan Cheng evan.cheng at apple.com
Wed Jul 20 12:53:19 PDT 2011


Author: evancheng
Date: Wed Jul 20 14:53:19 2011
New Revision: 135612

URL: http://llvm.org/viewvc/llvm-project?rev=135612&view=rev
Log:
Match MCContext change.

Modified:
    cfe/trunk/tools/driver/cc1as_main.cpp

Modified: cfe/trunk/tools/driver/cc1as_main.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/driver/cc1as_main.cpp?rev=135612&r1=135611&r2=135612&view=diff
==============================================================================
--- cfe/trunk/tools/driver/cc1as_main.cpp (original)
+++ cfe/trunk/tools/driver/cc1as_main.cpp Wed Jul 20 14:53:19 2011
@@ -48,7 +48,6 @@
 #include "llvm/Support/Signals.h"
 #include "llvm/Support/system_error.h"
 #include "llvm/Target/TargetAsmBackend.h"
-#include "llvm/Target/TargetAsmInfo.h"
 #include "llvm/Target/TargetAsmParser.h"
 #include "llvm/Target/TargetData.h"
 #include "llvm/Target/TargetInstrInfo.h"
@@ -277,13 +276,13 @@
     return false;
   }
 
-  const TargetAsmInfo *tai = new TargetAsmInfo(*TM);
   // FIXME: This is not pretty. MCContext has a ptr to MCObjectFileInfo and
   // MCObjectFileInfo needs a MCContext reference in order to initialize itself.
   OwningPtr<MCObjectFileInfo> MOFI(new MCObjectFileInfo());
-  MCContext Ctx(*MAI, *MRI, MOFI.get(), tai);
+  MCContext Ctx(*MAI, *MRI, MOFI.get());
   // FIXME: Assembler behavior can change with -static.
-  MOFI->InitMCObjectFileInfo(Opts.Triple, Reloc::Default, Ctx);
+  MOFI->InitMCObjectFileInfo(Opts.Triple,
+                             Reloc::Default, CodeModel::Default, Ctx);
   if (Opts.SaveTemporaryLabels)
     Ctx.setAllowTemporaryLabels(false);
 





More information about the cfe-commits mailing list