This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [RFC] gcc feature request: Moving blocks into sections
- From: Steven Rostedt <rostedt at goodmis dot org>
- To: "H. Peter Anvin" <hpa at linux dot intel dot com>
- Cc: Linus Torvalds <torvalds at linux-foundation dot org>, LKML <linux-kernel at vger dot kernel dot org>, gcc <gcc at gcc dot gnu dot org>, Ingo Molnar <mingo at kernel dot org>, Mathieu Desnoyers <mathieu dot desnoyers at efficios dot com>, Thomas Gleixner <tglx at linutronix dot de>, David Daney <ddaney dot cavm at gmail dot com>, Behan Webster <behanw at converseincode dot com>, Peter Zijlstra <peterz at infradead dot org>, Herbert Xu <herbert at gondor dot apana dot org dot au>
- Date: Mon, 05 Aug 2013 14:49:43 -0400
- Subject: Re: [RFC] gcc feature request: Moving blocks into sections
- References: <1375721715 dot 22073 dot 80 dot camel at gandalf dot local dot home> <CA+55aFw_o=D-j_SRn=Y4LhHm-tEyuP1Je5ZHVTYxbVyLyDcLEg at mail dot gmail dot com> <1375725328 dot 22073 dot 101 dot camel at gandalf dot local dot home> <51FFEC56 dot 6040206 at linux dot intel dot com> <1375727010 dot 22073 dot 110 dot camel at gandalf dot local dot home> <51FFEEEC dot 5060902 at linux dot intel dot com>
On Mon, 2013-08-05 at 11:29 -0700, H. Peter Anvin wrote:
> Traps nest, that's why there is a stack. (OK, so you don't want to take
> the same trap inside the trap handler, but that code should be very
> limited.) The trap instruction just becomes very short, but rather
> slow, call-return.
>
> However, when you consider the cost you have to consider that the
> tracepoint is doing other work, so it may very well amortize out.
Also, how would you pass the parameters? Every tracepoint has its own
parameters to pass to it. How would a trap know what where to get "prev"
and "next"?
-- Steve