X-Authentication-Warning: delorie.com: mail set sender to djgpp-workers-bounces using -f Date: Sat, 13 Nov 2004 23:52:05 +0200 From: "Eli Zaretskii" Sender: halo1 AT zahav DOT net DOT il To: djgpp-workers AT delorie DOT com Message-ID: <01c4c9cb$Blat.v2.2.2$29550bc0@zahav.net.il> Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=ISO-8859-1 X-Mailer: emacs 21.3.50 (via feedmail 8 I) and Blat ver 2.2.2 In-reply-to: <10411131756.AA83688@clio.rice.edu> (sandmann@clio.rice.edu) Subject: Re: Alignment problem on Windows XP References: <10411131756 DOT AA83688 AT clio DOT rice DOT edu> 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: sandmann AT clio DOT rice DOT edu (Charles Sandmann) > Date: Sat, 13 Nov 2004 11:56:17 -0600 (CST) > > I would first want to check the binary image used by the user with the > problem - it could be some installation problem that generates bad > executables? I asked the user for the binary, being unable to reproduce the problem on 2 XP boxes I have access to. > The example problem has the data in BSS, so I don't see how it could > have any address offsets. Sorry, I don't follow: what address offsets, and why BSS data cannot have them? Could you please elaborate? > If the XP DPMI provider sometimes returns blocks with alignment less than > we assume, I think the selector base would fix this (it would run slowly, > but the offsets would all be correct). I'm not sure I follow this, either, but FWIW, the temacs crash (on that user's machine; it works okay for me) during GC, which brought the problem to our attention in the first place, clearly shows that the selector base is aligned: Exiting due to signal SIGABRT Raised at eip=00168e5e eax=002f7e5c ebx=00000120 ecx=00000000 edx=00000000 esi=00000054 edi=002dfa78 ebp=002f7f08 esp=002f7e58 program=D:\src\emacsCVS\src\temacs.exe cs: sel=024f base=02f30000 limit=003affff ds: sel=0257 base=02f30000 limit=003affff es: sel=0257 base=02f30000 limit=003affff fs: sel=0227 base=00018030 limit=0000ffff gs: sel=0277 base=00000000 limit=0010ffff ss: sel=0257 base=02f30000 limit=003affff App stack: [002f8a78..002dfa78] Exceptn stack: [002df94c..002dda0c] Call frame traceback EIPs: 0x00168d84 ___djgpp_traceback_exit+48 0x00168e5e _raise+90 0x00152f3c _abort+55, line 5269 of msdos.c 0x000de42c _mark_object+2599, line 5122 of alloc.c > Since we allocate multiple memory blocks unless unixy sbrk is set, if > XP chose to return a block with an offset of modulo 4 bytes alignment > to the first block, all of the stuff in stack and/or sbrk() calls would > be at danger - we have code that tries to do alignment but I don't know > if it always works (probably not tested much). The test program is a tiny one--would it at all be at danger of hitting the multiple-block issue? In any case, thanks for the feedback.