1 /*========================== begin_copyright_notice ============================
2 
3 Copyright (C) 2021 Intel Corporation
4 
5 SPDX-License-Identifier: MIT
6 
7 ============================= end_copyright_notice ===========================*/
8 
9 #ifndef CM_CL_DEFINE_H
10 #define CM_CL_DEFINE_H
11 
12 #define CM_INLINE __attribute__((always_inline))
13 #define CM_NOINLINE __attribute__((noinline))
14 #define CM_NODEBUG __attribute__((nodebug))
15 #define _CM_BUILTIN_ __declspec(cm_builtin)
16 
17 namespace cm {
18 namespace atomic {
19 
20 enum class operation {
21   add = 0x0,
22   sub = 0x1,
23   min = 0x2,
24   max = 0x3,
25   xchg = 0x4,
26   andl = 0x5,
27   orl = 0x6,
28   xorl = 0x7,
29   minsint = 0x8,
30   maxsint = 0x9,
31   load = 0xA,
32   store = 0xB,
33   cmpxchg = 0xC
34 };
35 
36 } // namespace atomic
37 } // namespace cm
38 
39 #endif // CM_CL_DEFINE_H
40