Article View: gnu.gcc.bug
Article #2641GCC 1.35 bug on Sun 3 (68020), Sun Unix 3.5
From: Roland McGrath
Date: Sun, 14 May 1989 07:38
Date: Sun, 14 May 1989 07:38
20 lines
1008 bytes
1008 bytes
The following input produces bad code; the `fintrz' insn is not emitted at
all. It produces different, but equally bad, code with -O and without.
If the sequence `"f" "intrz" "%.x %1, %0"' is amalgomated into one string
`"fintrz%.x %1, %0"', or if `foo' is made non-`static', the problem goes away.
static inline double
foo(double value, double *iptr)
{
double ipart;
asm("f" "intrz" "%.x %1, %0" : "=f" (ipart) : "f" (value));
*iptr = ipart;
return(value - ipart);
}
double
bar(double value, double *iptr)
{
return foo(value, iptr);
}
Technical Details
Message-ID:
<8905140739.AA04972@tully.Berkeley.EDU>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!watmath!uunet!tut.cis.ohio-state.edu!GINGER.BERKELEY.EDU!mcgrath%tully.Berkeley.EDUShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watmath!uunet!tut.cis.ohio-state.edu!GINGER.BERKELEY.EDU!mcgrath%tully.Berkeley.EDU From: mcgrath%tully.Berkeley.EDU@GINGER.BERKELEY.EDU (Roland McGrath) Newsgroups: gnu.gcc.bug Subject: GCC 1.35 bug on Sun 3 (68020), Sun Unix 3.5 Message-ID: <8905140739.AA04972@tully.Berkeley.EDU> Date: 14 May 89 07:38:58 GMT Sender: daemon@tut.cis.ohio-state.edu Distribution: gnu Organization: GNUs Not Usenet Lines: 20