]> git.ipfire.org Git - thirdparty/glibc.git/commit
regex: __builtin_expect → __glibc_unlikely
authorPaul Eggert <eggert@cs.ucla.edu>
Mon, 15 Oct 2018 03:20:08 +0000 (22:20 -0500)
committerPaul Eggert <eggert@cs.ucla.edu>
Mon, 15 Oct 2018 04:36:55 +0000 (23:36 -0500)
commitf4efbdfb44ebb7dfe4c19759c426153bdd48a1dd
tree1e0e5597ff21cbf2da31cb3438b73510d296dda4
parent9f9feb6d5db3bf7b3cda6d7a23029f93da80895d
regex: __builtin_expect → __glibc_unlikely

[BZ#23744]
This refactoring was prompted by a problem when the regex code is
used as part of Gnulib and when the builder’s compiler does not grok
__builtin_expect.  Problem reported for Gawk by Nelson H.F. Beebe in:
https://lists.gnu.org/r/bug-gnulib/2018-09/msg00137.html
Although this refactoring does not fix the problem directly,
we might as well have Gawk use the now-preferred glibc style for when
__builtin_expect is unavailable.
* posix/regex_internal.h (BE): Remove.
All uses replaced by __glibc_unlikely or __glibc_likely.
ChangeLog
posix/regcomp.c
posix/regex.c
posix/regex_internal.c
posix/regex_internal.h
posix/regexec.c