[Llvm-bgq-discuss] c++ linkage

Jeff Hammond jhammond at alcf.anl.gov
Fri Dec 21 15:10:35 CST 2012


You could work on Vesta at ALCF instead because I know that the version
Hal installed there works >99% of the time.

Jeff

On Fri, Dec 21, 2012 at 2:15 PM, Michael Blocksome <blocksom at us.ibm.com> wrote:
> I seem to have a more fundamental problem as well.  I can't figure out how
> to link the appropriate libstdc++ .. any ideas?
>
> ====
>
> .../test> cat vector_test.cc
>
> #include <vector>
>
> int main ()
> {
>   std::vector<unsigned> foo;
>
>   return 0;
> };
>
> .../test> /bghome/blocksom/development/llvm/bgclang -v vector_test.cc -o
> vector_test.cnk
> clang version 3.3 (trunk 170436)
> Target: powerpc64-bgq-linux
> Thread model: posix
>  "/bghome/blocksom/development/llvm/install/bin/clang" -cc1 -triple
> powerpc64-bgq-linux -S -disable-free -main-file-name vector_test.cc
> -static-define -mrelocation-model static -mdisable-fp-elim -fmath-errno
> -ffp-contract=fast -mconstructor-aliases -target-cpu a2q
> -target-linker-version 2.20.51.0.2 -momit-leaf-frame-pointer -v
> -resource-dir /bghome/blocksom/development/llvm/install/bin/../lib/clang/3.3
> -fmodule-cache-path /var/tmp/clang-module-cache -internal-isystem
> /bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../../../powerpc64-bgq-linux/include/c++/4.4.6
> -internal-isystem
> /bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../../../powerpc64-bgq-linux/include/c++/4.4.6/powerpc64-bgq-linux
> -internal-isystem
> /bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../../../powerpc64-bgq-linux/include/c++/4.4.6/backward
> -internal-isystem /usr/local/include -internal-isystem
> /bghome/blocksom/development/llvm/install/bin/../lib/clang/3.3/include
> -internal-externc-isystem /include -internal-externc-isystem /usr/include
> -fdeprecated-macro -fno-dwarf-directory-asm -fdebug-compilation-dir
> /bghome/blocksom/development/boost-pami/next/test -ferror-limit 19
> -fmessage-length 231 -mstackrealign -fno-signed-char -fobjc-runtime=gcc
> -fcxx-exceptions -fexceptions -fdiagnostics-show-option -fcolor-diagnostics
> -isystem /bgsys/drivers/ppcfloor/gnu-linux/powerpc64-bgq-linux/sys-include
> -mllvm -enable-misched -mllvm -enable-aa-sched-mi -o
> /tmp/vector_test-f6IGjg.s -x c++ vector_test.cc
> clang -cc1 version 3.3 based upon LLVM 3.3svn default target
> powerpc64-unknown-linux-gnu
> ignoring nonexistent directory "/include"
> #include "..." search starts here:
> #include <...> search starts here:
>  /bgsys/drivers/ppcfloor/gnu-linux/powerpc64-bgq-linux/sys-include
>
> /bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../../../powerpc64-bgq-linux/include/c++/4.4.6
>
> /bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../../../powerpc64-bgq-linux/include/c++/4.4.6/powerpc64-bgq-linux
>
> /bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../../../powerpc64-bgq-linux/include/c++/4.4.6/backward
>  /usr/local/include
>  /bghome/blocksom/development/llvm/install/bin/../lib/clang/3.3/include
>  /usr/include
> End of search list.
>
> "/bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../../../powerpc64-bgq-linux/bin/as"
> -a64 -mppc64 -many -o /tmp/vector_test-wO5yyv.o /tmp/vector_test-f6IGjg.s
>
> "/bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../../../powerpc64-bgq-linux/bin/ld"
> --hash-style=gnu --no-add-needed --build-id -m elf64ppc -static -o
> vector_test.cnk
> /bgsys/drivers/ppcfloor/gnu-linux/powerpc64-bgq-linux/lib/crt1.o
> /bgsys/drivers/ppcfloor/gnu-linux/powerpc64-bgq-linux/lib/crti.o
> /bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/crtbeginT.o
> -L/bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6
> -L/bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../../../lib64
> -L/lib/../lib64 -L/usr/lib/../lib64
> -L/bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../../../powerpc64-bgq-linux/lib
> -L/bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/../../..
> -L/lib -L/usr/lib /tmp/vector_test-wO5yyv.o --start-group -lgcc -lgcc_eh -lc
> --end-group
> /bgsys/drivers/ppcfloor/gnu-linux/lib/gcc/powerpc64-bgq-linux/4.4.6/crtend.o
> /bgsys/drivers/ppcfloor/gnu-linux/powerpc64-bgq-linux/lib/crtn.o
> /tmp/vector_test-wO5yyv.o:(.text._ZNSt6vectorIjSaIjEED2Ev[_ZNSt6vectorIjSaIjEED2Ev]+0xac):
> undefined reference to `std::terminate()'
> /tmp/vector_test-wO5yyv.o:(.text._ZN9__gnu_cxx13new_allocatorIjE10deallocateEPjm[_ZN9__gnu_cxx13new_allocatorIjE10deallocateEPjm]+0x34):
> undefined reference to `operator delete(void*)'
> /tmp/vector_test-wO5yyv.o:(.eh_frame+0x87): undefined reference to
> `__gxx_personality_v0'
> clang: error: linker command failed with exit code 1 (use -v to see
> invocation)
>
> ====
>
> Thanks,
>
> Michael Blocksome
> Blue Gene Messaging
> blocksom at us.ibm.com
>
>
>
>
> From:        Hal Finkel <hfinkel at anl.gov>
> To:        Michael Blocksome/Rochester/IBM at IBMUS,
> Cc:        llvm-bgq-discuss at lists.alcf.anl.gov
> Date:        12/18/2012 11:58 AM
> Subject:        Re: [Llvm-bgq-discuss] clang ICE
> ________________________________
>
>
>
> ----- Original Message -----
>> From: "Hal Finkel" <hfinkel at anl.gov>
>> To: "Michael Blocksome" <blocksom at us.ibm.com>
>> Cc: llvm-bgq-discuss at lists.alcf.anl.gov
>> Sent: Monday, December 17, 2012 4:54:03 PM
>> Subject: Re: [Llvm-bgq-discuss] clang ICE
>>
>> ----- Original Message -----
>> > From: "Hal Finkel" <hfinkel at anl.gov>
>> > To: "Michael Blocksome" <blocksom at us.ibm.com>
>> > Cc: llvm-bgq-discuss at lists.alcf.anl.gov
>> > Sent: Monday, December 17, 2012 3:49:30 PM
>> > Subject: Re: [Llvm-bgq-discuss] clang ICE
>> >
>> > Michael,
>> >
>> > This is an LLVM inline assembly issue. If I can't figure out how to
>> > fix this in the next few minutes, I'll file a bug report.
>>
>> FYI: http://llvm.org/bugs/show_bug.cgi?id=14627
>>
>
> I committed a fix to this bug in r170436. Assuming the buildbots don't
> complain, I'll update the bug report.
>
> -Hal
>
>>  -Hal
>>
>> >
>> > Thanks again,
>> > Hal
>> >
>> > ----- Original Message -----
>> > > From: "Michael Blocksome" <blocksom at us.ibm.com>
>> > > To: llvm-bgq-discuss at lists.alcf.anl.gov
>> > > Sent: Monday, December 17, 2012 2:29:24 PM
>> > > Subject: [Llvm-bgq-discuss] clang ICE
>> > >
>> > >
>> > > I've encountered an ICE with clang and was wondering if someone
>> > > on
>> > > the list could recreate the problem? I thought I'd start here
>> > > instead of submitting a clang bug report since I'm using the
>> > > provided patches and compile script. I'm not sure if the problem
>> > > is
>> > > with the patched llvm/clang or if it is in the base source.
>> > >
>> > > bgclang-20121213
>> > > clang-bgq-r170143-20121213.patch
>> > > llvm-bgq-r170143-20121213.patch
>> > >
>> > > I've pulled out the majority of the junk around the failure and
>> > > have
>> > > it down to a few files and a clang command (whittled down from -v
>> > > output of the entire build). To recreate, just edit and run the
>> > > 'clang_ice.sh' file.
>> > >
>> > >
>> > >
>> > > Thanks,
>> > >
>> > > Michael Blocksome
>> > > Blue Gene Messaging
>> > > blocksom at us.ibm.com
>> > >
>> > > _______________________________________________
>> > > llvm-bgq-discuss mailing list
>> > > llvm-bgq-discuss at lists.alcf.anl.gov
>> > > https://lists.alcf.anl.gov/mailman/listinfo/llvm-bgq-discuss
>> > >
>> >
>> > --
>> > Hal Finkel
>> > Postdoctoral Appointee
>> > Leadership Computing Facility
>> > Argonne National Laboratory
>> > _______________________________________________
>> > llvm-bgq-discuss mailing list
>> > llvm-bgq-discuss at lists.alcf.anl.gov
>> > https://lists.alcf.anl.gov/mailman/listinfo/llvm-bgq-discuss
>> >
>>
>> --
>> Hal Finkel
>> Postdoctoral Appointee
>> Leadership Computing Facility
>> Argonne National Laboratory
>> _______________________________________________
>> llvm-bgq-discuss mailing list
>> llvm-bgq-discuss at lists.alcf.anl.gov
>> https://lists.alcf.anl.gov/mailman/listinfo/llvm-bgq-discuss
>>
>
> --
> Hal Finkel
> Postdoctoral Appointee
> Leadership Computing Facility
> Argonne National Laboratory
>
>
>
> _______________________________________________
> llvm-bgq-discuss mailing list
> llvm-bgq-discuss at lists.alcf.anl.gov
> https://lists.alcf.anl.gov/mailman/listinfo/llvm-bgq-discuss
>



-- 
Jeff Hammond
Argonne Leadership Computing Facility
University of Chicago Computation Institute
jhammond at alcf.anl.gov / (630) 252-5381
http://www.linkedin.com/in/jeffhammond
https://wiki.alcf.anl.gov/parts/index.php/User:Jhammond


More information about the llvm-bgq-discuss mailing list