Skip to content

Comments

Added an OpenCL deinitialization test and plugin infrastructure.#268

Merged
bashbaug merged 9 commits intoKhronosGroup:mainfrom
Kerilk:plugin-test
Feb 5, 2026
Merged

Added an OpenCL deinitialization test and plugin infrastructure.#268
bashbaug merged 9 commits intoKhronosGroup:mainfrom
Kerilk:plugin-test

Conversation

@Kerilk
Copy link
Contributor

@Kerilk Kerilk commented Jan 22, 2026

Hello,

This PR does several things:

  • Refactor platform specific components (and dependencies) of the loader in logical units;
  • Creates a test program (cl_plugin_loader_test) that loads and unloads a shared library plugin in a loop (leverages above components);
  • Creates a plugin, linked to the OpenCL ICD Loader that will exercise OpenCL calls when initialized through a predetermined entry point. When unloaded, this plugin will also automatically unload the OpenCL ICD Loader.
  • Adds a new test that will invoke the cl_plugin_loader_test program using the plugin, exercising the OpenCL ICD Loader loading and unload capabilities.

For now the test just verifies that the program returns correctly, but additional manual testing can be done using loader tracing and memory validator like valgrind to ensure proper execution and absence of memory leaks.

@Kerilk Kerilk requested review from EwanC and bashbaug January 22, 2026 01:26
Copy link
Contributor

@EwanC EwanC left a comment

Choose a reason for hiding this comment

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

LGTM, my comments are all superficial

@Kerilk
Copy link
Contributor Author

Kerilk commented Jan 22, 2026

Thanks for the great review! I'll go an fix these ASAP.

Copy link
Contributor

@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.

This is a very nice cleanup - thank you for doing this!

Copy link
Contributor

@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! Latest changes LGTM.

@bashbaug bashbaug merged commit 405c4be into KhronosGroup:main Feb 5, 2026
52 checks passed
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.

3 participants