1 //===- Auto-generated file, part of the LLVM/Offload project --------------===// 2 // 3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. 4 // See https://llvm.org/LICENSE.txt for license information. 5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception 6 // 7 //===----------------------------------------------------------------------===// 8 9 // Auto-generated file, do not manually edit. 10 11 #pragma once 12 13 #include <stddef.h> 14 #include <stdint.h> 15 16 #if defined(__cplusplus) 17 extern "C" { 18 #endif 19 20 /////////////////////////////////////////////////////////////////////////////// 21 #ifndef OL_VERSION_MAJOR 22 /// @brief Major version of the Offload API 23 #define OL_VERSION_MAJOR 0 24 #endif // OL_VERSION_MAJOR 25 26 /////////////////////////////////////////////////////////////////////////////// 27 #ifndef OL_VERSION_MINOR 28 /// @brief Minor version of the Offload API 29 #define OL_VERSION_MINOR 0 30 #endif // OL_VERSION_MINOR 31 32 /////////////////////////////////////////////////////////////////////////////// 33 #ifndef OL_VERSION_PATCH 34 /// @brief Patch version of the Offload API 35 #define OL_VERSION_PATCH 1 36 #endif // OL_VERSION_PATCH 37 38 /////////////////////////////////////////////////////////////////////////////// 39 #ifndef OL_APICALL 40 #if defined(_WIN32) 41 /// @brief Calling convention for all API functions 42 #define OL_APICALL __cdecl 43 #else 44 #define OL_APICALL 45 #endif // defined(_WIN32) 46 #endif // OL_APICALL 47 48 /////////////////////////////////////////////////////////////////////////////// 49 #ifndef OL_APIEXPORT 50 #if defined(_WIN32) 51 /// @brief Microsoft-specific dllexport storage-class attribute 52 #define OL_APIEXPORT __declspec(dllexport) 53 #else 54 #define OL_APIEXPORT 55 #endif // defined(_WIN32) 56 #endif // OL_APIEXPORT 57 58 /////////////////////////////////////////////////////////////////////////////// 59 #ifndef OL_DLLEXPORT 60 #if defined(_WIN32) 61 /// @brief Microsoft-specific dllexport storage-class attribute 62 #define OL_DLLEXPORT __declspec(dllexport) 63 #endif // defined(_WIN32) 64 #endif // OL_DLLEXPORT 65 66 /////////////////////////////////////////////////////////////////////////////// 67 #ifndef OL_DLLEXPORT 68 #if __GNUC__ >= 4 69 /// @brief GCC-specific dllexport storage-class attribute 70 #define OL_DLLEXPORT __attribute__((visibility("default"))) 71 #else 72 #define OL_DLLEXPORT 73 #endif // __GNUC__ >= 4 74 #endif // OL_DLLEXPORT 75 76 /////////////////////////////////////////////////////////////////////////////// 77 /// @brief Handle of a platform instance 78 typedef struct ol_platform_handle_t_ *ol_platform_handle_t; 79 80 /////////////////////////////////////////////////////////////////////////////// 81 /// @brief Handle of platform's device object 82 typedef struct ol_device_handle_t_ *ol_device_handle_t; 83 84 /////////////////////////////////////////////////////////////////////////////// 85 /// @brief Handle of context object 86 typedef struct ol_context_handle_t_ *ol_context_handle_t; 87 88 /////////////////////////////////////////////////////////////////////////////// 89 /// @brief Defines Return/Error codes 90 typedef enum ol_errc_t { 91 /// Success 92 OL_ERRC_SUCCESS = 0, 93 /// Invalid Value 94 OL_ERRC_INVALID_VALUE = 1, 95 /// Invalid platform 96 OL_ERRC_INVALID_PLATFORM = 2, 97 /// Device not found 98 OL_ERRC_DEVICE_NOT_FOUND = 3, 99 /// Invalid device 100 OL_ERRC_INVALID_DEVICE = 4, 101 /// Device hung, reset, was removed, or driver update occurred 102 OL_ERRC_DEVICE_LOST = 5, 103 /// plugin is not initialized or specific entry-point is not implemented 104 OL_ERRC_UNINITIALIZED = 6, 105 /// Out of resources 106 OL_ERRC_OUT_OF_RESOURCES = 7, 107 /// generic error code for unsupported versions 108 OL_ERRC_UNSUPPORTED_VERSION = 8, 109 /// generic error code for unsupported features 110 OL_ERRC_UNSUPPORTED_FEATURE = 9, 111 /// generic error code for invalid arguments 112 OL_ERRC_INVALID_ARGUMENT = 10, 113 /// handle argument is not valid 114 OL_ERRC_INVALID_NULL_HANDLE = 11, 115 /// pointer argument may not be nullptr 116 OL_ERRC_INVALID_NULL_POINTER = 12, 117 /// invalid size or dimensions (e.g., must not be zero, or is out of bounds) 118 OL_ERRC_INVALID_SIZE = 13, 119 /// enumerator argument is not valid 120 OL_ERRC_INVALID_ENUMERATION = 14, 121 /// enumerator argument is not supported by the device 122 OL_ERRC_UNSUPPORTED_ENUMERATION = 15, 123 /// Unknown or internal error 124 OL_ERRC_UNKNOWN = 16, 125 /// @cond 126 OL_ERRC_FORCE_UINT32 = 0x7fffffff 127 /// @endcond 128 129 } ol_errc_t; 130 131 /////////////////////////////////////////////////////////////////////////////// 132 /// @brief Details of the error condition returned by an API call 133 typedef struct ol_error_struct_t { 134 ol_errc_t Code; /// The error code 135 const char *Details; /// String containing error details 136 } ol_error_struct_t; 137 138 /////////////////////////////////////////////////////////////////////////////// 139 /// @brief Result type returned by all entry points. 140 typedef const ol_error_struct_t *ol_result_t; 141 142 /////////////////////////////////////////////////////////////////////////////// 143 #ifndef OL_SUCCESS 144 /// @brief Success condition 145 #define OL_SUCCESS NULL 146 #endif // OL_SUCCESS 147 148 /////////////////////////////////////////////////////////////////////////////// 149 /// @brief Code location information that can optionally be associated with an 150 /// API call 151 typedef struct ol_code_location_t { 152 const char *FunctionName; /// Function name 153 const char *SourceFile; /// Source code file 154 uint32_t LineNumber; /// Source code line number 155 uint32_t ColumnNumber; /// Source code column number 156 } ol_code_location_t; 157 158 /////////////////////////////////////////////////////////////////////////////// 159 /// @brief Perform initialization of the Offload library and plugins 160 /// 161 /// @details 162 /// - This must be the first API call made by a user of the Offload library 163 /// - Each call will increment an internal reference count that is 164 /// decremented by `olShutDown` 165 /// 166 /// @returns 167 /// - ::OL_RESULT_SUCCESS 168 /// - ::OL_ERRC_UNINITIALIZED 169 /// - ::OL_ERRC_DEVICE_LOST 170 /// - ::OL_ERRC_INVALID_NULL_HANDLE 171 /// - ::OL_ERRC_INVALID_NULL_POINTER 172 OL_APIEXPORT ol_result_t OL_APICALL olInit(); 173 174 /////////////////////////////////////////////////////////////////////////////// 175 /// @brief Release the resources in use by Offload 176 /// 177 /// @details 178 /// - This decrements an internal reference count. When this reaches 0, all 179 /// resources will be released 180 /// - Subsequent API calls made after this are not valid 181 /// 182 /// @returns 183 /// - ::OL_RESULT_SUCCESS 184 /// - ::OL_ERRC_UNINITIALIZED 185 /// - ::OL_ERRC_DEVICE_LOST 186 /// - ::OL_ERRC_INVALID_NULL_HANDLE 187 /// - ::OL_ERRC_INVALID_NULL_POINTER 188 OL_APIEXPORT ol_result_t OL_APICALL olShutDown(); 189 190 /////////////////////////////////////////////////////////////////////////////// 191 /// @brief Retrieves all available platforms 192 /// 193 /// @details 194 /// - Multiple calls to this function will return identical platforms 195 /// handles, in the same order. 196 /// 197 /// @returns 198 /// - ::OL_RESULT_SUCCESS 199 /// - ::OL_ERRC_UNINITIALIZED 200 /// - ::OL_ERRC_DEVICE_LOST 201 /// - ::OL_ERRC_INVALID_SIZE 202 /// + `NumEntries == 0` 203 /// - ::OL_ERRC_INVALID_NULL_HANDLE 204 /// - ::OL_ERRC_INVALID_NULL_POINTER 205 /// + `NULL == Platforms` 206 OL_APIEXPORT ol_result_t OL_APICALL olGetPlatform( 207 // [in] The number of platforms to be added to Platforms. NumEntries must be 208 // greater than zero. 209 uint32_t NumEntries, 210 // [out] Array of handle of platforms. If NumEntries is less than the number 211 // of platforms available, then olGetPlatform shall only retrieve that 212 // number of platforms. 213 ol_platform_handle_t *Platforms); 214 215 /////////////////////////////////////////////////////////////////////////////// 216 /// @brief Retrieves the number of available platforms 217 /// 218 /// @details 219 /// 220 /// @returns 221 /// - ::OL_RESULT_SUCCESS 222 /// - ::OL_ERRC_UNINITIALIZED 223 /// - ::OL_ERRC_DEVICE_LOST 224 /// - ::OL_ERRC_INVALID_NULL_HANDLE 225 /// - ::OL_ERRC_INVALID_NULL_POINTER 226 /// + `NULL == NumPlatforms` 227 OL_APIEXPORT ol_result_t OL_APICALL olGetPlatformCount( 228 // [out] returns the total number of platforms available. 229 uint32_t *NumPlatforms); 230 231 /////////////////////////////////////////////////////////////////////////////// 232 /// @brief Supported platform info 233 typedef enum ol_platform_info_t { 234 /// [char[]] The string denoting name of the platform. The size of the info 235 /// needs to be dynamically queried. 236 OL_PLATFORM_INFO_NAME = 0, 237 /// [char[]] The string denoting name of the vendor of the platform. The size 238 /// of the info needs to be dynamically queried. 239 OL_PLATFORM_INFO_VENDOR_NAME = 1, 240 /// [char[]] The string denoting the version of the platform. The size of the 241 /// info needs to be dynamically queried. 242 OL_PLATFORM_INFO_VERSION = 2, 243 /// [ol_platform_backend_t] The native backend of the platform. 244 OL_PLATFORM_INFO_BACKEND = 3, 245 /// @cond 246 OL_PLATFORM_INFO_FORCE_UINT32 = 0x7fffffff 247 /// @endcond 248 249 } ol_platform_info_t; 250 251 /////////////////////////////////////////////////////////////////////////////// 252 /// @brief Identifies the native backend of the platform 253 typedef enum ol_platform_backend_t { 254 /// The backend is not recognized 255 OL_PLATFORM_BACKEND_UNKNOWN = 0, 256 /// The backend is CUDA 257 OL_PLATFORM_BACKEND_CUDA = 1, 258 /// The backend is AMDGPU 259 OL_PLATFORM_BACKEND_AMDGPU = 2, 260 /// @cond 261 OL_PLATFORM_BACKEND_FORCE_UINT32 = 0x7fffffff 262 /// @endcond 263 264 } ol_platform_backend_t; 265 266 /////////////////////////////////////////////////////////////////////////////// 267 /// @brief Queries the given property of the platform 268 /// 269 /// @details 270 /// - `olGetPlatformInfoSize` can be used to query the storage size required 271 /// for the given query. 272 /// 273 /// @returns 274 /// - ::OL_RESULT_SUCCESS 275 /// - ::OL_ERRC_UNINITIALIZED 276 /// - ::OL_ERRC_DEVICE_LOST 277 /// - ::OL_ERRC_UNSUPPORTED_ENUMERATION 278 /// + If `PropName` is not supported by the platform. 279 /// - ::OL_ERRC_INVALID_SIZE 280 /// + `PropSize == 0` 281 /// + If `PropSize` is less than the real number of bytes needed to 282 /// return the info. 283 /// - ::OL_ERRC_INVALID_PLATFORM 284 /// - ::OL_ERRC_INVALID_NULL_HANDLE 285 /// + `NULL == Platform` 286 /// - ::OL_ERRC_INVALID_NULL_POINTER 287 /// + `NULL == PropValue` 288 OL_APIEXPORT ol_result_t OL_APICALL olGetPlatformInfo( 289 // [in] handle of the platform 290 ol_platform_handle_t Platform, 291 // [in] type of the info to retrieve 292 ol_platform_info_t PropName, 293 // [in] the number of bytes pointed to by pPlatformInfo. 294 size_t PropSize, 295 // [out] array of bytes holding the info. If Size is not equal to or greater 296 // to the real number of bytes needed to return the info then the 297 // OL_ERRC_INVALID_SIZE error is returned and pPlatformInfo is not used. 298 void *PropValue); 299 300 /////////////////////////////////////////////////////////////////////////////// 301 /// @brief Returns the storage size of the given platform query 302 /// 303 /// @details 304 /// 305 /// @returns 306 /// - ::OL_RESULT_SUCCESS 307 /// - ::OL_ERRC_UNINITIALIZED 308 /// - ::OL_ERRC_DEVICE_LOST 309 /// - ::OL_ERRC_UNSUPPORTED_ENUMERATION 310 /// + If `PropName` is not supported by the platform. 311 /// - ::OL_ERRC_INVALID_PLATFORM 312 /// - ::OL_ERRC_INVALID_NULL_HANDLE 313 /// + `NULL == Platform` 314 /// - ::OL_ERRC_INVALID_NULL_POINTER 315 /// + `NULL == PropSizeRet` 316 OL_APIEXPORT ol_result_t OL_APICALL olGetPlatformInfoSize( 317 // [in] handle of the platform 318 ol_platform_handle_t Platform, 319 // [in] type of the info to query 320 ol_platform_info_t PropName, 321 // [out] pointer to the number of bytes required to store the query 322 size_t *PropSizeRet); 323 324 /////////////////////////////////////////////////////////////////////////////// 325 /// @brief Supported device types 326 typedef enum ol_device_type_t { 327 /// The default device type as preferred by the runtime 328 OL_DEVICE_TYPE_DEFAULT = 0, 329 /// Devices of all types 330 OL_DEVICE_TYPE_ALL = 1, 331 /// GPU device type 332 OL_DEVICE_TYPE_GPU = 2, 333 /// CPU device type 334 OL_DEVICE_TYPE_CPU = 3, 335 /// @cond 336 OL_DEVICE_TYPE_FORCE_UINT32 = 0x7fffffff 337 /// @endcond 338 339 } ol_device_type_t; 340 341 /////////////////////////////////////////////////////////////////////////////// 342 /// @brief Supported device info 343 typedef enum ol_device_info_t { 344 /// [ol_device_type_t] type of the device 345 OL_DEVICE_INFO_TYPE = 0, 346 /// [ol_platform_handle_t] the platform associated with the device 347 OL_DEVICE_INFO_PLATFORM = 1, 348 /// [char[]] Device name 349 OL_DEVICE_INFO_NAME = 2, 350 /// [char[]] Device vendor 351 OL_DEVICE_INFO_VENDOR = 3, 352 /// [char[]] Driver version 353 OL_DEVICE_INFO_DRIVER_VERSION = 4, 354 /// @cond 355 OL_DEVICE_INFO_FORCE_UINT32 = 0x7fffffff 356 /// @endcond 357 358 } ol_device_info_t; 359 360 /////////////////////////////////////////////////////////////////////////////// 361 /// @brief Retrieves the number of available devices within a platform 362 /// 363 /// @details 364 /// 365 /// @returns 366 /// - ::OL_RESULT_SUCCESS 367 /// - ::OL_ERRC_UNINITIALIZED 368 /// - ::OL_ERRC_DEVICE_LOST 369 /// - ::OL_ERRC_INVALID_NULL_HANDLE 370 /// + `NULL == Platform` 371 /// - ::OL_ERRC_INVALID_NULL_POINTER 372 /// + `NULL == NumDevices` 373 OL_APIEXPORT ol_result_t OL_APICALL olGetDeviceCount( 374 // [in] handle of the platform instance 375 ol_platform_handle_t Platform, 376 // [out] pointer to the number of devices. 377 uint32_t *NumDevices); 378 379 /////////////////////////////////////////////////////////////////////////////// 380 /// @brief Retrieves devices within a platform 381 /// 382 /// @details 383 /// - Multiple calls to this function will return identical device handles, 384 /// in the same order. 385 /// 386 /// @returns 387 /// - ::OL_RESULT_SUCCESS 388 /// - ::OL_ERRC_UNINITIALIZED 389 /// - ::OL_ERRC_DEVICE_LOST 390 /// - ::OL_ERRC_INVALID_SIZE 391 /// + `NumEntries == 0` 392 /// - ::OL_ERRC_INVALID_NULL_HANDLE 393 /// + `NULL == Platform` 394 /// - ::OL_ERRC_INVALID_NULL_POINTER 395 /// + `NULL == Devices` 396 OL_APIEXPORT ol_result_t OL_APICALL olGetDevice( 397 // [in] handle of the platform instance 398 ol_platform_handle_t Platform, 399 // [in] the number of devices to be added to phDevices, which must be 400 // greater than zero 401 uint32_t NumEntries, 402 // [out] Array of device handles. If NumEntries is less than the number of 403 // devices available, then this function shall only retrieve that number of 404 // devices. 405 ol_device_handle_t *Devices); 406 407 /////////////////////////////////////////////////////////////////////////////// 408 /// @brief Queries the given property of the device 409 /// 410 /// @details 411 /// 412 /// @returns 413 /// - ::OL_RESULT_SUCCESS 414 /// - ::OL_ERRC_UNINITIALIZED 415 /// - ::OL_ERRC_DEVICE_LOST 416 /// - ::OL_ERRC_UNSUPPORTED_ENUMERATION 417 /// + If `PropName` is not supported by the device. 418 /// - ::OL_ERRC_INVALID_SIZE 419 /// + `PropSize == 0` 420 /// + If `PropSize` is less than the real number of bytes needed to 421 /// return the info. 422 /// - ::OL_ERRC_INVALID_DEVICE 423 /// - ::OL_ERRC_INVALID_NULL_HANDLE 424 /// + `NULL == Device` 425 /// - ::OL_ERRC_INVALID_NULL_POINTER 426 /// + `NULL == PropValue` 427 OL_APIEXPORT ol_result_t OL_APICALL olGetDeviceInfo( 428 // [in] handle of the device instance 429 ol_device_handle_t Device, 430 // [in] type of the info to retrieve 431 ol_device_info_t PropName, 432 // [in] the number of bytes pointed to by PropValue. 433 size_t PropSize, 434 // [out] array of bytes holding the info. If PropSize is not equal to or 435 // greater than the real number of bytes needed to return the info then the 436 // OL_ERRC_INVALID_SIZE error is returned and PropValue is not used. 437 void *PropValue); 438 439 /////////////////////////////////////////////////////////////////////////////// 440 /// @brief Returns the storage size of the given device query 441 /// 442 /// @details 443 /// 444 /// @returns 445 /// - ::OL_RESULT_SUCCESS 446 /// - ::OL_ERRC_UNINITIALIZED 447 /// - ::OL_ERRC_DEVICE_LOST 448 /// - ::OL_ERRC_UNSUPPORTED_ENUMERATION 449 /// + If `PropName` is not supported by the device. 450 /// - ::OL_ERRC_INVALID_DEVICE 451 /// - ::OL_ERRC_INVALID_NULL_HANDLE 452 /// + `NULL == Device` 453 /// - ::OL_ERRC_INVALID_NULL_POINTER 454 /// + `NULL == PropSizeRet` 455 OL_APIEXPORT ol_result_t OL_APICALL olGetDeviceInfoSize( 456 // [in] handle of the device instance 457 ol_device_handle_t Device, 458 // [in] type of the info to retrieve 459 ol_device_info_t PropName, 460 // [out] pointer to the number of bytes required to store the query 461 size_t *PropSizeRet); 462 463 /////////////////////////////////////////////////////////////////////////////// 464 /// @brief Function parameters for olGetPlatform 465 /// @details Each entry is a pointer to the parameter passed to the function; 466 typedef struct ol_get_platform_params_t { 467 uint32_t *pNumEntries; 468 ol_platform_handle_t **pPlatforms; 469 } ol_get_platform_params_t; 470 471 /////////////////////////////////////////////////////////////////////////////// 472 /// @brief Function parameters for olGetPlatformCount 473 /// @details Each entry is a pointer to the parameter passed to the function; 474 typedef struct ol_get_platform_count_params_t { 475 uint32_t **pNumPlatforms; 476 } ol_get_platform_count_params_t; 477 478 /////////////////////////////////////////////////////////////////////////////// 479 /// @brief Function parameters for olGetPlatformInfo 480 /// @details Each entry is a pointer to the parameter passed to the function; 481 typedef struct ol_get_platform_info_params_t { 482 ol_platform_handle_t *pPlatform; 483 ol_platform_info_t *pPropName; 484 size_t *pPropSize; 485 void **pPropValue; 486 } ol_get_platform_info_params_t; 487 488 /////////////////////////////////////////////////////////////////////////////// 489 /// @brief Function parameters for olGetPlatformInfoSize 490 /// @details Each entry is a pointer to the parameter passed to the function; 491 typedef struct ol_get_platform_info_size_params_t { 492 ol_platform_handle_t *pPlatform; 493 ol_platform_info_t *pPropName; 494 size_t **pPropSizeRet; 495 } ol_get_platform_info_size_params_t; 496 497 /////////////////////////////////////////////////////////////////////////////// 498 /// @brief Function parameters for olGetDeviceCount 499 /// @details Each entry is a pointer to the parameter passed to the function; 500 typedef struct ol_get_device_count_params_t { 501 ol_platform_handle_t *pPlatform; 502 uint32_t **pNumDevices; 503 } ol_get_device_count_params_t; 504 505 /////////////////////////////////////////////////////////////////////////////// 506 /// @brief Function parameters for olGetDevice 507 /// @details Each entry is a pointer to the parameter passed to the function; 508 typedef struct ol_get_device_params_t { 509 ol_platform_handle_t *pPlatform; 510 uint32_t *pNumEntries; 511 ol_device_handle_t **pDevices; 512 } ol_get_device_params_t; 513 514 /////////////////////////////////////////////////////////////////////////////// 515 /// @brief Function parameters for olGetDeviceInfo 516 /// @details Each entry is a pointer to the parameter passed to the function; 517 typedef struct ol_get_device_info_params_t { 518 ol_device_handle_t *pDevice; 519 ol_device_info_t *pPropName; 520 size_t *pPropSize; 521 void **pPropValue; 522 } ol_get_device_info_params_t; 523 524 /////////////////////////////////////////////////////////////////////////////// 525 /// @brief Function parameters for olGetDeviceInfoSize 526 /// @details Each entry is a pointer to the parameter passed to the function; 527 typedef struct ol_get_device_info_size_params_t { 528 ol_device_handle_t *pDevice; 529 ol_device_info_t *pPropName; 530 size_t **pPropSizeRet; 531 } ol_get_device_info_size_params_t; 532 533 /////////////////////////////////////////////////////////////////////////////// 534 /// @brief Variant of olInit that also sets source code location information 535 /// @details See also ::olInit 536 OL_APIEXPORT ol_result_t OL_APICALL 537 olInitWithCodeLoc(ol_code_location_t *CodeLocation); 538 539 /////////////////////////////////////////////////////////////////////////////// 540 /// @brief Variant of olShutDown that also sets source code location information 541 /// @details See also ::olShutDown 542 OL_APIEXPORT ol_result_t OL_APICALL 543 olShutDownWithCodeLoc(ol_code_location_t *CodeLocation); 544 545 /////////////////////////////////////////////////////////////////////////////// 546 /// @brief Variant of olGetPlatform that also sets source code location 547 /// information 548 /// @details See also ::olGetPlatform 549 OL_APIEXPORT ol_result_t OL_APICALL 550 olGetPlatformWithCodeLoc(uint32_t NumEntries, ol_platform_handle_t *Platforms, 551 ol_code_location_t *CodeLocation); 552 553 /////////////////////////////////////////////////////////////////////////////// 554 /// @brief Variant of olGetPlatformCount that also sets source code location 555 /// information 556 /// @details See also ::olGetPlatformCount 557 OL_APIEXPORT ol_result_t OL_APICALL olGetPlatformCountWithCodeLoc( 558 uint32_t *NumPlatforms, ol_code_location_t *CodeLocation); 559 560 /////////////////////////////////////////////////////////////////////////////// 561 /// @brief Variant of olGetPlatformInfo that also sets source code location 562 /// information 563 /// @details See also ::olGetPlatformInfo 564 OL_APIEXPORT ol_result_t OL_APICALL olGetPlatformInfoWithCodeLoc( 565 ol_platform_handle_t Platform, ol_platform_info_t PropName, size_t PropSize, 566 void *PropValue, ol_code_location_t *CodeLocation); 567 568 /////////////////////////////////////////////////////////////////////////////// 569 /// @brief Variant of olGetPlatformInfoSize that also sets source code location 570 /// information 571 /// @details See also ::olGetPlatformInfoSize 572 OL_APIEXPORT ol_result_t OL_APICALL olGetPlatformInfoSizeWithCodeLoc( 573 ol_platform_handle_t Platform, ol_platform_info_t PropName, 574 size_t *PropSizeRet, ol_code_location_t *CodeLocation); 575 576 /////////////////////////////////////////////////////////////////////////////// 577 /// @brief Variant of olGetDeviceCount that also sets source code location 578 /// information 579 /// @details See also ::olGetDeviceCount 580 OL_APIEXPORT ol_result_t OL_APICALL 581 olGetDeviceCountWithCodeLoc(ol_platform_handle_t Platform, uint32_t *NumDevices, 582 ol_code_location_t *CodeLocation); 583 584 /////////////////////////////////////////////////////////////////////////////// 585 /// @brief Variant of olGetDevice that also sets source code location 586 /// information 587 /// @details See also ::olGetDevice 588 OL_APIEXPORT ol_result_t OL_APICALL olGetDeviceWithCodeLoc( 589 ol_platform_handle_t Platform, uint32_t NumEntries, 590 ol_device_handle_t *Devices, ol_code_location_t *CodeLocation); 591 592 /////////////////////////////////////////////////////////////////////////////// 593 /// @brief Variant of olGetDeviceInfo that also sets source code location 594 /// information 595 /// @details See also ::olGetDeviceInfo 596 OL_APIEXPORT ol_result_t OL_APICALL olGetDeviceInfoWithCodeLoc( 597 ol_device_handle_t Device, ol_device_info_t PropName, size_t PropSize, 598 void *PropValue, ol_code_location_t *CodeLocation); 599 600 /////////////////////////////////////////////////////////////////////////////// 601 /// @brief Variant of olGetDeviceInfoSize that also sets source code location 602 /// information 603 /// @details See also ::olGetDeviceInfoSize 604 OL_APIEXPORT ol_result_t OL_APICALL olGetDeviceInfoSizeWithCodeLoc( 605 ol_device_handle_t Device, ol_device_info_t PropName, size_t *PropSizeRet, 606 ol_code_location_t *CodeLocation); 607 608 #if defined(__cplusplus) 609 } // extern "C" 610 #endif 611