From: Bill Wendling Date: Fri, 17 Jun 2011 20:55:01 +0000 (+0000) Subject: Use the verbose asm flag instead of a new flag for decoding the LSDA. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=e266ce6c6eaf52ebe2b18d85b5e23788cf2f6ef4;p=oota-llvm.git Use the verbose asm flag instead of a new flag for decoding the LSDA. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133292 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/include/llvm/MC/MCStreamer.h b/include/llvm/MC/MCStreamer.h index 6f017136c2d..69be46bdd5a 100644 --- a/include/llvm/MC/MCStreamer.h +++ b/include/llvm/MC/MCStreamer.h @@ -557,8 +557,7 @@ namespace llvm { MCInstPrinter *InstPrint = 0, MCCodeEmitter *CE = 0, TargetAsmBackend *TAB = 0, - bool ShowInst = false, - bool DecodeLSDA = false); + bool ShowInst = false); /// createMachOStreamer - Create a machine code streamer which will generate /// Mach-O format object files. diff --git a/include/llvm/Target/TargetRegistry.h b/include/llvm/Target/TargetRegistry.h index 0bec8bc1ecf..a464822893b 100644 --- a/include/llvm/Target/TargetRegistry.h +++ b/include/llvm/Target/TargetRegistry.h @@ -47,8 +47,7 @@ namespace llvm { MCInstPrinter *InstPrint, MCCodeEmitter *CE, TargetAsmBackend *TAB, - bool ShowInst, - bool DecodeLSDA); + bool ShowInst); /// Target - Wrapper for Target specific information. /// @@ -101,8 +100,7 @@ namespace llvm { MCInstPrinter *InstPrint, MCCodeEmitter *CE, TargetAsmBackend *TAB, - bool ShowInst, - bool DecodeLSDA); + bool ShowInst); private: /// Next - The next registered target in the linked list, maintained by the @@ -336,11 +334,10 @@ namespace llvm { MCInstPrinter *InstPrint, MCCodeEmitter *CE, TargetAsmBackend *TAB, - bool ShowInst, - bool DecodeLSDA) const { + bool ShowInst) const { // AsmStreamerCtorFn is default to llvm::createAsmStreamer return AsmStreamerCtorFn(Ctx, OS, isVerboseAsm, useLoc, useCFI, - InstPrint, CE, TAB, ShowInst, DecodeLSDA); + InstPrint, CE, TAB, ShowInst); } /// @} diff --git a/lib/CodeGen/LLVMTargetMachine.cpp b/lib/CodeGen/LLVMTargetMachine.cpp index 4ed959e120e..b98fbed695b 100644 --- a/lib/CodeGen/LLVMTargetMachine.cpp +++ b/lib/CodeGen/LLVMTargetMachine.cpp @@ -72,8 +72,6 @@ static cl::opt ShowMCEncoding("show-mc-encoding", cl::Hidden, cl::desc("Show encoding in .s output")); static cl::opt ShowMCInst("show-mc-inst", cl::Hidden, cl::desc("Show instruction structure in .s output")); -static cl::opt DecodeMCLSDA("decode-mc-lsda", cl::Hidden, - cl::desc("Print LSDA in human readable format in .s output")); static cl::opt EnableMCLogging("enable-mc-api-logging", cl::Hidden, cl::desc("Enable MC API logging")); static cl::opt VerifyMachineCode("verify-machineinstrs", cl::Hidden, @@ -154,8 +152,7 @@ bool LLVMTargetMachine::addPassesToEmitFile(PassManagerBase &PM, hasMCUseCFI(), InstPrinter, MCE, TAB, - ShowMCInst, - DecodeMCLSDA); + ShowMCInst); AsmStreamer.reset(S); break; } diff --git a/lib/MC/MCAsmStreamer.cpp b/lib/MC/MCAsmStreamer.cpp index 01de450d971..f83b91779d9 100644 --- a/lib/MC/MCAsmStreamer.cpp +++ b/lib/MC/MCAsmStreamer.cpp @@ -1605,8 +1605,8 @@ MCStreamer *llvm::createAsmStreamer(MCContext &Context, bool isVerboseAsm, bool useLoc, bool useCFI, MCInstPrinter *IP, MCCodeEmitter *CE, TargetAsmBackend *TAB, - bool ShowInst, bool DecodeLSDA) { - if (DecodeLSDA) + bool ShowInst) { + if (isVerboseAsm) return new MCLSDADecoderAsmStreamer(Context, OS, isVerboseAsm, useLoc, useCFI, IP, CE, TAB, ShowInst); diff --git a/lib/Target/PTX/PTXMCAsmStreamer.cpp b/lib/Target/PTX/PTXMCAsmStreamer.cpp index bc37b6a1fb2..1574670b6e9 100644 --- a/lib/Target/PTX/PTXMCAsmStreamer.cpp +++ b/lib/Target/PTX/PTXMCAsmStreamer.cpp @@ -533,8 +533,7 @@ namespace llvm { bool isVerboseAsm, bool useLoc, bool useCFI, MCInstPrinter *IP, MCCodeEmitter *CE, TargetAsmBackend *TAB, - bool ShowInst, - bool /*DecodeLSDA*/) { + bool ShowInst) { return new PTXMCAsmStreamer(Context, OS, isVerboseAsm, useLoc, IP, CE, ShowInst); } diff --git a/lib/Target/PTX/PTXTargetMachine.cpp b/lib/Target/PTX/PTXTargetMachine.cpp index 31ed09c3e9c..1b737c9d863 100644 --- a/lib/Target/PTX/PTXTargetMachine.cpp +++ b/lib/Target/PTX/PTXTargetMachine.cpp @@ -27,8 +27,7 @@ namespace llvm { MCInstPrinter *InstPrint, MCCodeEmitter *CE, TargetAsmBackend *TAB, - bool ShowInst, - bool DecodeLSDA); + bool ShowInst); } extern "C" void LLVMInitializePTXTarget() { diff --git a/tools/llvm-mc/llvm-mc.cpp b/tools/llvm-mc/llvm-mc.cpp index 48e2a61af83..077f0e6700b 100644 --- a/tools/llvm-mc/llvm-mc.cpp +++ b/tools/llvm-mc/llvm-mc.cpp @@ -61,10 +61,6 @@ static cl::opt ShowInstOperands("show-inst-operands", cl::desc("Show instructions operands as parsed")); -static cl::opt -DecodeLSDA("decode-lsda", - cl::desc("Print LSDA in human readable format")); - static cl::opt OutputAsmVariant("output-asm-variant", cl::desc("Syntax variant to use for output printing")); @@ -361,8 +357,7 @@ static int AssembleInput(const char *ProgName) { Str.reset(TheTarget->createAsmStreamer(Ctx, FOS, /*asmverbose*/true, /*useLoc*/ true, /*useCFI*/ true, IP, CE, TAB, - ShowInst, - DecodeLSDA)); + ShowInst)); } else if (FileType == OFT_Null) { Str.reset(createNullStreamer(Ctx)); } else {