Skip to content

Commit 55df793

Browse files
committed
[SYCL] Make Kernel1 Constructor Public
Signed-off-by: Hu, Peisen <[email protected]>
1 parent e1f532c commit 55df793

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

sycl/test-e2e/GroupAlgorithm/root_group.cpp

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,8 @@ void testQueriesAndProperties() {
6262

6363
template <typename T> class TestKernel1 {
6464
T *m_data;
65+
66+
public:
6567
TestKernel1(T *data) : m_data(data) {}
6668
void operator()(sycl::nd_item<1> it) const {
6769
volatile float X = 1.0f;
@@ -113,6 +115,9 @@ void testRootGroup() {
113115

114116
template <typename T> class TestKernel2 {
115117
T *m_testResults;
118+
119+
public:
120+
TestKernel2(T *testResults) : m_testResults(testResults) {}
116121
void operator()(sycl::nd_item<1> it) const {
117122
const auto root = it.ext_oneapi_get_root_group();
118123
if (root.leader() || root.get_local_id() == 3) {
@@ -134,9 +139,6 @@ template <typename T> class TestKernel2 {
134139
return sycl::ext::oneapi::experimental::properties{
135140
sycl::ext::oneapi::experimental::use_root_sync};
136141
}
137-
138-
public:
139-
TestKernel2(T *testResults) : m_testResults(testResults) {}
140142
};
141143

142144
void testRootGroupFunctions() {

0 commit comments

Comments
 (0)