On Wed, Nov 4, 2009 at 5:18 PM, tejas <kkte...@gmail.com> wrote: > Hi, > > I am writing a tool to extract dynamic trace from a program run using > valgrind. I am using a modified version of lackey to accomplish this. I > understand that valgrind prints out the assembly or x86(in this case) > instructions of the program when the --profile-flags option is used. I > was wondering if there is a way to know what the guest instruction is > (like addl $2, %eax), given a particular Imark? Is there a function that > can do this? If yes, can i call this function, giving the IMARK > information as input, from the instrumentation code?
The Imark contains the address of the original instruction. If you want to do anything with the original instruction you have to look at the memory and decode it yourself. Valgrind is really targeted towards tools that don't need to know about the exact original instructions but are happy to work with a platform-independent representation. Nick ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ Valgrind-users mailing list Valgrind-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/valgrind-users