The use of defined(__GNUC__) alone for the conditional for
__builtin_expect is ugly; there may be non-gcc compilers that support it
too.
[...]
You can override these definitions to whatever you like already. The (embedded) compilers I've used seem to be either GNU or LLVM based, or so different from a GNU compiler that this scheme will not work. In case a compiler ever shows up for which this scheme would work you can modify luaconf.h and add another test, that's what it is for.
Gé