[llvm] [Offload] Only initialize a plugin if it is needed (PR #92765)
Jan Patrick Lehr via llvm-commits
llvm-commits at lists.llvm.org
Thu May 23 05:58:44 PDT 2024
================
@@ -160,6 +153,27 @@ void PluginManager::registerLib(__tgt_bin_desc *Desc) {
if (Entry.flags == OMP_REGISTER_REQUIRES)
PM->addRequirements(Entry.data);
+ // Initialize all the plugins that have associated images.
+ for (auto &Plugin : Plugins) {
+ if (Plugin->is_active())
----------------
jplehr wrote:
Does this now need to be `is_initialized`?
https://github.com/llvm/llvm-project/pull/92765
More information about the llvm-commits
mailing list