This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/34841] 'make check' of libsndfile-1.0.17 fails with gcc-4.2.2 -O2 optimization, OK with -O1 one
- From: "ismail at pardus dot org dot tr" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 18 Jan 2008 02:45:51 -0000
- Subject: [Bug c/34841] 'make check' of libsndfile-1.0.17 fails with gcc-4.2.2 -O2 optimization, OK with -O1 one
- References: <bug-34841-13529@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #9 from ismail at pardus dot org dot tr 2008-01-18 02:45 -------
File lossy_comp_test.c starting line 761 :
sum_abs = abs (sum_abs + abs (abs (data [k]) - 256)) ;
if (sum_abs < 1.0)
{
printf ("\n\nLine %d: Signal is all zeros (%d, 0x%X).\n", __LINE__, sum_abs,
sum_abs) ;
exit (1) ;
} ;
sum_abs gets a value of -27260928 . Making sum_abs unsigned fixes the problem.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34841