00001 00014 #ifndef PARFUM_ITERATORS_CUDA_H 00015 #define PARFUM_ITERATORS_CUDA_H 00016 00017 #include "ParFUM_Iterators_Types.h" 00018 00019 00020 #ifdef CUDA 00021 00023 typedef struct { 00024 unsigned node_attr_size; 00025 unsigned elem_attr_size; 00026 unsigned model_attr_size; 00027 00028 unsigned num_local_elem; 00029 unsigned num_local_node; 00030 00032 void *mAttDevice; 00033 void *ElemDataDevice; 00034 void *NodeDataDevice; 00035 int *ElemConnDevice; 00036 int *n2eConnDevice; 00037 } MeshModelDevice; 00038 00039 00040 #define meshElement_D_GetAttrib(m, e) (((char*)(m)->ElemDataDevice) + (e)*(m)->elem_attr_size) 00041 #define meshNode_D_GetAttrib(m, n) (((char*)(m)->NodeDataDevice) + (n)*(m)->node_attr_size) 00042 #define meshElement_D_GetNode(m, e, idx) (((m)->ElemConnDevice)[e*4 + idx]) 00043 00044 #endif 00045 #endif