[Openmp-commits] [PATCH] D156245: [OpenMP][libomptarget] Process resources when getting/returning from managers

Kevin Sala via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Tue Jul 25 09:28:39 PDT 2023


kevinsala added inline comments.


================
Comment at: openmp/libomptarget/plugins-nextgen/common/PluginInterface/PluginInterface.h:1203-1209
+  /// Get a resource from the pool or create new ones. If the function succeeds,
+  /// the handle to the resource is saved in \p Handle. Also process each of the
+  /// obtained resource with \p Processor.
+  template <typename FuncTy>
+  Error getResourceImpl(ResourceHandleTy &Handle, FuncTy Processor) {
+    return getResourcesImpl(1, &Handle, Processor);
+  }
----------------
jdoerfert wrote:
> Do we need this one now?
Not really. Managers that override `getResource` can just call the `getResourcesImpl(/*Num=*/1, ...)` directly. I'll remove it.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D156245/new/

https://reviews.llvm.org/D156245



More information about the Openmp-commits mailing list