source: icGREP/icgrep-devel/llvm-3.8.0.src/test/CodeGen/Hexagon/ashift-left-right.ll @ 5027

Last change on this file since 5027 was 5027, checked in by cameron, 3 years ago

Upgrade to llvm 3.8

File size: 416 bytes
Line 
1; RUN: llc -march=hexagon < %s | FileCheck %s
2
3define i32 @foo(i32 %a, i32 %b) nounwind readnone {
4; CHECK: lsl
5; CHECK: aslh
6entry:
7  %shl1 = shl i32 16, %a
8  %shl2 = shl i32 %b, 16
9  %ret = mul i32 %shl1, %shl2
10  ret i32 %ret
11}
12
13define i32 @bar(i32 %a, i32 %b) nounwind readnone {
14; CHECK: asrh
15; CHECK: lsr
16entry:
17  %shl1 = ashr i32 16, %a
18  %shl2 = ashr i32 %b, 16
19  %ret = mul i32 %shl1, %shl2
20  ret i32 %ret
21}
Note: See TracBrowser for help on using the repository browser.