Hi Ron and Hal, I think, my investigation on -fno-openmp was not thorough enough. Based on your mails, I do think that Clang should have support for this option too. I will support this option.
-- mahesha On Mon, Oct 29, 2012 at 5:33 PM, Hal Finkel <[email protected]> wrote: > ----- Original Message ----- >> From: "Mahesha HS" <[email protected]> >> To: "Eli Friedman" <[email protected]>, "Dmitri Gribenko" >> <[email protected]> >> Cc: "llvm cfe" <[email protected]> >> Sent: Monday, October 29, 2012 12:47:50 AM >> Subject: [cfe-commits] OpenMP-Patch-1: fopenmp option support >> >> Hi Eli and Dmitri, >> >> Let me start again from the beginning one step at a time. Going >> further, I avoid sending more than one patch at a time as reviewing >> (big) several patches requires considerable effort, and also some >> time >> it is confusing. Attached is the very first patch to support -fopenmp >> option. This patch is in fact smaller one, and it already went >> through >> few rounds of review, and all the review comments are taken for it. >> >> However, please take one more look at it, and if it is in a good >> shape >> to commit, please do the same or provide me an approval to commit >> this >> patch. OTOH, if there is any fresh review comments, I will work on >> it. >> >> Note: Chandler as an opinion to support counter part of this option, >> namely -fno-openmp. I am still thinking, if it is worth supporting it >> as I am not aware of any other OpenMP compiler supporting such an >> option. However, let us think about it, and if we decide that it is >> useful to support it, I will support it. > > One thing that we could do, which gcc does not do (as of 4.7.2), is > explicitly disable all unused pragma warnings when -fno-openmp is provided. > Otherwise, the usefulness of -fno-openmp is certainly context dependent. As > Mahesha points out, so long as OpenMP is disabled by default (as it is in gcc > and many other compilers), using -fno-openmp by itself is a no-op. The > inverted options are sometimes useful for overriding default options in a > makefile (at least when the user options appear after the default options in > the makefile). In gcc, -fopenmp -fno-openmp leaves OpenMP disabled, while > -fno-openmp -fopenmp enables OpenMP. > > Mahesha, Thanks again for working on this. > > -Hal > >> >> >> -- >> mahesha >> >> _______________________________________________ >> cfe-commits mailing list >> [email protected] >> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits >> > > -- > Hal Finkel > Postdoctoral Appointee > Leadership Computing Facility > Argonne National Laboratory -- mahesha _______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
