Skip to content

fix: handle missing APIs on every static loader call - #555

Open
againull wants to merge 1 commit into
oneapi-src:masterfrom
againull:fix/loader-missing-api
Open

againull wants to merge 1 commit into
oneapi-src:masterfrom
againull:fix/loader-missing-api

Conversation

@againull

Copy link
Copy Markdown
Contributor

The static API wrappers cache function pointers, but only set a local error status during the first cache initialization. If an API is absent from the selected shared loader, the first call returns unsupported and subsequent calls invoke the cached null pointer causing a crash.

Check the cached pointer on each invocation instead of capturing a per-call result in its initializer. Regenerate the core, Sysman, Tools, and runtime wrappers from the updated template.

The static API wrappers cache function pointers, but only set a local error status during the first cache initialization. If an API is absent from the selected shared loader, the first call returns unsupported and subsequent calls invoke the cached null pointer.

Check the cached pointer on each invocation instead of capturing a per-call result in its initializer. Regenerate the core, Sysman, Tools, and runtime wrappers from the updated template.

Signed-off-by: Artur Gainullin <artur.gainullin@intel.com>

This branch has not been deployed

No deployments
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.

1 participant