Skip to contentSkip to conversation

micro-instruction size

Qemu-devel divya arora 2 participants 2 messages May 14, 2007

lore
Share & tools
lore
#0 lore raw

Hi,
I want to instrument call instruction so that my tracking function is called on each call instruction.

Quoted 1 line

From what I understand, I should

a) change target-i386/translate.c case 0xe8 to generate my own microinstruction, say gen_op_mycall()
b) Add functionality of op_mycall() to target-i386/op.c
c) Add this new micro-instruction in i386-softmmu/opc.h.

Is the above correct?
If yes, I am not sure how to determine the microinstructions size which is required in DEF(s, n, copy_size).

Thanks,
Divya

____________________________________________________________________________________Looking for a deal? Find great prices on flights and hotels with Yahoo! FareChase.
http://farechase.yahoo.com/

#1 lore raw
Quoted 11 lines

I want to instrument call instruction so that my tracking function is called on each call instruction.

Quoted 1 line

From what I understand, I should

a) change target-i386/translate.c case 0xe8 to generate my own microinstruction, say gen_op_mycall()
b) Add functionality of op_mycall() to target-i386/op.c
c) Add this new micro-instruction in i386-softmmu/opc.h.

Is the above correct?

You only need to perform steps A and B.
Step C is automatically taken care of by dyngen.c.
Similarly, the copy_size in DEF(s,n,copy_size) is automatically computed.

Sorav