File tree Expand file tree Collapse file tree 1 file changed +19
-10
lines changed
Expand file tree Collapse file tree 1 file changed +19
-10
lines changed Original file line number Diff line number Diff line change 55
66using namespace kernel_launcher ;
77
8+ struct point3 {
9+ unsigned long long x;
10+ unsigned long long y;
11+ unsigned long long z;
12+
13+ bool operator ==(point3 v) const {
14+ return x == v.x && y == v.y && z == v.z ;
15+ }
16+ };
17+
18+ namespace kernel_launcher {
19+ template <>
20+ struct IntoKernelArg <point3> {
21+ static KernelArg convert (point3 value) {
22+ return KernelArg::for_scalar<point3>(value);
23+ }
24+ };
25+ } // namespace kernel_launcher
26+
827TEST_CASE (" test load_best_config" ) {
928 std::string wisdom_dir = __FILE__;
1029 wisdom_dir = wisdom_dir.substr (0 , wisdom_dir.rfind (' /' ));
@@ -114,16 +133,6 @@ TEST_CASE("test KernelArg") {
114133 }
115134
116135 SECTION (" scalar point3" ) {
117- struct point3 {
118- unsigned long long x;
119- unsigned long long y;
120- unsigned long long z;
121-
122- bool operator ==(point3 v) const {
123- return x == v.x && y == v.y && z == v.z ;
124- }
125- };
126-
127136 point3 input = {1 , 2 , 3 };
128137
129138 KernelArg v = into_kernel_arg (input);
You can’t perform that action at this time.
0 commit comments