2007-03-26 Steven Munroe * sysdeps/powerpc/fpu/feupdateenv.c: Change mask to merge exceptions from env. diff -urN libc25-cvstip-20070320/sysdeps/powerpc/fpu/feupdateenv.c libc25/sysdeps/powerpc/fpu/feupdateenv.c --- libc25-cvstip-20070320/sysdeps/powerpc/fpu/feupdateenv.c 2001-07-05 23:56:02.000000000 -0500 +++ libc25/sysdeps/powerpc/fpu/feupdateenv.c 2007-03-27 09:13:54.875363776 -0500 @@ -1,5 +1,5 @@ /* Install given floating-point environment and raise exceptions. - Copyright (C) 1997,99,2000,01 Free Software Foundation, Inc. + Copyright (C) 1997,99,2000,01,07 Free Software Foundation, Inc. This file is part of the GNU C Library. Contributed by Ulrich Drepper , 1997. @@ -30,8 +30,10 @@ new.fenv = *envp; old.fenv = fegetenv_register (); - /* Copy the set exceptions from `old' to `new'. */ - new.l[1] = (new.l[1] & 0xE00000FF) | (old.l[1] & 0x1FFFFF00); + /* Restore rounding mode and exception enable from *envp and merge + exceptions. Leave fraction rounded/inexact and FP result/CC bits + unchanged. */ + new.l[1] = (old.l[1] & 0x1FFFFF00) | (new.l[1] & 0x1FF80FFF); /* Atomically enable and raise (if appropriate) exceptions set in `new'. */ fesetenv_register (new.fenv);