diff options
author | Tanya Lattner <tonic@nondot.org> | 2008-03-10 07:21:50 +0000 |
---|---|---|
committer | Tanya Lattner <tonic@nondot.org> | 2008-03-10 07:21:50 +0000 |
commit | ceca194c4355224723b309a3a27c5e5bc19cb6fc (patch) | |
tree | d976e8cf9d933c32868d72a94d1ec2d9d7205735 /test/ExecutionEngine/test-shift.ll | |
parent | f79e60649a5edea03bdccf8521d77c15cbb33af4 (diff) | |
download | external_llvm-ceca194c4355224723b309a3a27c5e5bc19cb6fc.zip external_llvm-ceca194c4355224723b309a3a27c5e5bc19cb6fc.tar.gz external_llvm-ceca194c4355224723b309a3a27c5e5bc19cb6fc.tar.bz2 |
Remove llvm-upgrade and update tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48137 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/ExecutionEngine/test-shift.ll')
-rw-r--r-- | test/ExecutionEngine/test-shift.ll | 67 |
1 files changed, 30 insertions, 37 deletions
diff --git a/test/ExecutionEngine/test-shift.ll b/test/ExecutionEngine/test-shift.ll index 2549f34..ebb85d3 100644 --- a/test/ExecutionEngine/test-shift.ll +++ b/test/ExecutionEngine/test-shift.ll @@ -1,40 +1,33 @@ -; RUN: llvm-upgrade %s | llvm-as -f -o %t.bc +; RUN: llvm-as < %s -f -o %t.bc ; RUN: lli %t.bc > /dev/null -; test shifts -int %main() { - %shamt = add ubyte 0, 1 - - ; Left shifts... - %t1.s = shl int 1, ubyte %shamt - %t2.s = shl int 1, ubyte 4 - - %t1 = shl uint 1, ubyte %shamt - %t2 = shl uint 1, ubyte 5 - - ;%t1 = shl long 1, ubyte %shamt - %t2.s = shl long 1, ubyte 4 - - ;%t1 = shl ulong 1, ubyte %shamt - %t2 = shl ulong 1, ubyte 5 - - ; Right shifts... - %tr1.s = shr int 1, ubyte %shamt - %tr2.s = shr int 1, ubyte 4 - - %tr1 = shr uint 1, ubyte %shamt - %tr2 = shr uint 1, ubyte 5 - - ;%tr1 = shr long 1, ubyte %shamt - %tr1.l = shr long 1, ubyte 4 - %tr2.l = shr long 1, ubyte %shamt - %tr3.l = shl long 1, ubyte 4 - %tr4.l = shl long 1, ubyte %shamt - - ;%t1 = shr ulong 1, ubyte %shamt - %tr1.u = shr ulong 1, ubyte 5 - %tr2.u = shr ulong 1, ubyte %shamt - %tr3.u = shl ulong 1, ubyte 5 - %tr4.u = shl ulong 1, ubyte %shamt - ret int 0 +define i32 @main() { + %shamt = add i8 0, 1 ; <i8> [#uses=8] + %shift.upgrd.1 = zext i8 %shamt to i32 ; <i32> [#uses=1] + %t1.s = shl i32 1, %shift.upgrd.1 ; <i32> [#uses=0] + %t2.s = shl i32 1, 4 ; <i32> [#uses=0] + %shift.upgrd.2 = zext i8 %shamt to i32 ; <i32> [#uses=1] + %t1 = shl i32 1, %shift.upgrd.2 ; <i32> [#uses=0] + %t2 = shl i32 1, 5 ; <i32> [#uses=0] + %t2.s.upgrd.3 = shl i64 1, 4 ; <i64> [#uses=0] + %t2.upgrd.4 = shl i64 1, 5 ; <i64> [#uses=0] + %shift.upgrd.5 = zext i8 %shamt to i32 ; <i32> [#uses=1] + %tr1.s = ashr i32 1, %shift.upgrd.5 ; <i32> [#uses=0] + %tr2.s = ashr i32 1, 4 ; <i32> [#uses=0] + %shift.upgrd.6 = zext i8 %shamt to i32 ; <i32> [#uses=1] + %tr1 = lshr i32 1, %shift.upgrd.6 ; <i32> [#uses=0] + %tr2 = lshr i32 1, 5 ; <i32> [#uses=0] + %tr1.l = ashr i64 1, 4 ; <i64> [#uses=0] + %shift.upgrd.7 = zext i8 %shamt to i64 ; <i64> [#uses=1] + %tr2.l = ashr i64 1, %shift.upgrd.7 ; <i64> [#uses=0] + %tr3.l = shl i64 1, 4 ; <i64> [#uses=0] + %shift.upgrd.8 = zext i8 %shamt to i64 ; <i64> [#uses=1] + %tr4.l = shl i64 1, %shift.upgrd.8 ; <i64> [#uses=0] + %tr1.u = lshr i64 1, 5 ; <i64> [#uses=0] + %shift.upgrd.9 = zext i8 %shamt to i64 ; <i64> [#uses=1] + %tr2.u = lshr i64 1, %shift.upgrd.9 ; <i64> [#uses=0] + %tr3.u = shl i64 1, 5 ; <i64> [#uses=0] + %shift.upgrd.10 = zext i8 %shamt to i64 ; <i64> [#uses=1] + %tr4.u = shl i64 1, %shift.upgrd.10 ; <i64> [#uses=0] + ret i32 0 } |