Date: Sun, 21 Jan 2001 21:22:35 +0200 From: "Eli Zaretskii" Sender: halo1 AT zahav DOT net DOT il To: "Tim Van Holder" Message-Id: <4634-Sun21Jan2001212234+0200-eliz@is.elta.co.il> X-Mailer: Emacs 20.6 (via feedmail 8.3.emacs20_6 I) and Blat ver 1.8.6 CC: djgpp-workers AT delorie DOT com In-reply-to: Subject: Re: Interaction between __dpmi_yield and signals? References: Reply-To: djgpp-workers AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp-workers AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk > From: "Tim Van Holder" > Date: Sun, 21 Jan 2001 19:09:07 +0100 > > > Please show the code which sets up the timer and the signal handler. > Seems to be this: > > void > signalAfter(deltaMilli, func) > int deltaMilli; > RETSIGTYPE (*func)(); This looks okay, but where is the signal handler, the one whose name is passed to signalAfter in the func argument? > No, was foreground all the time. > I did check the libc manual, Eli ;-P I didn't even remember I wrote this in libc.info ;-) > > OK. But since we're dealing with an interpreted language, I figured trying > > to debug something would prove difficult even without the timer stuff. > > Why? I routinely run Emacs (another interpreter) under GDB with no > > visible problems. I even debug GDB itself with GDB, although it has a > > command-line interpreter built into it. > My bad - since it's byte-compiled, there's no problem stepping through the > routines that ibnterpret those bytecodes; somehow I thought I'd be stepping > through machine code that had been generated at run-time (which wouldn't > have debug info). > I'll build a stabbed version later and see what the debugger says. I actually think that running the SIGALRM code under a debugger is not a good idea, as I wrote earlier, because it causes some strange interference with the debugger. But if the main Smalltalk program rarely or never uses timers, you can run it inside GDB. In any case, if you do run the timer code under GDB, don't forget to say "handle SIGALRM noprint nostop".