aboutsummaryrefslogtreecommitdiffstats
path: root/test/ExecutionEngine/OrcLazy/trivial_retval_1.ll
blob: 701f22cd390090ff2d242252e7469528d0df1093 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
; RUN: sh -c 'lli -jit-kind=orc-lazy %s; echo $?' | FileCheck %s
; CHECK: {{^30$}}
define i32 @baz() {
entry:
  ret i32 2
}

define i32 @bar() {
entry:
  %call = call i32 @baz()
  %mul = mul nsw i32 3, %call
  ret i32 %mul
}

define i32 @foo() {
entry:
  %call = call i32 @bar()
  %mul = mul nsw i32 5, %call
  ret i32 %mul
}

define i32 @main(i32 %argc, i8** %argv) {
entry:
  %call = call i32 @foo()
  ret i32 %call
}