From: Alan Modra Date: Wed, 9 Oct 2002 00:33:12 +0000 (+0000) Subject: * libgcc2.c (__floatdisf): Properly cure double rounding. X-Git-Tag: releases/gcc-3.2.1~188 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=926e8f0ff187cc771c25ed1fbca3661af934ff57;p=thirdparty%2Fgcc.git * libgcc2.c (__floatdisf): Properly cure double rounding. From-SVN: r57967 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 7508be747dad..e0331a12456e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,7 @@ +2002-10-09 Alan Modra + + * libgcc2.c (__floatdisf): Properly cure double rounding. + 2002-10-09 Gabriel Dos Reis PR doc/7484 diff --git a/gcc/libgcc2.c b/gcc/libgcc2.c index 4effc46e56e0..dd5eee7dbb52 100644 --- a/gcc/libgcc2.c +++ b/gcc/libgcc2.c @@ -1,7 +1,7 @@ /* More subroutines needed by GCC output code on some machines. */ /* Compile this one with gcc. */ /* Copyright (C) 1989, 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, - 2000, 2001 Free Software Foundation, Inc. + 2000, 2001, 2002 Free Software Foundation, Inc. This file is part of GCC. @@ -1115,7 +1115,10 @@ __floatdisf (DWtype u) && u < ((DWtype) 1 << DF_SIZE))) { if ((UDWtype) u & (REP_BIT - 1)) - u |= REP_BIT; + { + u &= ~ (REP_BIT - 1); + u |= REP_BIT; + } } } f = (Wtype) (u >> WORD_SIZE);