From f17a25c88b892d30c2b41ba7ecdfbdfb2b4be9cc Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Wed, 18 Jul 2007 16:29:46 +0000 Subject: It's not necessary to do rounding for alloca operations when the requested alignment is equal to the stack alignment. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40004 91177308-0d34-0410-b5e6-96231b3b80d8 --- test/ExecutionEngine/test-arith.ll | 38 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 test/ExecutionEngine/test-arith.ll (limited to 'test/ExecutionEngine/test-arith.ll') diff --git a/test/ExecutionEngine/test-arith.ll b/test/ExecutionEngine/test-arith.ll new file mode 100644 index 0000000..49d85af --- /dev/null +++ b/test/ExecutionEngine/test-arith.ll @@ -0,0 +1,38 @@ +; RUN: llvm-upgrade %s | llvm-as -f -o %t.bc +; RUN: lli %t.bc > /dev/null + +int %main() { + %A = add sbyte 0, 12 + %B = sub sbyte %A, 1 + %C = mul sbyte %B, %B + %D = div sbyte %C, %C + %E = rem sbyte %D, %D + %F = div ubyte 5, 6 + %G = rem ubyte 6, 5 + + %A = add short 0, 12 + %B = sub short %A, 1 + %C = mul short %B, %B + %D = div short %C, %C + %E = rem short %D, %D + %F = div ushort 5, 6 + %G = rem uint 6, 5 + + %A = add int 0, 12 + %B = sub int %A, 1 + %C = mul int %B, %B + %D = div int %C, %C + %E = rem int %D, %D + %F = div uint 5, 6 + %G1 = rem uint 6, 5 + + %A = add long 0, 12 + %B = sub long %A, 1 + %C = mul long %B, %B + %D = div long %C, %C + %E = rem long %D, %D + %F = div ulong 5, 6 + %G = rem ulong 6, 5 + + ret int 0 +} -- cgit v1.1