본문 바로가기
반응형

Program Language/OpenCL19

OpenCL Address Spaces Address Sapce 종류 __global Global memory Stores data for the entire device and can be read from and writen to 디바이스내의 모든 커널들이 공유할 수 있다.매우 느리다.사용을 최소화 하자.GPU에선 GPU DRAM에 위치한다. __constant Constant memory Similar to global memory, but is read-only __global메모리와 같다.다만, 쓰기가 불가능하다.플랫폼마다 다를 수 있는데, constant메모리 캐시가 있어 global메모리보다는 빠른듯 하다.읽기만 가능하기 때문에 동기화가 필요없다(불가능 하다.) __local Local memory Stores data for t.. 2012. 6. 2.
clFinish, clFlush, block cl_int clFinish (cl_command_queue command_queue) Blocks until all previously queued OpenCL commands in a command-queue are issued to the associated device and have completed. NotesBlocks until all previously queued OpenCL commands in command_queue are issued to the associated device and have completed.clFinish does not return until all queued commands in command_queue have been processed and com.. 2012. 5. 26.
clEnqueueCopyBufferRect vs clEnqueueWriteBufferRect cl_int clEnqueueCopyBufferRect (cl_command_queue command_queue, cl_mem src_buffer, cl_mem dst_buffer, const size_t src_origin[3], const size_t dst_origin[3], const size_t region[3], size_t src_row_pitch, size_t src_slice_pitch, size_t dst_row_pitch, size_t dst_slice_pitch, cl_uint num_events_in_wait_list, const cl_event *event_wait_list, cl_event *event) cl_int clEnqueueWriteBufferRect (cl_comma.. 2012. 5. 22.