From: Ben Decker To: djgpp-workers AT delorie DOT com Message-ID: <1042666298005458@lycos-europe.com> X-Mailer: LycosMail X-Originating-IP: [62.104.218.81] Mime-Version: 1.0 Subject: RE: Re: your mail Date: Wed, 15 Jan 2003 22:31:38 +0100 Content-Type: multipart/mixed; boundary="=_NextPart_Lycos_0054581042666298_ID" Reply-To: djgpp-workers AT delorie DOT com This message is in MIME format. Since your mail reader does not understand this format, some or all of this message may not be legible. --=_NextPart_Lycos_0054581042666298_ID Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Hello. > ------- Original Message ------- > From : sandmann AT clio DOT rice DOT edu (Charles Sandmann) > Date : Sun, 5 Jan 2003 21:15:08 -0600 (CST) >> > > But (at least this version) needs a second stack (probably for keeping track >> > > of mutex, i don't know...). DJGPP has no sigstack or sigaltstack. >Take a look at go32/dpmiexcp.c and go32/exceptn.S > >The documentation I have for sigstack looks like it would be fairly >straightforward to implement - the current exception stack is declared >in exceptn.S According to the man pages: "sigstack() is to be obsoleted at a future date. "A portable application, when being written or rewritten, should use sigaltstack() instead of sigstack()." The sigaltstack structure is defined as: struct sigaltstack { char *ss_sp; int ss_size; int ss_flags; }; (would this go in signal.h? ss_size may better be difined as size_t?) It is a bit confusing, because the structure is similar to stack_t (I notice DJGPP doesn't have that either). The values seem normally defined as follows: ss_sp = malloc(SIGSTKSZ) ss_size = SIGSTKSZ; ss_flags = 0; SIGSTKSZ is "the number of bytes/chars that would be used to cover the usual case when allocating an alternate stack area." For Linux it was defined as: #define MINSIGSTKSZ 131027 /* min. stack size for sigaltstack() */ #define SIGSTKSZ 262144 /* default stack size for sigaltstack() */ GNU platforms seem to store the sigaltstack() routine itself in a separate 'sigaltstack.c'. Would this also be suitable for DJGPP? Ben This is your brain: bash-2.05$ This is your brain on drugs: Starting Windows XP... Any questions? When words aren't enough - Vodafone live! A new world of colour, sounds, picture messages and information on your mobile. Click here to find out more. --=_NextPart_Lycos_0054581042666298_ID--