Skip to content

Commit 400e1e6

Browse files
authored
[SYCL][LIT] Mark spec const LIT as pass (#1875)
The spec_const LIT tests start to pass for Intel CPU and GPU devices with the Intel OpenCL GPU driver 20.19.16754. Duplicate the test for accelerators, e.g., FPGA, and only fail it for these. As a result regressions are now caught for OpenCL CPU and GPU devices. Fixes #1873 Signed-off-by: Bjoern Knafla <[email protected]>
1 parent e5ea144 commit 400e1e6

File tree

4 files changed

+42
-12
lines changed

4 files changed

+42
-12
lines changed

sycl/test/spec_const/spec_const_hw.cpp

+3-6
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
1-
// RUN: %clangxx -fsycl %s -o %t.out
1+
// UNSUPPORTED: cuda || level0
2+
//
3+
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
24
// RUN: env SYCL_DEVICE_TYPE=HOST %t.out
35
// RUN: %CPU_RUN_PLACEHOLDER %t.out
46
// RUN: %GPU_RUN_PLACEHOLDER %t.out
5-
// RUN: %ACC_RUN_PLACEHOLDER %t.out
6-
// TODO: re-enable after CI drivers are updated to newer which support spec
7-
// constants:
8-
// XFAIL: linux && opencl
9-
// UNSUPPORTED: cuda || level0
107
//
118
//==----------- spec_const_hw.cpp ------------------------------------------==//
129
//
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
//==----------- spec_const_hw_accelerator.cpp ------------------------------==//
2+
//
3+
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+
// See https://llvm.org/LICENSE.txt for license information.
5+
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+
//
7+
//===----------------------------------------------------------------------===//
8+
// The test checks that the specialization constant feature works correctly -
9+
// tool chain processes them correctly and runtime can correctly execute the
10+
// program.
11+
12+
// TODO: re-enable after CI drivers are updated to newer which support spec
13+
// constants:
14+
// XFAIL: linux && opencl && accelerator
15+
// UNSUPPORTED: cuda || level0
16+
#include "spec_const_hw.cpp"
17+
// RUN: %ACC_RUN_PLACEHOLDER %t.out

sycl/test/spec_const/spec_const_redefine.cpp

+3-6
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
1-
// RUN: %clangxx -fsycl %s -o %t.out
1+
// UNSUPPORTED: cuda || level0
2+
//
3+
// RUN: %clangxx -fsycl -fsycl-targets=%sycl_triple %s -o %t.out
24
// RUN: env SYCL_DEVICE_TYPE=HOST %t.out
35
// RUN: env SYCL_PI_TRACE=2 %CPU_RUN_PLACEHOLDER %t.out 2>&1 %CPU_CHECK_PLACEHOLDER
46
// RUN: env SYCL_PI_TRACE=2 %GPU_RUN_PLACEHOLDER %t.out 2>&1 %GPU_CHECK_PLACEHOLDER
5-
// RUN: env SYCL_PI_TRACE=2 %ACC_RUN_PLACEHOLDER %t.out 2>&1 %ACC_CHECK_PLACEHOLDER
6-
// TODO: re-enable after CI drivers are updated to newer which support spec
7-
// constants:
8-
// XFAIL: linux && opencl
9-
// UNSUPPORTED: cuda || level0
107
//
118
//==----------- spec_const_redefine.cpp ------------------------------------==//
129
//
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
//==----------- spec_const_redefine.cpp ------------------------------------==//
2+
//
3+
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4+
// See https://llvm.org/LICENSE.txt for license information.
5+
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6+
//
7+
//===----------------------------------------------------------------------===//
8+
// The test checks that:
9+
// - a specialization constant can be redifined and correct new value is used
10+
// after redefinition.
11+
// - the program is JITted only once per a unique set of specialization
12+
// constants values.
13+
14+
// TODO: re-enable after CI drivers are updated to newer which support spec
15+
// constants:
16+
// XFAIL: linux && opencl && accelerator
17+
// UNSUPPORTED: cuda || level0
18+
#include "spec_const_redefine_accelerator.cpp"
19+
// RUN: env SYCL_PI_TRACE=2 %ACC_RUN_PLACEHOLDER %t.out 2>&1 %ACC_CHECK_PLACEHOLDER

0 commit comments

Comments
 (0)