[Simh] [PATCH 05 of 14] sim_printf_log() for PDP18B

Peter Lund firefly at vax64.dk
Mon Sep 10 17:09:39 EDT 2007


1 file changed, 2 insertions(+), 5 deletions(-)
PDP18B/pdp18b_cpu.c |    7 ++-----


# HG changeset patch
# User Peter Lund <firefly at vax64.dk>
# Date 1189306509 -7200
# Node ID 95d944b6fab5ea634d52cd2c46cb5bbf3a3b3621
# Parent  dc0dda22f30a02c54aee3778cf22ba10ed0caea6
sim_printf_log() for PDP18B

diff -r dc0dda22f30a -r 95d944b6fab5 PDP18B/pdp18b_cpu.c
--- a/PDP18B/pdp18b_cpu.c	Sun Sep 09 04:54:50 2007 +0200
+++ b/PDP18B/pdp18b_cpu.c	Sun Sep 09 04:55:09 2007 +0200
@@ -278,6 +278,7 @@
 */
 
 #include "pdp18b_defs.h"
+#include "sim_console.h"
 
 #define SEXT(x)         ((int32) (((x) & SIGN)? (x) | ~DMASK: (x) & DMASK))
 
@@ -384,7 +385,6 @@ extern uint32 sim_brk_types, sim_brk_dfl
 extern uint32 sim_brk_types, sim_brk_dflt, sim_brk_summ; /* breakpoint info */
 extern t_bool sim_idle_enab;
 extern DEVICE *sim_devices[];
-extern FILE *sim_log;
 
 t_bool build_dev_tab (void);
 t_stat cpu_ex (t_value *vptr, t_addr addr, UNIT *uptr, int32 sw);
@@ -2105,10 +2105,7 @@ for (i = p =  0; (dptr = sim_devices[i])
         for (j = 0; j < dibp->num; j++) {               /* loop thru disp */
             if (dibp->dsp[j]) {                         /* any dispatch? */
                 if (dev_tab[dibp->dev + j]) {           /* already filled? */
-                    printf ("%s device number conflict at %02o\n",
-                        sim_dname (dptr), dibp->dev + j);
-                    if (sim_log) fprintf (sim_log,
-                        "%s device number conflict at %02o\n",
+                    sim_printf_log ("%s device number conflict at %02o\n",
                         sim_dname (dptr), dibp->dev + j);
                     return TRUE;
                     }



More information about the Simh mailing list