diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/core/CL/OpenCL.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/core/CL/OpenCL.cpp b/src/core/CL/OpenCL.cpp index 07baa5e7fb..2ebc3274aa 100644 --- a/src/core/CL/OpenCL.cpp +++ b/src/core/CL/OpenCL.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017-2023 Arm Limited. + * Copyright (c) 2017-2024 Arm Limited. * * SPDX-License-Identifier: MIT * @@ -196,7 +196,11 @@ bool CLSymbols::load(const std::vector<std::string> &libraries_filenames, bool u // functions. constexpr unsigned int num_platforms = 1U; std::vector<cl_platform_id> platform_ids(num_platforms); - clGetPlatformIDs(num_platforms, platform_ids.data(), nullptr); + cl_int err = clGetPlatformIDs(num_platforms, platform_ids.data(), nullptr); + if (err != CL_SUCCESS) + { + return false; + } // Command buffer and mutable dispatch command buffer extensions /// TODO: (COMPMID-6742) Load Command Buffer extensions in a Portable way |