Re: [Patch 4/4] Tell GCC 4.1 to move unlikely() code to a separate section



In-Reply-To: <200602271639.34776.ak@xxxxxxx>

On Mon, 27 Feb 2006 16:39:34, Andi Kleen wrote:
On Monday 27 February 2006 16:31, Arjan van de Ven wrote:
This patch is more controversial I assume; it offers the option
to use the gcc 4.1 option to move unlikely() code to a separate section.
On the con side, this means that longer byte sequences are needed to jump
to this code, on the Pro side it means that the unlikely() code isn't sharing
icache cachelines and tlbs anymore.

I don't think this will do anything because the default Makefile
still has

CFLAGS += -fno-reorder-blocks

This also won't work for functions that specify an explicit section name,
e.g. __sched, __kprobes etc. -- at least that's what the gcc 4.0.2 docs say.

--
Chuck
"Equations are the Devil's sentences." --Stephen Colbert

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



Relevant Pages

  • Re: [PATCH 2/8] tracing: create automated trace defines
    ... Perhaps we should fork off gcc and ship Linux with its own compiler. ... The unlikely code does not always get moved out that far. ... These are separate options. ...
    (Linux-Kernel)
  • Re: osx su pc. eccolo.
    ... > make che googlando ho visto essere causato da un bug in gcc 4.0 ... > (errore che pare avvenire con la compilazione di Mozilla). ... > patch su bugzilla, ... vettorizzante ed alcune estensioni note per dare problemi di gcc 4.0? ...
    (it.comp.macintosh)
  • Re: [PATCH 2/8] tracing: create automated trace defines
    ... Perhaps we should fork off gcc and ship Linux with its own compiler. ... and looking at the tracepoint code it did not move it ... Having all "unlikely"s go into a separate section would not help much, ...
    (Linux-Kernel)
  • Re: 32 vs. 64 bit on Leopard?
    ... Chris Ridd wrote: ... separate versions of gcc etc. for each? ... I'd be surprised if Apple felt they needed to do it differently. ...
    (uk.comp.sys.mac)
  • Re: 32 vs. 64 bit on Leopard?
    ... Chris Ridd wrote: ... separate versions of gcc etc. for each? ... I'd be surprised if Apple felt they needed to do it differently. ...
    (uk.comp.sys.mac)