summaryrefslogtreecommitdiff
path: root/tools/llc
diff options
context:
space:
mode:
Diffstat (limited to 'tools/llc')
-rw-r--r--tools/llc/llc.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/tools/llc/llc.cpp b/tools/llc/llc.cpp
index 269a5df904..abdc1ab634 100644
--- a/tools/llc/llc.cpp
+++ b/tools/llc/llc.cpp
@@ -273,6 +273,10 @@ static int compileModule(char **argv, LLVMContext &Context) {
TargetOptions Options = InitTargetOptionsFromCodeGenFlags();
Options.DisableIntegratedAS = NoIntegratedAssembler;
+ // Override default to generate verbose assembly unless we've seen the flag.
+ if (AsmVerbose.getNumOccurrences() == 0)
+ Options.MCOptions.AsmVerbose = true;
+
std::unique_ptr<TargetMachine> target(
TheTarget->createTargetMachine(TheTriple.getTriple(), MCPU, FeaturesStr,
Options, RelocModel, CMModel, OLvl));
@@ -309,9 +313,6 @@ static int compileModule(char **argv, LLVMContext &Context) {
mod->setDataLayout(DL);
PM.add(new DataLayoutPass(mod));
- // Override default to generate verbose assembly.
- Target.setAsmVerbosityDefault(true);
-
if (RelaxAll.getNumOccurrences() > 0 &&
FileType != TargetMachine::CGFT_ObjectFile)
errs() << argv[0]