xref: /aosp_15_r20/external/llvm/test/Bindings/llvm-c/calc.test (revision 9880d6810fe72a1726cb53787c6711e909410d58)
1*9880d681SAndroid Build Coastguard Worker; RUN: llvm-c-test --calc <%s | FileCheck %s
2*9880d681SAndroid Build Coastguard Worker
3*9880d681SAndroid Build Coastguard Worker; constant folding
4*9880d681SAndroid Build Coastguard Workertest 100 200 +
5*9880d681SAndroid Build Coastguard Worker;CHECK: ModuleID = 'test'
6*9880d681SAndroid Build Coastguard Worker;CHECK: define i64 @test
7*9880d681SAndroid Build Coastguard Worker;CHECK: {
8*9880d681SAndroid Build Coastguard Worker;CHECK: ret i64 300
9*9880d681SAndroid Build Coastguard Worker;CHECK: }
10*9880d681SAndroid Build Coastguard Worker
11*9880d681SAndroid Build Coastguard Workerarg1 0 @ 0 @ * 1 @ 1 @ * +
12*9880d681SAndroid Build Coastguard Worker;CHECK: ModuleID = 'arg1'
13*9880d681SAndroid Build Coastguard Worker;CHECK: getelementptr
14*9880d681SAndroid Build Coastguard Worker;CHECK: load
15*9880d681SAndroid Build Coastguard Worker;CHECK: ret
16