summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-02-02 22:54:51 +0000
committerChris Lattner <sabre@nondot.org>2010-02-02 22:54:51 +0000
commit32445d300fd49e719b38ac66e165d81c9959cbce (patch)
treecd1210272aa7690628be667bf3d5c84332596bc5 /llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
parentb251eb69019a5370dc6cd6826d6025a1a1a92e53 (diff)
downloadbcm5719-llvm-32445d300fd49e719b38ac66e165d81c9959cbce.tar.gz
bcm5719-llvm-32445d300fd49e719b38ac66e165d81c9959cbce.zip
move handling of asm-verbose out of AsmPrinter.cpp into LLVMTargetMachine.cpp with the rest of the command line options.
llvm-svn: 95152
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp19
1 files changed, 3 insertions, 16 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp b/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
index 36aa748426e..49db51ea0b6 100644
--- a/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp
@@ -53,22 +53,9 @@ using namespace llvm;
STATISTIC(EmittedInsts, "Number of machine instrs printed");
-static cl::opt<cl::boolOrDefault>
-AsmVerbose("asm-verbose", cl::desc("Add comments to directives."),
- cl::init(cl::BOU_UNSET));
-
-static bool getVerboseAsm(bool VDef) {
- switch (AsmVerbose) {
- default:
- case cl::BOU_UNSET: return VDef;
- case cl::BOU_TRUE: return true;
- case cl::BOU_FALSE: return false;
- }
-}
-
char AsmPrinter::ID = 0;
AsmPrinter::AsmPrinter(formatted_raw_ostream &o, TargetMachine &tm,
- const MCAsmInfo *T, bool VDef)
+ const MCAsmInfo *T, bool VerboseAsm)
: MachineFunctionPass(&ID), O(o),
TM(tm), MAI(T), TRI(tm.getRegisterInfo()),
@@ -76,11 +63,11 @@ AsmPrinter::AsmPrinter(formatted_raw_ostream &o, TargetMachine &tm,
// FIXME: Pass instprinter to streamer.
OutStreamer(*createAsmStreamer(OutContext, O, *T,
TM.getTargetData()->isLittleEndian(),
- getVerboseAsm(VDef), 0)),
+ VerboseAsm, 0)),
LastMI(0), LastFn(0), Counter(~0U), PrevDLT(NULL) {
DW = 0; MMI = 0;
- VerboseAsm = getVerboseAsm(VDef);
+ this->VerboseAsm = VerboseAsm;
}
AsmPrinter::~AsmPrinter() {
OpenPOWER on IntegriCloud