[LLVMdev] linux builds are borken

Chris Lattner clattner at apple.com
Tue Aug 18 09:53:23 PDT 2009


On Aug 18, 2009, at 4:45 AM, Anton Korobeynikov wrote:
> Hi, Chris
>
> Just FYI: libstdc++ on linux is definitely miscompiled.
> E.g.:

hi Anton,

Do you have any idea what patch is causing this or what the problem  
is?  I don't have a linux box handy to diagnose this on.

-Chris

>
> $ cat test.cpp
> #include <vector>
> #include <iostream>
>
> class A {
> public:
> A() { printf("Ctor!\n"); };
> ~A() { printf("Dtor!\n"); };
> };
>
> static A foo;
>
> int main(void) {
> std::vector<int> v;
>
> v.push_back(1);
>
> std::cout << "This is really test message" << std::endl;
> std::cout << "v[0]: " << v[0] << std::endl;
> return v.size();
> }
>
>
> $ ./llvm-g++ -static test.cpp && ./a.out
> Ctor!
> Segmentation fault
>
> valgrind is not clean on this a.out file. gcc-compiled libstdc++ is  
> ok.
> Currently I'm trying to figure out the status of mingw stuff. Later
> hopefully I'll try to return to this problem.
>
> -- 
> With best regards, Anton Korobeynikov.
>
> Faculty of Mathematics & Mechanics, Saint Petersburg State University.
>




More information about the llvm-dev mailing list