Skip to content

[Offload] Offloading API always initializes all plugins and devices #159636

@jhuber6

Description

@jhuber6

The offloading API currently loads all available plugins when we initialize. The overhead of initializing a plugin that isn't needed is quite large, and existing runtimes like OpenMP intentionally avoid this by checking if any images require a plugin before loading them. It would be nice if something similar could be implemented through the Offloading API.

Right now the API exposes the platform as an implementation detail of the device. I'm wondering if there's an easy solution to this. Either we change the initialization code to accept a callback that states if a platform should be used, or we perform this lazily until someone actually needs it.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions