You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

22 lines
416 B

; RUN: llc -march=hexagon < %s | FileCheck %s
define i32 @foo(i32 %a, i32 %b) nounwind readnone {
; CHECK: lsl
; CHECK: aslh
entry:
%shl1 = shl i32 16, %a
%shl2 = shl i32 %b, 16
%ret = mul i32 %shl1, %shl2
ret i32 %ret
}
define i32 @bar(i32 %a, i32 %b) nounwind readnone {
; CHECK: asrh
; CHECK: lsr
entry:
%shl1 = ashr i32 16, %a
%shl2 = ashr i32 %b, 16
%ret = mul i32 %shl1, %shl2
ret i32 %ret
}