[LLVMdev] LLVM built on VS C++ 2005
Jeff Cohen
jeffc at jolt-lang.org
Fri Feb 18 09:11:49 PST 2005
The answer to this FAQ question implies the answer is no. It relies on
g++ header files and libraries for STL support. Microsoft does not
implement STL using "libstdc++"; g++ does.
Why is my C++ binary so large?
C++ programs using the Standard Template Library (ie/ #include
<iostream>) cause a large part of the library to be statically linked
into the binary. The need to statically link the stdc++ into the binary
is two fold. First MSVCRT.dll does not contain C++ stdlib constructs.
Second the legal implications of generating a libstdc++.dll are
restricted by the licensing associated with the library.
Jeff Cohen wrote:
> I'm afraid that still does not completely answer the question. I'll
> accept that it will work for C programs, given what you quote. It
> says nothing about C++ however. That's a different animal entirely.
> g++ mangles names in a completely different fashion than VC++. Does
> mingw use VC++ style mangling? g++ processes exceptions in a
> completely different fashion than VC++. I think you get the picture :)
>
> Adam Treat wrote:
>
>> On Friday 18 February 2005 11:40 am, Jeff Cohen wrote:
>>
>>
>>> I'm not sure you understand the problem.
>>
>>
>> I wouldn't be surprised :)
>>
>>
>>
>>> Are you saying that a file compiled with mingw can catch an
>>> exception thrown by a file compiled
>>> with VC++ when the two are linked into a single program? That a
>>> program
>>> compiled with mingw can be linked against the VC++ runtime and *not*
>>> the
>>> mingw/gcc runtime?
>>>
>>
>>
>> AFAIK, mingw _does_ link against the MS runtime.
>>
>> mingw32 allows "one to produce native Windows programs that do not
>> rely on any 3rd-party C runtime DLLs." ^1
>>
>> mingw32 "uses Microsoft's runtime (either CRTDLL.DLL or MSVCRT.DLL)
>> for all services, and you get no more and no less than what Microsoft
>> provides." ^2
>>
>> 1) http://www.mingw.org/
>> 2)
>> http://www.xraylith.wisc.edu/~khan/software/gnu-win32/x86-win32-ports.html
>>
>>
>> _______________________________________________
>> LLVM Developers mailing list
>> LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu
>> http://mail.cs.uiuc.edu/mailman/listinfo/llvmdev
>>
>>
>>
>>
>
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu
> http://mail.cs.uiuc.edu/mailman/listinfo/llvmdev
>
>
More information about the llvm-dev
mailing list