The attached program fails when compiled with -fprofile-arcs -O2. This is a unit test of a matrix library, and by failing I mean that it detects a wrong behavior.
Valgrind reports an "Conditional jump or move depends on uninitialised value(s)". It works fine with gcc 4.2.4 and 4.4.1 regardless of the compilation options. It also works also fine with 4.3.3 if we remove the -fprofile-arcs flag. By "fine", I also mean valgrind does not report any error. -- Summary: Regression: broken generated code when using -fprofile- arcs and -O2 Product: gcc Version: 4.3.3 Status: UNCONFIRMED Severity: normal Priority: P3 Component: debug AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: gael dot guennebaud at gmail dot com GCC build triplet: 4.3.3 GCC host triplet: x86_64-suse-linux GCC target triplet: x86_64-suse-linux http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42255