Page MenuHomePhabricator

[OpenMP] Cleanup code

Authored by jlpeyton on Jul 9 2018, 3:54 PM.



This patch cleans up unused functions, variables, sign compare issues, and addresses some -Warning flags which are now enabled including -Wcast-qual. Not all the warning flags in LibompHandleFlags.cmake are enabled, but some are with this patch.

Some __kmp_gtid_from_* macros in kmp.h are switched to static inline functions which allows us to remove the awkward definition of KMP_DEBUG_ASSERT() and KMP_ASSERT() macros which used the comma operator. This had to be done for the innumerable -Wunused-value warnings related to KMP_DEBUG_ASSERT() (at least for gcc)

Diff Detail


Event Timeline

jlpeyton created this revision.Jul 9 2018, 3:54 PM
jlpeyton updated this revision to Diff 154726.Jul 9 2018, 4:03 PM

Forgot to merge in the CCAST() update from earlier today.

jlpeyton updated this revision to Diff 156882.Jul 23 2018, 2:40 PM

Updated patch so that -Warning flags are only included in stand alone builds since the LLVM in-tree builds already include the warning flags.

jlpeyton updated this revision to Diff 157997.Jul 30 2018, 10:33 AM

Removing switch statement changes as they would need a closer look in a future patch.

tlwilmar accepted this revision.Aug 6 2018, 1:41 PM


This revision is now accepted and ready to land.Aug 6 2018, 1:41 PM
Closed by commit rL339393: [OpenMP] Cleanup code (authored by jlpeyton, committed by ). · Explain WhyAug 9 2018, 3:05 PM
This revision was automatically updated to reflect the committed changes.