Thread (9 messages) 9 messages, 5 authors, 2009-09-24

Re: [PATCH 00/10] Add support for GCC's __builtin_unreachable() and use it in BUG.

From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Date: 2009-09-24 03:44:44
Also in: linux-s390, linuxppc-dev

On Thu, 2009-09-10 at 16:54 -0700, David Daney wrote:
Starting with version 4.5, GCC has a new built-in function called
__builtin_unreachable().  The function tells the compiler that control
flow will never reach that point.  Currently we trick the compiler by
putting in for(;;); but this has the disadvantage that extra code is
emitted for an endless loop.  For an i386 kernel using
__builtin_unreachable() results in an allyesconfig that is nearly 4000
bytes smaller.
For the powerpc part:

Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help