OpenCL* for CPU
Ask questions and share information on Intel® SDK for OpenCL™ Applications and OpenCL™ implementations for Intel® CPU.
Announcements
This forum covers OpenCL* for CPU only. OpenCL* for GPU questions can be asked in the GPU Compute Software forum. Intel® FPGA SDK for OpenCL™ questions can be ask in the FPGA Intel® High Level Design forum.
1718 Discussions

OpenCL build failure with error code -1073741511

ZHIFENG_W_Intel
Employee
10,076 Views

I'm trying my first OpenCL program. I installed "OpenCL™ Tools for Visual Studio" From <https://dynamicinstaller.intel.com/system-studio/> . Then, I created a project in VS2019, using "GPU openCL project for windows". I didn't change any line of code, just ran the "Build solution" command to build, and found the build failed with error code -1073741511 (see the first attached screenshot).

 

I copied and ran the build command in the command prompt window. It failed same but with more info. An error dialog appeared with title "ioc64.exe - Entry Point Not Found". (See the 2nd attached screenshot).

 

I googled and failed to find a solution. Also I tried reinstall the "OpenCL™ Tools for Visual Studio" multiple times. The issue persists.  It's frustrating and please help to provide some advices. Thanks!

0 Kudos
1 Solution
Michael_C_Intel1
Moderator
10,076 Views

Thanks for the feedback ZhifengW.

 

Zhifeng,

I think that driver is too old for the SDK. I have to speculate somewhat because vendors may or may not follow the same versioning scheme that applies to the reference drivers off of downloadcenter.intel.com.

The challenge with downloadcenter.intel.com drivers is that system vendors may disable them from installing.

Searching your vendor model shows they may have a driver release 02 Dec 2019 that could apply... Can you try an updated driver from the vendor?

Intel DCH drivers from early 2019 should work... I'd assume vendor repackages in late 2019 would include the needed updates.

 

-MichaelC

View solution in original post

0 Kudos
14 Replies
Michael_C_Intel1
Moderator
10,075 Views

Hi ZhifengW,

 

Thanks for the interest, experience feedback and the screen shots.

I haven't seen this issue before. At first impression, it looks like a back-end issue. I ran through deployment and GPU project build on an Intel® Core™ i5-6xxxU Processor + Windows* OS system and didn't observe the same issue.... but hopefully the comments below can steer toward a resolution.

Follow up:

Can you share your processor SKU? Version of Windows? Version of MSVS2019 (Help->About)?

What is the system vendor (if the system is not custom built)?

Can you share your OpenCL capable device configuration on the system (Intel and non-Intel devices)?
Where the display is connected?

Version of the graphics driver deployed for Intel Graphics Hardware (if applicable... assuming so)? Start->Device Manager->Display Adapters->Intel(R) Device Name->Properties->Driver Version (Driver Date & Driver Version)
 From where did you acquire it?

Does a CPU targeted project work? The CPU project similarly has an ioc64.exe kernel pass.


Some context about ioc64.exe:

ioc64.exe is a compiler front end tool that will compile the Template.cl kernel.It is triggered in configured MSVS projects by the Build action. Thus, users can see any kernel compile time errors before their program launches... as opposed to at runtime which would become harder to debug.

ioc64.exe has seen refactor and other enhancements between 2019u5 SDK and 2020 SDK versions. The clCreateProgramWithIL() codepath in it is new. Any ioc64.exe feedback given is appreciated.

ioc64.exe can be launched by hand from the commmand line to build a kernel.

Some of ioc64.exe's functionality can be accomplished by a user writing a program to build a kernel through either the Intel CPU or GFX OpenCL implementations, and examining the build output or storing the built kernel to disk for later consumption by the runtime.... i.e. the runtime can emit device built kernel binaries/intermediates.

A proxy to see if this functionality is working can be tried to check configuration health in clinfo... does clinfo work on the system? IIRC, clinfo has to perform a compile step to emit some of the parameters it displays... It may or may not expose a similar issue. Can you share the clinfo output of your current configuration?

Inspection tools like clinfo can be very useful in production development.

 

