44 #define KERNEL_STRUCT_BEGIN(name) struct {
45 #define KERNEL_STRUCT_MEMBER(parent_struct, type, name, feature) type name;
46 #define KERNEL_STRUCT_ARRAY_MEMBER KERNEL_STRUCT_MEMBER
47 #define KERNEL_STRUCT_END(name) \
50 #define KERNEL_STRUCT_END_ARRAY(name, cpu_size, gpu_size) \
53 #define KERNEL_STRUCT_VOLUME_STACK_SIZE MAX_VOLUME_STACK_SIZE
55 #undef KERNEL_STRUCT_BEGIN
56 #undef KERNEL_STRUCT_MEMBER
57 #undef KERNEL_STRUCT_ARRAY_MEMBER
58 #undef KERNEL_STRUCT_END
59 #undef KERNEL_STRUCT_END_ARRAY
63 #define KERNEL_STRUCT_BEGIN(name) struct {
64 #define KERNEL_STRUCT_MEMBER(parent_struct, type, name, feature) type name;
65 #define KERNEL_STRUCT_ARRAY_MEMBER KERNEL_STRUCT_MEMBER
66 #define KERNEL_STRUCT_END(name) \
69 #define KERNEL_STRUCT_END_ARRAY(name, cpu_size, gpu_size) \
72 #define KERNEL_STRUCT_VOLUME_STACK_SIZE MAX_VOLUME_STACK_SIZE
74 #undef KERNEL_STRUCT_BEGIN
75 #undef KERNEL_STRUCT_MEMBER
76 #undef KERNEL_STRUCT_ARRAY_MEMBER
77 #undef KERNEL_STRUCT_END
78 #undef KERNEL_STRUCT_END_ARRAY
79 #undef KERNEL_STRUCT_VOLUME_STACK_SIZE
97 #define KERNEL_STRUCT_BEGIN(name) struct {
98 #define KERNEL_STRUCT_MEMBER(parent_struct, type, name, feature) ccl_global type *name;
99 #define KERNEL_STRUCT_ARRAY_MEMBER KERNEL_STRUCT_MEMBER
100 #define KERNEL_STRUCT_END(name) \
103 #define KERNEL_STRUCT_END_ARRAY(name, cpu_size, gpu_size) \
106 #define KERNEL_STRUCT_VOLUME_STACK_SIZE MAX_VOLUME_STACK_SIZE
112 #undef KERNEL_STRUCT_BEGIN
113 #undef KERNEL_STRUCT_MEMBER
114 #undef KERNEL_STRUCT_ARRAY_MEMBER
115 #undef KERNEL_STRUCT_END
116 #undef KERNEL_STRUCT_END_ARRAY
117 #undef KERNEL_STRUCT_VOLUME_STACK_SIZE
143 #ifndef __KERNEL_GPU__
152 # define INTEGRATOR_STATE_NULL nullptr
154 # define INTEGRATOR_STATE(state, nested_struct, member) ((state)->nested_struct.member)
155 # define INTEGRATOR_STATE_WRITE(state, nested_struct, member) ((state)->nested_struct.member)
157 # define INTEGRATOR_STATE_ARRAY(state, nested_struct, array_index, member) \
158 ((state)->nested_struct[array_index].member)
159 # define INTEGRATOR_STATE_ARRAY_WRITE(state, nested_struct, array_index, member) \
160 ((state)->nested_struct[array_index].member)
171 # define INTEGRATOR_STATE_NULL -1
173 # define INTEGRATOR_STATE(state, nested_struct, member) \
174 kernel_integrator_state.nested_struct.member[state]
175 # define INTEGRATOR_STATE_WRITE(state, nested_struct, member) \
176 INTEGRATOR_STATE(state, nested_struct, member)
178 # define INTEGRATOR_STATE_ARRAY(state, nested_struct, array_index, member) \
179 kernel_integrator_state.nested_struct[array_index].member[state]
180 # define INTEGRATOR_STATE_ARRAY_WRITE(state, nested_struct, array_index, member) \
181 INTEGRATOR_STATE_ARRAY(state, nested_struct, array_index, member)
#define CCL_NAMESPACE_END
@ DEVICE_KERNEL_INTEGRATOR_NUM
const IntegratorShadowStateCPU *ccl_restrict ConstIntegratorShadowState
CCL_NAMESPACE_BEGIN struct IntegratorShadowStateCPU IntegratorShadowStateCPU
struct IntegratorQueueCounter IntegratorQueueCounter
struct IntegratorStateGPU IntegratorStateGPU
IntegratorStateCPU *ccl_restrict IntegratorState
const IntegratorStateCPU *ccl_restrict ConstIntegratorState
IntegratorShadowStateCPU *ccl_restrict IntegratorShadowState
struct IntegratorStateCPU IntegratorStateCPU
int num_queued[DEVICE_KERNEL_INTEGRATOR_NUM]
IntegratorShadowStateCPU shadow
IntegratorShadowStateCPU ao
ccl_global IntegratorQueueCounter * queue_counter
ccl_global int * next_shadow_path_index
ccl_global int * next_main_path_index
ccl_global int * sort_key_counter[DEVICE_KERNEL_INTEGRATOR_NUM]
uint sort_partition_divisor