[llvm-dev] Unresolved symbols in compiler-rt

Jerker Bäck via llvm-dev llvm-dev at lists.llvm.org
Fri Dec 8 11:27:05 PST 2017


Hello all,

I get unresolved external symbol __muloti4 when attempting to compile GNU m4
for Windows commandline. 
See details in bug: https://bugs.llvm.org/show_bug.cgi?id=16404#c22

Looking into this, I see that some parts of compiler-rt are disabled for
Windows due to the __LP64__ define. The code seem not portable as is to the
MS compiler, but according to my tests the code compiles and links OK with
clang: I have not tested functionality though. Regarding the __LP64__
define, it's wrong to define it for Windows. SUA/Interix have LP64 long type
model, while Cygwin, mingw and native Windows have LLP64. _M_X64 or
__x86_64__ is more common.

So I wonder, is the disabled compiler-rt parts intentional and not suitable
for Windows?
If not so, what can be done to enable it?

Thanks Erik




More information about the llvm-dev mailing list