Re: [patch 0/2] Immediate Values - jump patching update
- From: Pavel Machek <pavel@xxxxxx>
- Date: Wed, 14 May 2008 16:53:57 +0200
Hi!
At least one complication though is that in the case of markers,
tracing parameter evaluation is itself conditional (and placed out of
the hot path due to -freorder-blocks). With your suggested kind of
assembly ("g" constraints for all the expressions), those expressions
would be evaluated unconditionally, just to make them live somewhere.
That unconditional evaluation can easily entail memory reads and
dependent arithmetic, which could swamp the savings of eliminating
the marker-style conditional branch.
Well, it depends a bit on what kind of expressions you put in there.
You don't really want to put *expressions* in there as much as you
want to put *data* references in there, although, of course, if your
have something like "foo->bar[baz]->quux" then it's easy to trip upon.
and that's exactly what was tripped upon in sched.o and analyzed.
Furthermore, the suggestion of doing this exclusively within the DWARF2
space - besides the not particularly minor complication of it not being
implemented yet - is:
- quite substantially complex on its own
- would make Linux instrumentation dependent on all sorts of DWARF2
details which we had our 'fun' with before. (I proffer that that's
more fragile than any code patching can ever be.)
- if done self-sufficiently (i.e. if a kernel image can be used to
trace things, which i believe any usable kernel tracer must offer),
it would, with the current debug info format, enlargen the kernel RAM
image with quite a substantial amount of unswappable kernel memory.
I am not sure self-sufficiency is good goal here.
If tracing becomes part of kernel-user ABI, we are in big trouble...
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
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/
- Prev by Date: Re: [PATCH 4/4] jbd: fix error handling for checkpoint io (rebased)
- Next by Date: Re: [PATCH #repost] SCSI: megaraid, fix suspend/resume sections
- Previous by thread: Re: [patch 0/2] Immediate Values - jump patching update
- Next by thread: Re: [PATCH 1/1] x86: fix text_poke
- Index(es):
Relevant Pages
|
Loading