@@ -245,7 +245,7 @@ Error OpenCLDeviceManager::init() {
245245 RETURN_IF_ERR (parseConfig ());
246246
247247 cl_uint numPlatforms{0 };
248- cl_int err = clGetPlatformIDs (0 , NULL , &numPlatforms);
248+ cl_int err = clGetPlatformIDs (0 , nullptr , &numPlatforms);
249249 if (err != CL_SUCCESS) {
250250 return MAKE_ERR (" clGetPlatformIDs Failed." );
251251 }
@@ -255,7 +255,7 @@ Error OpenCLDeviceManager::init() {
255255 }
256256
257257 std::vector<cl_platform_id> platform_ids (numPlatforms);
258- err = clGetPlatformIDs (numPlatforms, platform_ids.data (), NULL );
258+ err = clGetPlatformIDs (numPlatforms, platform_ids.data (), nullptr );
259259
260260 cl_platform_id platform_id_used = platform_ids[clPlatformId];
261261
@@ -270,7 +270,7 @@ Error OpenCLDeviceManager::init() {
270270
271271 cl_ulong mem_size;
272272 err = clGetDeviceInfo (deviceId_, CL_DEVICE_GLOBAL_MEM_SIZE, sizeof (cl_ulong),
273- &mem_size, NULL );
273+ &mem_size, nullptr );
274274 if (err != CL_SUCCESS) {
275275 return MAKE_ERR (" Error getting device memory limit" );
276276 }
@@ -285,14 +285,14 @@ Error OpenCLDeviceManager::init() {
285285 localMemSize_ = 0 ;
286286 cl_device_local_mem_type localMemType;
287287 err = clGetDeviceInfo (deviceId_, CL_DEVICE_LOCAL_MEM_TYPE,
288- sizeof (localMemType), &localMemType, NULL );
288+ sizeof (localMemType), &localMemType, nullptr );
289289 if (err != CL_SUCCESS) {
290290 return MAKE_ERR (" Error getting device local memory type." );
291291 }
292292 if (localMemType == CL_LOCAL) {
293293 cl_ulong localMemSize;
294294 err = clGetDeviceInfo (deviceId_, CL_DEVICE_LOCAL_MEM_SIZE,
295- sizeof (localMemSize), &localMemSize, NULL );
295+ sizeof (localMemSize), &localMemSize, nullptr );
296296 if (err != CL_SUCCESS) {
297297 return MAKE_ERR (" Error getting device local memory type." );
298298 }
@@ -668,7 +668,7 @@ void OpenCLDeviceManager::translateTraceEvents(
668668 auto &event = devBindings->kernelLaunches .back ().event_ ;
669669 cl_ulong time_end;
670670 clGetEventProfilingInfo (event, CL_PROFILING_COMMAND_END, sizeof (time_end),
671- &time_end, NULL );
671+ &time_end, nullptr );
672672
673673 // Get the difference between the last event's end and the tsOffset
674674 // timestamp.
@@ -694,12 +694,12 @@ void OpenCLDeviceManager::translateTraceEvents(
694694
695695 if (clGetEventProfilingInfo (event, CL_PROFILING_COMMAND_START,
696696 sizeof (timeStart), &timeStart,
697- NULL ) != CL_SUCCESS) {
697+ nullptr ) != CL_SUCCESS) {
698698 continue ;
699699 }
700700 if (clGetEventProfilingInfo (event, CL_PROFILING_COMMAND_END,
701701 sizeof (timeEnd), &timeEnd,
702- NULL ) != CL_SUCCESS) {
702+ nullptr ) != CL_SUCCESS) {
703703 continue ;
704704 }
705705
0 commit comments