diff options
author | Dan Gohman <gohman@apple.com> | 2009-03-31 18:39:13 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2009-03-31 18:39:13 +0000 |
commit | 968dc7a2077d5c4a0b2fca9810b0fdf9cd62991b (patch) | |
tree | e18aa62737b225df2ec84a32c3cae264f39ff841 /lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp | |
parent | 46801029ea64dc9f3547b2977b455eae927fc7be (diff) | |
download | external_llvm-968dc7a2077d5c4a0b2fca9810b0fdf9cd62991b.zip external_llvm-968dc7a2077d5c4a0b2fca9810b0fdf9cd62991b.tar.gz external_llvm-968dc7a2077d5c4a0b2fca9810b0fdf9cd62991b.tar.bz2 |
Reapply 68073, with fixes. EH Landing-pad basic blocks are not
entered via fall-through. Don't miss fallthroughs from blocks
terminated by conditional branches. Also, move
isOnlyReachableByFallthrough out of line.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@68129 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp')
-rw-r--r-- | lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp b/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp index 3bdcf88..3b6b0ef 100644 --- a/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp +++ b/lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.cpp @@ -238,7 +238,10 @@ bool X86ATTAsmPrinter::runOnMachineFunction(MachineFunction &MF) { for (MachineFunction::const_iterator I = MF.begin(), E = MF.end(); I != E; ++I) { // Print a label for the basic block. - if (!I->pred_empty()) { + if (!VerboseAsm && (I->pred_empty() || I->isOnlyReachableByFallthrough())) { + // This is an entry block or a block that's only reachable via a + // fallthrough edge. In non-VerboseAsm mode, don't print the label. + } else { printBasicBlockLabel(I, true, true, VerboseAsm); O << '\n'; } |