cl::ParseCommandLineOptions(argc, argv, "llvm machine code playground\n");
MCTargetOptions MCOptions = InitMCTargetOptionsFromFlags();
TripleName = Triple::normalize(TripleName);
+ Triple TheTriple(TripleName);
setDwarfDebugFlags(argc, argv);
setDwarfDebugProducer();
const Target *TheTarget = GetTarget(ProgName);
if (!TheTarget)
return 1;
- // Now that GetTarget() has (potentially) replaced TripleName, it's safe to
- // construct the Triple object.
- Triple TheTriple(TripleName);
ErrorOr<std::unique_ptr<MemoryBuffer>> BufferPtr =
MemoryBuffer::getFileOrSTDIN(InputFilename);
// MCObjectFileInfo needs a MCContext reference in order to initialize itself.
MCObjectFileInfo MOFI;
MCContext Ctx(MAI.get(), MRI.get(), &MOFI, &SrcMgr);
- MOFI.InitMCObjectFileInfo(TheTriple, RelocModel, CMModel, Ctx);
+ MOFI.InitMCObjectFileInfo(TripleName, RelocModel, CMModel, Ctx);
if (SaveTempLabels)
Ctx.setAllowTemporaryLabels(false);