Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added missing interface for CL_SEMAPHORE_DEVICE_HANDLE_LIST_KHR property #113

Merged
merged 5 commits into from
Jun 21, 2024

Conversation

shajder
Copy link
Contributor

@shajder shajder commented Apr 9, 2024

Completed during work on CTS PR

@shajder
Copy link
Contributor Author

shajder commented Apr 9, 2024

I see the error from windows build:

       (Link target) -> 
         emulate.obj : error LNK2019: unresolved external symbol _clGetDeviceInfo@20 referenced in function "public: static struct _cl_semaphore_khr * __cdecl _cl_semaphore_khr::create(struct _cl_context *,unsigned __int64 const *,int *)" (?create@_cl_semaphore_khr@@SAPAU1@PAU_cl_context@@PB_KPAH@Z) [C:\projects\simpleopenclsamples\build\layers\11_semaemu\SemaEmu.vcxproj]
         C:\projects\simpleopenclsamples\build\layers\11_semaemu\Release\SemaEmu.dll : fatal error LNK1120: 1 

I am calling plain clGetDeviceInfo because g_pNextDispatch->clGetDeviceInfo for some reason does not use clGetDeviceInfo_override. Obviously this code works for me at my machine (Nvidia, ubuntu 22.04). Any clue on your mind how to call clGetDeviceInfo at Semaphore::create level ? Thanks

… to handle CL_SEMAPHORE_DEVICE_HANDLE_LIST_KHR flag
Copy link
Owner

@bashbaug bashbaug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for taking a look at this!

layers/11_semaemu/emulate.cpp Outdated Show resolved Hide resolved
layers/11_semaemu/emulate.cpp Outdated Show resolved Hide resolved
shajder added a commit to shajder/SimpleOpenCLSamples that referenced this pull request May 21, 2024
to distinguish between CL_SEMAPHORE_DEVICE_HANDLE_LIST_END_KHR and array
terminator
Copy link
Owner

@bashbaug bashbaug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! The latest version LGTM.

@bashbaug
Copy link
Owner

I'm going to go ahead and merge this even though there are CI failures because I think the failures are unrelated and already fixed in the main branch.

@bashbaug bashbaug merged commit dbc2b85 into bashbaug:main Jun 21, 2024
2 of 6 checks passed
bashbaug added a commit that referenced this pull request Jun 21, 2024
* Added missing interface for CL_SEMAPHORE_DEVICE_HANDLE_LIST_KHR property

* approach to correct CI checks errors around semaphore emulation layer to handle CL_SEMAPHORE_DEVICE_HANDLE_LIST_KHR flag

* Corrections related to negative CTS tests of clCreateSemaphoreWithPropertiesKHR

* corrections related to review #113

* Take into account additional property field

to distinguish between CL_SEMAPHORE_DEVICE_HANDLE_LIST_END_KHR and array
terminator

---------

Co-authored-by: Ben Ashbaugh <ben.ashbaugh@intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants