Matt Stupple wrote: > Solaris 10, x86 > > I'm getting an intermittent crash in ld when our nightly build runs (which > does a scratch build of our system with 'full' optimisation). Basically ld > core dumps whilst attempting to link of one of our binaries - here's the > stack from ld: > > # pstack core > core 'core' of 17339: /usr/ccs/bin/ld > -zld32=-S/tmp/lib_base_link.17025/libldstab_ws.so -zld > fee789e7 comp (e04b8ce8, e04b8ef0) + 57 > feef3bfa qsort (e04b8ce8, 412, 4, fee78990) + 106 > fee78ab3 ld32_sort_ordered (fedb7018) + 9b > fee79172 ld32_create_outfile (fedb7018) + 7a > fee702a6 ld32_main (66, 8046e18) + 46e > 0805130f main (66, 8046e18, 8046fb4) + 133 > 08050cb6 ???????? (66, 8047028, 8047038, 804706a, 80470a2, 80470d5) > > The compiler options look something like this: > > CC -o XXXX -mt -i -O -g0 -xO5 -xarch=sse3 -xcache=64/64/2:1024/64/16 > -xchip=k8f -xdepend=yes -fsimple=2 -fns=yes -ftrap=%none -xlibmil -xlibmopt > -xbuiltin=%all -nofstore -xregs=no%frameptr -Qoption CC -iropt -Qoption CC > -xcallee64 -sync_stdio=no -xipo=2 > > ... with a long list of objects, search dirs and libraries to link. > > Is this a know problem? It usually goes away if I rebuild... > > Thanks, > > Matt. > > > This message posted from opensolaris.org > _______________________________________________ > tools-linking mailing list > tools-linking at opensolaris.org
Is this a parallel make, where there are multiple compilations going on at the same time? dmake, or GNU make with the -j option, or something like that? Very often when we see ld cores that look like this, the cause is a sharable object that is simultaneously being linked itself, while being linked to by another process. The under-construction library gives the process linking against it inconsistent data, leading to a linker crash. If this is the case, the cure is to add the necessary dependencies to the makefile. - Ali