Quicker Fix Possibility:

If the system has Intel GFX hardware, can you try updating the Intel GFX driver? Try the system vendors website first for a driver package as some system vendors require using their drivers for support.

After checking at the vendor website... if that doesn't apply, try downloadcenter.intel.com, where ioc64.exe supported implementations are provided in the Intel DCH Gfx Drvier for Windows* OS.

If you can, please provide clinfo output before and after the configuration change.... Without looking at ioc64.exe source the issue looks like the Intel Graphics Runtime for OpenCL implementation is not configured correctly on the system for ioc64.exe to execute.

Note: DCH drivers that debuted under Windows OS approx. 1 year ago were a major inflection point that caused breakage in some legacy software. It's possible that the vendor has elected to redistribute Intel GFX drivers prior to this change... Confirming the driver in use may help.

 

Thanks,

-MichaelC

0 Kudos
chao__chen
Beginner
10,075 Views

I ran into the same situation, and I'm sure it was due to installing nvidia's latest graphics driver (441.87). Neither uninstalling the nvidia driver nor reinstalling the Intel opencl SDK nor using thesystem recovery to restore to the previous state can solve the problem. The only solution is to reinstall the operating system

0 Kudos
ZHIFENG_W_Intel
Employee
10,075 Views
Hi Michael, Thank you for the quick response! I tried the CPU target. The same issue happens. I also tried the installation of "Intel® SDK for OpenCL™ Applications". The issue persists. Also I tried to install the latest graphics driver from https://downloadcenter.intel.com/download/29274/Intel-Graphics-Windows-10-DCH-Drivers?product=80939. It can't be installed. Attached are 2 screenshots about my computer's CPU/windows/visual studio. My computer model is Dell Precision T3420.
0 Kudos
Michael_C_Intel1
Moderator
10,077 Views

Thanks for the feedback ZhifengW.

 

Zhifeng,

I think that driver is too old for the SDK. I have to speculate somewhat because vendors may or may not follow the same versioning scheme that applies to the reference drivers off of downloadcenter.intel.com.

The challenge with downloadcenter.intel.com drivers is that system vendors may disable them from installing.

Searching your vendor model shows they may have a driver release 02 Dec 2019 that could apply... Can you try an updated driver from the vendor?

Intel DCH drivers from early 2019 should work... I'd assume vendor repackages in late 2019 would include the needed updates.

 

-MichaelC

0 Kudos
Michael_C_Intel1
Moderator
10,075 Views

Thanks ChenC,

Is there anyway you can share your system configuration listing any non-Intel OpenCL devices? I'd like to forward it into the product team.

OpenCL implementations on Windows are typically found through the registry... Installers can edit the registry but implementation entry points must be referenced. OpenCL.dll will look in known locations in the registry for references.

Here is the Khronos reference on where registry entries on Windows* OS live for recent deployments... OpenCLDriverName gives the location string… See section 2.4
Some of the older references were in a separate location.

-MichaelC

0 Kudos
Ben_A_Intel
Employee
10,075 Views

I'm almost positive that this issue is caused by an older OpenCL ICD loader (OpenCL.dll).  Specifically, ioc64.exe is trying to use a newer OpenCL 2.1 API (clCreateProgramWithIL), but this API isn't found in the OpenCL ICD loader or any other DLLs, so it is failing to load.

The OpenCL ICD loader should be versioned to prevent issues like these, but it's possible that some installer is either failing to install a newer version, or erroneously overwriting the newer version with an older version.  A few things to check:

  • How many copies of OpenCL.dll do you have on your system?  Most of the installers I know of will install to c:\windows\system32 (for 64-bit apps) or c:\windows\syswow64 (for 32-bit apps).  If you find OpenCL.dll somewhere else, particularly in a location in your path, do you know where it came from?
  • Can you check the DLL version of your OpenCL.dll?  If it's 2.1 or newer then that's probably fine, but if it's 2.0 or older then it's likely too old.
  • Can you check the DLL exports for your OpenCL.dll, for example using "dumpbin /exports"?  Do you see an export for clCreateProgramWithIL?

