llvm.org GIT mirror llvm / 7e6b4f7
For PR1070: Tweak the RUN: lines of these tests to accommodate the renaming of variables done by llvm-upgrade. The renaming occurs as a result of avoiding name collisons for collapsed type planes. Conflicting names have a .u (unsigned) or .s (signed) suffix added. This patch updates the grep expression to accommodate the new names. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32815 91177308-0d34-0410-b5e6-96231b3b80d8 Reid Spencer 13 years ago
8 changed file(s) with 25 addition(s) and 19 deletion(s). Raw diff Collapse all Expand all
None ; RUN: (llvm-upgrade < %s | llvm-as -o /dev/null -f) 2>&1 | grep 'Cannot create a'
0 ; RUN: (llvm-upgrade < %s | llvm-as -o /dev/null -f) 2>&1 | grep 'Cannot resolve type'
11 ; Test for PR463. This program is erroneous, but should not crash llvm-as.
22 %.FOO = internal global %struct.none zeroinitializer
None ; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm &&
1 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0, #0" | wc -l | grep 1 &&
2 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0, #255" | wc -l | grep 1 &&
3 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0, #256" | wc -l | grep 1 &&
4 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep ".word.*257" | wc -l | grep 1 &&
5 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0, #-1073741761" | wc -l | grep 1 &&
6 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "mov r0, #1008" | wc -l | grep 1 &&
7 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "cmp r0, #65536" | wc -l | grep 1 &&
8 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | grep "\.comm.*a,4,4" | wc -l | grep 1
0 ; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm -o %t.s -f &&
1 ; RUN: grep "mov r0, #0" %t.s | wc -l | grep 1 &&
2 ; RUN: grep "mov r0, #255" %t.s | wc -l | grep 1 &&
3 ; RUN: grep "mov r0, #256" %t.s | wc -l | grep 1 &&
4 ; RUN: grep ".word.*257" %t.s | wc -l | grep 1 &&
5 ; RUN: grep "mov r0, #-1073741761" %t.s | wc -l | grep 1 &&
6 ; RUN: grep "mov r0, #1008" %t.s | wc -l | grep 1 &&
7 ; RUN: grep "cmp r0, #65536" %t.s | wc -l | grep 1 &&
8 ; RUN: grep "\.comm.*a.s,4,4" %t.s | wc -l | grep 1
99
1010 %a = internal global int 0
1111
None ; RUN: llvm-upgrade < %s | llvm-as | llc | grep 'foo bar":'
0 ; RUN: llvm-upgrade < %s | llvm-as | llc | grep 'foo bar.s":'
11
22 target endian = big
33 target pointersize = 32
11 ; RUN: llvm-upgrade < `dirname %s`/testlink1.ll | llvm-as > %t2.bc
22 ; RUN: llvm-link %t.bc %t.bc %t2.bc -o %t1.bc -f
33 ; RUN: llvm-dis < %t1.bc | grep "kallsyms_names = extern_weak" &&
4 ; RUN: llvm-dis < %t1.bc | grep "MyVar = external global i32" &&
5 ; RUN: llvm-dis < %t1.bc | grep "Inte = global i32"
4 ; RUN: llvm-dis < %t1.bc | grep "MyVar.s = external global i32" &&
5 ; RUN: llvm-dis < %t1.bc | grep "Inte.s = global i32"
66
77 %kallsyms_names = extern_weak global [0 x ubyte]
88 %MyVar = extern_weak global int
0 ; This test makes sure that these instructions are properly eliminated.
11 ;
22
3 ; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine | llvm-dis | grep -v 'sub i32 %Cok, %Bok' | not grep sub
3 ; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine | llvm-dis | \
4 ; RUN: grep -v 'sub i32 %Cok.s, %Bok.s' | not grep sub
45
56 implementation
67
None ; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine | llvm-dis | grep 'and i32 %Y, 8'
0 ; RUN: llvm-upgrade < %s | llvm-as | opt -instcombine | llvm-dis | \
1 ; RUN: grep 'and i32 %Y.s, 8'
12
23 int %test1(ubyte %X) {
34 %Y = cast ubyte %X to int
None ; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | grep "%X.1.lcssa" &&
1 ; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | not grep "%X.1.lcssa1"
0 ; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | \
1 ; RUN: grep "%X.1.s.lcssa" &&
2 ; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | \
3 ; RUN: not grep "%X.1.s.lcssa1"
24
35 declare bool %c1()
46 declare bool %c2()
None ; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | grep "X3.lcssa = phi i32" &&
1 ; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | grep "%X4 = add i32 3, %X3.lcssa"
0 ; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | \
1 ; RUN: grep "X3.s.lcssa = phi i32" &&
2 ; RUN: llvm-upgrade < %s | llvm-as | opt -lcssa | llvm-dis | \
3 ; RUN: grep "%X4.s = add i32 3, %X3.s.lcssa"
24
35 void %lcssa(bool %S2) {
46 entry: