architecture paper draft

Barton Miller bart@cs.wisc.edu
Tue Feb 15 22:26:00 GMT 2005


Chen, Brad wrote:

> As for figuring out the length of x86 instructions, Sri
> is right we do it all the time around here!

Figuring out instruction length is the first step.  However this limits you to 
using jmps only when you can find instructions of 5+ bytes in length.  Kerninst 
does additional analysis, building intra- and inter-procedural control flow 
graphs (and some basic date flow analysis too).  The important part of this 
analysis for this context is the intra-procedural, which identifies basic 
blocks. With such information, for instructions < 5 bytes, we can find 
instructions before or after the desired instrumentation point to gather enough 
bytes to fit a jmp.  This extra analysis can significantly reduce the number of 
times that you have to resort to a trap instead of a jump.

--bart



More information about the Systemtap mailing list