If you really want to, you can build an up-to-date OpenCL 2.2 OpenCL.dll from https://github.com/KhronosGroup/OpenCL-ICD-Loader, but this shouldn't be required.

0 Kudos
ZHIFENG_W_Intel
Employee
10,075 Views
Thank you, Michael and Ashbaugh, for the advises! I installed the latest graphics driver from Dell site. The issue disappeared. The displayed openCL version changes from v2.0 to v2.1. So it indeed due to the old graphics driver.
0 Kudos
Michael_C_Intel1
Moderator
10,075 Views

For any thread lurkers and OpenCL developers...

BenA's guidance is useful general guidance when diagnosing a system with devices from multiple vendors. It's possible an installer from some vendor can replace OpenCL.dll with an older version... so it's incompatible with newer programs. Newer versions of the dll should be backward compatible.

-MichaelC

0 Kudos
chris_st
Beginner
10,076 Views

Hello

I have installed the Intel OpenCL SDK version 2020.0.245 (*) on my Dell Precision 5540 with Intel Graphics 630 and NVIDIA Quadro T2000. Im using Windows 10 and Visual Studio 2019. Executing OpenCL kernels on the GPU works well.

I have the same problem. When I run ioc64.exe I get the error: "The procedure entry point clCreateProgramWithIl could not be located in the DLL..."

I've checked my installed OpenCL.dll and it doesn't contain an export for clCreateProgramWithIL. I've checked some other computers and it seems that the NVIDIA version of OpenCL.dll doesn't contain the necessary functions. Another laptop with AMD graphics adapter and OpenCL.dll contains the necessary functions.

Now, I have installed an older version of the OpenCL SDK, version 2019.5.345, and ioc64.exe runs now. However, when I try to compile a OpenCL kernel I get the following error message: error CL : Failed to get platform id...: 0 (CL_SUCCESS) It's the same problem as discussed in thread: https://software.intel.com/en-us/forums/opencl/topic/605570 

(*) Unfortunately, the problem isn't solved in the newest SDK: intel_sdk_for_opencl_applications_2020.1.396

Chris

0 Kudos
RoyTro
Beginner
10,075 Views
I faced the exact same problem. I got the error code -1073741511 when loading the OpenCL GPU Project. I found the source of the problem. When I click on ioc64.exe or ioc32.exe which my project was trying to load, I get " "The procedure entry point clCreateProgramWithIL could not be located in the dynamic link library" followed by the path to my executable.". I found that clCreateProgramWithIL was in the lib file but wasn't in the OpenCL.DLL file which is why the error persists. I heard that clCreateProgramWithIL can only OpenCL 2.1 or newer. My computer's version of OpenCL is 1.2. The problem with updating it to 2.1 is that my computer is only compatible with 1.2.
0 Kudos
Quant_Geek
Beginner
10,075 Views

I am also having the same problem.  It came with the nVidia Titan RTX drivers that I installed last month. Clearly, all nVidia-based systems are having problems and based on the documentation at nVidia, they only support OpenCL 1.2. 

0 Kudos
faber__byron
Novice
10,075 Views

I'm having the same problem.  'Looks like the nvidia drivers screw up the OpenCL dll version.. and even when thats corrected, ioc64 s till reports  " error CL: Failed to get platform id...: 0 (CL_SUCCESS)"

Anybody found a solution?

0 Kudos
Sergey_I_Intel1
Employee
10,075 Views

Hello Byron,

 

This should be issue with your CPU Runtime, or GPU Driver.

Please, reinstall them to have correct environment.

To check your environment you can use clinfo here.

 

Best regards,

Sergey

0 Kudos
faber__byron
Novice
10,075 Views

[edit]

Actually.   no magic, you're right.  clinfo suggested the cpu runtime didn't exist for some reason, but the gpu runtimes did.  'reinstalling the dell supplied intel gpu driver got the cpu runtime back in order and now everything is fine.

I do think, as others have said, the nvidia graphics drivers are installing an odd opencl.dll, but forcing the intel gpu driver back on got it straight.

Thanks again!

0 Kudos
Reply