1 May 2011 03:19
Re: [PATCH] arm reversible : <phase_2_complete>
Petr Hluzín <petr.hluzin <at> gmail.com>
2011-05-01 01:19:43 GMT
2011-05-01 01:19:43 GMT
On 25 April 2011 16:03, paawan oza <paawan1982 <at> yahoo.com> wrote:
> Hi Petr,
>
> I have implemented your review comments.
Typo "hamdle" in thumb_hamdle_ld_st_stack_insn() still exists.
I decoded the `arm_mem_r *arm_mems' strucutre:
arm_mems[0].len - is number of valid records `arm_mems[i]' after [0].
arm_mems[i].len - is number of bytes modified by the instruction.
arm_mems[0].addr - is undefined (never written, never read) - except
on line: thumb_insn_r->arm_mems[0].addr =
u_buf[0].s_word+u_buf[1].s_word;
arm_mems[i].addr - is target address of the modified block (for i=1..)
This is reusing field arm_mem_r::len for two different things.
This is ugly.
Move the counter into insn_decode_record_t. Or use struct arm_mem_r {
int count;
struct {
uint32_t len;
CORE_ADDR addr;
} array[0];
}
Each instance of insn_decode_record_t is allocated and freed before
new instance is allocated, therefore its size does not matter.
(Continue reading)
RSS Feed