Lines Matching refs:error
162 int error; in test_large_single_compile() local
190 error = create_single_kernel_helper_create_program(context, &program, numLines, lines); in test_large_single_compile()
191 if( program == NULL || error != CL_SUCCESS ) in test_large_single_compile()
193 …ng test program with %d lines! (%s in %s:%d)", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_single_compile()
197 error = clReleaseProgram( program ); in test_large_single_compile()
198 test_error( error, "Unable to release a program object" ); in test_large_single_compile()
204 error = clBuildProgram( program, 1, &deviceID, NULL, NULL, NULL ); in test_large_single_compile()
205 test_error( error, "Unable to build a long program" ); in test_large_single_compile()
208 error = clReleaseProgram( program ); in test_large_single_compile()
209 test_error( error, "Unable to release a program object" ); in test_large_single_compile()
260 int error; in test_large_multi_file_library() local
297 error = create_single_kernel_helper_create_program(context, &program, 2 * numLines + 2, lines); in test_large_multi_file_library()
298 if( program == NULL || error != CL_SUCCESS ) in test_large_multi_file_library()
300 …est program with %d lines! (%s) (in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_multi_file_library()
310 error = clReleaseProgram( program ); in test_large_multi_file_library()
311 test_error( error, "Unable to release program object" ); in test_large_multi_file_library()
318 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_large_multi_file_library()
319 test_error( error, "Unable to compile a simple program" ); in test_large_multi_file_library()
326 simple_kernels[i] = clCreateProgramWithSource( context, 1, &kernel_source, NULL, &error ); in test_large_multi_file_library()
327 if( simple_kernels[i] == NULL || error != CL_SUCCESS ) in test_large_multi_file_library()
329 …est program with %d lines! (%s) (in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_multi_file_library()
334 error = clCompileProgram(simple_kernels[i], 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_large_multi_file_library()
335 test_error( error, "Unable to compile a simple program" ); in test_large_multi_file_library()
341 …inkProgram(context, 1, &deviceID, "-create-library", numLines, simple_kernels, NULL, NULL, &error); in test_large_multi_file_library()
342 test_error( error, "Unable to create a multi-line library" ); in test_large_multi_file_library()
346 …newly_linked_program = clLinkProgram(context, 1, &deviceID, NULL, 2, programs, NULL, NULL, &error); in test_large_multi_file_library()
347 test_error( error, "Unable to link a program with a library" ); in test_large_multi_file_library()
350 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CompositeKernel", &error); in test_large_multi_file_library()
351 test_error( error, "Unable to create a composite kernel" ); in test_large_multi_file_library()
354 error = verifyCopyBuffer(context, queue, kernel); in test_large_multi_file_library()
355 if (error != CL_SUCCESS) in test_large_multi_file_library()
356 return error; in test_large_multi_file_library()
359 error = clReleaseProgram( program ); in test_large_multi_file_library()
360 test_error( error, "Unable to release program object" ); in test_large_multi_file_library()
371 error = clReleaseProgram( simple_kernels[i] ); in test_large_multi_file_library()
372 test_error( error, "Unable to release program object" ); in test_large_multi_file_library()
376 error = clReleaseKernel( kernel ); in test_large_multi_file_library()
377 test_error( error, "Unable to release kernel object" ); in test_large_multi_file_library()
379 error = clReleaseProgram( my_newly_minted_library ); in test_large_multi_file_library()
380 test_error( error, "Unable to release program object" ); in test_large_multi_file_library()
382 error = clReleaseProgram( my_newly_linked_program ); in test_large_multi_file_library()
383 test_error( error, "Unable to release program object" ); in test_large_multi_file_library()
426 int error; in test_large_multiple_embedded_headers() local
466 error = create_single_kernel_helper_create_program(context, &headers[i], 1, &line); in test_large_multiple_embedded_headers()
467 if( headers[i] == NULL || error != CL_SUCCESS ) in test_large_multiple_embedded_headers()
469 …ble to create a simple header program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_large_multiple_embedded_headers()
485 error = create_single_kernel_helper_create_program(context, &program, 2 * numLines + 2, lines); in test_large_multiple_embedded_headers()
486 if( program == NULL || error != CL_SUCCESS ) in test_large_multiple_embedded_headers()
488 …est program with %d lines! (%s) (in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_multiple_embedded_headers()
493 …error = clCompileProgram(program, 1, &deviceID, NULL, numLines, headers, header_names, NULL, NULL); in test_large_multiple_embedded_headers()
494 test_error( error, "Unable to compile a simple program" ); in test_large_multiple_embedded_headers()
501 …error = create_single_kernel_helper_create_program(context, &simple_kernels[i], 1, &kernel_source); in test_large_multiple_embedded_headers()
502 if( simple_kernels[i] == NULL || error != CL_SUCCESS ) in test_large_multiple_embedded_headers()
504 …est program with %d lines! (%s) (in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_multiple_embedded_headers()
509 error = clCompileProgram(simple_kernels[i], 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_large_multiple_embedded_headers()
510 test_error( error, "Unable to compile a simple program" ); in test_large_multiple_embedded_headers()
516 …inkProgram(context, 1, &deviceID, "-create-library", numLines, simple_kernels, NULL, NULL, &error); in test_large_multiple_embedded_headers()
517 test_error( error, "Unable to create a multi-line library" ); in test_large_multiple_embedded_headers()
521 …newly_linked_program = clLinkProgram(context, 1, &deviceID, NULL, 2, programs, NULL, NULL, &error); in test_large_multiple_embedded_headers()
522 test_error( error, "Unable to link a program with a library" ); in test_large_multiple_embedded_headers()
525 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CompositeKernel", &error); in test_large_multiple_embedded_headers()
526 test_error( error, "Unable to create a composite kernel" ); in test_large_multiple_embedded_headers()
529 error = verifyCopyBuffer(context, queue, kernel); in test_large_multiple_embedded_headers()
530 if (error != CL_SUCCESS) in test_large_multiple_embedded_headers()
531 return error; in test_large_multiple_embedded_headers()
534 error = clReleaseProgram( program ); in test_large_multiple_embedded_headers()
535 test_error( error, "Unable to release program object" ); in test_large_multiple_embedded_headers()
551 error = clReleaseProgram( simple_kernels[i] ); in test_large_multiple_embedded_headers()
552 test_error( error, "Unable to release program object" ); in test_large_multiple_embedded_headers()
553 error = clReleaseProgram( headers[i] ); in test_large_multiple_embedded_headers()
554 test_error( error, "Unable to release header program object" ); in test_large_multiple_embedded_headers()
559 error = clReleaseKernel( kernel ); in test_large_multiple_embedded_headers()
560 test_error( error, "Unable to release kernel object" ); in test_large_multiple_embedded_headers()
562 error = clReleaseProgram( my_newly_minted_library ); in test_large_multiple_embedded_headers()
563 test_error( error, "Unable to release program object" ); in test_large_multiple_embedded_headers()
565 error = clReleaseProgram( my_newly_linked_program ); in test_large_multiple_embedded_headers()
566 test_error( error, "Unable to release program object" ); in test_large_multiple_embedded_headers()
614 int error; in test_large_multiple_libraries() local
660 …error = create_single_kernel_helper_create_program(context, &my_program_and_libraries[0], 2 * numL… in test_large_multiple_libraries()
661 if( my_program_and_libraries[0] == NULL || error != CL_SUCCESS ) in test_large_multiple_libraries()
663 … test program with %d lines! (%s in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_multiple_libraries()
668 …error = clCompileProgram(my_program_and_libraries[0], 1, &deviceID, NULL, 0, NULL, NULL, NULL, NUL… in test_large_multiple_libraries()
669 test_error( error, "Unable to compile a simple program" ); in test_large_multiple_libraries()
676 …error = create_single_kernel_helper_create_program(context, &simple_kernels[i], 1, &kernel_source); in test_large_multiple_libraries()
677 if( simple_kernels[i] == NULL || error != CL_SUCCESS ) in test_large_multiple_libraries()
679 … test program with %d lines! (%s in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_multiple_libraries()
684 error = clCompileProgram(simple_kernels[i], 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_large_multiple_libraries()
685 test_error( error, "Unable to compile a simple program" ); in test_large_multiple_libraries()
692 …, &deviceID, "-create-library", numFilesInLib, simple_kernels+i*numFilesInLib, NULL, NULL, &error); in test_large_multiple_libraries()
693 test_error( error, "Unable to create a multi-line library" ); in test_large_multiple_libraries()
697 …Program(context, 1, &deviceID, NULL, numLibraries+1, my_program_and_libraries, NULL, NULL, &error); in test_large_multiple_libraries()
698 test_error( error, "Unable to link a program with a library" ); in test_large_multiple_libraries()
701 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CompositeKernel", &error); in test_large_multiple_libraries()
702 test_error( error, "Unable to create a composite kernel" ); in test_large_multiple_libraries()
705 error = verifyCopyBuffer(context, queue, kernel); in test_large_multiple_libraries()
706 if (error != CL_SUCCESS) in test_large_multiple_libraries()
707 return error; in test_large_multiple_libraries()
711 error = clReleaseProgram( my_program_and_libraries[i] ); in test_large_multiple_libraries()
712 test_error( error, "Unable to release program object" ); in test_large_multiple_libraries()
727 error = clReleaseProgram( simple_kernels[i] ); in test_large_multiple_libraries()
728 test_error( error, "Unable to release program object" ); in test_large_multiple_libraries()
732 error = clReleaseKernel( kernel ); in test_large_multiple_libraries()
733 test_error( error, "Unable to release kernel object" ); in test_large_multiple_libraries()
735 error = clReleaseProgram( my_newly_linked_program ); in test_large_multiple_libraries()
736 test_error( error, "Unable to release program object" ); in test_large_multiple_libraries()
779 int error; in test_large_multiple_files_multiple_libraries() local
824 …error = create_single_kernel_helper_create_program(context, &my_programs_and_libraries[0], 2 * num… in test_large_multiple_files_multiple_libraries()
825 if( my_programs_and_libraries[0] == NULL || error != CL_SUCCESS ) in test_large_multiple_files_multiple_libraries()
827 … test program with %d lines! (%s in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_multiple_files_multiple_libraries()
832 …error = clCompileProgram(my_programs_and_libraries[0], 1, &deviceID, NULL, 0, NULL, NULL, NULL, NU… in test_large_multiple_files_multiple_libraries()
833 test_error( error, "Unable to compile a simple program" ); in test_large_multiple_files_multiple_libraries()
840 …error = create_single_kernel_helper_create_program(context, &simple_kernels[i], 1, &kernel_source); in test_large_multiple_files_multiple_libraries()
841 if( simple_kernels[i] == NULL || error != CL_SUCCESS ) in test_large_multiple_files_multiple_libraries()
843 … test program with %d lines! (%s in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_multiple_files_multiple_libraries()
848 error = clCompileProgram(simple_kernels[i], 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_large_multiple_files_multiple_libraries()
849 test_error( error, "Unable to compile a simple program" ); in test_large_multiple_files_multiple_libraries()
861 …", numFilesInLib, simple_kernels+(i*numFilesInLib+numLibraries*numFilesInLib), NULL, NULL, &error); in test_large_multiple_files_multiple_libraries()
862 test_error( error, "Unable to create a multi-line library" ); in test_large_multiple_files_multiple_libraries()
866 …D, NULL, numLibraries+1+numLibraries*numFilesInLib, my_programs_and_libraries, NULL, NULL, &error); in test_large_multiple_files_multiple_libraries()
867 test_error( error, "Unable to link a program with a library" ); in test_large_multiple_files_multiple_libraries()
870 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CompositeKernel", &error); in test_large_multiple_files_multiple_libraries()
871 test_error( error, "Unable to create a composite kernel" ); in test_large_multiple_files_multiple_libraries()
874 error = verifyCopyBuffer(context, queue, kernel); in test_large_multiple_files_multiple_libraries()
875 if (error != CL_SUCCESS) in test_large_multiple_files_multiple_libraries()
876 return error; in test_large_multiple_files_multiple_libraries()
880 error = clReleaseProgram( my_programs_and_libraries[i] ); in test_large_multiple_files_multiple_libraries()
881 test_error( error, "Unable to release program object" ); in test_large_multiple_files_multiple_libraries()
897 error = clReleaseProgram( simple_kernels[i] ); in test_large_multiple_files_multiple_libraries()
898 test_error( error, "Unable to release program object" ); in test_large_multiple_files_multiple_libraries()
902 error = clReleaseKernel( kernel ); in test_large_multiple_files_multiple_libraries()
903 test_error( error, "Unable to release kernel object" ); in test_large_multiple_files_multiple_libraries()
905 error = clReleaseProgram( my_newly_linked_program ); in test_large_multiple_files_multiple_libraries()
906 test_error( error, "Unable to release program object" ); in test_large_multiple_files_multiple_libraries()
949 int error; in test_large_multiple_files() local
983 …error = create_single_kernel_helper_create_program(context, &my_programs[0], 2 * numLines + 2, lin… in test_large_multiple_files()
984 if( my_programs[0] == NULL || error != CL_SUCCESS ) in test_large_multiple_files()
986 … test program with %d lines! (%s in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_multiple_files()
991 error = clCompileProgram(my_programs[0], 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_large_multiple_files()
992 test_error( error, "Unable to compile a simple program" ); in test_large_multiple_files()
999 …error = create_single_kernel_helper_create_program(context, &my_programs[i + 1], 1, &kernel_source… in test_large_multiple_files()
1000 if( my_programs[i+1] == NULL || error != CL_SUCCESS ) in test_large_multiple_files()
1002 … test program with %d lines! (%s in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_multiple_files()
1007 error = clCompileProgram(my_programs[i+1], 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_large_multiple_files()
1008 test_error( error, "Unable to compile a simple program" ); in test_large_multiple_files()
1014 …_program = clLinkProgram(context, 1, &deviceID, NULL, 1+numLines, my_programs, NULL, NULL, &error); in test_large_multiple_files()
1015 test_error( error, "Unable to link a program with a library" ); in test_large_multiple_files()
1018 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CompositeKernel", &error); in test_large_multiple_files()
1019 test_error( error, "Unable to create a composite kernel" ); in test_large_multiple_files()
1022 error = verifyCopyBuffer(context, queue, kernel); in test_large_multiple_files()
1023 if (error != CL_SUCCESS) in test_large_multiple_files()
1024 return error; in test_large_multiple_files()
1028 error = clReleaseProgram( my_programs[i] ); in test_large_multiple_files()
1029 test_error( error, "Unable to release program object" ); in test_large_multiple_files()
1042 error = clReleaseKernel( kernel ); in test_large_multiple_files()
1043 test_error( error, "Unable to release kernel object" ); in test_large_multiple_files()
1045 error = clReleaseProgram( my_newly_linked_program ); in test_large_multiple_files()
1046 test_error( error, "Unable to release program object" ); in test_large_multiple_files()
1089 int error; in test_simple_compile_only() local
1093 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_simple_compile_only()
1094 if( program == NULL || error != CL_SUCCESS ) in test_simple_compile_only()
1096 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_compile_only()
1100 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_compile_only()
1101 test_error( error, "Unable to compile a simple program" ); in test_simple_compile_only()
1104 error = clReleaseProgram( program ); in test_simple_compile_only()
1105 test_error( error, "Unable to release program object" ); in test_simple_compile_only()
1112 int error; in test_simple_static_compile_only() local
1117 error = create_single_kernel_helper_create_program(context, &program, 1, &compile_static_var); in test_simple_static_compile_only()
1118 if( program == NULL || error != CL_SUCCESS ) in test_simple_static_compile_only()
1120 …a simple static variable test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_static_compile_only()
1125 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_static_compile_only()
1126 test_error( error, "Unable to compile a simple static variable program" ); in test_simple_static_compile_only()
1129 error = clReleaseProgram( program ); in test_simple_static_compile_only()
1130 test_error( error, "Unable to release program object" ); in test_simple_static_compile_only()
1132 … error = create_single_kernel_helper_create_program(context, &program, 1, &compile_static_struct); in test_simple_static_compile_only()
1133 if( program == NULL || error != CL_SUCCESS ) in test_simple_static_compile_only()
1135 …e a simple static struct test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_static_compile_only()
1140 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_static_compile_only()
1141 test_error( error, "Unable to compile a simple static variable program" ); in test_simple_static_compile_only()
1144 error = clReleaseProgram( program ); in test_simple_static_compile_only()
1145 test_error( error, "Unable to release program object" ); in test_simple_static_compile_only()
1147 …error = create_single_kernel_helper_create_program(context, &program, 1, &compile_static_function); in test_simple_static_compile_only()
1148 if( program == NULL || error != CL_SUCCESS ) in test_simple_static_compile_only()
1150 …a simple static function test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_static_compile_only()
1155 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_static_compile_only()
1156 test_error( error, "Unable to compile a simple static function program" ); in test_simple_static_compile_only()
1159 error = clReleaseProgram( program ); in test_simple_static_compile_only()
1160 test_error( error, "Unable to release program object" ); in test_simple_static_compile_only()
1167 int error; in test_simple_extern_compile_only() local
1171 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_header); in test_simple_extern_compile_only()
1172 if( program == NULL || error != CL_SUCCESS ) in test_simple_extern_compile_only()
1174 …e a simple extern kernel test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_extern_compile_only()
1179 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_extern_compile_only()
1180 test_error( error, "Unable to compile a simple extern kernel program" ); in test_simple_extern_compile_only()
1183 error = clReleaseProgram( program ); in test_simple_extern_compile_only()
1184 test_error( error, "Unable to release program object" ); in test_simple_extern_compile_only()
1186 error = create_single_kernel_helper_create_program(context, &program, 1, &compile_extern_var); in test_simple_extern_compile_only()
1187 if( program == NULL || error != CL_SUCCESS ) in test_simple_extern_compile_only()
1189 …a simple extern variable test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_extern_compile_only()
1194 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_extern_compile_only()
1195 test_error( error, "Unable to compile a simple extern variable program" ); in test_simple_extern_compile_only()
1198 error = clReleaseProgram( program ); in test_simple_extern_compile_only()
1199 test_error( error, "Unable to release program object" ); in test_simple_extern_compile_only()
1201 … error = create_single_kernel_helper_create_program(context, &program, 1, &compile_extern_struct); in test_simple_extern_compile_only()
1202 if( program == NULL || error != CL_SUCCESS ) in test_simple_extern_compile_only()
1204 …e a simple extern struct test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_extern_compile_only()
1209 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_extern_compile_only()
1210 test_error( error, "Unable to compile a simple extern variable program" ); in test_simple_extern_compile_only()
1213 error = clReleaseProgram( program ); in test_simple_extern_compile_only()
1214 test_error( error, "Unable to release program object" ); in test_simple_extern_compile_only()
1216 …error = create_single_kernel_helper_create_program(context, &program, 1, &compile_extern_function); in test_simple_extern_compile_only()
1217 if( program == NULL || error != CL_SUCCESS ) in test_simple_extern_compile_only()
1219 …a simple extern function test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_extern_compile_only()
1224 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_extern_compile_only()
1225 test_error( error, "Unable to compile a simple extern function program" ); in test_simple_extern_compile_only()
1228 error = clReleaseProgram( program ); in test_simple_extern_compile_only()
1229 test_error( error, "Unable to release program object" ); in test_simple_extern_compile_only()
1250 int error; in simple_compile_callback() local
1253 error = clSetUserEventStatus(simple_compile_user_data->m_event, CL_COMPLETE); in simple_compile_callback()
1254 if (error != CL_SUCCESS) in simple_compile_callback()
1256 … set user event status to CL_COMPLETE! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in simple_compile_callback()
1264 int error; in test_simple_compile_with_callback() local
1269 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_simple_compile_with_callback()
1270 if( program == NULL || error != CL_SUCCESS ) in test_simple_compile_with_callback()
1272 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_compile_with_callback()
1276 compile_program_completion_event = clCreateUserEvent(context, &error); in test_simple_compile_with_callback()
1277 test_error( error, "Unable to create a user event"); in test_simple_compile_with_callback()
1281 …error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, simple_compile_callback, (voi… in test_simple_compile_with_callback()
1282 test_error( error, "Unable to compile a simple program with a callback" ); in test_simple_compile_with_callback()
1284 error = clWaitForEvents(1, &compile_program_completion_event); in test_simple_compile_with_callback()
1285 test_error( error, "clWaitForEvents failed when waiting on compile_program_completion_event"); in test_simple_compile_with_callback()
1288 error = clReleaseEvent(compile_program_completion_event); in test_simple_compile_with_callback()
1289 test_error( error, "Unable to release event object" ); in test_simple_compile_with_callback()
1291 error = clReleaseProgram( program ); in test_simple_compile_with_callback()
1292 test_error( error, "Unable to release program object" ); in test_simple_compile_with_callback()
1299 int error; in test_simple_embedded_header_compile() local
1303 … program = clCreateProgramWithSource(context, 1, &another_simple_kernel_with_header, NULL, &error); in test_simple_embedded_header_compile()
1304 if( program == NULL || error != CL_SUCCESS ) in test_simple_embedded_header_compile()
1306 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_embedded_header_compile()
1310 header = clCreateProgramWithSource(context, 1, &simple_header, NULL, &error); in test_simple_embedded_header_compile()
1311 if( header == NULL || error != CL_SUCCESS ) in test_simple_embedded_header_compile()
1313 …ble to create a simple header program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_embedded_header_compile()
1317 …error = clCompileProgram(program, 1, &deviceID, NULL, 1, &header, &simple_header_name, NULL, NULL); in test_simple_embedded_header_compile()
1318 test_error( error, "Unable to compile a simple program with embedded header" ); in test_simple_embedded_header_compile()
1321 error = clReleaseProgram( program ); in test_simple_embedded_header_compile()
1322 test_error( error, "Unable to release program object" ); in test_simple_embedded_header_compile()
1324 error = clReleaseProgram( header ); in test_simple_embedded_header_compile()
1325 test_error( error, "Unable to release program object" ); in test_simple_embedded_header_compile()
1332 int error; in test_simple_link_only() local
1336 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_simple_link_only()
1337 if( program == NULL || error != CL_SUCCESS ) in test_simple_link_only()
1339 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_link_only()
1343 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_link_only()
1344 test_error( error, "Unable to compile a simple program" ); in test_simple_link_only()
1346 …newly_linked_program = clLinkProgram(context, 1, &deviceID, NULL, 1, &program, NULL, NULL, &error); in test_simple_link_only()
1347 test_error( error, "Unable to link a simple program" ); in test_simple_link_only()
1350 error = clReleaseProgram( program ); in test_simple_link_only()
1351 test_error( error, "Unable to release program object" ); in test_simple_link_only()
1353 error = clReleaseProgram( my_newly_linked_program ); in test_simple_link_only()
1354 test_error( error, "Unable to release program object" ); in test_simple_link_only()
1361 int error; in test_two_file_regular_variable_access() local
1366 error = create_single_kernel_helper_create_program(context, &program, 2, sources); in test_two_file_regular_variable_access()
1367 if( program == NULL || error != CL_SUCCESS ) in test_two_file_regular_variable_access()
1369 … a test program with regular variable! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_two_file_regular_variable_access()
1373 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_two_file_regular_variable_access()
1374 test_error( error, "Unable to compile a simple program with regular function" ); in test_two_file_regular_variable_access()
1376 …error = create_single_kernel_helper_create_program(context, &second_program, 1, &link_static_var_a… in test_two_file_regular_variable_access()
1377 if( program == NULL || error != CL_SUCCESS ) in test_two_file_regular_variable_access()
1379 …at tries to access a regular variable! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_two_file_regular_variable_access()
1383 error = clCompileProgram(second_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_two_file_regular_variable_access()
1384 test_error( error, "Unable to compile a program that tries to access a regular variable" ); in test_two_file_regular_variable_access()
1387 …y_linked_program = clLinkProgram(context, 1, &deviceID, NULL, 2, two_programs, NULL, NULL, &error); in test_two_file_regular_variable_access()
1388 …test_error( error, "clLinkProgram: Expected a different error code while linking a program that tr… in test_two_file_regular_variable_access()
1391 error = clReleaseProgram( program ); in test_two_file_regular_variable_access()
1392 test_error( error, "Unable to release program object" ); in test_two_file_regular_variable_access()
1394 error = clReleaseProgram( second_program ); in test_two_file_regular_variable_access()
1395 test_error( error, "Unable to release program object" ); in test_two_file_regular_variable_access()
1397 error = clReleaseProgram( my_newly_linked_program ); in test_two_file_regular_variable_access()
1398 test_error( error, "Unable to release program object" ); in test_two_file_regular_variable_access()
1405 int error; in test_two_file_regular_struct_access() local
1410 error = create_single_kernel_helper_create_program(context, &program, 2, sources); in test_two_file_regular_struct_access()
1411 if( program == NULL || error != CL_SUCCESS ) in test_two_file_regular_struct_access()
1413 …te a test program with regular struct! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_two_file_regular_struct_access()
1417 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_two_file_regular_struct_access()
1418 test_error( error, "Unable to compile a simple program with regular struct" ); in test_two_file_regular_struct_access()
1420 …error = create_single_kernel_helper_create_program(context, &second_program, 1, &link_static_struc… in test_two_file_regular_struct_access()
1421 if( second_program == NULL || error != CL_SUCCESS ) in test_two_file_regular_struct_access()
1423 …that tries to access a regular struct! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_two_file_regular_struct_access()
1427 error = clCompileProgram(second_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_two_file_regular_struct_access()
1428 test_error( error, "Unable to compile a program that tries to access a regular struct" ); in test_two_file_regular_struct_access()
1431 …y_linked_program = clLinkProgram(context, 1, &deviceID, NULL, 2, two_programs, NULL, NULL, &error); in test_two_file_regular_struct_access()
1432 …test_error( error, "clLinkProgram: Expected a different error code while linking a program that tr… in test_two_file_regular_struct_access()
1435 error = clReleaseProgram( program ); in test_two_file_regular_struct_access()
1436 test_error( error, "Unable to release program object" ); in test_two_file_regular_struct_access()
1438 error = clReleaseProgram( second_program ); in test_two_file_regular_struct_access()
1439 test_error( error, "Unable to release program object" ); in test_two_file_regular_struct_access()
1441 error = clReleaseProgram( my_newly_linked_program ); in test_two_file_regular_struct_access()
1442 test_error( error, "Unable to release program object" ); in test_two_file_regular_struct_access()
1450 int error; in test_two_file_regular_function_access() local
1455 error = create_single_kernel_helper_create_program(context, &program, 2, sources); in test_two_file_regular_function_access()
1456 if( program == NULL || error != CL_SUCCESS ) in test_two_file_regular_function_access()
1458 … a test program with regular function! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_two_file_regular_function_access()
1462 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_two_file_regular_function_access()
1463 test_error( error, "Unable to compile a simple program with regular function" ); in test_two_file_regular_function_access()
1465 …error = create_single_kernel_helper_create_program(context, &second_program, 1, &link_static_funct… in test_two_file_regular_function_access()
1466 if( second_program == NULL || error != CL_SUCCESS ) in test_two_file_regular_function_access()
1468 …at tries to access a regular function! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_two_file_regular_function_access()
1472 error = clCompileProgram(second_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_two_file_regular_function_access()
1473 test_error( error, "Unable to compile a program that tries to access a regular function" ); in test_two_file_regular_function_access()
1476 …y_linked_program = clLinkProgram(context, 1, &deviceID, NULL, 2, two_programs, NULL, NULL, &error); in test_two_file_regular_function_access()
1477 …test_error( error, "clLinkProgram: Expected a different error code while linking a program that tr… in test_two_file_regular_function_access()
1480 error = clReleaseProgram( program ); in test_two_file_regular_function_access()
1481 test_error( error, "Unable to release program object" ); in test_two_file_regular_function_access()
1483 error = clReleaseProgram( second_program ); in test_two_file_regular_function_access()
1484 test_error( error, "Unable to release program object" ); in test_two_file_regular_function_access()
1486 error = clReleaseProgram( my_newly_linked_program ); in test_two_file_regular_function_access()
1487 test_error( error, "Unable to release program object" ); in test_two_file_regular_function_access()
1494 int error; in test_simple_embedded_header_link() local
1498 … program = clCreateProgramWithSource(context, 1, &another_simple_kernel_with_header, NULL, &error); in test_simple_embedded_header_link()
1499 if( program == NULL || error != CL_SUCCESS ) in test_simple_embedded_header_link()
1501 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_embedded_header_link()
1505 header = clCreateProgramWithSource(context, 1, &simple_header, NULL, &error); in test_simple_embedded_header_link()
1506 if( header == NULL || error != CL_SUCCESS ) in test_simple_embedded_header_link()
1508 …ble to create a simple header program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_embedded_header_link()
1512 …error = clCompileProgram(program, 1, &deviceID, NULL, 1, &header, &simple_header_name, NULL, NULL); in test_simple_embedded_header_link()
1513 test_error( error, "Unable to compile a simple program with embedded header" ); in test_simple_embedded_header_link()
1515 error = create_single_kernel_helper_create_program(context, &simple_program, 1, &simple_kernel); in test_simple_embedded_header_link()
1516 if( simple_program == NULL || error != CL_SUCCESS ) in test_simple_embedded_header_link()
1518 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_embedded_header_link()
1522 error = clCompileProgram(simple_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_embedded_header_link()
1523 test_error( error, "Unable to compile a simple program" ); in test_simple_embedded_header_link()
1526 …lly_linked_program = clLinkProgram(context, 1, &deviceID, "", 2, two_programs, NULL, NULL, &error); in test_simple_embedded_header_link()
1527 …test_error( error, "Unable to create an executable from two binaries, one compiled with embedded h… in test_simple_embedded_header_link()
1530 error = clReleaseProgram( program ); in test_simple_embedded_header_link()
1531 test_error( error, "Unable to release program object" ); in test_simple_embedded_header_link()
1533 error = clReleaseProgram( header ); in test_simple_embedded_header_link()
1534 test_error( error, "Unable to release program object" ); in test_simple_embedded_header_link()
1536 error = clReleaseProgram( simple_program ); in test_simple_embedded_header_link()
1537 test_error( error, "Unable to release program object" ); in test_simple_embedded_header_link()
1539 error = clReleaseProgram( fully_linked_program ); in test_simple_embedded_header_link()
1540 test_error( error, "Unable to release program object" ); in test_simple_embedded_header_link()
1556 int error; in simple_link_callback() local
1559 error = clSetUserEventStatus(simple_link_user_data->m_event, CL_COMPLETE); in simple_link_callback()
1560 if (error != CL_SUCCESS) in simple_link_callback()
1562 … set user event status to CL_COMPLETE! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in simple_link_callback()
1570 int error; in test_simple_link_with_callback() local
1575 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_simple_link_with_callback()
1576 if( program == NULL || error != CL_SUCCESS ) in test_simple_link_with_callback()
1578 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_link_with_callback()
1582 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_link_with_callback()
1583 test_error( error, "Unable to compile a simple program" ); in test_simple_link_with_callback()
1585 link_program_completion_event = clCreateUserEvent(context, &error); in test_simple_link_with_callback()
1586 test_error( error, "Unable to create a user event"); in test_simple_link_with_callback()
1590 …ext, 1, &deviceID, NULL, 1, &program, simple_link_callback, (void*)&simple_link_user_data, &error); in test_simple_link_with_callback()
1591 test_error( error, "Unable to link a simple program" ); in test_simple_link_with_callback()
1593 error = clWaitForEvents(1, &link_program_completion_event); in test_simple_link_with_callback()
1594 test_error( error, "clWaitForEvents failed when waiting on link_program_completion_event"); in test_simple_link_with_callback()
1597 error = clReleaseEvent(link_program_completion_event); in test_simple_link_with_callback()
1598 test_error( error, "Unable to release event object" ); in test_simple_link_with_callback()
1600 error = clReleaseProgram( program ); in test_simple_link_with_callback()
1601 test_error( error, "Unable to release program object" ); in test_simple_link_with_callback()
1603 error = clReleaseProgram( my_linked_library ); in test_simple_link_with_callback()
1604 test_error( error, "Unable to release program object" ); in test_simple_link_with_callback()
1627 int error, result = CL_SUCCESS; in verifyCopyBuffer() local
1650 cnDimension * sizeof( cl_float ), srcBuffer, &error); in verifyCopyBuffer()
1651 test_error( error, "Unable to create a source memory buffer" ); in verifyCopyBuffer()
1654 cnDimension * sizeof( cl_float ), 0, &error); in verifyCopyBuffer()
1655 test_error( error, "Unable to create a destination memory buffer" ); in verifyCopyBuffer()
1659 error = clSetKernelArg(kernel, 0, sizeof( cl_mem ), ( void * )&deviceMemSrc ); in verifyCopyBuffer()
1660 test_error( error, "Unable to set the first kernel argument" ); in verifyCopyBuffer()
1663 error = clSetKernelArg(kernel, 1, sizeof( cl_mem ), ( void * )&deviceMemDst ); in verifyCopyBuffer()
1664 test_error( error, "Unable to set the second kernel argument" ); in verifyCopyBuffer()
1667 error = clEnqueueNDRangeKernel(queue, kernel, 1, NULL, in verifyCopyBuffer()
1669 test_error( error, "Unable to enqueue kernel" ); in verifyCopyBuffer()
1671 error = clFlush( queue ); in verifyCopyBuffer()
1672 test_error( error, "Unable to flush the queue" ); in verifyCopyBuffer()
1675 … error = clEnqueueReadBuffer(queue, deviceMemDst, CL_TRUE, 0, cnDimension * sizeof( cl_float ), in verifyCopyBuffer()
1677 test_error( error, "Unable to read the destination buffer" ); in verifyCopyBuffer()
1679 error = clFlush( queue ); in verifyCopyBuffer()
1680 test_error( error, "Unable to flush the queue" ); in verifyCopyBuffer()
1720 error = clReleaseMemObject( deviceMemSrc ); in verifyCopyBuffer()
1721 test_error( error, "Unable to release memory object" ); in verifyCopyBuffer()
1726 error = clReleaseMemObject( deviceMemDst ); in verifyCopyBuffer()
1727 test_error( error, "Unable to release memory object" ); in verifyCopyBuffer()
1735 int error; in test_execute_after_simple_compile_and_link() local
1739 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_execute_after_simple_compile_and_link()
1740 if( program == NULL || error != CL_SUCCESS ) in test_execute_after_simple_compile_and_link()
1742 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_simple_compile_and_link()
1746 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_simple_compile_and_link()
1747 test_error( error, "Unable to compile a simple program" ); in test_execute_after_simple_compile_and_link()
1749 …newly_linked_program = clLinkProgram(context, 1, &deviceID, NULL, 1, &program, NULL, NULL, &error); in test_execute_after_simple_compile_and_link()
1750 test_error( error, "Unable to link a simple program" ); in test_execute_after_simple_compile_and_link()
1752 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CopyBuffer", &error); in test_execute_after_simple_compile_and_link()
1753 test_error( error, "Unable to create a simple kernel" ); in test_execute_after_simple_compile_and_link()
1755 error = verifyCopyBuffer(context, queue, kernel); in test_execute_after_simple_compile_and_link()
1756 if (error != CL_SUCCESS) in test_execute_after_simple_compile_and_link()
1757 return error; in test_execute_after_simple_compile_and_link()
1760 error = clReleaseKernel( kernel ); in test_execute_after_simple_compile_and_link()
1761 test_error( error, "Unable to release kernel object" ); in test_execute_after_simple_compile_and_link()
1763 error = clReleaseProgram( program ); in test_execute_after_simple_compile_and_link()
1764 test_error( error, "Unable to release program object" ); in test_execute_after_simple_compile_and_link()
1766 error = clReleaseProgram( my_newly_linked_program ); in test_execute_after_simple_compile_and_link()
1767 test_error( error, "Unable to release program object" ); in test_execute_after_simple_compile_and_link()
1774 int error; in test_execute_after_simple_compile_and_link_no_device_info() local
1778 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_execute_after_simple_compile_and_link_no_device_info()
1779 if( program == NULL || error != CL_SUCCESS ) in test_execute_after_simple_compile_and_link_no_device_info()
1781 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_simple_compile_and_link_no_device_info()
1785 error = clCompileProgram(program, 0, NULL, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_simple_compile_and_link_no_device_info()
1786 test_error( error, "Unable to compile a simple program" ); in test_execute_after_simple_compile_and_link_no_device_info()
1788 …m my_newly_linked_program = clLinkProgram(context, 0, NULL, NULL, 1, &program, NULL, NULL, &error); in test_execute_after_simple_compile_and_link_no_device_info()
1789 test_error( error, "Unable to link a simple program" ); in test_execute_after_simple_compile_and_link_no_device_info()
1791 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CopyBuffer", &error); in test_execute_after_simple_compile_and_link_no_device_info()
1792 test_error( error, "Unable to create a simple kernel" ); in test_execute_after_simple_compile_and_link_no_device_info()
1794 error = verifyCopyBuffer(context, queue, kernel); in test_execute_after_simple_compile_and_link_no_device_info()
1795 if (error != CL_SUCCESS) in test_execute_after_simple_compile_and_link_no_device_info()
1796 return error; in test_execute_after_simple_compile_and_link_no_device_info()
1799 error = clReleaseKernel( kernel ); in test_execute_after_simple_compile_and_link_no_device_info()
1800 test_error( error, "Unable to release kernel object" ); in test_execute_after_simple_compile_and_link_no_device_info()
1802 error = clReleaseProgram( program ); in test_execute_after_simple_compile_and_link_no_device_info()
1803 test_error( error, "Unable to release program object" ); in test_execute_after_simple_compile_and_link_no_device_info()
1805 error = clReleaseProgram( my_newly_linked_program ); in test_execute_after_simple_compile_and_link_no_device_info()
1806 test_error( error, "Unable to release program object" ); in test_execute_after_simple_compile_and_link_no_device_info()
1813 int error; in test_execute_after_simple_compile_and_link_with_defines() local
1817 …error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel_with_defin… in test_execute_after_simple_compile_and_link_with_defines()
1818 if( program == NULL || error != CL_SUCCESS ) in test_execute_after_simple_compile_and_link_with_defines()
1820 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_simple_compile_and_link_with_defines()
1824 …error = clCompileProgram(program, 1, &deviceID, "-DFIRST=5 -DSECOND=37", 0, NULL, NULL, NULL, NULL… in test_execute_after_simple_compile_and_link_with_defines()
1825 test_error( error, "Unable to compile a simple program" ); in test_execute_after_simple_compile_and_link_with_defines()
1827 …newly_linked_program = clLinkProgram(context, 1, &deviceID, NULL, 1, &program, NULL, NULL, &error); in test_execute_after_simple_compile_and_link_with_defines()
1828 test_error( error, "Unable to link a simple program" ); in test_execute_after_simple_compile_and_link_with_defines()
1830 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CopyBuffer", &error); in test_execute_after_simple_compile_and_link_with_defines()
1831 test_error( error, "Unable to create a simple kernel" ); in test_execute_after_simple_compile_and_link_with_defines()
1833 error = verifyCopyBuffer(context, queue, kernel); in test_execute_after_simple_compile_and_link_with_defines()
1834 if (error != CL_SUCCESS) in test_execute_after_simple_compile_and_link_with_defines()
1835 return error; in test_execute_after_simple_compile_and_link_with_defines()
1838 error = clReleaseKernel( kernel ); in test_execute_after_simple_compile_and_link_with_defines()
1839 test_error( error, "Unable to release kernel object" ); in test_execute_after_simple_compile_and_link_with_defines()
1841 error = clReleaseProgram( program ); in test_execute_after_simple_compile_and_link_with_defines()
1842 test_error( error, "Unable to release program object" ); in test_execute_after_simple_compile_and_link_with_defines()
1844 error = clReleaseProgram( my_newly_linked_program ); in test_execute_after_simple_compile_and_link_with_defines()
1845 test_error( error, "Unable to release program object" ); in test_execute_after_simple_compile_and_link_with_defines()
1852 int error; in test_execute_after_serialize_reload_object() local
1858 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_execute_after_serialize_reload_object()
1859 if( program == NULL || error != CL_SUCCESS ) in test_execute_after_serialize_reload_object()
1861 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_serialize_reload_object()
1865 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_serialize_reload_object()
1866 test_error( error, "Unable to compile a simple program" ); in test_execute_after_serialize_reload_object()
1869 …error = clGetProgramInfo( program, CL_PROGRAM_BINARY_SIZES, sizeof( binarySize ), &binarySize, NUL… in test_execute_after_serialize_reload_object()
1870 test_error( error, "Unable to get binary size" ); in test_execute_after_serialize_reload_object()
1891 error = clGetProgramInfo( program, CL_PROGRAM_BINARIES, 0, NULL, &size ); in test_execute_after_serialize_reload_object()
1892 test_error( error, "Unable to get expected size of binaries array" ); in test_execute_after_serialize_reload_object()
1900 error = clGetProgramInfo( program, CL_PROGRAM_BINARIES, sizeof( buffers ), &buffers, NULL ); in test_execute_after_serialize_reload_object()
1901 test_error( error, "Unable to get program binary" ); in test_execute_after_serialize_reload_object()
1904 …WithBinary(context, 1, &deviceID, &binarySize, (const unsigned char**)buffers, loadErrors, &error); in test_execute_after_serialize_reload_object()
1905 test_error( error, "Unable to create program with binary" ); in test_execute_after_serialize_reload_object()
1907 …_program = clLinkProgram(context, 1, &deviceID, NULL, 1, &program_with_binary, NULL, NULL, &error); in test_execute_after_serialize_reload_object()
1908 test_error( error, "Unable to link a simple program" ); in test_execute_after_serialize_reload_object()
1910 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CopyBuffer", &error); in test_execute_after_serialize_reload_object()
1911 test_error( error, "Unable to create a simple kernel" ); in test_execute_after_serialize_reload_object()
1913 error = verifyCopyBuffer(context, queue, kernel); in test_execute_after_serialize_reload_object()
1914 if (error != CL_SUCCESS) in test_execute_after_serialize_reload_object()
1915 return error; in test_execute_after_serialize_reload_object()
1918 error = clReleaseKernel( kernel ); in test_execute_after_serialize_reload_object()
1919 test_error( error, "Unable to release kernel object" ); in test_execute_after_serialize_reload_object()
1921 error = clReleaseProgram( program ); in test_execute_after_serialize_reload_object()
1922 test_error( error, "Unable to release program object" ); in test_execute_after_serialize_reload_object()
1924 error = clReleaseProgram( my_newly_linked_program ); in test_execute_after_serialize_reload_object()
1925 test_error( error, "Unable to release program object" ); in test_execute_after_serialize_reload_object()
1927 error = clReleaseProgram( program_with_binary ); in test_execute_after_serialize_reload_object()
1928 test_error( error, "Unable to release program object" ); in test_execute_after_serialize_reload_object()
1937 int error; in test_execute_after_serialize_reload_library() local
1944 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_execute_after_serialize_reload_library()
1945 if( program == NULL || error != CL_SUCCESS ) in test_execute_after_serialize_reload_library()
1947 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_serialize_reload_library()
1951 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_serialize_reload_library()
1952 test_error( error, "Unable to compile a simple program" ); in test_execute_after_serialize_reload_library()
1954 …library = clLinkProgram(context, 1, &deviceID, "-create-library", 1, &program, NULL, NULL, &error); in test_execute_after_serialize_reload_library()
1955 test_error( error, "Unable to create a simple library" ); in test_execute_after_serialize_reload_library()
1959 …error = clGetProgramInfo( my_newly_minted_library, CL_PROGRAM_BINARY_SIZES, sizeof( binarySize ), … in test_execute_after_serialize_reload_library()
1960 test_error( error, "Unable to get binary size" ); in test_execute_after_serialize_reload_library()
1980 error = clGetProgramInfo( my_newly_minted_library, CL_PROGRAM_BINARIES, 0, NULL, &size ); in test_execute_after_serialize_reload_library()
1981 test_error( error, "Unable to get expected size of binaries array" ); in test_execute_after_serialize_reload_library()
1989 …error = clGetProgramInfo( my_newly_minted_library, CL_PROGRAM_BINARIES, sizeof( buffers ), &buffer… in test_execute_after_serialize_reload_library()
1990 test_error( error, "Unable to get program binary" ); in test_execute_after_serialize_reload_library()
1993 …WithBinary(context, 1, &deviceID, &binarySize, (const unsigned char**)buffers, loadErrors, &error); in test_execute_after_serialize_reload_library()
1994 test_error( error, "Unable to create program with binary" ); in test_execute_after_serialize_reload_library()
1996 …error = create_single_kernel_helper_create_program(context, &another_program, 1, &another_simple_k… in test_execute_after_serialize_reload_library()
1997 if( another_program == NULL || error != CL_SUCCESS ) in test_execute_after_serialize_reload_library()
1999 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_serialize_reload_library()
2003 error = clCompileProgram(another_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_serialize_reload_library()
2004 test_error( error, "Unable to compile a simple program" ); in test_execute_after_serialize_reload_library()
2007 …ked_program = clLinkProgram(context, 1, &deviceID, "", 2, program_and_archive, NULL, NULL, &error); in test_execute_after_serialize_reload_library()
2008 test_error( error, "Unable to create an executable from a binary and a library" ); in test_execute_after_serialize_reload_library()
2010 cl_kernel kernel = clCreateKernel(fully_linked_program, "CopyBuffer", &error); in test_execute_after_serialize_reload_library()
2011 test_error( error, "Unable to create a simple kernel" ); in test_execute_after_serialize_reload_library()
2013 error = verifyCopyBuffer(context, queue, kernel); in test_execute_after_serialize_reload_library()
2014 if (error != CL_SUCCESS) in test_execute_after_serialize_reload_library()
2015 return error; in test_execute_after_serialize_reload_library()
2017 cl_kernel another_kernel = clCreateKernel(fully_linked_program, "AnotherCopyBuffer", &error); in test_execute_after_serialize_reload_library()
2018 test_error( error, "Unable to create another simple kernel" ); in test_execute_after_serialize_reload_library()
2020 error = verifyCopyBuffer(context, queue, another_kernel); in test_execute_after_serialize_reload_library()
2021 if (error != CL_SUCCESS) in test_execute_after_serialize_reload_library()
2022 return error; in test_execute_after_serialize_reload_library()
2025 error = clReleaseKernel( kernel ); in test_execute_after_serialize_reload_library()
2026 test_error( error, "Unable to release kernel object" ); in test_execute_after_serialize_reload_library()
2028 error = clReleaseKernel( another_kernel ); in test_execute_after_serialize_reload_library()
2029 test_error( error, "Unable to release another kernel object" ); in test_execute_after_serialize_reload_library()
2031 error = clReleaseProgram( program ); in test_execute_after_serialize_reload_library()
2032 test_error( error, "Unable to release program object" ); in test_execute_after_serialize_reload_library()
2034 error = clReleaseProgram( another_program ); in test_execute_after_serialize_reload_library()
2035 test_error( error, "Unable to release program object" ); in test_execute_after_serialize_reload_library()
2037 error = clReleaseProgram( my_newly_minted_library ); in test_execute_after_serialize_reload_library()
2038 test_error( error, "Unable to release program object" ); in test_execute_after_serialize_reload_library()
2040 error = clReleaseProgram( library_with_binary ); in test_execute_after_serialize_reload_library()
2041 test_error( error, "Unable to release program object" ); in test_execute_after_serialize_reload_library()
2043 error = clReleaseProgram( fully_linked_program ); in test_execute_after_serialize_reload_library()
2044 test_error( error, "Unable to release program object" ); in test_execute_after_serialize_reload_library()
2053 int error; in program_compile_completion_callback() local
2057 error = clSetUserEventStatus(compile_program_completion_event, CL_COMPLETE); in program_compile_completion_callback()
2058 if (error != CL_SUCCESS) in program_compile_completion_callback()
2060 … set user event status to CL_COMPLETE! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in program_compile_completion_callback()
2068 int error; in program_link_completion_callback() local
2072 error = clSetUserEventStatus(link_program_completion_event, CL_COMPLETE); in program_link_completion_callback()
2073 if (error != CL_SUCCESS) in program_link_completion_callback()
2075 … set user event status to CL_COMPLETE! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in program_link_completion_callback()
2083 int error; in test_execute_after_simple_compile_and_link_with_callbacks() local
2088 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_execute_after_simple_compile_and_link_with_callbacks()
2089 if( program == NULL || error != CL_SUCCESS ) in test_execute_after_simple_compile_and_link_with_callbacks()
2091 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_simple_compile_and_link_with_callbacks()
2095 compile_program_completion_event = clCreateUserEvent(context, &error); in test_execute_after_simple_compile_and_link_with_callbacks()
2096 test_error( error, "Unable to create a user event"); in test_execute_after_simple_compile_and_link_with_callbacks()
2098 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, in test_execute_after_simple_compile_and_link_with_callbacks()
2100 test_error( error, "Unable to compile a simple program" ); in test_execute_after_simple_compile_and_link_with_callbacks()
2102 error = clWaitForEvents(1, &compile_program_completion_event); in test_execute_after_simple_compile_and_link_with_callbacks()
2103 test_error( error, "clWaitForEvents failed when waiting on compile_program_completion_event"); in test_execute_after_simple_compile_and_link_with_callbacks()
2105 error = clReleaseEvent(compile_program_completion_event); in test_execute_after_simple_compile_and_link_with_callbacks()
2106 test_error( error, "Unable to release event object" ); in test_execute_after_simple_compile_and_link_with_callbacks()
2108 link_program_completion_event = clCreateUserEvent(context, &error); in test_execute_after_simple_compile_and_link_with_callbacks()
2109 test_error( error, "Unable to create a user event"); in test_execute_after_simple_compile_and_link_with_callbacks()
2112 program_link_completion_callback, (void*)link_program_completion_event, &error); in test_execute_after_simple_compile_and_link_with_callbacks()
2113 test_error( error, "Unable to link a simple program" ); in test_execute_after_simple_compile_and_link_with_callbacks()
2115 error = clWaitForEvents(1, &link_program_completion_event); in test_execute_after_simple_compile_and_link_with_callbacks()
2116 test_error( error, "clWaitForEvents failed when waiting on link_program_completion_event"); in test_execute_after_simple_compile_and_link_with_callbacks()
2118 error = clReleaseEvent(link_program_completion_event); in test_execute_after_simple_compile_and_link_with_callbacks()
2119 test_error( error, "Unable to release event object" ); in test_execute_after_simple_compile_and_link_with_callbacks()
2121 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CopyBuffer", &error); in test_execute_after_simple_compile_and_link_with_callbacks()
2122 test_error( error, "Unable to create a simple kernel" ); in test_execute_after_simple_compile_and_link_with_callbacks()
2124 error = verifyCopyBuffer(context, queue, kernel); in test_execute_after_simple_compile_and_link_with_callbacks()
2125 if (error != CL_SUCCESS) in test_execute_after_simple_compile_and_link_with_callbacks()
2126 return error; in test_execute_after_simple_compile_and_link_with_callbacks()
2129 error = clReleaseKernel( kernel ); in test_execute_after_simple_compile_and_link_with_callbacks()
2130 test_error( error, "Unable to release kernel object" ); in test_execute_after_simple_compile_and_link_with_callbacks()
2132 error = clReleaseProgram( program ); in test_execute_after_simple_compile_and_link_with_callbacks()
2133 test_error( error, "Unable to release program object" ); in test_execute_after_simple_compile_and_link_with_callbacks()
2135 error = clReleaseProgram( my_newly_linked_program ); in test_execute_after_simple_compile_and_link_with_callbacks()
2136 test_error( error, "Unable to release program object" ); in test_execute_after_simple_compile_and_link_with_callbacks()
2143 int error; in test_simple_library_only() local
2147 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_simple_library_only()
2148 if( program == NULL || error != CL_SUCCESS ) in test_simple_library_only()
2150 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_library_only()
2154 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_library_only()
2155 test_error( error, "Unable to compile a simple program" ); in test_simple_library_only()
2157 …library = clLinkProgram(context, 1, &deviceID, "-create-library", 1, &program, NULL, NULL, &error); in test_simple_library_only()
2158 test_error( error, "Unable to create a simple library" ); in test_simple_library_only()
2161 error = clReleaseProgram( program ); in test_simple_library_only()
2162 test_error( error, "Unable to release program object" ); in test_simple_library_only()
2164 error = clReleaseProgram( my_newly_minted_library ); in test_simple_library_only()
2165 test_error( error, "Unable to release program object" ); in test_simple_library_only()
2172 int error; in test_simple_library_with_callback() local
2177 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_simple_library_with_callback()
2178 if( program == NULL || error != CL_SUCCESS ) in test_simple_library_with_callback()
2180 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_library_with_callback()
2184 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_library_with_callback()
2185 test_error( error, "Unable to compile a simple program" ); in test_simple_library_with_callback()
2187 link_program_completion_event = clCreateUserEvent(context, &error); in test_simple_library_with_callback()
2188 test_error( error, "Unable to create a user event"); in test_simple_library_with_callback()
2193 simple_link_callback, (void*)&simple_link_user_data, &error); in test_simple_library_with_callback()
2194 test_error( error, "Unable to create a simple library" ); in test_simple_library_with_callback()
2196 error = clWaitForEvents(1, &link_program_completion_event); in test_simple_library_with_callback()
2197 test_error( error, "clWaitForEvents failed when waiting on link_program_completion_event"); in test_simple_library_with_callback()
2200 error = clReleaseEvent(link_program_completion_event); in test_simple_library_with_callback()
2201 test_error( error, "Unable to release event object" ); in test_simple_library_with_callback()
2203 error = clReleaseProgram( program ); in test_simple_library_with_callback()
2204 test_error( error, "Unable to release program object" ); in test_simple_library_with_callback()
2206 error = clReleaseProgram( my_newly_minted_library ); in test_simple_library_with_callback()
2207 test_error( error, "Unable to release program object" ); in test_simple_library_with_callback()
2214 int error; in test_simple_library_with_link() local
2218 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_simple_library_with_link()
2219 if( program == NULL || error != CL_SUCCESS ) in test_simple_library_with_link()
2221 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_library_with_link()
2225 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_library_with_link()
2226 test_error( error, "Unable to compile a simple program" ); in test_simple_library_with_link()
2228 …library = clLinkProgram(context, 1, &deviceID, "-create-library", 1, &program, NULL, NULL, &error); in test_simple_library_with_link()
2229 test_error( error, "Unable to create a simple library" ); in test_simple_library_with_link()
2231 …error = create_single_kernel_helper_create_program(context, &another_program, 1, &another_simple_k… in test_simple_library_with_link()
2232 if( another_program == NULL || error != CL_SUCCESS ) in test_simple_library_with_link()
2234 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_simple_library_with_link()
2238 error = clCompileProgram(another_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_simple_library_with_link()
2239 test_error( error, "Unable to compile a simple program" ); in test_simple_library_with_link()
2242 …ked_program = clLinkProgram(context, 1, &deviceID, "", 2, program_and_archive, NULL, NULL, &error); in test_simple_library_with_link()
2243 test_error( error, "Unable to create an executable from a binary and a library" ); in test_simple_library_with_link()
2246 error = clReleaseProgram( program ); in test_simple_library_with_link()
2247 test_error( error, "Unable to release program object" ); in test_simple_library_with_link()
2249 error = clReleaseProgram( another_program ); in test_simple_library_with_link()
2250 test_error( error, "Unable to release program object" ); in test_simple_library_with_link()
2252 error = clReleaseProgram( my_newly_minted_library ); in test_simple_library_with_link()
2253 test_error( error, "Unable to release program object" ); in test_simple_library_with_link()
2255 error = clReleaseProgram( fully_linked_program ); in test_simple_library_with_link()
2256 test_error( error, "Unable to release program object" ); in test_simple_library_with_link()
2263 int error; in test_execute_after_simple_library_with_link() local
2267 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_execute_after_simple_library_with_link()
2268 if( program == NULL || error != CL_SUCCESS ) in test_execute_after_simple_library_with_link()
2270 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_simple_library_with_link()
2274 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_simple_library_with_link()
2275 test_error( error, "Unable to compile a simple program" ); in test_execute_after_simple_library_with_link()
2277 …library = clLinkProgram(context, 1, &deviceID, "-create-library", 1, &program, NULL, NULL, &error); in test_execute_after_simple_library_with_link()
2278 test_error( error, "Unable to create a simple library" ); in test_execute_after_simple_library_with_link()
2280 …error = create_single_kernel_helper_create_program(context, &another_program, 1, &another_simple_k… in test_execute_after_simple_library_with_link()
2281 if( another_program == NULL || error != CL_SUCCESS ) in test_execute_after_simple_library_with_link()
2283 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_simple_library_with_link()
2287 error = clCompileProgram(another_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_simple_library_with_link()
2288 test_error( error, "Unable to compile a simple program" ); in test_execute_after_simple_library_with_link()
2291 …ked_program = clLinkProgram(context, 1, &deviceID, "", 2, program_and_archive, NULL, NULL, &error); in test_execute_after_simple_library_with_link()
2292 test_error( error, "Unable to create an executable from a binary and a library" ); in test_execute_after_simple_library_with_link()
2294 cl_kernel kernel = clCreateKernel(fully_linked_program, "CopyBuffer", &error); in test_execute_after_simple_library_with_link()
2295 test_error( error, "Unable to create a simple kernel" ); in test_execute_after_simple_library_with_link()
2297 error = verifyCopyBuffer(context, queue, kernel); in test_execute_after_simple_library_with_link()
2298 if (error != CL_SUCCESS) in test_execute_after_simple_library_with_link()
2299 return error; in test_execute_after_simple_library_with_link()
2301 cl_kernel another_kernel = clCreateKernel(fully_linked_program, "AnotherCopyBuffer", &error); in test_execute_after_simple_library_with_link()
2302 test_error( error, "Unable to create another simple kernel" ); in test_execute_after_simple_library_with_link()
2304 error = verifyCopyBuffer(context, queue, another_kernel); in test_execute_after_simple_library_with_link()
2305 if (error != CL_SUCCESS) in test_execute_after_simple_library_with_link()
2306 return error; in test_execute_after_simple_library_with_link()
2309 error = clReleaseKernel( kernel ); in test_execute_after_simple_library_with_link()
2310 test_error( error, "Unable to release kernel object" ); in test_execute_after_simple_library_with_link()
2312 error = clReleaseKernel( another_kernel ); in test_execute_after_simple_library_with_link()
2313 test_error( error, "Unable to release another kernel object" ); in test_execute_after_simple_library_with_link()
2315 error = clReleaseProgram( program ); in test_execute_after_simple_library_with_link()
2316 test_error( error, "Unable to release program object" ); in test_execute_after_simple_library_with_link()
2318 error = clReleaseProgram( another_program ); in test_execute_after_simple_library_with_link()
2319 test_error( error, "Unable to release program object" ); in test_execute_after_simple_library_with_link()
2321 error = clReleaseProgram( my_newly_minted_library ); in test_execute_after_simple_library_with_link()
2322 test_error( error, "Unable to release program object" ); in test_execute_after_simple_library_with_link()
2324 error = clReleaseProgram( fully_linked_program ); in test_execute_after_simple_library_with_link()
2325 test_error( error, "Unable to release program object" ); in test_execute_after_simple_library_with_link()
2332 int error; in test_two_file_link() local
2336 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_two_file_link()
2337 if( program == NULL || error != CL_SUCCESS ) in test_two_file_link()
2339 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_two_file_link()
2343 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_two_file_link()
2344 test_error( error, "Unable to compile a simple program" ); in test_two_file_link()
2347 …error = create_single_kernel_helper_create_program(context, &another_program, 1, &another_simple_k… in test_two_file_link()
2348 if( another_program == NULL || error != CL_SUCCESS ) in test_two_file_link()
2350 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_two_file_link()
2354 error = clCompileProgram(another_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_two_file_link()
2355 test_error( error, "Unable to compile a simple program" ); in test_two_file_link()
2358 …lly_linked_program = clLinkProgram(context, 1, &deviceID, "", 2, two_programs, NULL, NULL, &error); in test_two_file_link()
2359 test_error( error, "Unable to create an executable from two binaries" ); in test_two_file_link()
2362 error = clReleaseProgram( program ); in test_two_file_link()
2363 test_error( error, "Unable to release program object" ); in test_two_file_link()
2365 error = clReleaseProgram( another_program ); in test_two_file_link()
2366 test_error( error, "Unable to release program object" ); in test_two_file_link()
2368 error = clReleaseProgram( fully_linked_program ); in test_two_file_link()
2369 test_error( error, "Unable to release program object" ); in test_two_file_link()
2376 int error; in test_execute_after_two_file_link() local
2380 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_execute_after_two_file_link()
2381 if( program == NULL || error != CL_SUCCESS ) in test_execute_after_two_file_link()
2383 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_two_file_link()
2387 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_two_file_link()
2388 test_error( error, "Unable to compile a simple program" ); in test_execute_after_two_file_link()
2390 …error = create_single_kernel_helper_create_program(context, &another_program, 1, &another_simple_k… in test_execute_after_two_file_link()
2391 if( another_program == NULL || error != CL_SUCCESS ) in test_execute_after_two_file_link()
2393 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_two_file_link()
2397 error = clCompileProgram(another_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_two_file_link()
2398 test_error( error, "Unable to compile a simple program" ); in test_execute_after_two_file_link()
2401 …lly_linked_program = clLinkProgram(context, 1, &deviceID, "", 2, two_programs, NULL, NULL, &error); in test_execute_after_two_file_link()
2402 test_error( error, "Unable to create an executable from two binaries" ); in test_execute_after_two_file_link()
2404 cl_kernel kernel = clCreateKernel(fully_linked_program, "CopyBuffer", &error); in test_execute_after_two_file_link()
2405 test_error( error, "Unable to create a simple kernel" ); in test_execute_after_two_file_link()
2407 error = verifyCopyBuffer(context, queue, kernel); in test_execute_after_two_file_link()
2408 if (error != CL_SUCCESS) in test_execute_after_two_file_link()
2409 return error; in test_execute_after_two_file_link()
2411 cl_kernel another_kernel = clCreateKernel(fully_linked_program, "AnotherCopyBuffer", &error); in test_execute_after_two_file_link()
2412 test_error( error, "Unable to create another simple kernel" ); in test_execute_after_two_file_link()
2414 error = verifyCopyBuffer(context, queue, another_kernel); in test_execute_after_two_file_link()
2415 if (error != CL_SUCCESS) in test_execute_after_two_file_link()
2416 return error; in test_execute_after_two_file_link()
2419 error = clReleaseKernel( kernel ); in test_execute_after_two_file_link()
2420 test_error( error, "Unable to release kernel object" ); in test_execute_after_two_file_link()
2422 error = clReleaseKernel( another_kernel ); in test_execute_after_two_file_link()
2423 test_error( error, "Unable to release another kernel object" ); in test_execute_after_two_file_link()
2425 error = clReleaseProgram( program ); in test_execute_after_two_file_link()
2426 test_error( error, "Unable to release program object" ); in test_execute_after_two_file_link()
2428 error = clReleaseProgram( another_program ); in test_execute_after_two_file_link()
2429 test_error( error, "Unable to release program object" ); in test_execute_after_two_file_link()
2431 error = clReleaseProgram( fully_linked_program ); in test_execute_after_two_file_link()
2432 test_error( error, "Unable to release program object" ); in test_execute_after_two_file_link()
2439 int error; in test_execute_after_embedded_header_link() local
2444 … program = clCreateProgramWithSource(context, 1, &another_simple_kernel_with_header, NULL, &error); in test_execute_after_embedded_header_link()
2445 if( program == NULL || error != CL_SUCCESS ) in test_execute_after_embedded_header_link()
2447 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_embedded_header_link()
2451 header = clCreateProgramWithSource(context, 1, &simple_header, NULL, &error); in test_execute_after_embedded_header_link()
2452 if( header == NULL || error != CL_SUCCESS ) in test_execute_after_embedded_header_link()
2454 …ble to create a simple header program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_embedded_header_link()
2458 …error = clCompileProgram(program, 1, &deviceID, NULL, 1, &header, &simple_header_name, NULL, NULL); in test_execute_after_embedded_header_link()
2459 test_error( error, "Unable to compile a simple program with embedded header" ); in test_execute_after_embedded_header_link()
2461 simple_program = clCreateProgramWithSource(context, 1, &simple_kernel, NULL, &error); in test_execute_after_embedded_header_link()
2462 if( simple_program == NULL || error != CL_SUCCESS ) in test_execute_after_embedded_header_link()
2464 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_embedded_header_link()
2468 error = clCompileProgram(simple_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_embedded_header_link()
2469 test_error( error, "Unable to compile a simple program" ); in test_execute_after_embedded_header_link()
2472 …lly_linked_program = clLinkProgram(context, 1, &deviceID, "", 2, two_programs, NULL, NULL, &error); in test_execute_after_embedded_header_link()
2473 …test_error( error, "Unable to create an executable from two binaries, one compiled with embedded h… in test_execute_after_embedded_header_link()
2475 cl_kernel kernel = clCreateKernel(fully_linked_program, "CopyBuffer", &error); in test_execute_after_embedded_header_link()
2476 test_error( error, "Unable to create a simple kernel" ); in test_execute_after_embedded_header_link()
2478 error = verifyCopyBuffer(context, queue, kernel); in test_execute_after_embedded_header_link()
2479 if (error != CL_SUCCESS) in test_execute_after_embedded_header_link()
2480 return error; in test_execute_after_embedded_header_link()
2482 cl_kernel another_kernel = clCreateKernel(fully_linked_program, "AnotherCopyBuffer", &error); in test_execute_after_embedded_header_link()
2483 test_error( error, "Unable to create another simple kernel" ); in test_execute_after_embedded_header_link()
2485 error = verifyCopyBuffer(context, queue, another_kernel); in test_execute_after_embedded_header_link()
2486 if (error != CL_SUCCESS) in test_execute_after_embedded_header_link()
2487 return error; in test_execute_after_embedded_header_link()
2490 error = clReleaseKernel( kernel ); in test_execute_after_embedded_header_link()
2491 test_error( error, "Unable to release kernel object" ); in test_execute_after_embedded_header_link()
2493 error = clReleaseKernel( another_kernel ); in test_execute_after_embedded_header_link()
2494 test_error( error, "Unable to release another kernel object" ); in test_execute_after_embedded_header_link()
2496 error = clReleaseProgram( program ); in test_execute_after_embedded_header_link()
2497 test_error( error, "Unable to release program object" ); in test_execute_after_embedded_header_link()
2499 error = clReleaseProgram( header ); in test_execute_after_embedded_header_link()
2500 test_error( error, "Unable to release program object" ); in test_execute_after_embedded_header_link()
2502 error = clReleaseProgram( simple_program ); in test_execute_after_embedded_header_link()
2503 test_error( error, "Unable to release program object" ); in test_execute_after_embedded_header_link()
2505 error = clReleaseProgram( fully_linked_program ); in test_execute_after_embedded_header_link()
2506 test_error( error, "Unable to release program object" ); in test_execute_after_embedded_header_link()
2522 int error; in test_execute_after_included_header_link() local
2527 … program = clCreateProgramWithSource(context, 1, &another_simple_kernel_with_header, NULL, &error); in test_execute_after_included_header_link()
2528 if( program == NULL || error != CL_SUCCESS ) in test_execute_after_included_header_link()
2530 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_included_header_link()
2572 error = clCompileProgram(program, 1, &deviceID, "-I/tmp/foo/bar", 0, NULL, NULL, NULL, NULL); in test_execute_after_included_header_link()
2574 error = clCompileProgram(program, 1, &deviceID, "-Ifoo/bar", 0, NULL, NULL, NULL, NULL); in test_execute_after_included_header_link()
2576 test_error( error, "Unable to compile a simple program with included header" ); in test_execute_after_included_header_link()
2600 simple_program = clCreateProgramWithSource(context, 1, &simple_kernel, NULL, &error); in test_execute_after_included_header_link()
2601 if( simple_program == NULL || error != CL_SUCCESS ) in test_execute_after_included_header_link()
2603 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_execute_after_included_header_link()
2607 error = clCompileProgram(simple_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_execute_after_included_header_link()
2608 test_error( error, "Unable to compile a simple program" ); in test_execute_after_included_header_link()
2611 …lly_linked_program = clLinkProgram(context, 1, &deviceID, "", 2, two_programs, NULL, NULL, &error); in test_execute_after_included_header_link()
2612 …test_error( error, "Unable to create an executable from two binaries, one compiled with embedded h… in test_execute_after_included_header_link()
2614 cl_kernel kernel = clCreateKernel(fully_linked_program, "CopyBuffer", &error); in test_execute_after_included_header_link()
2615 test_error( error, "Unable to create a simple kernel" ); in test_execute_after_included_header_link()
2617 error = verifyCopyBuffer(context, queue, kernel); in test_execute_after_included_header_link()
2618 if (error != CL_SUCCESS) in test_execute_after_included_header_link()
2619 return error; in test_execute_after_included_header_link()
2621 cl_kernel another_kernel = clCreateKernel(fully_linked_program, "AnotherCopyBuffer", &error); in test_execute_after_included_header_link()
2622 test_error( error, "Unable to create another simple kernel" ); in test_execute_after_included_header_link()
2624 error = verifyCopyBuffer(context, queue, another_kernel); in test_execute_after_included_header_link()
2625 if (error != CL_SUCCESS) in test_execute_after_included_header_link()
2626 return error; in test_execute_after_included_header_link()
2629 error = clReleaseKernel( kernel ); in test_execute_after_included_header_link()
2630 test_error( error, "Unable to release kernel object" ); in test_execute_after_included_header_link()
2632 error = clReleaseKernel( another_kernel ); in test_execute_after_included_header_link()
2633 test_error( error, "Unable to release another kernel object" ); in test_execute_after_included_header_link()
2635 error = clReleaseProgram( program ); in test_execute_after_included_header_link()
2636 test_error( error, "Unable to release program object" ); in test_execute_after_included_header_link()
2638 error = clReleaseProgram( simple_program ); in test_execute_after_included_header_link()
2639 test_error( error, "Unable to release program object" ); in test_execute_after_included_header_link()
2641 error = clReleaseProgram( fully_linked_program ); in test_execute_after_included_header_link()
2642 test_error( error, "Unable to release program object" ); in test_execute_after_included_header_link()
2649 int error; in test_program_binary_type() local
2657 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_program_binary_type()
2658 if( program == NULL || error != CL_SUCCESS ) in test_program_binary_type()
2660 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_program_binary_type()
2664 error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_program_binary_type()
2665 test_error( error, "Unable to compile a simple program" ); in test_program_binary_type()
2667 …error = clGetProgramBuildInfo (program, deviceID, CL_PROGRAM_BINARY_TYPE, sizeof(cl_program_binary… in test_program_binary_type()
2668 test_error( error, "Unable to get program binary type" ); in test_program_binary_type()
2677 …error = clGetProgramInfo( program, CL_PROGRAM_BINARY_SIZES, sizeof( binarySize ), &binarySize, NUL… in test_program_binary_type()
2678 test_error( error, "Unable to get binary size" ); in test_program_binary_type()
2699 error = clGetProgramInfo( program, CL_PROGRAM_BINARIES, 0, NULL, &size ); in test_program_binary_type()
2700 test_error( error, "Unable to get expected size of binaries array" ); in test_program_binary_type()
2708 error = clGetProgramInfo( program, CL_PROGRAM_BINARIES, sizeof( buffers ), &buffers, NULL ); in test_program_binary_type()
2709 test_error( error, "Unable to get program binary" ); in test_program_binary_type()
2712 …WithBinary(context, 1, &deviceID, &binarySize, (const unsigned char**)buffers, loadErrors, &error); in test_program_binary_type()
2713 test_error( error, "Unable to create program with binary" ); in test_program_binary_type()
2715 …error = clGetProgramBuildInfo (program_with_binary, deviceID, CL_PROGRAM_BINARY_TYPE, sizeof(cl_pr… in test_program_binary_type()
2716 test_error( error, "Unable to get program binary type" ); in test_program_binary_type()
2726 …LinkProgram(context, 1, &deviceID, "-create-library", 1, &program_with_binary, NULL, NULL, &error); in test_program_binary_type()
2727 test_error( error, "Unable to create a simple library" ); in test_program_binary_type()
2728 …error = clGetProgramBuildInfo (my_newly_minted_library, deviceID, CL_PROGRAM_BINARY_TYPE, sizeof(c… in test_program_binary_type()
2729 test_error( error, "Unable to get program binary type" ); in test_program_binary_type()
2738 …error = clGetProgramInfo( my_newly_minted_library, CL_PROGRAM_BINARY_SIZES, sizeof( binarySize ), … in test_program_binary_type()
2739 test_error( error, "Unable to get binary size" ); in test_program_binary_type()
2759 error = clGetProgramInfo( my_newly_minted_library, CL_PROGRAM_BINARIES, 0, NULL, &size ); in test_program_binary_type()
2760 test_error( error, "Unable to get expected size of binaries array" ); in test_program_binary_type()
2768 …error = clGetProgramInfo( my_newly_minted_library, CL_PROGRAM_BINARIES, sizeof( buffers ), &buffer… in test_program_binary_type()
2769 test_error( error, "Unable to get program binary" ); in test_program_binary_type()
2772 …WithBinary(context, 1, &deviceID, &binarySize, (const unsigned char**)buffers, loadErrors, &error); in test_program_binary_type()
2773 test_error( error, "Unable to create program with binary" ); in test_program_binary_type()
2774 …error = clGetProgramBuildInfo (library_with_binary, deviceID, CL_PROGRAM_BINARY_TYPE, sizeof(cl_pr… in test_program_binary_type()
2775 test_error( error, "Unable to get program binary type" ); in test_program_binary_type()
2784 …error = create_single_kernel_helper_create_program(context, &another_program, 1, &another_simple_k… in test_program_binary_type()
2785 if( another_program == NULL || error != CL_SUCCESS ) in test_program_binary_type()
2787 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_program_binary_type()
2791 error = clCompileProgram(another_program, 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_program_binary_type()
2792 test_error( error, "Unable to compile a simple program" ); in test_program_binary_type()
2795 …ked_program = clLinkProgram(context, 1, &deviceID, "", 2, program_and_archive, NULL, NULL, &error); in test_program_binary_type()
2796 test_error( error, "Unable to create an executable from a binary and a library" ); in test_program_binary_type()
2798 …error = clGetProgramBuildInfo (fully_linked_program, deviceID, CL_PROGRAM_BINARY_TYPE, sizeof(cl_p… in test_program_binary_type()
2799 test_error( error, "Unable to get program binary type" ); in test_program_binary_type()
2808 …error = clGetProgramInfo( fully_linked_program, CL_PROGRAM_BINARY_SIZES, sizeof( binarySize ), &bi… in test_program_binary_type()
2809 test_error( error, "Unable to get binary size" ); in test_program_binary_type()
2830 error = clGetProgramInfo( fully_linked_program, CL_PROGRAM_BINARIES, 0, NULL, &size ); in test_program_binary_type()
2831 test_error( error, "Unable to get expected size of binaries array" ); in test_program_binary_type()
2839 …error = clGetProgramInfo( fully_linked_program, CL_PROGRAM_BINARIES, sizeof( buffers ), &buffers, … in test_program_binary_type()
2840 test_error( error, "Unable to get program binary" ); in test_program_binary_type()
2843 …WithBinary(context, 1, &deviceID, &binarySize, (const unsigned char**)buffers, loadErrors, &error); in test_program_binary_type()
2844 test_error( error, "Unable to create program with binary" ); in test_program_binary_type()
2846 …error = clGetProgramBuildInfo (fully_linked_program_with_binary, deviceID, CL_PROGRAM_BINARY_TYPE,… in test_program_binary_type()
2847 test_error( error, "Unable to get program binary type" ); in test_program_binary_type()
2857 error = clBuildProgram(fully_linked_program_with_binary, 1, &deviceID, NULL, NULL, NULL); in test_program_binary_type()
2858 test_error( error, "Unable to build a simple program" ); in test_program_binary_type()
2860 cl_kernel kernel = clCreateKernel(fully_linked_program_with_binary, "CopyBuffer", &error); in test_program_binary_type()
2861 test_error( error, "Unable to create a simple kernel" ); in test_program_binary_type()
2863 error = verifyCopyBuffer(context, queue, kernel); in test_program_binary_type()
2864 if (error != CL_SUCCESS) in test_program_binary_type()
2865 return error; in test_program_binary_type()
2867 …nel another_kernel = clCreateKernel(fully_linked_program_with_binary, "AnotherCopyBuffer", &error); in test_program_binary_type()
2868 test_error( error, "Unable to create another simple kernel" ); in test_program_binary_type()
2870 error = verifyCopyBuffer(context, queue, another_kernel); in test_program_binary_type()
2871 if (error != CL_SUCCESS) in test_program_binary_type()
2872 return error; in test_program_binary_type()
2875 error = clReleaseKernel( kernel ); in test_program_binary_type()
2876 test_error( error, "Unable to release kernel object" ); in test_program_binary_type()
2878 error = clReleaseKernel( another_kernel ); in test_program_binary_type()
2879 test_error( error, "Unable to release another kernel object" ); in test_program_binary_type()
2881 error = clReleaseProgram( program ); in test_program_binary_type()
2882 test_error( error, "Unable to release program object" ); in test_program_binary_type()
2885 error = create_single_kernel_helper_create_program(context, &program, 1, &simple_kernel); in test_program_binary_type()
2886 if( program == NULL || error != CL_SUCCESS ) in test_program_binary_type()
2888 …nable to create a simple test program! (%s in %s:%d)\n", IGetErrorString( error ), __FILE__, __LIN… in test_program_binary_type()
2892 error = clBuildProgram(program, 1, &deviceID, NULL, NULL, NULL); in test_program_binary_type()
2893 test_error( error, "Unable to build a simple program" ); in test_program_binary_type()
2894 …error = clGetProgramBuildInfo (program, deviceID, CL_PROGRAM_BINARY_TYPE, sizeof(cl_program_binary… in test_program_binary_type()
2895 test_error( error, "Unable to get program binary type" ); in test_program_binary_type()
2904 error = clReleaseProgram( program ); in test_program_binary_type()
2905 test_error( error, "Unable to release program object" ); in test_program_binary_type()
2907 error = clReleaseProgram( another_program ); in test_program_binary_type()
2908 test_error( error, "Unable to release program object" ); in test_program_binary_type()
2910 error = clReleaseProgram( my_newly_minted_library ); in test_program_binary_type()
2911 test_error( error, "Unable to release program object" ); in test_program_binary_type()
2913 error = clReleaseProgram( library_with_binary ); in test_program_binary_type()
2914 test_error( error, "Unable to release program object" ); in test_program_binary_type()
2916 error = clReleaseProgram( fully_linked_program ); in test_program_binary_type()
2917 test_error( error, "Unable to release program object" ); in test_program_binary_type()
2919 error = clReleaseProgram( fully_linked_program_with_binary ); in test_program_binary_type()
2920 test_error( error, "Unable to release program object" ); in test_program_binary_type()
2922 error = clReleaseProgram( program_with_binary ); in test_program_binary_type()
2923 test_error( error, "Unable to release program object" ); in test_program_binary_type()
2972 int error; in test_large_compile_and_link_status_options_log() local
3018 error = create_single_kernel_helper_create_program(context, &program, 2 * numLines + 2, lines); in test_large_compile_and_link_status_options_log()
3019 if( program == NULL || error != CL_SUCCESS ) in test_large_compile_and_link_status_options_log()
3021 …est program with %d lines! (%s) (in %s:%d)\n", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_compile_and_link_status_options_log()
3026 …error = clGetProgramBuildInfo( program, deviceID, CL_PROGRAM_BUILD_STATUS, sizeof( status ), &stat… in test_large_compile_and_link_status_options_log()
3027 test_error( error, "Unable to get program compile status" ); in test_large_compile_and_link_status_options_log()
3035 …error = clCompileProgram(program, 1, &deviceID, NULL, 0, NULL, NULL, test_notify_compile_complete,… in test_large_compile_and_link_status_options_log()
3036 test_error( error, "Unable to compile a simple program" ); in test_large_compile_and_link_status_options_log()
3039 …error = clGetProgramBuildInfo( program, deviceID, CL_PROGRAM_BUILD_STATUS, sizeof( status ), &stat… in test_large_compile_and_link_status_options_log()
3040 test_error( error, "Unable to get program compile status" ); in test_large_compile_and_link_status_options_log()
3046 …error = clGetProgramBuildInfo( program, deviceID, CL_PROGRAM_BUILD_STATUS, sizeof( status ), &stat… in test_large_compile_and_link_status_options_log()
3047 test_error( error, "Unable to get program compile status" ); in test_large_compile_and_link_status_options_log()
3055 error = clGetProgramBuildInfo( program, deviceID, CL_PROGRAM_BUILD_LOG, 0, NULL, &size_ret ); in test_large_compile_and_link_status_options_log()
3056 test_error( error, "Device failed to return compile log size" ); in test_large_compile_and_link_status_options_log()
3058 …error = clGetProgramBuildInfo( program, deviceID, CL_PROGRAM_BUILD_LOG, size_ret, compile_log, NUL… in test_large_compile_and_link_status_options_log()
3059 if (error != CL_SUCCESS){ in test_large_compile_and_link_status_options_log()
3061 test_error(error, "clGetProgramBuildInfo CL_PROGRAM_BUILD_LOG failed"); in test_large_compile_and_link_status_options_log()
3066 … error = clGetProgramBuildInfo( program, deviceID, CL_PROGRAM_BUILD_OPTIONS, 0, NULL, &size_ret ); in test_large_compile_and_link_status_options_log()
3067 test_error(error, "Device failed to return compile options size"); in test_large_compile_and_link_status_options_log()
3069 …error = clGetProgramBuildInfo( program, deviceID, CL_PROGRAM_BUILD_OPTIONS, size_ret, compile_opti… in test_large_compile_and_link_status_options_log()
3070 …test_error(error, "Device failed to return compile options.\nclGetProgramBuildInfo CL_PROGRAM_BUIL… in test_large_compile_and_link_status_options_log()
3080 …error = create_single_kernel_helper_create_program(context, &simple_kernels[i], 1, &kernel_source); in test_large_compile_and_link_status_options_log()
3081 if( simple_kernels[i] == NULL || error != CL_SUCCESS ) in test_large_compile_and_link_status_options_log()
3083 …ng test program with %d lines! (%s in %s:%d)", numLines, IGetErrorString( error ), __FILE__, __LIN… in test_large_compile_and_link_status_options_log()
3088 error = clCompileProgram(simple_kernels[i], 1, &deviceID, NULL, 0, NULL, NULL, NULL, NULL); in test_large_compile_and_link_status_options_log()
3089 test_error( error, "Unable to compile a simple program" ); in test_large_compile_and_link_status_options_log()
3095 …, numLines, simple_kernels, test_notify_create_library_complete, (void *)"create library", &error); in test_large_compile_and_link_status_options_log()
3096 test_error( error, "Unable to create a multi-line library" ); in test_large_compile_and_link_status_options_log()
3099 …error = clGetProgramBuildInfo( my_newly_minted_library, deviceID, CL_PROGRAM_BUILD_STATUS, sizeof(… in test_large_compile_and_link_status_options_log()
3100 test_error( error, "Unable to get library creation link status" ); in test_large_compile_and_link_status_options_log()
3106 …error = clGetProgramBuildInfo( my_newly_minted_library, deviceID, CL_PROGRAM_BUILD_STATUS, sizeof(… in test_large_compile_and_link_status_options_log()
3107 test_error( error, "Unable to get library creation link status" ); in test_large_compile_and_link_status_options_log()
3114 …error = clGetProgramBuildInfo( my_newly_minted_library, deviceID, CL_PROGRAM_BUILD_LOG, 0, NULL, &… in test_large_compile_and_link_status_options_log()
3115 test_error( error, "Device failed to return a library creation log size" ); in test_large_compile_and_link_status_options_log()
3117 …error = clGetProgramBuildInfo( my_newly_minted_library, deviceID, CL_PROGRAM_BUILD_LOG, size_ret, … in test_large_compile_and_link_status_options_log()
3118 if (error != CL_SUCCESS) { in test_large_compile_and_link_status_options_log()
3120 test_error(error, "clGetProgramBuildInfo CL_PROGRAM_BUILD_LOG failed"); in test_large_compile_and_link_status_options_log()
3125 …error = clGetProgramBuildInfo( my_newly_minted_library, deviceID, CL_PROGRAM_BUILD_OPTIONS, 0, NUL… in test_large_compile_and_link_status_options_log()
3126 test_error(error, "Device failed to return library creation options size"); in test_large_compile_and_link_status_options_log()
3128 …error = clGetProgramBuildInfo( my_newly_minted_library, deviceID, CL_PROGRAM_BUILD_OPTIONS, size_r… in test_large_compile_and_link_status_options_log()
3129 …test_error(error, "Device failed to return library creation options.\nclGetProgramBuildInfo CL_PRO… in test_large_compile_and_link_status_options_log()
3136 …am(context, 1, &deviceID, NULL, 2, programs, test_notify_link_complete, (void *)"linking", &error); in test_large_compile_and_link_status_options_log()
3137 test_error( error, "Unable to link a program with a library" ); in test_large_compile_and_link_status_options_log()
3140 …error = clGetProgramBuildInfo( my_newly_linked_program, deviceID, CL_PROGRAM_BUILD_STATUS, sizeof(… in test_large_compile_and_link_status_options_log()
3141 test_error( error, "Unable to get program link status" ); in test_large_compile_and_link_status_options_log()
3147 …error = clGetProgramBuildInfo( my_newly_linked_program, deviceID, CL_PROGRAM_BUILD_STATUS, sizeof(… in test_large_compile_and_link_status_options_log()
3148 test_error( error, "Unable to get program link status" ); in test_large_compile_and_link_status_options_log()
3155 …error = clGetProgramBuildInfo( my_newly_linked_program, deviceID, CL_PROGRAM_BUILD_LOG, 0, NULL, &… in test_large_compile_and_link_status_options_log()
3156 test_error( error, "Device failed to return a linking log size" ); in test_large_compile_and_link_status_options_log()
3158 …error = clGetProgramBuildInfo( my_newly_linked_program, deviceID, CL_PROGRAM_BUILD_LOG, size_ret, … in test_large_compile_and_link_status_options_log()
3159 if (error != CL_SUCCESS){ in test_large_compile_and_link_status_options_log()
3161 test_error(error, "clGetProgramBuildInfo CL_PROGRAM_BUILD_LOG failed"); in test_large_compile_and_link_status_options_log()
3166 …error = clGetProgramBuildInfo( my_newly_linked_program, deviceID, CL_PROGRAM_BUILD_OPTIONS, 0, NUL… in test_large_compile_and_link_status_options_log()
3167 test_error(error, "Device failed to return linking options size"); in test_large_compile_and_link_status_options_log()
3169 …error = clGetProgramBuildInfo( my_newly_linked_program, deviceID, CL_PROGRAM_BUILD_OPTIONS, size_r… in test_large_compile_and_link_status_options_log()
3170 …test_error(error, "Device failed to return linking options.\nclGetProgramBuildInfo CL_PROGRAM_BUIL… in test_large_compile_and_link_status_options_log()
3176 cl_kernel kernel = clCreateKernel(my_newly_linked_program, "CompositeKernel", &error); in test_large_compile_and_link_status_options_log()
3177 test_error( error, "Unable to create a composite kernel" ); in test_large_compile_and_link_status_options_log()
3180 error = verifyCopyBuffer(context, queue, kernel); in test_large_compile_and_link_status_options_log()
3181 if (error != CL_SUCCESS) in test_large_compile_and_link_status_options_log()
3182 return error; in test_large_compile_and_link_status_options_log()
3185 error = clReleaseKernel( kernel ); in test_large_compile_and_link_status_options_log()
3186 test_error( error, "Unable to release kernel object" ); in test_large_compile_and_link_status_options_log()
3188 error = clReleaseProgram( program ); in test_large_compile_and_link_status_options_log()
3189 test_error( error, "Unable to release program object" ); in test_large_compile_and_link_status_options_log()
3200 error = clReleaseProgram( simple_kernels[i] ); in test_large_compile_and_link_status_options_log()
3201 test_error( error, "Unable to release program object" ); in test_large_compile_and_link_status_options_log()
3205 error = clReleaseProgram( my_newly_minted_library ); in test_large_compile_and_link_status_options_log()
3206 test_error( error, "Unable to release program object" ); in test_large_compile_and_link_status_options_log()
3208 error = clReleaseProgram( my_newly_linked_program ); in test_large_compile_and_link_status_options_log()
3209 test_error( error, "Unable to release program object" ); in test_large_compile_and_link_status_options_log()