From 0dda2eec666499f2b4f3e65b39ab6a2ec23ec965 Mon Sep 17 00:00:00 2001 From: hallgren <hallgren> Date: Wed, 6 Jul 1994 20:55:18 +0000 Subject: [PATCH] Updated for the sgi. --- lisp/mips-arch.c | 17 ++++++++++++++++- lisp/mips-assem.S | 11 ++++++++++- 2 files changed, 26 insertions(+), 2 deletions(-) diff --git a/lisp/mips-arch.c b/lisp/mips-arch.c index bc5ac7812..bd023ac39 100644 --- a/lisp/mips-arch.c +++ b/lisp/mips-arch.c @@ -1,5 +1,12 @@ #include <stdio.h> + +#ifdef mach #include <mips/cpu.h> +#else +#ifdef irix +#include <sys/sbd.h> +#endif +#endif #include "lisp.h" #include "globals.h" @@ -30,7 +37,11 @@ struct sigcontext *scp; { /* Skip the offending instruction */ if (scp->sc_cause & CAUSE_BD) +#ifdef mach emulate_branch(scp, *(unsigned long *)scp->sc_pc); +#else + ; +#endif else scp->sc_pc += 4; } @@ -107,7 +118,9 @@ void arch_do_displaced_inst(struct sigcontext *scp, opcode = next_inst >> 26; if (opcode == 1 || ((opcode & 0x3c) == 0x4) || ((next_inst & 0xf00e0000) == 0x80000000)) { tmp = *scp; - emulate_branch(&tmp, next_inst); +#ifdef mach + emulate_branch(&tmp, next_inst); +#endif next_pc = (unsigned long *)tmp.sc_pc; } else @@ -117,7 +130,9 @@ void arch_do_displaced_inst(struct sigcontext *scp, *next_pc = (trap_AfterBreakpoint << 16) | 0xd; os_flush_icache((os_vm_address_t)next_pc, sizeof(unsigned long)); +#ifdef mach sigreturn(scp); +#endif } static void sigtrap_handler(int signal, int code, struct sigcontext *scp) diff --git a/lisp/mips-assem.S b/lisp/mips-assem.S index df9b7f53f..4908037e2 100644 --- a/lisp/mips-assem.S +++ b/lisp/mips-assem.S @@ -1,5 +1,11 @@ -/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/mips-assem.S,v 1.3 1993/01/10 17:27:07 wlott Exp $ */ +/* $Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/lisp/mips-assem.S,v 1.4 1994/07/06 20:55:18 hallgren Exp $ */ +#ifdef mach #include <machine/regdef.h> +#else +#ifdef irix +#include <sys/regdef.h> +#endif +#endif #include "internals.h" #include "lispregs.h" @@ -186,6 +192,9 @@ call_into_c: .set reorder /* Into C land we go. */ +#ifdef irix + move t9, reg_CFUNC +#endif jal reg_CFUNC /* Clear unsaved descriptor regs */ -- GitLab