Skip to content

Commit a1a8876

Browse files
[SYCLomatic] Add macro document in the dpct.hpp (#2631)
Signed-off-by: Jiang, Zhiwei <zhiwei.jiang@intel.com> Co-authored-by: Wang, Zhiming <zhiming.wang@intel.com>
1 parent 5d3b1e2 commit a1a8876

File tree

1 file changed

+31
-0
lines changed
  • clang/runtime/dpct-rt/include/dpct

1 file changed

+31
-0
lines changed

clang/runtime/dpct-rt/include/dpct/dpct.hpp

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,37 @@
66
//
77
//===----------------------------------------------------------------------===//
88

9+
// clang-format off
10+
/*
11+
There are 3 macros that can be used to control the behavior of the helper
12+
function files.
13+
+========================+=========================+===========================+
14+
| | Helper function files | Helper function files |
15+
| Macro Name | Used in dpct migrated | Used in direct |
16+
| | code | programming |
17+
+========================+=========================+===========================+
18+
| DPCT_USM_LEVEL_NONE | USM by default. | USM by default. |
19+
| (Use USM or SYCL | Use SYCL Buffer by | Define it explicitly to |
20+
| buffer) | running dpct with | use the SYCL buffer. |
21+
| | "--use-level=none". | |
22+
+------------------------+-------------------------+---------------------------+
23+
| DPCT_PROFILING_ENABLED | Enabled heuristically | Disable by default. |
24+
| (Enable SYCL queue | depends on the input | Define it explicitly to |
25+
| profiling) | code. | enable. |
26+
| | Enable explicitly by | |
27+
| | running dpct with | |
28+
| | "--enable-profiling". | |
29+
| | Disable by removing the | |
30+
| | macro definition | |
31+
| | manually. | |
32+
+------------------------+-------------------------+---------------------------+
33+
| DPCT_HELPER_VERBOSE | Disable by default. | Disable by default. |
34+
| (Verbose option) | Define it explicitly to | Define it explicitly to |
35+
| | enable. | enable. |
36+
+========================+=========================+===========================+
37+
*/
38+
// clang-format on
39+
940
#ifndef __DPCT_HPP__
1041
#define __DPCT_HPP__
1142

0 commit comments

Comments
 (0)