|
From: Eric L. <ew...@an...> - 2006-06-03 05:02:28
|
>> I've looked into VEX's exported interface and I only see >> LibVEX_Translate which does all the steps (bb to ir, optimize, >> instrument, etc.) of translating from the guest bytes to the host bytes >> but I only want the IR that it spits out in the middle, > > That much at least is easy enough. It hands the optimised, > uninstrumented IR to the tool's primary instrumentation function; you can > print it out or whatever at that point. > >> preferably wrapped in some kinda nice clean data structure. > > Personally I think the IR types are about as clean as you're going to get. > I've found them pleasant to work with over the past couple of years. Yea you're right, the IR data structures are easy enough to understand and use after I looked into them some more. But what I want is to use VEX as a library to generate IR and then use that IR in my own project. Initially, I thought VEX did just that and handed the IR over to the tools for further processing, but now it's clear to me that it only lets you define the instrumentation functions. Would it be a fairly involved endeavor to take apart VEX and extract just the parts that generate the IR? e.g. make calls to bb_to_IR? I mean does VEX have sub modules that would make that easier? or would I have to first understand the whole thing, then change and recompile it? Thanks, Eric > > J > > |