[llvm] r258993 - Tweak unnamed label syntax in textual IR for easier matching in tests.
Evgeniy Stepanov via llvm-commits
llvm-commits at lists.llvm.org
Wed Jan 27 13:53:09 PST 2016
Author: eugenis
Date: Wed Jan 27 15:53:08 2016
New Revision: 258993
URL: http://llvm.org/viewvc/llvm-project?rev=258993&view=rev
Log:
Tweak unnamed label syntax in textual IR for easier matching in tests.
Change the unnamed label comments like
; <label>:8 ; preds = %1
to
; <label>:8: ; preds = %1
This way lit tests can match [[LABEL]]: in both asserts and no-asserts builds.
Modified:
llvm/trunk/lib/IR/AsmWriter.cpp
llvm/trunk/test/Transforms/SimplifyCFG/merge-cond-stores-2.ll
Modified: llvm/trunk/lib/IR/AsmWriter.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/IR/AsmWriter.cpp?rev=258993&r1=258992&r2=258993&view=diff
==============================================================================
--- llvm/trunk/lib/IR/AsmWriter.cpp (original)
+++ llvm/trunk/lib/IR/AsmWriter.cpp Wed Jan 27 15:53:08 2016
@@ -2676,7 +2676,7 @@ void AssemblyWriter::printBasicBlock(con
Out << "\n; <label>:";
int Slot = Machine.getLocalSlot(BB);
if (Slot != -1)
- Out << Slot;
+ Out << Slot << ":";
else
Out << "<badref>";
}
Modified: llvm/trunk/test/Transforms/SimplifyCFG/merge-cond-stores-2.ll
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Transforms/SimplifyCFG/merge-cond-stores-2.ll?rev=258993&r1=258992&r2=258993&view=diff
==============================================================================
--- llvm/trunk/test/Transforms/SimplifyCFG/merge-cond-stores-2.ll (original)
+++ llvm/trunk/test/Transforms/SimplifyCFG/merge-cond-stores-2.ll Wed Jan 27 15:53:08 2016
@@ -27,10 +27,10 @@ target triple = "armv7--linux-gnueabihf"
; CHECK: select
; CHECK-NOT: select
; CHECK: br i1 {{.*}}, label %[[L:.*]], label %[[R:.*]]
-; CHECK: [[L]] ; preds =
+; CHECK: [[L]]: ; preds =
; CHECK-NEXT: store
; CHECK-NEXT: br label %[[R]]
-; CHECK: [[R]] ; preds =
+; CHECK: [[R]]: ; preds =
; CHECK-NEXT: ret i32 0
define i32 @f(i32* %b) {
More information about the llvm-commits
mailing list