www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1995/10/05/18:06:35

Date: Thu, 05 Oct 1995 16:12:03 -0500 (CDT)
From: Aaron Ucko <UCKO AT VAX1 DOT ROCKHURST DOT EDU>
Subject: Re: Stupped : V2.0 bug?
To: sandmann AT clio DOT rice DOT edu
Cc: djgpp AT sun DOT soe DOT clarkson DOT edu
Organization: Rockhurst College; Kansas City, MO

>> under 1.12.4 run's w/o error
>> under 2.0 gets a nasty SEGFAULT while accessing a 2d array of floats. 
>
>It's difficult to say what the problem is without a complete listing
>of the source assembly line causing the fault and the contents of all
>the registers.
>
>But in almost all cases I have seen so far, V2 execution failures have
>been related to programs expecting uninitialized memory (stack/malloc)
>values to be set to zero when first accessed, which V2 no longer does
>(unless you include crt0.h and set a special flag to zero the memory).

Isn't calloc() the function you're supposed to use if you want
zeroed memory anyway?

-- Aaron Ucko (ucko AT vax1 DOT rockhurst DOT edu; finger for PGP public key) | httyp!
"That's right," he said. "We're philosophers. We think, therefore we am."
-- Terry Pratchett, _Small Gods_ | Geek Code 3.1 [for explanation, finger 
 hayden AT mankato DOT msus DOT edu]: GCS/M/S/C d- s: g+ a17 C++(+++)>++++ UL++>++++ P++ 
 L++>+++++ E- W(-) N++(+) o+ K- w--- O M@ V-(--) PS++(+++) PE- Y(+) PGP(+) t(+)
 !5 X-- R(-) tv-@ b++(+++) DI+ !D(--) G++(+++) e->+++++(*) h!>+ r-(--)>+++ y?

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019