PDP11: Fix PSW handling for breakpoints and other aborts

Fixes #701.  The issue is more general than just breakpoints, it
potentially affects any exception dealt with by the ABORT macro.
This commit is contained in:
Paul Koning 2019-05-15 20:14:33 -04:00
parent a24119aff7
commit 096f9dbd71

View file

@ -932,12 +932,11 @@ while (reason == 0) {
reg_mods = 0; reg_mods = 0;
inst_pc = PC; inst_pc = PC;
/* Save PSW also because condition codes need to be preserved. /* Save PSW also because condition codes need to be preserved. We
We just save the whole PSW because that is sufficient (that just save the whole PSW because that is sufficient. If
representation is up to date at this point). If restoring is restoring is needed, both the PSW and the components that need
needed, both the PSW and the components that need to be restored to be restored are handled explicitly. */
are handled explicitly. */ inst_psw = get_PSW ();
inst_psw = PSW;
saved_sim_interval = sim_interval; saved_sim_interval = sim_interval;
if (BPT_SUMM_PC) { /* possible breakpoint */ if (BPT_SUMM_PC) { /* possible breakpoint */
t_addr pa = relocR (PC | isenable); /* relocate PC */ t_addr pa = relocR (PC | isenable); /* relocate PC */