This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c/52794] gcc.dg/tree-prof/pr52027.c fails on x86_64/i386-apple-darwin*
- From: "howarth at nitro dot med.uc.edu" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Fri, 30 Mar 2012 19:22:23 +0000
- Subject: [Bug c/52794] gcc.dg/tree-prof/pr52027.c fails on x86_64/i386-apple-darwin*
- Auto-submitted: auto-generated
- References: <bug-52794-4@http.gcc.gnu.org/bugzilla/>
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52794
--- Comment #1 from Jack Howarth <howarth at nitro dot med.uc.edu> 2012-03-30 19:22:23 UTC ---
Created attachment 27046
--> http://gcc.gnu.org/bugzilla/attachment.cgi?id=27046
testcase from radar://10960042 generated on x86_64-apple-darwin11
The FSF gcc testsuite failure...
FAIL: gcc.dg/tree-prof/pr52027.c compilation, -fprofile-use -D_PROFILE_USE
UNRESOLVED: gcc.dg/tree-prof/pr52027.c execution, -fprofile-use
-D_PROFILE_USE
seen at -m32/-m64 with Xcode 4.3's linker may be showing a linker bug. The
attached
testcase contains the files obtained with...
/sw/src/fink.build/gcc47-4.7.0-1/darwin_objdir/gcc/xgcc
-B/sw/src/fink.build/gcc47-4.7.0-1/darwin_objdir/gcc/
/sw/src/fink.build/gcc47-4.7.0-1/gcc-4.7-20120228/gcc/testsuite/gcc.dg/tree-prof/pr52027.c
-O -freorder-blocks-and-partition -fno-reorder-functions -fprofile-generate
-D_PROFILE_GENERATE -lm -m64 -o pr52027.x01
Executing the resulting pr52027.x01 to produce the profiling code in
pr52027.gcda (provided) and...
/sw/src/fink.build/gcc47-4.7.0-1/darwin_objdir/gcc/xgcc
-B/sw/src/fink.build/gcc47-4.7.0-1/darwin_objdir/gcc/
/sw/src/fink.build/gcc47-4.7.0-1/gcc-4.7-20120228/gcc/testsuite/gcc.dg/tree-prof/pr52027.c
-O -freorder-blocks-and-partition -fno-reorder-functions -fprofile-use
-D_PROFILE_USE -lm -m64 -v --save-temps -o pr52027.x02
which produces the linker error...
Assertion failed: (cfiStartsArray[i] != cfiStartsArray[i-1]), function parse,
file /SourceCache/ld64/ld64-128.2/src/ld/parsers/macho_relocatable_file.cpp,
line 1519.
0 0x1010331df __assert_rtn + 79
1 0x10104eae5
mach_o::relocatable::Parser<x86_64>::parse(mach_o::relocatable::ParserOptions
const&) + 917
2 0x10103c32e mach_o::relocatable::Parser<x86_64>::parse(unsigned char
const*, unsigned long long, char const*, long, unsigned int,
mach_o::relocatable::ParserOptions const&) + 286
3 0x101038b2b mach_o::relocatable::parse(unsigned char const*, unsigned long
long, char const*, long, unsigned int, mach_o::relocatable::ParserOptions
const&) + 91
4 0x1010716fd ld::tool::InputFiles::makeFile(Options::FileInfo const&, bool)
+ 653
5 0x101072cfb ld::tool::InputFiles::InputFiles(Options&, char const**) + 651
6 0x101033426 main + 358
7 0x1010236a4 start + 52
which can be reproduced with the provided bad_link shell script which
executes...
ld -dynamic -arch x86_64 -macosx_version_min 10.7.3 -weak_reference_mismatches
non-weak -o pr52027.x02 -lcrt1.10.6.o -L. pr52027.o -no_compact_unwind -lSystem
-lgcc_ext.10.5 -lgcc -lSystem -v