Re: [RFC][PATCH] tracepoints: Move the work out of line from hotpathsections

From: David Daney
Date: Thu Aug 09 2012 - 19:54:20 EST


On 08/09/2012 04:16 PM, H. Peter Anvin wrote:
On 08/09/2012 03:25 PM, Steven Rostedt wrote:

It might be better to improve gcc to move really cold branches out of
line (really, really far away), and use the compiler to do this, rather
than to use an extra indirection that adds bloat and complexity to the
kernel.

Oh, you mean like: -freorder-blocks-and-partition


I think modifying gcc is something that can help more than tracing. But
that's been a pipe dream for such a long time that I've started dreaming
about winning a gold medal in the Olympics instead. Standing on the
podium listening to the crowd chanting your name along with your country
is more fun to dream about than seeing your unlikely code stop becoming
hurdles for the CPU sprinters.


At one point, maybe, but lately we have had a lot more traction from the
gcc developers, giving us features like __fentry__ and asm goto.


I don't claim that -freorder-blocks-and-partition is bug free, but I imagine that the GCC developers would be open to fixing any bugs found.

David Daney

--
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/