2011/4/24 Peter Maydell >Thanks for finding this. I agree the fix is required, but I think I'd >prefer it if the thumb code for this case handled it in the same way >the disas_arm_insn() code does: > > loaded_base = 0; > TCGV_UNUSED(loaded_var); > [...] > tmp = gen_ld32(addr, IS_USER(s)); > if (i == 15) { > gen_bx(s, tmp); > } else if (i == rn) { > loaded_var = tmp; > loaded_base = 1; > } else { > store_reg(s, i, tmp); > } > [...] > if (loaded_base) { > store_reg(s, rn, loaded_var); > } > >-- PMM
Thank you for your advice. I am going to send a new patch soon.