On 06/15/2018 10:35 AM, Jakub Jelinek wrote: > On Fri, Jun 15, 2018 at 10:31:26AM -0600, Jeff Law wrote: >> On 06/14/2018 02:32 PM, David Malcolm wrote: >>> The idea is to later use these macros to mark the >>> if (dump_enabled_p ()) >>> parts of the compiler as cold, in the hope of helping non-PGO builds >>> of gcc. >>> >>> I haven't measured it yet, though. >>> >>> gcc/ChangeLog: >>> * system.h (GCC_LIKELY, GCC_UNLIKELY): New macros, adapted from >>> libgfortran.h. >> ISTM if we're going to bother with this stuff that we should try to be >> consistent between glibc and gcc. Anything else seems like utter >> madness to me. > > Do we really need these macros at all? I certainly question this as well.
We are already using > __builtin_expect directly in gcc/ subdirectory (with system.h providing > a dummy macro if not supported by the host compiler). > And I bet GCC developers are all familiar with __builtin_expect. Yup. But I doubt we want to litter the sources with references to them. jeff