File tree Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Expand file tree Collapse file tree 2 files changed +5
-6
lines changed Original file line number Diff line number Diff line change 1
- // XFAIL: *
2
1
// RUN: cir-translate -cir-to-llvmir --disable-cc-lowering %s -o %t.ll
3
2
// RUN: FileCheck --input-file=%t.ll %s --check-prefix=LLVM
4
3
@@ -9,13 +8,14 @@ module {
9
8
cir.func private @my_add(%a: !s32i, %b: !s32i) -> !s32i cc(spir_function)
10
9
11
10
cir.func @ind(%fnptr: !fnptr, %a : !s32i) {
12
- %1 = cir.call %fnptr(%a) : (!fnptr, !s32i) -> !s32i cc(spir_kernel)
13
- // LLVM: %{{[0-9]+}} = call spir_kernel i32 %{{[0-9]+}}(i32 %{{[0-9]+}})
11
+ // https://github.com/llvm/clangir/issues/1814
12
+ // %1 = cir.call %fnptr(%a) : (!fnptr, !s32i) -> !s32i cc(spir_kernel)
13
+ // LLVM-DISABLE: %{{[0-9]+}} = call spir_kernel i32 %{{[0-9]+}}(i32 %{{[0-9]+}})
14
14
15
15
%2 = cir.call %fnptr(%a) : (!fnptr, !s32i) -> !s32i cc(spir_function)
16
16
// LLVM: %{{[0-9]+}} = call spir_func i32 %{{[0-9]+}}(i32 %{{[0-9]+}})
17
17
18
- %3 = cir.call @my_add(%1 , %2) : (!s32i, !s32i) -> !s32i cc(spir_function)
18
+ %3 = cir.call @my_add(%2 , %2) : (!s32i, !s32i) -> !s32i cc(spir_function)
19
19
// LLVM: %{{[0-9]+}} = call spir_func i32 @my_add(i32 %{{[0-9]+}}, i32 %{{[0-9]+}})
20
20
21
21
cir.return
Original file line number Diff line number Diff line change 1
1
// RUN: cir-opt %s -cir-to-llvm -o - | FileCheck %s -check-prefix=MLIR
2
2
// RUN: cir-translate %s -cir-to-llvmir --disable-cc-lowering | FileCheck %s -check-prefix=LLVM
3
- // XFAIL: *
4
3
5
4
!s32i = !cir.int<s, 32>
6
5
module {
@@ -116,7 +115,7 @@ module {
116
115
// LLVM: %{{.+}} = call i32 @add(i32 0, i32 1) #[[#pure:]]
117
116
// LLVM: %{{.+}} = call i32 @add(i32 0, i32 1) #[[#const:]]
118
117
// LLVM: }
119
- // LLVM: attributes #[[#pure]] = { nounwind willreturn memory(read) }
118
+ // LLVM: attributes #[[#pure]] = { nounwind willreturn memory(read, errnomem: none ) }
120
119
// LLVM: attributes #[[#const]] = { nounwind willreturn memory(none) }
121
120
122
121
} // end module
You can’t perform that action at this time.
0 commit comments