Skip to content
This repository was archived by the owner on Mar 28, 2023. It is now read-only.

Commit 5ade206

Browse files
author
Steffen Larsen
committed
[SYCL][CUDA] Unoptimized stream regression test
Previously the CUDA backend would fail due to invalid atomic memory orders not being optimized out. The use of these invalid memory orders have been removed in recent changes, so this commit adds a regression test to make sure they do not resurface. Signed-off-by: Steffen Larsen <[email protected]>
1 parent e15ad21 commit 5ade206

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -O0 -o %t.out
2+
// RUN: %HOST_RUN_PLACEHOLDER %t.out
3+
// RUN: %CPU_RUN_PLACEHOLDER %t.out
4+
// RUN: %GPU_RUN_PLACEHOLDER %t.out
5+
6+
#include <sycl/sycl.hpp>
7+
8+
int main() {
9+
sycl::queue q;
10+
q.submit([&](sycl::handler &cgh) {
11+
sycl::stream os(1024, 256, cgh);
12+
cgh.single_task([=]() { os << "test"; });
13+
});
14+
return 0;
15+
}

0 commit comments

Comments
 (0)