Skip to content

Commit 7b34aee

Browse files
authored
[SYCL][NATIVECPU] Update Native CPU attributes test (#15451)
Removes the check for `__mux_work_group_barrier` since on Native CPU work group barriers are materialized by OCK's WorkItemLoopPass, and since now we correctly remove unused functions from the module, there are no more references to `__mux_work_group_barrier`.
1 parent 65c58c4 commit 7b34aee

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed
Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
// REQUIRES: native_cpu_ock
2-
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu -Xclang -sycl-std=2020 -mllvm -sycl-native-dump-device-ir %s | FileCheck %s
2+
// RUN: %clangxx -fsycl -fsycl-targets=native_cpu -Xclang -sycl-std=2020 -mllvm -sycl-native-dump-device-ir %s &> %t.ll
3+
// RUN: FileCheck %s --input-file %t.ll --check-prefix=CHECK-WG-BARRIER
4+
// RUN: FileCheck %s --input-file %t.ll
35

46
#include "sycl.hpp"
57
using namespace sycl;
@@ -11,17 +13,17 @@ int main() {
1113
deviceQueue.submit([&](handler &h) {
1214
h.parallel_for<Test>(
1315
r, [=](nd_item<2> it) {
14-
it.barrier(access::fence_space::local_space);
15-
//CHECK-DAG: call void @__mux_work_group_barrier({{.*}})
1616
atomic_fence(memory_order::acquire, memory_scope::work_group);
1717
//CHECK-DAG: call void @__mux_mem_barrier({{.*}})
1818
});
1919
});
2020

2121
}
2222

23-
//CHECK-DAG: define{{.*}}@__mux_work_group_barrier{{.*}}#[[ATTR:[0-9]+]]
24-
//CHECK-DAG: [[ATTR]]{{.*}}convergent
23+
// Currently Native CPU uses the WorkItemLoops pass from the oneAPI
24+
// Construction Kit to materialize barriers, so the builtin shouldn't
25+
// be referenced anymore in the module.
26+
// CHECK-WG-BARRIER-NOT: @__mux_work_group_barrier
2527

26-
//CHECK-DAG: define{{.*}}@__mux_mem_barrier{{.*}}#[[ATTR_MEM:[0-9]+]]
27-
//CHECK-DAG: [[ATTR_MEM]]{{.*}}convergent
28+
// CHECK-DAG: define{{.*}}@__mux_mem_barrier{{.*}}#[[ATTR_MEM:[0-9]+]]
29+
// CHECK-DAG: [[ATTR_MEM]]{{.*}}convergent

0 commit comments

Comments
 (0)