[PATCH] D138496: [OpenMP][OMPContext] Move SIMD alignment calculation to LLVM Frontend

Dominik Adamski via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Dec 15 06:54:50 PST 2022


domada added inline comments.


================
Comment at: llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp:3074
+  static std::string PreviousFeaturesString;
+  static std::unique_ptr<TargetMachine> TgtInfo;
+  const Target *TheTarget;
----------------
jdoerfert wrote:
> No static variables here, please.
> These should be members of the class or a helper class.
> Should we have a map of these to the respective TargetMachine?
I added a new helper class TargetMachineCache for storing TargetMachine items.

Please let me know if it is ok, that this class is located in OMPContext.h.

Storing TargetMachine objects required modification of ASTContext class.


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

https://reviews.llvm.org/D138496



More information about the llvm-commits mailing list