[PATCH] D106033: [OpenMP] Folding threadLimit and numThreads when single value in kernels

Johannes Doerfert via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jul 20 08:27:19 PDT 2021


jdoerfert added inline comments.


================
Comment at: llvm/lib/Transforms/IPO/OpenMPOpt.cpp:3614
 
+  /// Fold __kmpc_get_hardware_num_blocks into a constant if possible.
+  /// The value is an attribute in the kernel
----------------
JonChesterfield wrote:
> I haven't read through this part, but if we can only fold it to a constant sometimes, we shouldn't mark the calls that survive noinline, as that'll be expensive for the cases that this pass misses.
We are about to remove noinline from known runtime functions such that we can keep them around until we get to OpenMP-Opt as calls. This will have the effect we want without any drawbacks. Thus, adding `noinline` in the runitme will be totally fine.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D106033



More information about the llvm-commits mailing list