Changeset View
Changeset View
Standalone View
Standalone View
intern/cycles/device/opencl/opencl_util.cpp
| Show First 20 Lines • Show All 1,067 Lines • ▼ Show 20 Lines | if(clGetDeviceInfo(device_id, | ||||
| if(length != 0 && board_name[0] != '\0') { | if(length != 0 && board_name[0] != '\0') { | ||||
| return board_name; | return board_name; | ||||
| } | } | ||||
| } | } | ||||
| /* Fallback to standard device name API. */ | /* Fallback to standard device name API. */ | ||||
| return get_device_name(device_id); | return get_device_name(device_id); | ||||
| } | } | ||||
| int OpenCLInfo::mem_address_alignment(cl_device_id device_id) | |||||
brecht: Would rename to `mem_address_alignment`. | |||||
| { | |||||
| int base_align_bits; | |||||
| if(clGetDeviceInfo(device_id, | |||||
| CL_DEVICE_MEM_BASE_ADDR_ALIGN, | |||||
| sizeof(int), | |||||
| &base_align_bits, | |||||
| NULL) == CL_SUCCESS) | |||||
| { | |||||
| return base_align_bits/8; | |||||
| } | |||||
| return 1; | |||||
| } | |||||
| CCL_NAMESPACE_END | CCL_NAMESPACE_END | ||||
| #endif | #endif | ||||
Would rename to mem_address_alignment.