Skip to content

Commit 0f89803

Browse files
committed
Adds tests for inlining with dotprod
1 parent af3232b commit 0f89803

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
; RUN: opt < %s -mtriple=arm-unknown-linux-gnu -S -passes=inline | FileCheck %s
2+
; RUN: opt < %s -mtriple=arm-unknown-linux-gnu -S -passes='cgscc(inline)' | FileCheck %s
3+
4+
declare i32 @foo(...) #0
5+
6+
define i32 @callee() #0 {
7+
entry:
8+
%call = call i32 (...) @foo()
9+
ret i32 %call
10+
}
11+
12+
define i32 @dotcallee() #1 {
13+
entry:
14+
%call = call i32 (...) @foo()
15+
ret i32 %call
16+
}
17+
18+
define i32 @dotcaller() #1 {
19+
entry:
20+
%call = call i32 @callee()
21+
ret i32 %call
22+
; CHECK-LABEL: dotcaller
23+
; CHECK: call i32 (...) @foo()
24+
}
25+
26+
define i32 @caller() #0 {
27+
entry:
28+
%call = call i32 @dotcallee()
29+
ret i32 %call
30+
; CHECK-LABEL: caller
31+
; CHECK: call i32 @dotcallee()
32+
}
33+
34+
attributes #0 = { "target-cpu"="generic" "target-features"="+dsp,+neon" }
35+
attributes #1 = { "target-cpu"="generic" "target-features"="+dsp,+neon,+dotprod" }

0 commit comments

Comments
 (0)