[Simh] trouble selecting VAX ethernet on CentOS

Michael L. Umbricht mike at umbricht.org
Wed Feb 29 15:38:32 EST 2012


With no special options to "make vax" I do get "push   %rbp" from "disas
eth_open"

-mikeu

[mikeu at rigel markpizz-simh-9386369]$ make vax
lib paths are: /lib64/ /usr/lib64/ /usr/lib64/atlas/ /usr/lib64/mysql/
/usr/lib64/qt-3.3/lib/ /usr/lib64/xulrunner-2/
using libm: /usr/lib64//libm.so
using librt: /usr/lib64//librt.so
using libpthread: /usr/lib64//libpthread.so /usr/include/pthread.h
using libdl: /usr/lib64//libdl.so /usr/include/dlfcn.h
using libpcap: /usr/include/pcap.h
*** Simulator(s) being built with networking support using
*** Linux provided libpcap components
gcc -std=c99 -U__STRICT_ANSI__ -g -I . -D_GNU_SOURCE -DSIM_ASYNCH_IO
-DUSE_READER_THREAD  -DHAVE_DLOPEN=so  sim_BuildROMs.c -o BIN/BuildROMs
BIN/BuildROMs
rm -f BIN/BuildROMs
gcc -std=c99 -U__STRICT_ANSI__ -g -I . -D_GNU_SOURCE -DSIM_ASYNCH_IO
-DUSE_READER_THREAD  -DHAVE_DLOPEN=so  VAX/vax_cpu.c VAX/vax_cpu1.c
VAX/vax_fpa.c VAX/vax_io.c VAX/vax_cis.c VAX/vax_octa.c  VAX/vax_cmode.c
VAX/vax_mmu.c VAX/vax_stddev.c VAX/vax_sysdev.c VAX/vax_sys.c 
VAX/vax_syscm.c VAX/vax_syslist.c PDP11/pdp11_rl.c PDP11/pdp11_rq.c
PDP11/pdp11_ts.c PDP11/pdp11_dz.c PDP11/pdp11_lp.c PDP11/pdp11_tq.c
PDP11/pdp11_xq.c PDP11/pdp11_ry.c PDP11/pdp11_vh.c PDP11/pdp11_cr.c
PDP11/pdp11_io_lib.c scp.c sim_console.c sim_fio.c sim_timer.c
sim_sock.c sim_tmxr.c sim_ether.c sim_tape.c sim_disk.c -DVM_VAX
-DUSE_INT64 -DUSE_ADDR64 -I VAX -I PDP11 -DUSE_SHARED -DUSE_TAP_NETWORK
-o BIN/vax -lm -lrt  -lpthread  -ldl  
[mikeu at rigel markpizz-simh-9386369]$ gdb BIN/vax
GNU gdb (GDB) Red Hat Enterprise Linux (7.2-50.el6)
Copyright (C) 2010 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later
<http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show
copying"
and "show warranty" for details.
This GDB was configured as "x86_64-redhat-linux-gnu".
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>...
Reading symbols from
/home/mikeu/Downloads/markpizz-simh-9386369/BIN/vax...done.
(gdb) disas eth_open
Dump of assembler code for function eth_open:
   0x00000000004532c1 <+0>:	push   %rbp

<snip>

> -------- Original Message --------
> Subject: Re: [Simh] trouble selecting VAX ethernet on CentOS
> From: Michael Bloom <mabloom at dslextreme.com>
> Date: Mon, February 27, 2012 11:44 pm
> To: "Michael L. Umbricht" <mike at umbricht.org>
> Cc: simh at trailing-edge.com
> 
> 
> Before doing what I had previously suggested (below), you could first 
> check to see if it might help by typing "disas eth_open" in gdb.  If the 
> first line reads "push   %rbp", then you have frame pointers.
> 
> If you don't have framepointers, THEN add -fno-omit-frame-pointer to 
> your gcc command, rebuild SIMH, and then try running under gdb again.
> 
> In contrast with their more recent practices, Ubuntu seems to have made 
> a change for the better, according to some tests I just made.  When gcc  
> 4.6 changed the default frame pointer option to be to omit  them,  
> Ubuntu chose not to pick up that change. But some other distros may not 
> have made that choice, so it might be good to always add 
> "-fno-omit-frame-pointer" whenever using "-g" on intel boxes.
> 
> - Michael
> 
> P.S. There  are two other reasons I can immediately think of for why the 
> stack might look so messed up.  One is that something has clobbered it 
> (maybe the compiler hasn't generated code that is safe for your 
> threads?).  The other is that in the event of a SIGSEGV, your kernel 
> might be leaving virgin evidence of the trap frame  and not bothering to 
> set up the signal trampoline code and trap frame so as to be trackable 
> by a debugger.   (If so, it's a fixable problem, but not a user fixable 
> one, and the fix might have binary backward compatibility issues, unless 
> the person fixing it really lucks out).
> 
> On 02/26/2012 11:26 PM, Michael Bloom wrote:
> > Uggh.  It looks like you are on a system that doesn't set up usable 
> > (for the purposes of debugging)  stack frames.
> >
> > I didn't see a "-fomit-frame-pointer" in your compilation, but  if you 
> > are using a recent gcc (>=4.6, or maybe just set up that way on CentOS 
> > for the hell of it), then that's the default on your system.
> >
> > Add -fno-omit-frame-pointer to your gcc command, rebuild SIMH, and 
> > then try running under gdb again.
> >
> > The presence of frame pointers should help gdb find what's in each 
> > stack frame.
> >
> > Also, while you are in gdb, try listing the lines around 1454. Unless 
> > I missed the release announcement, 3.8.2 is a pre-release, so the 
> > lines you have may not be the same as the ones others have, so people 
> > can't go by just line numbers to see where you are.
> >
> > - Michael
> >




More information about the Simh mailing list