------- Comment #14 from kargl at gcc dot gnu dot org 2009-07-08 16:56 ------- (In reply to comment #11) > Created an attachment (id=18158) --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=18158&action=view) [edit] > Patch - lightly tested > > Attached patch fixes the problem [independent of > "-f(no-)signed-zeros"/-ffast-math]. > > The crucial option is "-fno-sign-zero" (which shall not be confused with > -f(no-)signed-zeros): > > $ gfortran -O3 -fno-sign-zero ahfj.f90 && ./a.out > With val = 0.0000000 test = 0.0000000 > pass >
I've tested the patch and the -ftree-dump-original output looks correct. I've also attached two testcase for the testsuite. I do note that this option is activated by -std=legacy. Perhaps, it should be. Patch is okay. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=40675