From mboxrd@z Thu Jan 1 00:00:00 1970 From: scott snyder To: law@cygnus.COM Cc: egcs@cygnus.COM Subject: Re: regression test results for 970904 on alpha-dec-osf4.0 Date: Thu, 04 Sep 1997 22:46:00 -0000 Message-id: <199709050546.FAA15859@d0sgif.fnal.gov> References: <4795.873435911@hurl.cygnus.com> X-SW-Source: 1997-09/msg00186.html > In message < 199709050447.EAA14961@d0sgif.fnal.gov >you write: > > As reported earlier, this is due to assumption in this test case > > that 2*sizeof(long) == sizeof(double), which is false for the alpha. > > If this is fixed, this test passes. >A patch would be welcome. hi - I included a little patch with the previous regression report i sent; however, that was a little cheesy in that it tested for just __alpha. Here's one which might be a little more generally applicable. This still assumes that a double is 64 bits, but i'm not sure how to reliably test for that using the preprocessor. sss *** /d0sgif/data1/snyder/egcs/gcc/testsuite/gcc.c-torture/execute/cbrt.c Mon Aug 25 11:37:23 1997 --- cbrt.c Fri Sep 5 01:37:58 1997 *************** *** 9,14 **** --- 9,16 ---- * ==================================================== */ + #include + #ifndef __vax__ static const unsigned long B1 = 715094163, /* B1 = (682-0.03306235651)*2**20 */ *************** *** 30,36 **** --- 32,46 ---- unsigned sign; union { double t; + #ifndef WORD_BIT + unsigned long pt[2]; + #elif (WORD_BIT == 32) + unsigned int pt[2]; + #elif (LONG_BIT == 32) unsigned long pt[2]; + #else + #error No suitable integer type found. + #endif } ut, ux; int n0;