[PATCH] D24071: [compiler-rt] [builtins] Allow building the necessary ARM builtins for MSVC mode with cmake
Martin Storsjö via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 31 02:58:44 PDT 2016
mstorsjo created this revision.
mstorsjo added reviewers: compnerd, rengolin.
mstorsjo added a subscriber: llvm-commits.
Herald added subscribers: dberris, samparker, rengolin, aemerson.
Even though llvm emits calls to __rt_{s,u}div{,64} when targeting Windows on ARM, it also emits calls to some of these (__moddi3, __umoddi3), making the compiler-rt builtins necessary in this configuration.
https://reviews.llvm.org/D24071
Files:
lib/builtins/CMakeLists.txt
Index: lib/builtins/CMakeLists.txt
===================================================================
--- lib/builtins/CMakeLists.txt
+++ lib/builtins/CMakeLists.txt
@@ -367,7 +367,21 @@
${arm_Thumb1_VFPv2_SOURCES}
${arm_Thumb1_icache_SOURCES})
-if(NOT WIN32)
+if(MSVC)
+ set(arm_SOURCES
+ divdi3.c
+ divsi3.c
+ divmoddi4.c
+ divmodsi4.c
+ moddi3.c
+ modsi3.c
+ udivdi3.c
+ udivsi3.c
+ umodsi3.c
+ umoddi3.c
+ udivmoddi4.c
+ udivmodsi4.c)
+elseif(NOT WIN32)
# TODO the EABI sources should only be added to EABI targets
set(arm_SOURCES
${arm_SOURCES}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D24071.69818.patch
Type: text/x-patch
Size: 631 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20160831/fd7f8486/attachment.bin>
More information about the llvm-commits
mailing list