es40-developers Mailing List for AlphaServer ES40 Emulator (Page 13)
Status: Alpha
Brought to you by:
iamcamiel
You can subscribe to this list here.
2008 |
Jan
|
Feb
(132) |
Mar
(117) |
Apr
(27) |
May
(1) |
Jun
(16) |
Jul
|
Aug
|
Sep
(4) |
Oct
(5) |
Nov
(2) |
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2009 |
Jan
|
Feb
|
Mar
|
Apr
(5) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2010 |
Jan
|
Feb
|
Mar
|
Apr
(3) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2011 |
Jan
|
Feb
|
Mar
|
Apr
(3) |
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Camiel V. <iam...@gm...> - 2008-02-08 07:56:51
|
I've changed the keyboard implementation to default to scancode set 3 (PS/2) rather than 2 (AT); this seems to do the trick for me. At least, Ctrl-P and Ctrl-C now work as it should. Camiel. On Feb 8, 2008 8:02 AM, Camiel Vanderhoeven <iam...@gm...> wrote: > Hello David, > > This ties in with a discussion I've had with Brian on this mailing list; > > The scanset 2 scancodes for the left control key is 0x14; this is > delivered fine. It appears now, however, that SRM is expecting scanset > 3 codes; in this set, 0x14 means Caps Lock. > > This is an important clue in sorting this mess out. I think I might > have it in a few hours... > > Camiel. > > > On Feb 8, 2008 2:23 AM, Hittner, David T. <dav...@ng...> wrote: > > > > > > > > As I'm testing VMS booting, I've run into these SDL input issues: > > 1) A failed MOP boot where it retries forever, unless you type Ctrl/C to > > exit, or > > 2) A BUGCHECK memory dump, where Ctrl/P would normally stop it > > 3) If you're sitting on the SRM command line in the SDL console, and you > > hit UpArrow by mistake, the SDL console hangs forever > > > > Is this easily fixable? > > > > It also still has the problem where hitting the keypad 'enter' key hangs the > > SDL console forever. > > > > All these behavior issues are on Windows XP 32-bit. > > > > Dave > |
From: Camiel V. <iam...@gm...> - 2008-02-08 07:02:35
|
Hello David, This ties in with a discussion I've had with Brian on this mailing list; The scanset 2 scancodes for the left control key is 0x14; this is delivered fine. It appears now, however, that SRM is expecting scanset 3 codes; in this set, 0x14 means Caps Lock. This is an important clue in sorting this mess out. I think I might have it in a few hours... Camiel. On Feb 8, 2008 2:23 AM, Hittner, David T. <dav...@ng...> wrote: > > > > As I'm testing VMS booting, I've run into these SDL input issues: > 1) A failed MOP boot where it retries forever, unless you type Ctrl/C to > exit, or > 2) A BUGCHECK memory dump, where Ctrl/P would normally stop it > 3) If you're sitting on the SRM command line in the SDL console, and you > hit UpArrow by mistake, the SDL console hangs forever > > Is this easily fixable? > > It also still has the problem where hitting the keypad 'enter' key hangs the > SDL console forever. > > All these behavior issues are on Windows XP 32-bit. > > Dave |
From: Camiel V. <iam...@gm...> - 2008-02-07 21:31:19
|
Hi Brian, Forget the change I suggested; it's wrong. The behaviour seems to be correct as it was: For a "b", the untranslated set-2 scancode is 0x32 (make) 0xf0 0x32 (break). The translated set-2 scancode is 0x30 (make) 0xb0 (break). So, I guess the question is why translation is being enabled... Camiel. On Feb 7, 2008 10:03 PM, Brian Wheeler <bdw...@in...> wrote: > Nope, that didn't seem to do it. Here's the debugging output of me > hitting 'b' on the keyboard in SRM (where it works) and netbsd debug > (where it doesn't) > > --- in srm -- > > gen_scancode(): 21 pressed > keyboard: gen_scancode with scancode_translate cleared > gen_scancode(): writing raw 32 > kbd_enQ(0x32)kbd_enQ: putting scancode 0x32 in internal buffer > service_keyboard: key in internal buffer waiting > READ(60) = 32 > service_keyboard(): no keys waiting > gen_scancode(): 21 released > keyboard: gen_scancode with scancode_translate cleared > gen_scancode(): writing raw f0 > kbd_enQ(0xf0)kbd_enQ: putting scancode 0xf0 in internal buffer > gen_scancode(): writing raw 32 > kbd_enQ(0x32)kbd_enQ: putting scancode 0x32 in internal buffer > service_keyboard: key in internal buffer waiting > READ(60) = f0 > service_keyboard: key in internal buffer waiting > READ(60) = 32 > service_keyboard(): no keys waiting > > --- traffic from the netbsd kernel --- > > write command byte > set_aux_clock_enable(1) > allow_irq12 set to 0 > keyboard: scan convert turned off > Scancodes_translate set to 0 > service_keyboard(): no keys waiting > write command byte > set_aux_clock_enable(1) > allow_irq12 set to 0 > Scancodes_translate set to 1 > get keyboard command byte > kbd_controller_enQ(44) source=00 > READ(60) = 44 > controller passed byte f0h to keyboard > Expecting scancode set info... > kbd_enQ(0xfa)kbd_enQ: putting scancode 0xfa in internal buffer > service_keyboard: key in internal buffer waiting > READ(60) = fa > controller passed byte 02h to keyboard > Switched to scancode set 2 > kbd_enQ(0xfa)kbd_enQ: putting scancode 0xfa in internal buffer > service_keyboard: key in internal buffer waiting > READ(60) = fa > controller passed byte f4h to keyboard > kbd_enQ(0xfa)kbd_enQ: putting scancode 0xfa in internal buffer > service_keyboard: key in internal buffer waiting > READ(60) = fa > service_keyboard(): no keys waiting > > --- in debugger --- > > gen_scancode(): 21 pressed > gen_scancode(): writing translated 30 > kbd_enQ(0x30)kbd_enQ: putting scancode 0x30 in internal buffer > service_keyboard: key in internal buffer waiting > READ(60) = 30 > service_keyboard(): no keys waiting > gen_scancode(): 21 released > > > > Brian > > > > On Thu, 2008-02-07 at 21:53 +0100, Camiel Vanderhoeven wrote: > > Hi Brian, > > > > I think disabling the translation altogether isn't the right solution. > > There is indeed a bug in the translation code. Could you try adding > > the following line around line 619? If this solves the problem, I'll > > commit it to CVS, with some comments added about how the different > > scancode sets and translations (should) work. > > > > if (scancode[i] == 0xF0) > > { > > escaped=0x80; > > i++; <==== ADD THIS LINE > > } > > else > > > > On Feb 7, 2008 7:39 PM, Brian Wheeler <bdw...@in...> wrote: > > > Actually, skip the line 1850 stuff, it doesn't seem to work. However, > > > > > > if (state.kbd_controller.scancodes_translate && 0) > > > > > > on line 609 (or thereabouts) does fix the problem. > > > > > > Brian > > > > > > > > > > > > On Thu, 2008-02-07 at 13:17 -0500, Brian Wheeler wrote: > > > > It looks like the 8042 keyboard translation is faulty. SRM turns it off > > > > during the bootup sequence, and netbsd turns it off (again), and then on > > > > right before it goes to the debugger. I've forced it to 0 on > > > > AliM1543C.cpp around line 1850: > > > > > > > > state.kbd_controller.scancodes_translate = 0; > > > > > > > > and the netbsd debugger is working as expected. > > > > > > > > I also commented out the XWarpPointer call in gui/gui_x11.cpp and it > > > > doesn't keep moving the mouse to the center of the window. > > > > > > > > > > > > Brian > > > > > > > > > > > > ------------------------------------------------------------------------- > > > > This SF.net email is sponsored by: Microsoft > > > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > > > _______________________________________________ > > > > Es40-developers mailing list > > > > Es4...@li... > > > > https://lists.sourceforge.net/lists/listinfo/es40-developers > > > > > > > > > ------------------------------------------------------------------------- > > > This SF.net email is sponsored by: Microsoft > > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > > _______________________________________________ > > > Es40-developers mailing list > > > Es4...@li... > > > https://lists.sourceforge.net/lists/listinfo/es40-developers > > > > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by: Microsoft > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > _______________________________________________ > > Es40-developers mailing list > > Es4...@li... > > https://lists.sourceforge.net/lists/listinfo/es40-developers > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Es40-developers mailing list > Es4...@li... > https://lists.sourceforge.net/lists/listinfo/es40-developers > |
From: Brian W. <bdw...@in...> - 2008-02-07 21:03:13
|
Nope, that didn't seem to do it. Here's the debugging output of me hitting 'b' on the keyboard in SRM (where it works) and netbsd debug (where it doesn't) --- in srm -- gen_scancode(): 21 pressed keyboard: gen_scancode with scancode_translate cleared gen_scancode(): writing raw 32 kbd_enQ(0x32)kbd_enQ: putting scancode 0x32 in internal buffer service_keyboard: key in internal buffer waiting READ(60) = 32 service_keyboard(): no keys waiting gen_scancode(): 21 released keyboard: gen_scancode with scancode_translate cleared gen_scancode(): writing raw f0 kbd_enQ(0xf0)kbd_enQ: putting scancode 0xf0 in internal buffer gen_scancode(): writing raw 32 kbd_enQ(0x32)kbd_enQ: putting scancode 0x32 in internal buffer service_keyboard: key in internal buffer waiting READ(60) = f0 service_keyboard: key in internal buffer waiting READ(60) = 32 service_keyboard(): no keys waiting --- traffic from the netbsd kernel --- write command byte set_aux_clock_enable(1) allow_irq12 set to 0 keyboard: scan convert turned off Scancodes_translate set to 0 service_keyboard(): no keys waiting write command byte set_aux_clock_enable(1) allow_irq12 set to 0 Scancodes_translate set to 1 get keyboard command byte kbd_controller_enQ(44) source=00 READ(60) = 44 controller passed byte f0h to keyboard Expecting scancode set info... kbd_enQ(0xfa)kbd_enQ: putting scancode 0xfa in internal buffer service_keyboard: key in internal buffer waiting READ(60) = fa controller passed byte 02h to keyboard Switched to scancode set 2 kbd_enQ(0xfa)kbd_enQ: putting scancode 0xfa in internal buffer service_keyboard: key in internal buffer waiting READ(60) = fa controller passed byte f4h to keyboard kbd_enQ(0xfa)kbd_enQ: putting scancode 0xfa in internal buffer service_keyboard: key in internal buffer waiting READ(60) = fa service_keyboard(): no keys waiting --- in debugger --- gen_scancode(): 21 pressed gen_scancode(): writing translated 30 kbd_enQ(0x30)kbd_enQ: putting scancode 0x30 in internal buffer service_keyboard: key in internal buffer waiting READ(60) = 30 service_keyboard(): no keys waiting gen_scancode(): 21 released Brian On Thu, 2008-02-07 at 21:53 +0100, Camiel Vanderhoeven wrote: > Hi Brian, > > I think disabling the translation altogether isn't the right solution. > There is indeed a bug in the translation code. Could you try adding > the following line around line 619? If this solves the problem, I'll > commit it to CVS, with some comments added about how the different > scancode sets and translations (should) work. > > if (scancode[i] == 0xF0) > { > escaped=0x80; > i++; <==== ADD THIS LINE > } > else > > On Feb 7, 2008 7:39 PM, Brian Wheeler <bdw...@in...> wrote: > > Actually, skip the line 1850 stuff, it doesn't seem to work. However, > > > > if (state.kbd_controller.scancodes_translate && 0) > > > > on line 609 (or thereabouts) does fix the problem. > > > > Brian > > > > > > > > On Thu, 2008-02-07 at 13:17 -0500, Brian Wheeler wrote: > > > It looks like the 8042 keyboard translation is faulty. SRM turns it off > > > during the bootup sequence, and netbsd turns it off (again), and then on > > > right before it goes to the debugger. I've forced it to 0 on > > > AliM1543C.cpp around line 1850: > > > > > > state.kbd_controller.scancodes_translate = 0; > > > > > > and the netbsd debugger is working as expected. > > > > > > I also commented out the XWarpPointer call in gui/gui_x11.cpp and it > > > doesn't keep moving the mouse to the center of the window. > > > > > > > > > Brian > > > > > > > > > ------------------------------------------------------------------------- > > > This SF.net email is sponsored by: Microsoft > > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > > _______________________________________________ > > > Es40-developers mailing list > > > Es4...@li... > > > https://lists.sourceforge.net/lists/listinfo/es40-developers > > > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by: Microsoft > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > _______________________________________________ > > Es40-developers mailing list > > Es4...@li... > > https://lists.sourceforge.net/lists/listinfo/es40-developers > > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Es40-developers mailing list > Es4...@li... > https://lists.sourceforge.net/lists/listinfo/es40-developers |
From: Camiel V. <iam...@gm...> - 2008-02-07 20:53:56
|
Hi Brian, I think disabling the translation altogether isn't the right solution. There is indeed a bug in the translation code. Could you try adding the following line around line 619? If this solves the problem, I'll commit it to CVS, with some comments added about how the different scancode sets and translations (should) work. if (scancode[i] == 0xF0) { escaped=0x80; i++; <==== ADD THIS LINE } else On Feb 7, 2008 7:39 PM, Brian Wheeler <bdw...@in...> wrote: > Actually, skip the line 1850 stuff, it doesn't seem to work. However, > > if (state.kbd_controller.scancodes_translate && 0) > > on line 609 (or thereabouts) does fix the problem. > > Brian > > > > On Thu, 2008-02-07 at 13:17 -0500, Brian Wheeler wrote: > > It looks like the 8042 keyboard translation is faulty. SRM turns it off > > during the bootup sequence, and netbsd turns it off (again), and then on > > right before it goes to the debugger. I've forced it to 0 on > > AliM1543C.cpp around line 1850: > > > > state.kbd_controller.scancodes_translate = 0; > > > > and the netbsd debugger is working as expected. > > > > I also commented out the XWarpPointer call in gui/gui_x11.cpp and it > > doesn't keep moving the mouse to the center of the window. > > > > > > Brian > > > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by: Microsoft > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > _______________________________________________ > > Es40-developers mailing list > > Es4...@li... > > https://lists.sourceforge.net/lists/listinfo/es40-developers > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Es40-developers mailing list > Es4...@li... > https://lists.sourceforge.net/lists/listinfo/es40-developers > |
From: Camiel V. <iam...@gm...> - 2008-02-07 20:34:28
|
This has been committed to the CVS repository. I hope you get a segfault real soon! ;-) Camiel. On Feb 7, 2008 3:48 PM, Brian Wheeler <bdw...@in...> wrote: > Sometimes I get a segfault when I'm running es40. I've added code > (specific to g++) which will dump a backtrace and exit. Of course, > since I've added that code I've not seen a segfault, but I'm hopeful :) > > Brian > > =================================================================== > RCS file: /cvsroot/es40/es40/src/Makefile,v > retrieving revision 1.20 > diff -u -r1.20 Makefile > --- Makefile 2 Feb 2008 16:43:01 -0000 1.20 > +++ Makefile 7 Feb 2008 14:47:48 -0000 > @@ -102,7 +102,7 @@ > # -O3 -- optimize at level 3 > # -mtune=<cpu> -- cpu is one of: generic, core2, athlon64, > pentium4, etc > # > -CTUNINGFLAGS = -O3 -mtune=generic > +CTUNINGFLAGS = -O3 -mtune=generic > > # > # CDEBUGFLAGS - turn on debugging in ES40 > @@ -124,8 +124,9 @@ > # -DDEBUG_KBD Turn on keyboard debugging > # -DDEBUG_PIC Turn on Programmable Interrupt > Controller debugging > # -DDEBUG_LPT Turn on debugging for LPT Port > +# -DDEBUG_BACKTRACE Turn on backtrace dump on SIGSEGV > # > -CDEBUGFLAGS = -g -DHIDE_COUNTER > +CDEBUGFLAGS = -g -DHIDE_COUNTER -DDEBUG_BACKTRACE > > # > # ES40 Options > @@ -247,4 +248,3 @@ > $(DEPEND) -o.do -a -- $(IDB_CFLAGS) -- $(SRCS) > clean: > rm -f es40 es40_idb es40_lss es40_lsm *.o *.do *.mao *.slo *.trc > gui/*.o gui/*.mao gui/*.slo gui/*.do > - > Index: AlphaSim.cpp > =================================================================== > RCS file: /cvsroot/es40/es40/src/AlphaSim.cpp,v > retrieving revision 1.39 > diff -u -r1.39 AlphaSim.cpp > --- AlphaSim.cpp 5 Feb 2008 10:15:57 -0000 1.39 > +++ AlphaSim.cpp 7 Feb 2008 14:47:48 -0000 > @@ -180,6 +180,46 @@ > 0 > }; > > + > +#ifdef DEBUG_BACKTRACE > +#ifdef __GNUG__ > +#include <execinfo.h> > +#include <signal.h> > +#define HAS_BACKTRACE > + > +#define BTCOUNT 100 > +void *btbuffer[BTCOUNT]; > + > +void segv_handler(int signum) { > + int nptrs = backtrace(btbuffer, BTCOUNT); > + char **strings; > + > + printf("%%SYS-F-SEGFAULT: The Alpha Simulator has Segfaulted.\n"); > + printf("-SYS-F-SEGFAULT: Backtrace follows.\n"); > + > + printf("backtrace() returned %d addresses.\n",nptrs); > + strings = backtrace_symbols(btbuffer,nptrs); > + if(strings==NULL) { > + perror("backtrace_symbols"); > + exit(1); > + } > + > + for(int i = 0; i < nptrs; i++) { > + printf("%3d %s\n",nptrs-i, strings[i]); > + } > + free(strings); > + exit(1); > +} > + > +#else > +#warning "Your compiler isn't configured to support backtraces." > +#endif // __GNUG__ > +#endif > + > + > + > + > + > /** > * Entry point for the application. > * > @@ -214,6 +254,12 @@ > char *filename = 0; > FILE *f; > > +#ifdef HAS_BACKTRACE > +#ifdef __GNUG__ > + signal(SIGSEGV, &segv_handler); > +#endif > +#endif > + > try > { > #if defined(IDB) && (defined(LS_MASTER) || defined(LS_SLAVE)) > > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Es40-developers mailing list > Es4...@li... > https://lists.sourceforge.net/lists/listinfo/es40-developers > |
From: Brian W. <bdw...@in...> - 2008-02-07 18:39:38
|
Actually, skip the line 1850 stuff, it doesn't seem to work. However, if (state.kbd_controller.scancodes_translate && 0) on line 609 (or thereabouts) does fix the problem. Brian On Thu, 2008-02-07 at 13:17 -0500, Brian Wheeler wrote: > It looks like the 8042 keyboard translation is faulty. SRM turns it off > during the bootup sequence, and netbsd turns it off (again), and then on > right before it goes to the debugger. I've forced it to 0 on > AliM1543C.cpp around line 1850: > > state.kbd_controller.scancodes_translate = 0; > > and the netbsd debugger is working as expected. > > I also commented out the XWarpPointer call in gui/gui_x11.cpp and it > doesn't keep moving the mouse to the center of the window. > > > Brian > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Es40-developers mailing list > Es4...@li... > https://lists.sourceforge.net/lists/listinfo/es40-developers |
From: Brian W. <bdw...@in...> - 2008-02-07 18:17:17
|
It looks like the 8042 keyboard translation is faulty. SRM turns it off during the bootup sequence, and netbsd turns it off (again), and then on right before it goes to the debugger. I've forced it to 0 on AliM1543C.cpp around line 1850: state.kbd_controller.scancodes_translate = 0; and the netbsd debugger is working as expected. I also commented out the XWarpPointer call in gui/gui_x11.cpp and it doesn't keep moving the mouse to the center of the window. Brian |
From: Brian W. <bdw...@in...> - 2008-02-07 14:48:49
|
Sometimes I get a segfault when I'm running es40. I've added code (specific to g++) which will dump a backtrace and exit. Of course, since I've added that code I've not seen a segfault, but I'm hopeful :) Brian =================================================================== RCS file: /cvsroot/es40/es40/src/Makefile,v retrieving revision 1.20 diff -u -r1.20 Makefile --- Makefile 2 Feb 2008 16:43:01 -0000 1.20 +++ Makefile 7 Feb 2008 14:47:48 -0000 @@ -102,7 +102,7 @@ # -O3 -- optimize at level 3 # -mtune=<cpu> -- cpu is one of: generic, core2, athlon64, pentium4, etc # -CTUNINGFLAGS = -O3 -mtune=generic +CTUNINGFLAGS = -O3 -mtune=generic # # CDEBUGFLAGS - turn on debugging in ES40 @@ -124,8 +124,9 @@ # -DDEBUG_KBD Turn on keyboard debugging # -DDEBUG_PIC Turn on Programmable Interrupt Controller debugging # -DDEBUG_LPT Turn on debugging for LPT Port +# -DDEBUG_BACKTRACE Turn on backtrace dump on SIGSEGV # -CDEBUGFLAGS = -g -DHIDE_COUNTER +CDEBUGFLAGS = -g -DHIDE_COUNTER -DDEBUG_BACKTRACE # # ES40 Options @@ -247,4 +248,3 @@ $(DEPEND) -o.do -a -- $(IDB_CFLAGS) -- $(SRCS) clean: rm -f es40 es40_idb es40_lss es40_lsm *.o *.do *.mao *.slo *.trc gui/*.o gui/*.mao gui/*.slo gui/*.do - Index: AlphaSim.cpp =================================================================== RCS file: /cvsroot/es40/es40/src/AlphaSim.cpp,v retrieving revision 1.39 diff -u -r1.39 AlphaSim.cpp --- AlphaSim.cpp 5 Feb 2008 10:15:57 -0000 1.39 +++ AlphaSim.cpp 7 Feb 2008 14:47:48 -0000 @@ -180,6 +180,46 @@ 0 }; + +#ifdef DEBUG_BACKTRACE +#ifdef __GNUG__ +#include <execinfo.h> +#include <signal.h> +#define HAS_BACKTRACE + +#define BTCOUNT 100 +void *btbuffer[BTCOUNT]; + +void segv_handler(int signum) { + int nptrs = backtrace(btbuffer, BTCOUNT); + char **strings; + + printf("%%SYS-F-SEGFAULT: The Alpha Simulator has Segfaulted.\n"); + printf("-SYS-F-SEGFAULT: Backtrace follows.\n"); + + printf("backtrace() returned %d addresses.\n",nptrs); + strings = backtrace_symbols(btbuffer,nptrs); + if(strings==NULL) { + perror("backtrace_symbols"); + exit(1); + } + + for(int i = 0; i < nptrs; i++) { + printf("%3d %s\n",nptrs-i, strings[i]); + } + free(strings); + exit(1); +} + +#else +#warning "Your compiler isn't configured to support backtraces." +#endif // __GNUG__ +#endif + + + + + /** * Entry point for the application. * @@ -214,6 +254,12 @@ char *filename = 0; FILE *f; +#ifdef HAS_BACKTRACE +#ifdef __GNUG__ + signal(SIGSEGV, &segv_handler); +#endif +#endif + try { #if defined(IDB) && (defined(LS_MASTER) || defined(LS_SLAVE)) |
From: Camiel V. <iam...@gm...> - 2008-02-06 16:41:05
|
Hello everyone, I just made a new CVS snapshot available for download on http://www.sourceforge.net/projects/es40. This fixes a couple of issues with the previous snapshot, and some older bugs. Camiel. Changes from last snapshot build: - Fixed registration of ROM expansion address. (06-feb-2008, Camiel Vanderhoeven) - Check for FPEN in old floating point code. (06-feb-2008, Camiel Vanderhoeven) - Proper interrupt handling in serial port device. Fixes an initialization bug spotted by David Hittner. (06-feb-2008, Camiel Vanderhoeven) - Disable unaligned access check alltogether; it doesn't work properly for some reason. (05-feb-2008, Camiel Vanderhoeven) - The new floating point code (21-jan-2008) has some unidentified problems. The OpenVMS installation routine fails with this new code. For now, the old floating point code has been restored, and the new floating-point code is used only when HAVE_NEW_FP has been defined. The new code should be fixed, so we can take advantage of floating point exceptions. (05-feb-2008, Camiel Vanderhoeven) - Display a message when system initialization has failed. (05-feb-2008, Brian Wheeler) - Put X64 around 64-bit constants in DO_CVTQL. (compilation issue on some Linux'es) (05-feb-2008, Camiel Vanderhoeven) - Corrected a typo in the definition of PCI_PTE_SHIFT (2 should be 12) that caused an OpenVMS procgone bugcheck. (04-feb-2008, Camiel Vanderhoeven) Changes from version 0.17: - Completed LPT support so it works with FreeBSD as a guest OS. (02-feb-2008, Brian Wheeler) - Avoid unnecessary shift-operations to calculate constant values. (01-feb-2008, Camiel Vanderhoeven) - Improved speed by remembering the number of instructions left in current memory page, so that the translation-buffer doens't need to be consulted on every instruction fetch when the Icache is disabled. (30-jan-2008, Camiel Vanderhoeven) - Remember separate last found translation-buffer entries for read and write operations. This should help with memory copy operations. (29-jan-2008, Camiel Vanderhoeven) - Avoid interrupts from the new IDE device that originated while interrupts were disabled. (29-jan-2008, Brian Wheeler) - Improved floating-point exception handling. (28-jan-2008, Camiel Vanderhoeven) - Lifted hardcoded file-size limit of 10,000 bytes for config file. (26-jan-2008, Camiel Vanderhoeven) - Bugfix in the VAX floating point STF and the IEEE floating point STS instructions. (26-jan-2008, Camiel Vanderhoeven) - Don't repeat interrupts from the new IDE controller too soon. (26-jan-2008, Brian Wheeler) - Do unaligned trap only when a page boundary is crossed. Something is causing alignment traps in the SRM console, with the DAT bit set to false, and no OS handler in place. Also, when OpenVMS boots there are alignment traps that shouldn't happen. None of these cross page boundaries, so we're safe for now. (26-jan-2008, Camiel Vanderhoeven) - Trap on unaligned memory access. The previous implementation where unaligned accesses were silently allowed could go wrong when page boundaries are crossed. (25-jan-2008, Camiel Vanderhoeven) - Allow specifying autocreate_size on a disk image to have it created if it doesn't exist. (25-jan-2008, Camiel Vanderhoeven) - Added an option to disable the processor Icache. The emulator runs faster when this is disabled, but that might lead to problems with some OS'es. (25-jan-2008, Camiel Vanderhoeven) - Added do_pci_write and do_pci_read functions to the PCI base device. (24-jan-2008, Camiel Vanderhoeven, David Hittner) - Fixed overflow-detection. (24-jan-2008, Camiel Vanderhoeven) - Added missing integer /V instructions (22-jan-2008, Camiel Vanderhoeven, Bob Supnik) - win32 GUI made compatible with older windows SDK. (22-jan-2008, Camiel Vanderhoeven) - New floating-point code (21-jan-2008, Camiel Vanderhoeven, Bob Supnik) - Fixed misinterpretation of the INT bit in integer overflow traps. (Camiel Vanderhoeven, 21-jan-2008) - Limited the maximum number of sectors, as the OpenVMS IDE driver doesn't like 255 sectors. (Camiel Vanderhoeven, 21-jan-2008) - Added X11 GUI. (20-jan-2008, Camiel Vanderhoeven) - Added win32 GUI. (19-jan-2008, Camiel Vanderhoeven) - Run CPU in a separate thread if CPU_THREADS is defined. NOTA BENE: This is very experimental, and has several problems. (19-jan-2008, Camiel Vanderhoeven) - Replaced sext_64 inlines for performance reasons (18-jan-2008, Camiel Vanderhoeven, David Hittner) - Process device interrupts after a 100-cpu-cycle delay. (18-jan-2008, Camiel Vanderhoeven) - Added ADDL/V instruction (16-jan-2008, David Hittner, Bob Supnik) - Fixed some timeouts on new IDE controller. (16-jan-2008, Brian Wheeler) - When a keyboard self-test command is received, and the queue is not empty, the queue is cleared so the 0x55 that's sent back will be the first thing in line. Makes the keyboard initialize a little better with SRM. (15-jan-2008, Brian Wheeler) - Bugfix regarding double deletion of disk device objects. (13-jan-2008, Brian Wheeler) - New IDE-controller working on big-endian host architectures. (13-jan-2008, Fang Zhe) - Support additional CD-ROM commands. (13-jan-2008, Brian Wheeler) - Smart algorithm for determining optimal cylinder/head/sector disk layout. (13-jan-2008, Camiel Vanderhoeven) - End debugger run on Ctrl-C. (12-jan-2008, Brian Wheeler) - SCSI Engine added to Disk class. SCSIBus class and SCSIDevice base class added. (12-jan-2008, Camiel Vanderhoeven) - bugfix to ATAPI code in new IDE controller. SRM can now boot from IDE CD-ROMs. (09-jan-2008, Brian wheeler) - ATAPI improvements to new IDE controller. (09-jan-2008, Brian wheeler) - Put filename without path in disk model number. (09-jan-2008, Brian Wheeler) - Save disk state to state file. (09-jan-2008, Camiel Vanderhoeven) - Use Brian Wheeler's CNewIde class instead of the CAliM1543C_ide class if HAVE_NEW_IDE is defined. This change will be undone when the new ide controller will replace the old standard one. (08-jan-2008, Camiel Vanderhoeven) - "Old" IDE-controller working on big-endian host architectures. (08-jan-2008, Fang Zhe) - S3 Trio VGA-card working on big-endian host architectures. (08-jan-2008, Fang Zhe) - Removed last references to IDE disk read SRM replacement. (08-jan-2008, Camiel Vanderhoeven) - Added NewIde class. Due to replace the current IDE controller implementation. (08-jan-2008, Brian Wheeler) - PCI scatter/gather DMA memory mapping support added. (07-jan-2008, Camiel Vanderhoeven) - Default blocksize set to 2048 bytes for CD-ROM devices. (06-jan-2008, Camiel Vanderhoeven) - Allow changing block-size on disk devices. (06-jan-2008, Camiel Vanderhoeven) - Fixed typo in network-code (05-jan-2008, Fausto Saporito) - Do 64-bit file I/O properly for FreeBSD and OS X. (05-jan-2008, Fang Zhe) - Added CDiskDevice class to allow using raw devices. (05-jan-2008, Camiel Vanderhoeven) - Made MAC-address of network-card configurable (04-jan-2008, David Hittner) - Make telnet work on Apple OS X. (04-jan-2008, Fang Zhe) - Improved compatibility with SDL on Apple OS X (including keyboard). (04-jan-2008, Fang Zhe) - Added swap_xx macro's for use in places where bytes need to be swapped regardless of endianess. (04-jan-2008, Camiel Vanderhoeven) - Support for larger disk images by using 64-bit file I/O. (04-jan-2008, Camiel Vanderhoeven) - Cirrus VGA-card working on big-endian host architectures. (03-jan-2008, Camiel Vanderhoeven) - PCI base device working on big-endian host architectures. (03-jan-2008, Camiel Vanderhoeven) - Compatibility with SDL on Apple OS X. (03-jan-2008, Fang Zhe) - Compileable on Apple OS X and FreeBSD. (03-jan-2008, Fang Zhe) - CPU working on big-endian host architectures. (02-jan-2008, Camiel Vanderhoeven) - Recognize endianess on more architectures. (02-jan-2008, Fang Zhe) |
From: Camiel V. <iam...@gm...> - 2008-02-06 11:02:43
|
Hello everyone, The serial port emulation had an issue where it could loose interrupts. This has been corrected in CVS, and fixes the following bug that David Hittner reported: "After VMS boots using the VGA console, if you log in to the TTA0 or TTB0 port, and it does a SET TERM /INQ, you get a message about an invalid escape sequence, and then the echo of the character that you are typing is 'delayed' by 4 or 5 characters, so that that you are typing ahead blindly. If you do another SET TERM /INQ manually, the delay increases to even more characters. REALLY odd." Camiel. |
From: Camiel V. <iam...@gm...> - 2008-02-05 10:24:39
|
Hello all, Brian's patch has been applied to the CVS repository. As is mentioned in the comments for the CConfigurator constructor: * \bug This needs to be more robust! As it is now, this code was more or less "hacked together" in a * few minutes. Also, more comments should be provided to make it more readable. The Configurator works fine as long as the config-file is valid; if it isn't, it could probably go wrong in many places. If anyone would like to have a go at building in more checks, please do so. The same goes for all issues listed in the "bugs" and "todo" pages on http://es40.sourceforge.net. Also if you know of any issues that are not on one of these lists, please let me know. Camiel. On Feb 4, 2008 8:52 PM, brian wheeler <bdw...@in...> wrote: > It looks like the configurator doesn't catch missing '}' in the > configuration file. This patch catches when theSystem doesn't get setup > correctly and exits gracefully instead of segfaulting when trying to > load the rom file. > > Brian > > =================================================================== > diff -u -r1.38 AlphaSim.cpp > --- AlphaSim.cpp 26 Jan 2008 12:21:59 -0000 1.38 > +++ AlphaSim.cpp 4 Feb 2008 19:51:47 -0000 > @@ -253,6 +253,11 @@ > fclose(f); > free(ch1); > > + if(!theSystem) { > + printf("%%SYS-F-INIT: Initialization of system has failed. > Syntax error in config?.\n",theSystem); > + exit(1); > + } > + > #if defined(IDB) > trc = new CTraceEngine(theSystem); > #endif > ==================================================================== > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Es40-developers mailing list > Es4...@li... > https://lists.sourceforge.net/lists/listinfo/es40-developers > |
From: brian w. <bdw...@in...> - 2008-02-04 19:52:26
|
It looks like the configurator doesn't catch missing '}' in the configuration file. This patch catches when theSystem doesn't get setup correctly and exits gracefully instead of segfaulting when trying to load the rom file. Brian =================================================================== diff -u -r1.38 AlphaSim.cpp --- AlphaSim.cpp 26 Jan 2008 12:21:59 -0000 1.38 +++ AlphaSim.cpp 4 Feb 2008 19:51:47 -0000 @@ -253,6 +253,11 @@ fclose(f); free(ch1); + if(!theSystem) { + printf("%%SYS-F-INIT: Initialization of system has failed. Syntax error in config?.\n",theSystem); + exit(1); + } + #if defined(IDB) trc = new CTraceEngine(theSystem); #endif ==================================================================== |
From: Camiel V. <iam...@gm...> - 2008-02-04 16:19:49
|
Hello Everyone, I just discovered a bug in a patch I applied on February 1st that causes a PROCGONE bugcheck on OpenVMS bootup. I just fixed this, so if you synchronize with the CVS repository, this bug should be gone. Camiel. |
From: Camiel V. <iam...@gm...> - 2008-02-04 08:35:31
|
Hello everyone, I'd like to call your attention to a new mailing-list, es4...@li.... On this list, all aspects related to the development of the emulator can be discussed. If you're helping to develop ES40, or would simply like to stay up-to-date with the latest patches and code changes, please join this list by sending an e-mail to es4...@li..., with "subscribe" in the body of your e-mail. Here's the first message intended for this new list, to give you a bit of a foretaste: --- A new CVS snapshot is available for download; 20080203_1045, and the documentation at http://es40.sourceforge.net has been updated. Changes from release 0.17 are: - Completed LPT support so it works with FreeBSD as a guest OS. (02-feb-2008, Brian Wheeler) - Avoid unnecessary shift-operations to calculate constant values. (01-feb-2008, Camiel Vanderhoeven) - Improved speed by remembering the number of instructions left in current memory page, so that the translation-buffer doens't need to be consulted on every instruction fetch when the Icache is disabled. (30-jan-2008, Camiel Vanderhoeven) - Remember separate last found translation-buffer entries for read and write operations. This should help with memory copy operations. (29-jan-2008, Camiel Vanderhoeven) - Avoid interrupts from the new IDE device that originated while interrupts were disabled. (29-jan-2008, Brian Wheeler) - Improved floating-point exception handling. (28-jan-2008, Camiel Vanderhoeven) - Lifted hardcoded file-size limit of 10,000 bytes for config file. (26-jan-2008, Camiel Vanderhoeven) - Bugfix in the VAX floating point STF and the IEEE floating point STS instructions. (26-jan-2008, Camiel Vanderhoeven) - Don't repeat interrupts from the new IDE controller too soon. (26-jan-2008, Brian Wheeler) - Do unaligned trap only when a page boundary is crossed. Something is causing alignment traps in the SRM console, with the DAT bit set to false, and no OS handler in place. Also, when OpenVMS boots there are alignment traps that shouldn't happen. None of these cross page boundaries, so we're safe for now. (26-jan-2008, Camiel Vanderhoeven) - Trap on unaligned memory access. The previous implementation where unaligned accesses were silently allowed could go wrong when page boundaries are crossed. (25-jan-2008, Camiel Vanderhoeven) - Allow specifying autocreate_size on a disk image to have it created if it doesn't exist. (25-jan-2008, Camiel Vanderhoeven) - Added an option to disable the processor Icache. The emulator runs faster when this is disabled, but that might lead to problems with some OS'es. (25-jan-2008, Camiel Vanderhoeven) - Added do_pci_write and do_pci_read functions to the PCI base device. (24-jan-2008, Camiel Vanderhoeven, David Hittner) - Fixed overflow-detection. (24-jan-2008, Camiel Vanderhoeven) - Added missing integer /V instructions (22-jan-2008, Camiel Vanderhoeven, Bob Supnik) - win32 GUI made compatible with older windows SDK. (22-jan-2008, Camiel Vanderhoeven) - New floating-point code (21-jan-2008, Camiel Vanderhoeven, Bob Supnik) - Fixed misinterpretation of the INT bit in integer overflow traps. (Camiel Vanderhoeven, 21-jan-2008) - Limited the maximum number of sectors, as the OpenVMS IDE driver doesn't like 255 sectors. (Camiel Vanderhoeven, 21-jan-2008) - Added X11 GUI. (20-jan-2008, Camiel Vanderhoeven) - Added win32 GUI. (19-jan-2008, Camiel Vanderhoeven) - Run CPU in a separate thread if CPU_THREADS is defined. NOTA BENE: This is very experimental, and has several problems. (19-jan-2008, Camiel Vanderhoeven) - Replaced sext_64 inlines for performance reasons (18-jan-2008, Camiel Vanderhoeven, David Hittner) - Process device interrupts after a 100-cpu-cycle delay. (18-jan-2008, Camiel Vanderhoeven) - Added ADDL/V instruction (16-jan-2008, David Hittner, Bob Supnik) - Fixed some timeouts on new IDE controller. (16-jan-2008, Brian Wheeler) - When a keyboard self-test command is received, and the queue is not empty, the queue is cleared so the 0x55 that's sent back will be the first thing in line. Makes the keyboard initialize a little better with SRM. (15-jan-2008, Brian Wheeler) - Bugfix regarding double deletion of disk device objects. (13-jan-2008, Brian Wheeler) - New IDE-controller working on big-endian host architectures. (13-jan-2008, Fang Zhe) - Support additional CD-ROM commands. (13-jan-2008, Brian Wheeler) - Smart algorithm for determining optimal cylinder/head/sector disk layout. (13-jan-2008, Camiel Vanderhoeven) - End debugger run on Ctrl-C. (12-jan-2008, Brian Wheeler) - SCSI Engine added to Disk class. SCSIBus class and SCSIDevice base class added. (12-jan-2008, Camiel Vanderhoeven) - bugfix to ATAPI code in new IDE controller. SRM can now boot from IDE CD-ROMs. (09-jan-2008, Brian wheeler) - ATAPI improvements to new IDE controller. (09-jan-2008, Brian wheeler) - Put filename without path in disk model number. (09-jan-2008, Brian Wheeler) - Save disk state to state file. (09-jan-2008, Camiel Vanderhoeven) - Use Brian Wheeler's CNewIde class instead of the CAliM1543C_ide class if HAVE_NEW_IDE is defined. This change will be undone when the new ide controller will replace the old standard one. (08-jan-2008, Camiel Vanderhoeven) - "Old" IDE-controller working on big-endian host architectures. (08-jan-2008, Fang Zhe) - S3 Trio VGA-card working on big-endian host architectures. (08-jan-2008, Fang Zhe) - Removed last references to IDE disk read SRM replacement. (08-jan-2008, Camiel Vanderhoeven) - Added NewIde class. Due to replace the current IDE controller implementation. (08-jan-2008, Brian Wheeler) - PCI scatter/gather DMA memory mapping support added. (07-jan-2008, Camiel Vanderhoeven) - Default blocksize set to 2048 bytes for CD-ROM devices. (06-jan-2008, Camiel Vanderhoeven) - Allow changing block-size on disk devices. (06-jan-2008, Camiel Vanderhoeven) - Fixed typo in network-code (05-jan-2008, Fausto Saporito) - Do 64-bit file I/O properly for FreeBSD and OS X. (05-jan-2008, Fang Zhe) - Added CDiskDevice class to allow using raw devices. (05-jan-2008, Camiel Vanderhoeven) - Made MAC-address of network-card configurable (04-jan-2008, David Hittner) - Make telnet work on Apple OS X. (04-jan-2008, Fang Zhe) - Improved compatibility with SDL on Apple OS X (including keyboard). (04-jan-2008, Fang Zhe) - Added swap_xx macro's for use in places where bytes need to be swapped regardless of endianess. (04-jan-2008, Camiel Vanderhoeven) - Support for larger disk images by using 64-bit file I/O. (04-jan-2008, Camiel Vanderhoeven) - Cirrus VGA-card working on big-endian host architectures. (03-jan-2008, Camiel Vanderhoeven) - PCI base device working on big-endian host architectures. (03-jan-2008, Camiel Vanderhoeven) - Compatibility with SDL on Apple OS X. (03-jan-2008, Fang Zhe) - Compileable on Apple OS X and FreeBSD. (03-jan-2008, Fang Zhe) - CPU working on big-endian host architectures. (02-jan-2008, Camiel Vanderhoeven) - Recognize endianess on more architectures. (02-jan-2008, Fang Zhe) Camiel. |