[Openmp-commits] [PATCH] LLVM OpenMP CMake Overhaul

Jonathan Peyton jonathan.l.peyton at intel.com
Tue Jun 23 10:04:12 PDT 2015


> I am strongly apposed to this change. This was designed specifically to ensure that each set of compilers can easily set their own specific flags. Do not remove this feature.

> Why - who cares? fwiw - most cmake files are named CMakeLists.txt

>  .cmake is typically used for cmake files which are meant to be reused as "modules".

>  I am a bit annoyed with the history of the cmake build system. My original system worked and was removed without much justification "just because". Now it's being refactored again and it's unclear to me the driving motivation.

Maybe I can help answer these questions with the aid of the email message below.  To get the LLVM OpenMP Runtime set as the default OpenMP runtime library linked when using the -fopenmp flag, we have to get our CMake build to use LLVM conventions/standards.  This meant putting everything in its own pseudo namespace Libomp, libomp_ , or LIBOMP_ and creating a real configuration step which checks for compiler flags, features, etc.  I've followed what libcxx and compiler-rt do by having a config-ix.cmake file which does all this.  Although the compiler flags approach I had worked for gcc,clang,icc,and msvc, this method of checking the compiler flags is more generic and allows any compiler that supports the flag to use it.  Also, there are at least three other methods of adding custom flags (-DLIBOMP_${LANG}FLAGS=' ... ' , -DCMAKE_${LANG}_FLAGS=' ... ' , or good ole CFLAGS=' ... ' envirable).  The ultimate goal here is to get the LLVM OpenMP Runtime set as the default, so I have to do whatever it takes to achieve that.  If I get the ok to keep the old compiler flag method, I will.

- Johnny




More information about the Openmp-commits mailing list