handle RTI/RTT
Some checks failed
Build / cmake-builds (push) Has been cancelled
Build / makefile (macos-latest, besm6 imlac tt2500 microvax3900 microvax1 rtvax1000 vaxstation3100m76 vaxstation4000m60) (push) Has been cancelled
Build / makefile (macos-latest, id16 id32 sds lgp h316 cdc1700 swtp6800mp-a swtp6800mp-a2 tx-0 ssem b5500 sage pdq3 alpha) (push) Has been cancelled
Build / makefile (macos-latest, microvax2 vax730 vax750 vax780 vax8200 vax8600 microvax2000 infoserver100 infoserver150vxt microvax3100 microvax3100e vaxstation3100m30 vaxstation3100m38) (push) Has been cancelled
Build / makefile (macos-latest, microvax3100m80 vaxstation4000vlc infoserver1000 nova eclipse hp2100 hp3000 i1401 i1620 s3 altair altairz80 gri i7094) (push) Has been cancelled
Build / makefile (macos-latest, pdp1 pdp4 pdp6 pdp7 pdp8 pdp9 pdp10 pdp10-ka pdp10-ki pdp10-kl pdp10-ks pdp11 pdp15 vax) (push) Has been cancelled
Build / makefile (macos-latest, scelbi 3b2 i701 i704 i7010 i7070 i7080 i7090 sigma uc15 i650 sel32 intel-mds ibm1130) (push) Has been cancelled
Build / makefile (ubuntu-latest, besm6 imlac tt2500 microvax3900 microvax1 rtvax1000 vaxstation3100m76 vaxstation4000m60) (push) Has been cancelled
Build / makefile (ubuntu-latest, id16 id32 sds lgp h316 cdc1700 swtp6800mp-a swtp6800mp-a2 tx-0 ssem b5500 sage pdq3 alpha) (push) Has been cancelled
Build / makefile (ubuntu-latest, microvax2 vax730 vax750 vax780 vax8200 vax8600 microvax2000 infoserver100 infoserver150vxt microvax3100 microvax3100e vaxstation3100m30 vaxstation3100m38) (push) Has been cancelled
Build / makefile (ubuntu-latest, microvax3100m80 vaxstation4000vlc infoserver1000 nova eclipse hp2100 hp3000 i1401 i1620 s3 altair altairz80 gri i7094) (push) Has been cancelled
Build / makefile (ubuntu-latest, pdp1 pdp4 pdp6 pdp7 pdp8 pdp9 pdp10 pdp10-ka pdp10-ki pdp10-kl pdp10-ks pdp11 pdp15 vax) (push) Has been cancelled
Build / makefile (ubuntu-latest, scelbi 3b2 i701 i704 i7010 i7070 i7080 i7090 sigma uc15 i650 sel32 intel-mds ibm1130) (push) Has been cancelled
Some checks failed
Build / cmake-builds (push) Has been cancelled
Build / makefile (macos-latest, besm6 imlac tt2500 microvax3900 microvax1 rtvax1000 vaxstation3100m76 vaxstation4000m60) (push) Has been cancelled
Build / makefile (macos-latest, id16 id32 sds lgp h316 cdc1700 swtp6800mp-a swtp6800mp-a2 tx-0 ssem b5500 sage pdq3 alpha) (push) Has been cancelled
Build / makefile (macos-latest, microvax2 vax730 vax750 vax780 vax8200 vax8600 microvax2000 infoserver100 infoserver150vxt microvax3100 microvax3100e vaxstation3100m30 vaxstation3100m38) (push) Has been cancelled
Build / makefile (macos-latest, microvax3100m80 vaxstation4000vlc infoserver1000 nova eclipse hp2100 hp3000 i1401 i1620 s3 altair altairz80 gri i7094) (push) Has been cancelled
Build / makefile (macos-latest, pdp1 pdp4 pdp6 pdp7 pdp8 pdp9 pdp10 pdp10-ka pdp10-ki pdp10-kl pdp10-ks pdp11 pdp15 vax) (push) Has been cancelled
Build / makefile (macos-latest, scelbi 3b2 i701 i704 i7010 i7070 i7080 i7090 sigma uc15 i650 sel32 intel-mds ibm1130) (push) Has been cancelled
Build / makefile (ubuntu-latest, besm6 imlac tt2500 microvax3900 microvax1 rtvax1000 vaxstation3100m76 vaxstation4000m60) (push) Has been cancelled
Build / makefile (ubuntu-latest, id16 id32 sds lgp h316 cdc1700 swtp6800mp-a swtp6800mp-a2 tx-0 ssem b5500 sage pdq3 alpha) (push) Has been cancelled
Build / makefile (ubuntu-latest, microvax2 vax730 vax750 vax780 vax8200 vax8600 microvax2000 infoserver100 infoserver150vxt microvax3100 microvax3100e vaxstation3100m30 vaxstation3100m38) (push) Has been cancelled
Build / makefile (ubuntu-latest, microvax3100m80 vaxstation4000vlc infoserver1000 nova eclipse hp2100 hp3000 i1401 i1620 s3 altair altairz80 gri i7094) (push) Has been cancelled
Build / makefile (ubuntu-latest, pdp1 pdp4 pdp6 pdp7 pdp8 pdp9 pdp10 pdp10-ka pdp10-ki pdp10-kl pdp10-ks pdp11 pdp15 vax) (push) Has been cancelled
Build / makefile (ubuntu-latest, scelbi 3b2 i701 i704 i7010 i7070 i7080 i7090 sigma uc15 i650 sel32 intel-mds ibm1130) (push) Has been cancelled
This commit is contained in:
parent
c54a66edeb
commit
f0f4e5c3b8
2 changed files with 13 additions and 2 deletions
|
@ -871,7 +871,7 @@ else {
|
||||||
Check for traps or interrupts. If trap, locate the vector and check
|
Check for traps or interrupts. If trap, locate the vector and check
|
||||||
for stop condition. If interrupt, locate the vector.
|
for stop condition. If interrupt, locate the vector.
|
||||||
*/
|
*/
|
||||||
|
int show = 0;
|
||||||
while (reason == 0) {
|
while (reason == 0) {
|
||||||
|
|
||||||
int32 IR, srcspec, srcreg, dstspec, dstreg;
|
int32 IR, srcspec, srcreg, dstspec, dstreg;
|
||||||
|
@ -1095,8 +1095,11 @@ while (reason == 0) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 2: /* RTI */
|
case 2: /* RTI */
|
||||||
|
// show = 1;
|
||||||
src = ReadW (SP | dsenable);
|
src = ReadW (SP | dsenable);
|
||||||
src2 = ReadW (((SP + 2) & 0177777) | dsenable);
|
src2 = ReadW (((SP + 2) & 0177777) | dsenable);
|
||||||
|
// if (IR == 2)
|
||||||
|
// printf("> %06o %06o", src, src2);
|
||||||
STACKFILE[cm] = SP = (SP + 4) & 0177777;
|
STACKFILE[cm] = SP = (SP + 4) & 0177777;
|
||||||
oldrs = rs;
|
oldrs = rs;
|
||||||
put_PSW (src2, (cm != MD_KER)); /* store PSW, prot */
|
put_PSW (src2, (cm != MD_KER)); /* store PSW, prot */
|
||||||
|
@ -1109,11 +1112,14 @@ while (reason == 0) {
|
||||||
SP = STACKFILE[cm];
|
SP = STACKFILE[cm];
|
||||||
isenable = calc_is (cm);
|
isenable = calc_is (cm);
|
||||||
dsenable = calc_ds (cm);
|
dsenable = calc_ds (cm);
|
||||||
|
// printf("(%d)", trap_req);
|
||||||
trap_req = calc_ints (ipl, trap_req);
|
trap_req = calc_ints (ipl, trap_req);
|
||||||
JMP_PC (src);
|
JMP_PC (src);
|
||||||
if (CPUT (HAS_RTT) && tbit && /* RTT impl? */
|
if (CPUT (HAS_RTT) && tbit && /* RTT impl? */
|
||||||
(IR == 000002))
|
(IR == 000002))
|
||||||
setTRAP (TRAP_TRC); /* RTI immed trap */
|
setTRAP (TRAP_TRC); /* RTI immed trap */
|
||||||
|
// if (IR == 2)
|
||||||
|
// printf("| %06o %06o <%d|%d>", PC, get_PSW(), trap_req, TRAP_INT);
|
||||||
break;
|
break;
|
||||||
case 7: /* MFPT */
|
case 7: /* MFPT */
|
||||||
if (CPUT (HAS_MFPT)) /* implemented? */
|
if (CPUT (HAS_MFPT)) /* implemented? */
|
||||||
|
@ -2472,7 +2478,7 @@ while (reason == 0) {
|
||||||
else setTRAP (TRAP_ILL);
|
else setTRAP (TRAP_ILL);
|
||||||
break; /* end case 017 */
|
break; /* end case 017 */
|
||||||
} /* end switch op */
|
} /* end switch op */
|
||||||
if (trap_req == 0)
|
if (trap_req == 0 || trap_req == 2048 /* RTI/RTT? */)
|
||||||
break;
|
break;
|
||||||
} /* end main loop */
|
} /* end main loop */
|
||||||
|
|
||||||
|
@ -2483,6 +2489,8 @@ for (i = 0; i < 6; i++)
|
||||||
REGFILE[i][rs] = R[i];
|
REGFILE[i][rs] = R[i];
|
||||||
STACKFILE[cm] = SP;
|
STACKFILE[cm] = SP;
|
||||||
saved_PC = PC & 0177777;
|
saved_PC = PC & 0177777;
|
||||||
|
//if (show)
|
||||||
|
//printf("%06o %06o\n", saved_PC, PSW);
|
||||||
pcq_r->qptr = pcq_p; /* update pc q ptr */
|
pcq_r->qptr = pcq_p; /* update pc q ptr */
|
||||||
set_r_display (rs, cm);
|
set_r_display (rs, cm);
|
||||||
return reason;
|
return reason;
|
||||||
|
|
|
@ -540,6 +540,9 @@ void emit_misc_operations()
|
||||||
|
|
||||||
PSW = psw_val;
|
PSW = psw_val;
|
||||||
|
|
||||||
|
//if (instr == 2)
|
||||||
|
// printf("PSW=%06o, ", PSW);
|
||||||
|
|
||||||
json_t *obj = generate_test(&id, mem, 3, 1, NULL, 0);
|
json_t *obj = generate_test(&id, mem, 3, 1, NULL, 0);
|
||||||
if (obj)
|
if (obj)
|
||||||
json_array_append_new(out, obj);
|
json_array_append_new(out, obj);
|
||||||
|
|
Loading…
Add table
Reference in a new issue