We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8600d54 commit e13afe9Copy full SHA for e13afe9
src/example6.cpp
@@ -10,12 +10,10 @@ namespace mhp = dr::mhp;
10
using T = uint16_t;
11
using MDA = dr::mhp::distributed_mdarray<T, 2>;
12
13
+/* 2D pattern search in a distributed multidimensional (2D) array */
14
int main() {
-#ifdef SYCL_LANGUAGE_VERSION
15
mhp::init(sycl::default_selector_v);
16
-#else
17
- mhp::init();
18
-#endif
+
19
std::size_t arr_size = 7;
20
const std::size_t pattern_size = 2;
21
const std::size_t radius = pattern_size - 1;
@@ -42,7 +40,7 @@ int main() {
42
40
pattern[0][1] == a_submdspan(0, 1) &&
43
41
pattern[1][0] == a_submdspan(1, 0) &&
44
pattern[1][1] == a_submdspan(1, 1)) {
45
- occurrences(0, 0)++;
+ occurrences(0, 0) = 1;
46
}
47
};
48
0 commit comments