Anthony Barbier | 3a6163e | 2018-08-10 17:36:36 +0100 | [diff] [blame] | 1 | #define CL_TARGET_OPENCL_VERSION 200 |
Anthony Barbier | 6ff3b19 | 2017-09-04 18:44:23 +0100 | [diff] [blame] | 2 | #include <CL/cl.h> |
| 3 | #include <stdio.h> |
| 4 | |
| 5 | #define PRINT_STUB_ERROR printf("\n!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!\nERROR: %s from stub libOpenCL.so library called! This library can be used to resolve OpenCL symbols at compile time but must *not* be in your runtime path (You need to use a real OpenCL implementation, this one is empty)\n!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!\n", __func__) |
| 6 | |
| 7 | cl_int |
| 8 | clGetPlatformIDs(cl_uint num_entries, |
| 9 | cl_platform_id * platforms, |
| 10 | cl_uint * num_platforms) |
| 11 | { |
| 12 | PRINT_STUB_ERROR; |
| 13 | return CL_OUT_OF_RESOURCES; |
| 14 | } |
| 15 | |
| 16 | cl_int |
| 17 | clGetPlatformInfo(cl_platform_id platform, |
| 18 | cl_platform_info param_name, |
| 19 | size_t param_value_size, |
| 20 | void * param_value, |
| 21 | size_t * param_value_size_ret) |
| 22 | { |
| 23 | PRINT_STUB_ERROR; |
| 24 | return CL_OUT_OF_RESOURCES; |
| 25 | } |
| 26 | |
| 27 | cl_int |
| 28 | clGetDeviceIDs(cl_platform_id platform, |
| 29 | cl_device_type device_type, |
| 30 | cl_uint num_entries, |
| 31 | cl_device_id * devices, |
| 32 | cl_uint * num_devices) |
| 33 | { |
| 34 | PRINT_STUB_ERROR; |
| 35 | return CL_OUT_OF_RESOURCES; |
| 36 | } |
| 37 | |
| 38 | cl_int |
| 39 | clGetDeviceInfo(cl_device_id device, |
| 40 | cl_device_info param_name, |
| 41 | size_t param_value_size, |
| 42 | void * param_value, |
| 43 | size_t * param_value_size_ret) |
| 44 | { |
| 45 | PRINT_STUB_ERROR; |
| 46 | return CL_OUT_OF_RESOURCES; |
| 47 | } |
| 48 | |
| 49 | cl_int |
| 50 | clCreateSubDevices(cl_device_id in_device, |
| 51 | const cl_device_partition_property * properties, |
| 52 | cl_uint num_devices, |
| 53 | cl_device_id * out_devices, |
| 54 | cl_uint * num_devices_ret) |
| 55 | { |
| 56 | PRINT_STUB_ERROR; |
| 57 | return CL_OUT_OF_RESOURCES; |
| 58 | } |
| 59 | |
| 60 | cl_int |
| 61 | clRetainDevice(cl_device_id device) |
| 62 | { |
| 63 | PRINT_STUB_ERROR; |
| 64 | return CL_OUT_OF_RESOURCES; |
| 65 | } |
| 66 | |
| 67 | cl_int |
| 68 | clReleaseDevice(cl_device_id device) |
| 69 | { |
| 70 | PRINT_STUB_ERROR; |
| 71 | return CL_OUT_OF_RESOURCES; |
| 72 | } |
| 73 | |
| 74 | cl_context |
| 75 | clCreateContext(const cl_context_properties * properties, |
| 76 | cl_uint num_devices, |
| 77 | const cl_device_id * devices, |
| 78 | void (CL_CALLBACK * pfn_notify)(const char *, const void *, size_t, void *), |
| 79 | void * user_data, |
| 80 | cl_int * errcode_ret) |
| 81 | { |
| 82 | PRINT_STUB_ERROR; |
| 83 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 84 | return NULL; |
| 85 | } |
| 86 | |
| 87 | cl_context |
| 88 | clCreateContextFromType(const cl_context_properties * properties, |
| 89 | cl_device_type device_type, |
| 90 | void (CL_CALLBACK * pfn_notify )(const char *, const void *, size_t, void *), |
| 91 | void * user_data, |
| 92 | cl_int * errcode_ret) |
| 93 | { |
| 94 | PRINT_STUB_ERROR; |
| 95 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 96 | return NULL; |
| 97 | } |
| 98 | |
| 99 | cl_int |
| 100 | clRetainContext(cl_context context) |
| 101 | { |
| 102 | PRINT_STUB_ERROR; |
| 103 | return CL_OUT_OF_RESOURCES; |
| 104 | } |
| 105 | |
| 106 | cl_int |
| 107 | clReleaseContext(cl_context context) |
| 108 | { |
| 109 | PRINT_STUB_ERROR; |
| 110 | return CL_OUT_OF_RESOURCES; |
| 111 | } |
| 112 | |
| 113 | cl_int |
| 114 | clGetContextInfo(cl_context context, |
| 115 | cl_context_info param_name, |
| 116 | size_t param_value_size, |
| 117 | void * param_value, |
| 118 | size_t * param_value_size_ret) |
| 119 | { |
| 120 | PRINT_STUB_ERROR; |
| 121 | return CL_OUT_OF_RESOURCES; |
| 122 | } |
| 123 | |
| 124 | cl_command_queue |
| 125 | clCreateCommandQueue(cl_context context, |
| 126 | cl_device_id device, |
| 127 | cl_command_queue_properties properties, |
| 128 | cl_int * errcode_ret) |
| 129 | { |
| 130 | PRINT_STUB_ERROR; |
| 131 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 132 | return NULL; |
| 133 | } |
| 134 | |
| 135 | cl_int |
| 136 | clRetainCommandQueue(cl_command_queue command_queue) |
| 137 | { |
| 138 | PRINT_STUB_ERROR; |
| 139 | return CL_OUT_OF_RESOURCES; |
| 140 | } |
| 141 | |
| 142 | cl_int |
| 143 | clReleaseCommandQueue(cl_command_queue command_queue) |
| 144 | { |
| 145 | PRINT_STUB_ERROR; |
| 146 | return CL_OUT_OF_RESOURCES; |
| 147 | } |
| 148 | |
| 149 | cl_int |
| 150 | clGetCommandQueueInfo(cl_command_queue command_queue, |
| 151 | cl_command_queue_info param_name, |
| 152 | size_t param_value_size, |
| 153 | void * param_value, |
| 154 | size_t * param_value_size_ret) |
| 155 | { |
| 156 | PRINT_STUB_ERROR; |
| 157 | return CL_OUT_OF_RESOURCES; |
| 158 | } |
| 159 | |
| 160 | cl_mem |
| 161 | clCreateBuffer(cl_context context, |
| 162 | cl_mem_flags flags, |
| 163 | size_t size, |
| 164 | void * host_ptr, |
| 165 | cl_int * errcode_ret) |
| 166 | { |
| 167 | PRINT_STUB_ERROR; |
| 168 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 169 | return NULL; |
| 170 | } |
| 171 | |
| 172 | cl_mem |
| 173 | clCreateSubBuffer(cl_mem buffer, |
| 174 | cl_mem_flags flags, |
| 175 | cl_buffer_create_type buffer_create_type, |
| 176 | const void * buffer_create_info, |
| 177 | cl_int * errcode_ret) |
| 178 | { |
| 179 | PRINT_STUB_ERROR; |
| 180 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 181 | return NULL; |
| 182 | } |
| 183 | |
| 184 | cl_mem |
| 185 | clCreateImage(cl_context context, |
| 186 | cl_mem_flags flags, |
| 187 | const cl_image_format * image_format, |
| 188 | const cl_image_desc * image_desc, |
| 189 | void * host_ptr, |
| 190 | cl_int * errcode_ret) |
| 191 | { |
| 192 | PRINT_STUB_ERROR; |
| 193 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 194 | return NULL; |
| 195 | } |
| 196 | |
| 197 | cl_int |
| 198 | clRetainMemObject(cl_mem memobj) |
| 199 | { |
| 200 | PRINT_STUB_ERROR; |
| 201 | return CL_OUT_OF_RESOURCES; |
| 202 | } |
| 203 | |
| 204 | cl_int |
| 205 | clReleaseMemObject(cl_mem memobj) |
| 206 | { |
| 207 | PRINT_STUB_ERROR; |
| 208 | return CL_OUT_OF_RESOURCES; |
| 209 | } |
| 210 | |
| 211 | cl_int |
| 212 | clGetSupportedImageFormats(cl_context context, |
| 213 | cl_mem_flags flags, |
| 214 | cl_mem_object_type image_type, |
| 215 | cl_uint num_entries, |
| 216 | cl_image_format * image_formats, |
| 217 | cl_uint * num_image_formats) |
| 218 | { |
| 219 | PRINT_STUB_ERROR; |
| 220 | return CL_OUT_OF_RESOURCES; |
| 221 | } |
| 222 | |
| 223 | cl_int |
| 224 | clGetMemObjectInfo(cl_mem memobj, |
| 225 | cl_mem_info param_name, |
| 226 | size_t param_value_size, |
| 227 | void * param_value, |
| 228 | size_t * param_value_size_ret) |
| 229 | { |
| 230 | PRINT_STUB_ERROR; |
| 231 | return CL_OUT_OF_RESOURCES; |
| 232 | } |
| 233 | |
| 234 | cl_int |
| 235 | clGetImageInfo(cl_mem image, |
| 236 | cl_image_info param_name, |
| 237 | size_t param_value_size, |
| 238 | void * param_value, |
| 239 | size_t * param_value_size_ret) |
| 240 | { |
| 241 | PRINT_STUB_ERROR; |
| 242 | return CL_OUT_OF_RESOURCES; |
| 243 | } |
| 244 | |
| 245 | cl_int |
| 246 | clSetMemObjectDestructorCallback( cl_mem memobj, |
| 247 | void (CL_CALLBACK * pfn_notify)( cl_mem memobj, void* user_data), |
| 248 | void * user_data ) |
| 249 | { |
| 250 | PRINT_STUB_ERROR; |
| 251 | return CL_OUT_OF_RESOURCES; |
| 252 | } |
| 253 | |
| 254 | cl_sampler |
| 255 | clCreateSampler(cl_context context, |
| 256 | cl_bool normalized_coords, |
| 257 | cl_addressing_mode addressing_mode, |
| 258 | cl_filter_mode filter_mode, |
| 259 | cl_int * errcode_ret) |
| 260 | { |
| 261 | PRINT_STUB_ERROR; |
| 262 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 263 | return NULL; |
| 264 | } |
| 265 | |
| 266 | cl_int |
| 267 | clRetainSampler(cl_sampler sampler) |
| 268 | { |
| 269 | PRINT_STUB_ERROR; |
| 270 | return CL_OUT_OF_RESOURCES; |
| 271 | } |
| 272 | |
| 273 | cl_int |
| 274 | clReleaseSampler(cl_sampler sampler) |
| 275 | { |
| 276 | PRINT_STUB_ERROR; |
| 277 | return CL_OUT_OF_RESOURCES; |
| 278 | } |
| 279 | |
| 280 | cl_int |
| 281 | clGetSamplerInfo(cl_sampler sampler, |
| 282 | cl_sampler_info param_name, |
| 283 | size_t param_value_size, |
| 284 | void * param_value, |
| 285 | size_t * param_value_size_ret) |
| 286 | { |
| 287 | PRINT_STUB_ERROR; |
| 288 | return CL_OUT_OF_RESOURCES; |
| 289 | } |
| 290 | |
| 291 | cl_program |
| 292 | clCreateProgramWithSource(cl_context context, |
| 293 | cl_uint count, |
| 294 | const char ** strings, |
| 295 | const size_t * lengths, |
| 296 | cl_int * errcode_ret) |
| 297 | { |
| 298 | PRINT_STUB_ERROR; |
| 299 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 300 | return NULL; |
| 301 | } |
| 302 | |
| 303 | cl_program |
| 304 | clCreateProgramWithBinary(cl_context context, |
| 305 | cl_uint num_devices, |
| 306 | const cl_device_id * device_list, |
| 307 | const size_t * lengths, |
| 308 | const unsigned char ** binaries, |
| 309 | cl_int * binary_status, |
| 310 | cl_int * errcode_ret) |
| 311 | { |
| 312 | PRINT_STUB_ERROR; |
| 313 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 314 | return NULL; |
| 315 | } |
| 316 | |
| 317 | cl_program |
| 318 | clCreateProgramWithBuiltInKernels(cl_context context, |
| 319 | cl_uint num_devices, |
| 320 | const cl_device_id * device_list, |
| 321 | const char * kernel_names, |
| 322 | cl_int * errcode_ret) |
| 323 | { |
| 324 | PRINT_STUB_ERROR; |
| 325 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 326 | return NULL; |
| 327 | } |
| 328 | |
| 329 | cl_int |
| 330 | clRetainProgram(cl_program program) |
| 331 | { |
| 332 | PRINT_STUB_ERROR; |
| 333 | return CL_OUT_OF_RESOURCES; |
| 334 | } |
| 335 | |
| 336 | cl_int |
| 337 | clReleaseProgram(cl_program program) |
| 338 | { |
| 339 | PRINT_STUB_ERROR; |
| 340 | return CL_OUT_OF_RESOURCES; |
| 341 | } |
| 342 | |
| 343 | cl_int |
| 344 | clBuildProgram(cl_program program, |
| 345 | cl_uint num_devices, |
| 346 | const cl_device_id * device_list, |
| 347 | const char * options, |
| 348 | void (CL_CALLBACK * pfn_notify)(cl_program program, void * user_data), |
| 349 | void * user_data) |
| 350 | { |
| 351 | PRINT_STUB_ERROR; |
| 352 | return CL_OUT_OF_RESOURCES; |
| 353 | } |
| 354 | |
| 355 | cl_int |
| 356 | clCompileProgram(cl_program program, |
| 357 | cl_uint num_devices, |
| 358 | const cl_device_id * device_list, |
| 359 | const char * options, |
| 360 | cl_uint num_input_headers, |
| 361 | const cl_program * input_headers, |
| 362 | const char ** header_include_names, |
| 363 | void (CL_CALLBACK * pfn_notify)(cl_program program, void * user_data), |
| 364 | void * user_data) |
| 365 | { |
| 366 | PRINT_STUB_ERROR; |
| 367 | return CL_OUT_OF_RESOURCES; |
| 368 | } |
| 369 | |
| 370 | cl_program |
| 371 | clLinkProgram(cl_context context, |
| 372 | cl_uint num_devices, |
| 373 | const cl_device_id * device_list, |
| 374 | const char * options, |
| 375 | cl_uint num_input_programs, |
| 376 | const cl_program * input_programs, |
| 377 | void (CL_CALLBACK * pfn_notify)(cl_program program, void * user_data), |
| 378 | void * user_data, |
| 379 | cl_int * errcode_ret ) |
| 380 | { |
| 381 | PRINT_STUB_ERROR; |
| 382 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 383 | return NULL; |
| 384 | } |
| 385 | |
| 386 | |
| 387 | cl_int |
| 388 | clUnloadPlatformCompiler(cl_platform_id platform) |
| 389 | { |
| 390 | PRINT_STUB_ERROR; |
| 391 | return CL_OUT_OF_RESOURCES; |
| 392 | } |
| 393 | |
| 394 | cl_int |
| 395 | clGetProgramInfo(cl_program program, |
| 396 | cl_program_info param_name, |
| 397 | size_t param_value_size, |
| 398 | void * param_value, |
| 399 | size_t * param_value_size_ret) |
| 400 | { |
| 401 | PRINT_STUB_ERROR; |
| 402 | return CL_OUT_OF_RESOURCES; |
| 403 | } |
| 404 | |
| 405 | cl_int |
| 406 | clGetProgramBuildInfo(cl_program program, |
| 407 | cl_device_id device, |
| 408 | cl_program_build_info param_name, |
| 409 | size_t param_value_size, |
| 410 | void * param_value, |
| 411 | size_t * param_value_size_ret) |
| 412 | { |
| 413 | PRINT_STUB_ERROR; |
| 414 | return CL_OUT_OF_RESOURCES; |
| 415 | } |
| 416 | |
| 417 | cl_kernel |
| 418 | clCreateKernel(cl_program program, |
| 419 | const char * kernel_name, |
| 420 | cl_int * errcode_ret) |
| 421 | { |
| 422 | PRINT_STUB_ERROR; |
| 423 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 424 | return NULL; |
| 425 | } |
| 426 | |
| 427 | cl_int |
| 428 | clCreateKernelsInProgram(cl_program program, |
| 429 | cl_uint num_kernels, |
| 430 | cl_kernel * kernels, |
| 431 | cl_uint * num_kernels_ret) |
| 432 | { |
| 433 | PRINT_STUB_ERROR; |
| 434 | return CL_OUT_OF_RESOURCES; |
| 435 | } |
| 436 | |
| 437 | cl_int |
| 438 | clRetainKernel(cl_kernel kernel) |
| 439 | { |
| 440 | PRINT_STUB_ERROR; |
| 441 | return CL_OUT_OF_RESOURCES; |
| 442 | } |
| 443 | |
| 444 | cl_int |
| 445 | clReleaseKernel(cl_kernel kernel) |
| 446 | { |
| 447 | PRINT_STUB_ERROR; |
| 448 | return CL_OUT_OF_RESOURCES; |
| 449 | } |
| 450 | |
| 451 | cl_int |
| 452 | clSetKernelArg(cl_kernel kernel, |
| 453 | cl_uint arg_index, |
| 454 | size_t arg_size, |
| 455 | const void * arg_value) |
| 456 | { |
| 457 | PRINT_STUB_ERROR; |
| 458 | return CL_OUT_OF_RESOURCES; |
| 459 | } |
| 460 | |
| 461 | cl_int |
| 462 | clGetKernelInfo(cl_kernel kernel, |
| 463 | cl_kernel_info param_name, |
| 464 | size_t param_value_size, |
| 465 | void * param_value, |
| 466 | size_t * param_value_size_ret) |
| 467 | { |
| 468 | PRINT_STUB_ERROR; |
| 469 | return CL_OUT_OF_RESOURCES; |
| 470 | } |
| 471 | |
| 472 | cl_int |
| 473 | clGetKernelArgInfo(cl_kernel kernel, |
| 474 | cl_uint arg_indx, |
| 475 | cl_kernel_arg_info param_name, |
| 476 | size_t param_value_size, |
| 477 | void * param_value, |
| 478 | size_t * param_value_size_ret) |
| 479 | { |
| 480 | PRINT_STUB_ERROR; |
| 481 | return CL_OUT_OF_RESOURCES; |
| 482 | } |
| 483 | |
| 484 | cl_int |
| 485 | clGetKernelWorkGroupInfo(cl_kernel kernel, |
| 486 | cl_device_id device, |
| 487 | cl_kernel_work_group_info param_name, |
| 488 | size_t param_value_size, |
| 489 | void * param_value, |
| 490 | size_t * param_value_size_ret) |
| 491 | { |
| 492 | PRINT_STUB_ERROR; |
| 493 | return CL_OUT_OF_RESOURCES; |
| 494 | } |
| 495 | |
| 496 | cl_int |
| 497 | clWaitForEvents(cl_uint num_events, |
| 498 | const cl_event * event_list) |
| 499 | { |
| 500 | PRINT_STUB_ERROR; |
| 501 | return CL_OUT_OF_RESOURCES; |
| 502 | } |
| 503 | |
| 504 | cl_int |
| 505 | clGetEventInfo(cl_event event, |
| 506 | cl_event_info param_name, |
| 507 | size_t param_value_size, |
| 508 | void * param_value, |
| 509 | size_t * param_value_size_ret) |
| 510 | { |
| 511 | PRINT_STUB_ERROR; |
| 512 | return CL_OUT_OF_RESOURCES; |
| 513 | } |
| 514 | |
| 515 | cl_event |
| 516 | clCreateUserEvent(cl_context context, |
| 517 | cl_int * errcode_ret) |
| 518 | { |
| 519 | PRINT_STUB_ERROR; |
| 520 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 521 | return NULL; |
| 522 | } |
| 523 | |
| 524 | cl_int |
| 525 | clRetainEvent(cl_event event) |
| 526 | { |
| 527 | PRINT_STUB_ERROR; |
| 528 | return CL_OUT_OF_RESOURCES; |
| 529 | } |
| 530 | |
| 531 | cl_int |
| 532 | clReleaseEvent(cl_event event) |
| 533 | { |
| 534 | PRINT_STUB_ERROR; |
| 535 | return CL_OUT_OF_RESOURCES; |
| 536 | } |
| 537 | |
| 538 | cl_int |
| 539 | clSetUserEventStatus(cl_event event, |
| 540 | cl_int execution_status) |
| 541 | { |
| 542 | PRINT_STUB_ERROR; |
| 543 | return CL_OUT_OF_RESOURCES; |
| 544 | } |
| 545 | |
| 546 | cl_int |
| 547 | clSetEventCallback( cl_event event, |
| 548 | cl_int command_exec_callback_type, |
| 549 | void (CL_CALLBACK * pfn_notify)(cl_event, cl_int, void *), |
| 550 | void * user_data) |
| 551 | { |
| 552 | PRINT_STUB_ERROR; |
| 553 | return CL_OUT_OF_RESOURCES; |
| 554 | } |
| 555 | |
| 556 | cl_int |
| 557 | clGetEventProfilingInfo(cl_event event, |
| 558 | cl_profiling_info param_name, |
| 559 | size_t param_value_size, |
| 560 | void * param_value, |
| 561 | size_t * param_value_size_ret) |
| 562 | { |
| 563 | PRINT_STUB_ERROR; |
| 564 | return CL_OUT_OF_RESOURCES; |
| 565 | } |
| 566 | |
| 567 | cl_int |
| 568 | clFlush(cl_command_queue command_queue) |
| 569 | { |
| 570 | PRINT_STUB_ERROR; |
| 571 | return CL_OUT_OF_RESOURCES; |
| 572 | } |
| 573 | |
| 574 | cl_int |
| 575 | clFinish(cl_command_queue command_queue) |
| 576 | { |
| 577 | PRINT_STUB_ERROR; |
| 578 | return CL_OUT_OF_RESOURCES; |
| 579 | } |
| 580 | |
| 581 | cl_int |
| 582 | clEnqueueReadBuffer(cl_command_queue command_queue, |
| 583 | cl_mem buffer, |
| 584 | cl_bool blocking_read, |
| 585 | size_t offset, |
| 586 | size_t size, |
| 587 | void * ptr, |
| 588 | cl_uint num_events_in_wait_list, |
| 589 | const cl_event * event_wait_list, |
| 590 | cl_event * event) |
| 591 | { |
| 592 | PRINT_STUB_ERROR; |
| 593 | return CL_OUT_OF_RESOURCES; |
| 594 | } |
| 595 | |
| 596 | cl_int |
| 597 | clEnqueueReadBufferRect(cl_command_queue command_queue, |
| 598 | cl_mem buffer, |
| 599 | cl_bool blocking_read, |
| 600 | const size_t * buffer_offset, |
| 601 | const size_t * host_offset, |
| 602 | const size_t * region, |
| 603 | size_t buffer_row_pitch, |
| 604 | size_t buffer_slice_pitch, |
| 605 | size_t host_row_pitch, |
| 606 | size_t host_slice_pitch, |
| 607 | void * ptr, |
| 608 | cl_uint num_events_in_wait_list, |
| 609 | const cl_event * event_wait_list, |
| 610 | cl_event * event) |
| 611 | { |
| 612 | PRINT_STUB_ERROR; |
| 613 | return CL_OUT_OF_RESOURCES; |
| 614 | } |
| 615 | |
| 616 | cl_int |
| 617 | clEnqueueWriteBuffer(cl_command_queue command_queue, |
| 618 | cl_mem buffer, |
| 619 | cl_bool blocking_write, |
| 620 | size_t offset, |
| 621 | size_t size, |
| 622 | const void * ptr, |
| 623 | cl_uint num_events_in_wait_list, |
| 624 | const cl_event * event_wait_list, |
| 625 | cl_event * event) |
| 626 | { |
| 627 | PRINT_STUB_ERROR; |
| 628 | return CL_OUT_OF_RESOURCES; |
| 629 | } |
| 630 | |
| 631 | cl_int |
| 632 | clEnqueueWriteBufferRect(cl_command_queue command_queue, |
| 633 | cl_mem buffer, |
| 634 | cl_bool blocking_write, |
| 635 | const size_t * buffer_offset, |
| 636 | const size_t * host_offset, |
| 637 | const size_t * region, |
| 638 | size_t buffer_row_pitch, |
| 639 | size_t buffer_slice_pitch, |
| 640 | size_t host_row_pitch, |
| 641 | size_t host_slice_pitch, |
| 642 | const void * ptr, |
| 643 | cl_uint num_events_in_wait_list, |
| 644 | const cl_event * event_wait_list, |
| 645 | cl_event * event) |
| 646 | { |
| 647 | PRINT_STUB_ERROR; |
| 648 | return CL_OUT_OF_RESOURCES; |
| 649 | } |
| 650 | |
| 651 | cl_int |
| 652 | clEnqueueFillBuffer(cl_command_queue command_queue, |
| 653 | cl_mem buffer, |
| 654 | const void * pattern, |
| 655 | size_t pattern_size, |
| 656 | size_t offset, |
| 657 | size_t size, |
| 658 | cl_uint num_events_in_wait_list, |
| 659 | const cl_event * event_wait_list, |
| 660 | cl_event * event) |
| 661 | { |
| 662 | PRINT_STUB_ERROR; |
| 663 | return CL_OUT_OF_RESOURCES; |
| 664 | } |
| 665 | |
| 666 | cl_int |
| 667 | clEnqueueCopyBuffer(cl_command_queue command_queue, |
| 668 | cl_mem src_buffer, |
| 669 | cl_mem dst_buffer, |
| 670 | size_t src_offset, |
| 671 | size_t dst_offset, |
| 672 | size_t size, |
| 673 | cl_uint num_events_in_wait_list, |
| 674 | const cl_event * event_wait_list, |
| 675 | cl_event * event) |
| 676 | { |
| 677 | PRINT_STUB_ERROR; |
| 678 | return CL_OUT_OF_RESOURCES; |
| 679 | } |
| 680 | |
| 681 | cl_int |
| 682 | clEnqueueCopyBufferRect(cl_command_queue command_queue, |
| 683 | cl_mem src_buffer, |
| 684 | cl_mem dst_buffer, |
| 685 | const size_t * src_origin, |
| 686 | const size_t * dst_origin, |
| 687 | const size_t * region, |
| 688 | size_t src_row_pitch, |
| 689 | size_t src_slice_pitch, |
| 690 | size_t dst_row_pitch, |
| 691 | size_t dst_slice_pitch, |
| 692 | cl_uint num_events_in_wait_list, |
| 693 | const cl_event * event_wait_list, |
| 694 | cl_event * event) |
| 695 | { |
| 696 | PRINT_STUB_ERROR; |
| 697 | return CL_OUT_OF_RESOURCES; |
| 698 | } |
| 699 | |
| 700 | cl_int |
| 701 | clEnqueueReadImage(cl_command_queue command_queue, |
| 702 | cl_mem image, |
| 703 | cl_bool blocking_read, |
| 704 | const size_t * origin, |
| 705 | const size_t * region, |
| 706 | size_t row_pitch, |
| 707 | size_t slice_pitch, |
| 708 | void * ptr, |
| 709 | cl_uint num_events_in_wait_list, |
| 710 | const cl_event * event_wait_list, |
| 711 | cl_event * event) |
| 712 | { |
| 713 | PRINT_STUB_ERROR; |
| 714 | return CL_OUT_OF_RESOURCES; |
| 715 | } |
| 716 | |
| 717 | cl_int |
| 718 | clEnqueueWriteImage(cl_command_queue command_queue, |
| 719 | cl_mem image, |
| 720 | cl_bool blocking_write, |
| 721 | const size_t * origin, |
| 722 | const size_t * region, |
| 723 | size_t input_row_pitch, |
| 724 | size_t input_slice_pitch, |
| 725 | const void * ptr, |
| 726 | cl_uint num_events_in_wait_list, |
| 727 | const cl_event * event_wait_list, |
| 728 | cl_event * event) |
| 729 | { |
| 730 | PRINT_STUB_ERROR; |
| 731 | return CL_OUT_OF_RESOURCES; |
| 732 | } |
| 733 | |
| 734 | cl_int |
| 735 | clEnqueueFillImage(cl_command_queue command_queue, |
| 736 | cl_mem image, |
| 737 | const void * fill_color, |
| 738 | const size_t * origin, |
| 739 | const size_t * region, |
| 740 | cl_uint num_events_in_wait_list, |
| 741 | const cl_event * event_wait_list, |
| 742 | cl_event * event) |
| 743 | { |
| 744 | PRINT_STUB_ERROR; |
| 745 | return CL_OUT_OF_RESOURCES; |
| 746 | } |
| 747 | |
| 748 | cl_int |
| 749 | clEnqueueCopyImage(cl_command_queue command_queue, |
| 750 | cl_mem src_image, |
| 751 | cl_mem dst_image, |
| 752 | const size_t * src_origin, |
| 753 | const size_t * dst_origin, |
| 754 | const size_t * region, |
| 755 | cl_uint num_events_in_wait_list, |
| 756 | const cl_event * event_wait_list, |
| 757 | cl_event * event) |
| 758 | { |
| 759 | PRINT_STUB_ERROR; |
| 760 | return CL_OUT_OF_RESOURCES; |
| 761 | } |
| 762 | |
| 763 | cl_int |
| 764 | clEnqueueCopyImageToBuffer(cl_command_queue command_queue, |
| 765 | cl_mem src_image, |
| 766 | cl_mem dst_buffer, |
| 767 | const size_t * src_origin, |
| 768 | const size_t * region, |
| 769 | size_t dst_offset, |
| 770 | cl_uint num_events_in_wait_list, |
| 771 | const cl_event * event_wait_list, |
| 772 | cl_event * event) |
| 773 | { |
| 774 | PRINT_STUB_ERROR; |
| 775 | return CL_OUT_OF_RESOURCES; |
| 776 | } |
| 777 | |
| 778 | cl_int |
| 779 | clEnqueueCopyBufferToImage(cl_command_queue command_queue, |
| 780 | cl_mem src_buffer, |
| 781 | cl_mem dst_image, |
| 782 | size_t src_offset, |
| 783 | const size_t * dst_origin, |
| 784 | const size_t * region, |
| 785 | cl_uint num_events_in_wait_list, |
| 786 | const cl_event * event_wait_list, |
| 787 | cl_event * event) |
| 788 | { |
| 789 | PRINT_STUB_ERROR; |
| 790 | return CL_OUT_OF_RESOURCES; |
| 791 | } |
| 792 | |
| 793 | void * |
| 794 | clEnqueueMapBuffer(cl_command_queue command_queue, |
| 795 | cl_mem buffer, |
| 796 | cl_bool blocking_map, |
| 797 | cl_map_flags map_flags, |
| 798 | size_t offset, |
| 799 | size_t size, |
| 800 | cl_uint num_events_in_wait_list, |
| 801 | const cl_event * event_wait_list, |
| 802 | cl_event * event, |
| 803 | cl_int * errcode_ret) |
| 804 | { |
| 805 | PRINT_STUB_ERROR; |
| 806 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 807 | return NULL; |
| 808 | } |
| 809 | |
| 810 | void * |
| 811 | clEnqueueMapImage(cl_command_queue command_queue, |
| 812 | cl_mem image, |
| 813 | cl_bool blocking_map, |
| 814 | cl_map_flags map_flags, |
| 815 | const size_t * origin, |
| 816 | const size_t * region, |
| 817 | size_t * image_row_pitch, |
| 818 | size_t * image_slice_pitch, |
| 819 | cl_uint num_events_in_wait_list, |
| 820 | const cl_event * event_wait_list, |
| 821 | cl_event * event, |
| 822 | cl_int * errcode_ret) |
| 823 | { |
| 824 | PRINT_STUB_ERROR; |
| 825 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 826 | return NULL; |
| 827 | } |
| 828 | |
| 829 | cl_int |
| 830 | clEnqueueUnmapMemObject(cl_command_queue command_queue, |
| 831 | cl_mem memobj, |
| 832 | void * mapped_ptr, |
| 833 | cl_uint num_events_in_wait_list, |
| 834 | const cl_event * event_wait_list, |
| 835 | cl_event * event) |
| 836 | { |
| 837 | PRINT_STUB_ERROR; |
| 838 | return CL_OUT_OF_RESOURCES; |
| 839 | } |
| 840 | |
| 841 | cl_int |
| 842 | clEnqueueMigrateMemObjects(cl_command_queue command_queue, |
| 843 | cl_uint num_mem_objects, |
| 844 | const cl_mem * mem_objects, |
| 845 | cl_mem_migration_flags flags, |
| 846 | cl_uint num_events_in_wait_list, |
| 847 | const cl_event * event_wait_list, |
| 848 | cl_event * event) |
| 849 | { |
| 850 | PRINT_STUB_ERROR; |
| 851 | return CL_OUT_OF_RESOURCES; |
| 852 | } |
| 853 | |
| 854 | cl_int |
| 855 | clEnqueueNDRangeKernel(cl_command_queue command_queue, |
| 856 | cl_kernel kernel, |
| 857 | cl_uint work_dim, |
| 858 | const size_t * global_work_offset, |
| 859 | const size_t * global_work_size, |
| 860 | const size_t * local_work_size, |
| 861 | cl_uint num_events_in_wait_list, |
| 862 | const cl_event * event_wait_list, |
| 863 | cl_event * event) |
| 864 | { |
| 865 | PRINT_STUB_ERROR; |
| 866 | return CL_OUT_OF_RESOURCES; |
| 867 | } |
| 868 | |
| 869 | cl_int |
| 870 | clEnqueueTask(cl_command_queue command_queue, |
| 871 | cl_kernel kernel, |
| 872 | cl_uint num_events_in_wait_list, |
| 873 | const cl_event * event_wait_list, |
| 874 | cl_event * event) |
| 875 | { |
| 876 | PRINT_STUB_ERROR; |
| 877 | return CL_OUT_OF_RESOURCES; |
| 878 | } |
| 879 | |
| 880 | cl_int |
| 881 | clEnqueueNativeKernel(cl_command_queue command_queue, |
| 882 | void (CL_CALLBACK * user_func)(void *), |
| 883 | void * args, |
| 884 | size_t cb_args, |
| 885 | cl_uint num_mem_objects, |
| 886 | const cl_mem * mem_list, |
| 887 | const void ** args_mem_loc, |
| 888 | cl_uint num_events_in_wait_list, |
| 889 | const cl_event * event_wait_list, |
| 890 | cl_event * event) |
| 891 | { |
| 892 | PRINT_STUB_ERROR; |
| 893 | return CL_OUT_OF_RESOURCES; |
| 894 | } |
| 895 | |
| 896 | cl_int |
| 897 | clEnqueueMarkerWithWaitList(cl_command_queue command_queue, |
| 898 | cl_uint num_events_in_wait_list, |
| 899 | const cl_event * event_wait_list, |
| 900 | cl_event * event) |
| 901 | { |
| 902 | PRINT_STUB_ERROR; |
| 903 | return CL_OUT_OF_RESOURCES; |
| 904 | } |
| 905 | |
| 906 | cl_int |
| 907 | clEnqueueBarrierWithWaitList(cl_command_queue command_queue, |
| 908 | cl_uint num_events_in_wait_list, |
| 909 | const cl_event * event_wait_list, |
| 910 | cl_event * event) |
| 911 | { |
| 912 | PRINT_STUB_ERROR; |
| 913 | return CL_OUT_OF_RESOURCES; |
| 914 | } |
| 915 | |
| 916 | void * |
| 917 | clGetExtensionFunctionAddressForPlatform(cl_platform_id platform, |
| 918 | const char * func_name) |
| 919 | { |
| 920 | PRINT_STUB_ERROR; |
| 921 | return NULL; |
| 922 | } |
| 923 | |
| 924 | |
| 925 | cl_mem |
| 926 | clCreateImage2D(cl_context context, |
| 927 | cl_mem_flags flags, |
| 928 | const cl_image_format * image_format, |
| 929 | size_t image_width, |
| 930 | size_t image_height, |
| 931 | size_t image_row_pitch, |
| 932 | void * host_ptr, |
| 933 | cl_int * errcode_ret) |
| 934 | { |
| 935 | PRINT_STUB_ERROR; |
| 936 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 937 | return NULL; |
| 938 | } |
| 939 | |
| 940 | cl_mem |
| 941 | clCreateImage3D(cl_context context, |
| 942 | cl_mem_flags flags, |
| 943 | const cl_image_format * image_format, |
| 944 | size_t image_width, |
| 945 | size_t image_height, |
| 946 | size_t image_depth, |
| 947 | size_t image_row_pitch, |
| 948 | size_t image_slice_pitch, |
| 949 | void * host_ptr, |
| 950 | cl_int * errcode_ret) |
| 951 | { |
| 952 | PRINT_STUB_ERROR; |
| 953 | if( errcode_ret ) *errcode_ret = CL_OUT_OF_RESOURCES; |
| 954 | return NULL; |
| 955 | } |
| 956 | |
| 957 | cl_int |
| 958 | clEnqueueMarker(cl_command_queue command_queue, |
| 959 | cl_event * event) |
| 960 | { |
| 961 | PRINT_STUB_ERROR; |
| 962 | return CL_OUT_OF_RESOURCES; |
| 963 | } |
| 964 | |
| 965 | cl_int |
| 966 | clEnqueueWaitForEvents(cl_command_queue command_queue, |
| 967 | cl_uint num_events, |
| 968 | const cl_event * event_list) |
| 969 | { |
| 970 | PRINT_STUB_ERROR; |
| 971 | return CL_OUT_OF_RESOURCES; |
| 972 | } |
| 973 | |
| 974 | cl_int |
| 975 | clEnqueueBarrier(cl_command_queue command_queue) |
| 976 | { |
| 977 | PRINT_STUB_ERROR; |
| 978 | return CL_OUT_OF_RESOURCES; |
| 979 | } |
| 980 | |
| 981 | cl_int |
| 982 | clUnloadCompiler(void) |
| 983 | { |
| 984 | PRINT_STUB_ERROR; |
| 985 | return CL_OUT_OF_RESOURCES; |
| 986 | } |
| 987 | |
| 988 | void * |
| 989 | clGetExtensionFunctionAddress(const char * func_name) |
| 990 | { |
| 991 | PRINT_STUB_ERROR; |
| 992 | return NULL; |
| 993 | } |
| 994 | |
| 995 | cl_int |
| 996 | clSetCommandQueueProperty(cl_command_queue command_queue, |
| 997 | cl_command_queue_properties properties, |
| 998 | cl_bool enable, |
| 999 | cl_command_queue_properties * old_properties) |
| 1000 | { |
| 1001 | PRINT_STUB_ERROR; |
| 1002 | return CL_OUT_OF_RESOURCES; |
| 1003 | } |