From: pokornp AT math DOT vscht DOT cz () Newsgroups: comp.os.msdos.djgpp Subject: Re: gcc-dos 2.8.1 and Exiting due to signal SIGFPE ? Date: 9 Apr 1998 22:42:37 GMT Organization: Prague Institute of Chemical Technology Lines: 54 Message-ID: <6gjist$9qf$1@news.vscht.cz> References: <6gj5vc$6oe$1 AT news DOT vscht DOT cz> NNTP-Posting-Host: math.vscht.cz To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk pokornp AT math DOT vscht DOT cz wrote: : When I use a cross-compiler gcc-dos 2.8.1 from HP-UX 10.20 to MS-DOS 6.22 : the exe file runs O.K. sometimes but sometimes stops with : "Exiting due to signal SIGFPE : Floating point exception at eip=0000176e" : Compiling the C-program with gcc 2.8.1 : gcc -o prog -Wall -O2 prog.c -lm : gcc-dos -o prog.exe -Wall -O2 prog.c -lm : produces *no* warnings : and prog runs always O.K. in HP-UX : so I hoped it is well written and portable. : Have you come across this error ? : Thank you This error is really strange. The piece of code looks like this: -------------------------------------------------------- aaa () { (void) printf ("aaa has been called\n"); some more stuff } main () { another more stuff (void) printf ("aaa will be called\n"); <------this works aaa(); <------and this no more yet more stuff } -------------------------------------------------------- And the result: aaa will be called Exiting due to signal SIGFPE Floating point exception at eip=0000176e STRANGE !!! And it happens on both 486 and on Pentium, so PC hardware mulfunction is not probable. Oh oh oh :-( Have you any idea what to do ? Pavel Pokorny Math Dept, Prague Institute of Chemical Technology e-mail: Pavel DOT Pokorny AT vscht DOT cz http://staff.vscht.cz/mat/Pavel.Pokorny