Messages in this thread | | | Date | Fri, 8 Aug 2008 20:36:02 -0400 (EDT) | From | Steven Rostedt <> | Subject | Re: [PATCH 0/5] ftrace: to kill a daemon |
| |
On Sat, 9 Aug 2008, Andi Kleen wrote:
> Steven Rostedt <rostedt@goodmis.org> writes: > > > I'm stubborn, I want to get it right _and_ keep it fast. > > For me it would seem better to just not use two part 5 byte nops > instead of adding such hacks. I doubt there are that many of them > anyways. I bet you won't be able to measure any difference between the > different nop types in any macro benchmark.
I wish we had a true 5 byte nop. The alternative is a jmp 0, which is measurable. This is replacing mcount from a kernel compile with the -pg option. With a basic build (not counting modules), I have over 15,000 locations that are turned into these 5 byte nops.
# objdump -dr vmlinux.o | grep mcount |wc 15152 45489 764924
If we use the jmp 0, then yes, we will see the overhead. The double nop that is used for 5 bytes, is significantly better than the jump.
-- Steve
| |