diff options
author | Chris Lattner <sabre@nondot.org> | 2010-02-02 22:58:13 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2010-02-02 22:58:13 +0000 |
commit | e16ad1a9833c89965c921f137cfb6c424ff3e9c2 (patch) | |
tree | 2f9b4d5a6561439ae81cc99f7f03109ea7d64d35 /lib/CodeGen/LLVMTargetMachine.cpp | |
parent | 1f21990284906b1d3ed244d99808c6dade04d295 (diff) |
simplify getVerboseAsm
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95153 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/LLVMTargetMachine.cpp')
-rw-r--r-- | lib/CodeGen/LLVMTargetMachine.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/CodeGen/LLVMTargetMachine.cpp b/lib/CodeGen/LLVMTargetMachine.cpp index 3063e5e1ef..a4f313938d 100644 --- a/lib/CodeGen/LLVMTargetMachine.cpp +++ b/lib/CodeGen/LLVMTargetMachine.cpp @@ -66,12 +66,12 @@ static cl::opt<cl::boolOrDefault> AsmVerbose("asm-verbose", cl::desc("Add comments to directives."), cl::init(cl::BOU_UNSET)); -static bool getVerboseAsm(bool VDef) { +static bool getVerboseAsm() { switch (AsmVerbose) { - default: - case cl::BOU_UNSET: return VDef; - case cl::BOU_TRUE: return true; - case cl::BOU_FALSE: return false; + default: + case cl::BOU_UNSET: return TargetMachine::getAsmVerbosityDefault(); + case cl::BOU_TRUE: return true; + case cl::BOU_FALSE: return false; } } @@ -123,7 +123,7 @@ LLVMTargetMachine::addPassesToEmitFile(PassManagerBase &PM, case CGFT_AssemblyFile: { FunctionPass *Printer = getTarget().createAsmPrinter(Out, *this, getMCAsmInfo(), - getVerboseAsm(getAsmVerbosityDefault())); + getVerboseAsm()); if (Printer == 0) return CGFT_ErrorOccurred; PM.add(Printer); break; |