blob: a1b31ec464d5c0dc40a63da3e8ec2803a194f953 [file] [log] [blame]
Dan Gohmanf17a25c2007-07-18 16:29:46 +00001; RUN: llvm-upgrade < %s | llvm-as | llc -march=arm | \
Dan Gohman8c89a502007-08-15 13:36:28 +00002; RUN: grep {ldr.*\\\[.*\],} | count 1
Dan Gohmanf17a25c2007-07-18 16:29:46 +00003
4int %test(int %a, int %b, int %c) {
5 %tmp1 = mul int %a, %b
6 %tmp2 = cast int %tmp1 to int*
7 %tmp3 = load int* %tmp2
8 %tmp4 = sub int %tmp1, %c
9 %tmp5 = mul int %tmp4, %tmp3
10 ret int %tmp5
11}