[Openmp-commits] [PATCH] D106509: [OpenMP][OpenACC] Implement `ompx_hold` map type modifier extension in Clang (1/2)

Joel E. Denny via Phabricator via Openmp-commits openmp-commits at lists.llvm.org
Thu Aug 12 13:20:20 PDT 2021

jdenny added inline comments.

Comment at: clang/include/clang/Driver/Options.td:2383
+defm openmp_extensions: BoolFOption<"openmp-extensions",
+  LangOpts<"OpenMPExtensions">, DefaultFalse,
+  PosFlag<SetTrue, [CC1Option, NoArgumentUnused],
ABataev wrote:
> Why do you want to disable it by default?
I thought that's what we agreed upon.

I'm personally happy if, in general, all features are enabled by default and users opt out by requesting strict conformance, but Clang doesn't do that today even for features from newer OpenMP standards.  Should it do so for extensions, which appear in no standard?

What would you prefer?

Comment at: clang/lib/Driver/ToolChains/Clang.cpp:5774-5776
+      if (Args.hasFlag(options::OPT_fopenmp_extensions,
+                       options::OPT_fno_openmp_extensions, /*Default=*/false))
+        CmdArgs.push_back("-fopenmp-extensions");
ABataev wrote:
> Do we still need this?
I tried removing these, but then the driver doesn't pass `-fopenmp-extensions` to the front end.  Am I doing something wrong?



More information about the Openmp-commits mailing list