mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-12-30 17:33:24 +00:00
5b9fcd1c8e
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74889 91177308-0d34-0410-b5e6-96231b3b80d8
11 lines
411 B
LLVM
11 lines
411 B
LLVM
; RUN: llvm-as < %s | llc -march=thumb -mattr=+thumb2 | \
|
|
; RUN: grep smlabt | count 1
|
|
|
|
define i32 @f3(i32 %a, i16 %x, i32 %y) {
|
|
%tmp = sext i16 %x to i32 ; <i32> [#uses=1]
|
|
%tmp2 = ashr i32 %y, 16 ; <i32> [#uses=1]
|
|
%tmp3 = mul i32 %tmp2, %tmp ; <i32> [#uses=1]
|
|
%tmp5 = add i32 %tmp3, %a ; <i32> [#uses=1]
|
|
ret i32 %tmp5
|
|
}
|