regs->ARM_ip = arch->vex.guest_R12;
regs->ARM_sp = arch->vex.guest_R13;
regs->ARM_lr = arch->vex.guest_R14;
- regs->ARM_pc = arch->vex.guest_R15;
+ regs->ARM_pc = arch->vex.guest_R15T;
regs->ARM_cpsr = LibVEX_GuestARM_get_cpsr( &((ThreadArchState*)arch)->vex );
#else
uregs.ARM_ip = vex->guest_R12;
uregs.ARM_sp = vex->guest_R13;
uregs.ARM_lr = vex->guest_R14;
- uregs.ARM_pc = vex->guest_R15;
+ uregs.ARM_pc = vex->guest_R15T;
uregs.ARM_cpsr = LibVEX_GuestARM_get_cpsr(vex);
return VG_(ptrace)(VKI_PTRACE_SETREGS, pid, NULL, &uregs);
VG_(memset)(&arch->vex_shadow1, 0, sizeof(VexGuestARMState));
VG_(memset)(&arch->vex_shadow2, 0, sizeof(VexGuestARMState));
- arch->vex.guest_R13 = iifii.initial_client_SP;
- arch->vex.guest_R15 = iifii.initial_client_IP;
+ arch->vex.guest_R13 = iifii.initial_client_SP;
+ arch->vex.guest_R15T = iifii.initial_client_IP;
/* This is just EABI stuff. */
// FIXME jrs: what's this for?
SC2(ip,R12);
SC2(sp,R13);
SC2(lr,R14);
- SC2(pc,R15);
+ SC2(pc,R15T);
# undef SC2
sc->trap_no = trapno;
tst->arch.vex.guest_R1 = (Addr)&rsf->info;
tst->arch.vex.guest_R2 = (Addr)&rsf->sig.uc;
}
- else{
+ else {
build_sigframe(tst, (struct sigframe *)sp, siginfo, siguc,
handler, flags, mask, restorer);
- }
+ }
VG_(set_SP)(tid, sp);
VG_TRACK( post_reg_write, Vg_CoreSignal, tid, VG_O_STACK_PTR,
sizeof(Addr));
- tst->arch.vex.guest_R0 = sigNo;
+ tst->arch.vex.guest_R0 = sigNo;
- if(flags & VKI_SA_RESTORER)
- tst->arch.vex.guest_R14 = (Addr) restorer;
+ if (flags & VKI_SA_RESTORER)
+ tst->arch.vex.guest_R14 = (Addr) restorer;
- tst->arch.vex.guest_R15 = (Addr) handler; /* R15 == PC */
+ tst->arch.vex.guest_R15T = (Addr) handler; /* R15 == PC */
}
REST(ip,R12);
REST(sp,R13);
REST(lr,R14);
- REST(pc,R15);
+ REST(pc,R15T);
# undef REST
tst->arch.vex_shadow1 = priv->vex_shadow1;
if (VG_(clo_trace_signals))
VG_(message)(Vg_DebugMsg,
- "vg_pop_signal_frame (thread %d): isRT=%d valid magic; PC=%#x",
- tid, has_siginfo, tst->arch.vex.guest_R15);
+ "vg_pop_signal_frame (thread %d): "
+ "isRT=%d valid magic; PC=%#x",
+ tid, has_siginfo, tst->arch.vex.guest_R15T);
/* tell the tools */
VG_TRACK( post_deliver_signal, tid, sigNo );
}
#elif defined(VGP_arm_linux)
- arch->vex.guest_R15 -= 4; // sizeof(arm instr)
+ // INTERWORKING FIXME. This is certainly wrong. Need to look at
+ // R15T to determine current mode, then back up accordingly.
+ arch->vex.guest_R15T -= 4; // sizeof(arm instr)
{
- UChar *p = (UChar*)arch->vex.guest_R15;
+ UChar *p = (UChar*)arch->vex.guest_R15T;
if ((p[3] & 0xF) != 0xF)
VG_(message)(Vg_DebugMsg,
"?! restarting over syscall that is not syscall at %#llx %02x %02x %02x %02x\n",
- arch->vex.guest_R15 + 0ULL, p[0], p[1], p[2], p[3]);
+ arch->vex.guest_R15T + 0ULL, p[0], p[1], p[2], p[3]);
vg_assert((p[3] & 0xF) == 0xF);
}