[PATCH] D153924: Allowing exception handling in OpenMP target regions when offloading to AMDGCN or NVPTX targets

Anton Rydahl via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Aug 2 16:20:33 PDT 2023


AntonRydahl marked 2 inline comments as done.
AntonRydahl added inline comments.


================
Comment at: clang/lib/CodeGen/CGException.cpp:624
+  const bool is_omp_gpu_target =
+      (CGM.getLangOpts().OpenMPIsDevice && (T.isNVPTX() || T.isAMDGCN()));
+  if (is_omp_gpu_target) {
----------------
jdoerfert wrote:
> Check the LLVM style guide, or the surrounding code, for variable naming.
Is it better now? Variables have to use camel case and start with an uppercase character, right?


================
Comment at: clang/lib/Frontend/CompilerInvocation.cpp:3837
+    Opts.Exceptions = exceptions_user_enabled;
+    Opts.CXXExceptions = exceptions_user_enabled;
   }
----------------
jdoerfert wrote:
> I don't get this. Is this needed?
The way it is right now before this patch, we are overwriting the users command line arguments. So `-fexceptions` and `fcxx-exceptions` will have no effect on the device. But we could introduce a new command line option instead.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D153924



More information about the cfe-commits mailing list