Skip to content

Commit a6b264b

Browse files
author
Alexey Samsonov
committed
Move original compiler-rt functions (libgcc replacement) to lib/builtins directory
llvm-svn: 201393
1 parent 0b28ea9 commit a6b264b

File tree

240 files changed

+271
-259
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

240 files changed

+271
-259
lines changed

compiler-rt/lib/CMakeLists.txt

Lines changed: 1 addition & 234 deletions
Original file line numberDiff line numberDiff line change
@@ -33,240 +33,7 @@ if(LLVM_USE_SANITIZER STREQUAL "")
3333
endif()
3434
endif()
3535

36-
# The top-level lib directory contains a large amount of C code which provides
37-
# generic implementations of the core runtime library along with optimized
38-
# architecture-specific code in various subdirectories.
39-
40-
set(GENERIC_SOURCES
41-
absvdi2.c
42-
absvsi2.c
43-
absvti2.c
44-
adddf3.c
45-
addsf3.c
46-
addvdi3.c
47-
addvsi3.c
48-
addvti3.c
49-
apple_versioning.c
50-
ashldi3.c
51-
ashlti3.c
52-
ashrdi3.c
53-
ashrti3.c
54-
# FIXME: atomic.c may only be compiled if host compiler understands _Atomic
55-
# atomic.c
56-
clear_cache.c
57-
clzdi2.c
58-
clzsi2.c
59-
clzti2.c
60-
cmpdi2.c
61-
cmpti2.c
62-
comparedf2.c
63-
comparesf2.c
64-
ctzdi2.c
65-
ctzsi2.c
66-
ctzti2.c
67-
divdc3.c
68-
divdf3.c
69-
divdi3.c
70-
divmoddi4.c
71-
divmodsi4.c
72-
divsc3.c
73-
divsf3.c
74-
divsi3.c
75-
divti3.c
76-
divxc3.c
77-
enable_execute_stack.c
78-
eprintf.c
79-
extendsfdf2.c
80-
ffsdi2.c
81-
ffsti2.c
82-
fixdfdi.c
83-
fixdfsi.c
84-
fixdfti.c
85-
fixsfdi.c
86-
fixsfsi.c
87-
fixsfti.c
88-
fixunsdfdi.c
89-
fixunsdfsi.c
90-
fixunsdfti.c
91-
fixunssfdi.c
92-
fixunssfsi.c
93-
fixunssfti.c
94-
fixunsxfdi.c
95-
fixunsxfsi.c
96-
fixunsxfti.c
97-
fixxfdi.c
98-
fixxfti.c
99-
floatdidf.c
100-
floatdisf.c
101-
floatdixf.c
102-
floatsidf.c
103-
floatsisf.c
104-
floattidf.c
105-
floattisf.c
106-
floattixf.c
107-
floatundidf.c
108-
floatundisf.c
109-
floatundixf.c
110-
floatunsidf.c
111-
floatunsisf.c
112-
floatuntidf.c
113-
floatuntisf.c
114-
floatuntixf.c
115-
gcc_personality_v0.c
116-
int_util.c
117-
lshrdi3.c
118-
lshrti3.c
119-
moddi3.c
120-
modsi3.c
121-
modti3.c
122-
muldc3.c
123-
muldf3.c
124-
muldi3.c
125-
mulodi4.c
126-
mulosi4.c
127-
muloti4.c
128-
mulsc3.c
129-
mulsf3.c
130-
multi3.c
131-
mulvdi3.c
132-
mulvsi3.c
133-
mulvti3.c
134-
mulxc3.c
135-
negdf2.c
136-
negdi2.c
137-
negsf2.c
138-
negti2.c
139-
negvdi2.c
140-
negvsi2.c
141-
negvti2.c
142-
paritydi2.c
143-
paritysi2.c
144-
parityti2.c
145-
popcountdi2.c
146-
popcountsi2.c
147-
popcountti2.c
148-
powidf2.c
149-
powisf2.c
150-
powitf2.c
151-
powixf2.c
152-
subdf3.c
153-
subsf3.c
154-
subvdi3.c
155-
subvsi3.c
156-
subvti3.c
157-
trampoline_setup.c
158-
truncdfsf2.c
159-
ucmpdi2.c
160-
ucmpti2.c
161-
udivdi3.c
162-
udivmoddi4.c
163-
udivmodsi4.c
164-
udivmodti4.c
165-
udivsi3.c
166-
udivti3.c
167-
umoddi3.c
168-
umodsi3.c
169-
umodti3.c
170-
)
171-
172-
set(x86_64_SOURCES
173-
x86_64/floatdidf.c
174-
x86_64/floatdisf.c
175-
x86_64/floatdixf.c
176-
x86_64/floatundidf.S
177-
x86_64/floatundisf.S
178-
x86_64/floatundixf.S
179-
${GENERIC_SOURCES})
180-
181-
set(i386_SOURCES
182-
i386/ashldi3.S
183-
i386/ashrdi3.S
184-
i386/divdi3.S
185-
i386/floatdidf.S
186-
i386/floatdisf.S
187-
i386/floatdixf.S
188-
i386/floatundidf.S
189-
i386/floatundisf.S
190-
i386/floatundixf.S
191-
i386/lshrdi3.S
192-
i386/moddi3.S
193-
i386/muldi3.S
194-
i386/udivdi3.S
195-
i386/umoddi3.S
196-
${GENERIC_SOURCES})
197-
198-
set(arm_SOURCES
199-
arm/adddf3vfp.S
200-
arm/addsf3vfp.S
201-
arm/aeabi_dcmp.S
202-
arm/aeabi_fcmp.S
203-
arm/aeabi_idivmod.S
204-
arm/aeabi_ldivmod.S
205-
arm/aeabi_memcmp.S
206-
arm/aeabi_memcpy.S
207-
arm/aeabi_memmove.S
208-
arm/aeabi_memset.S
209-
arm/aeabi_uidivmod.S
210-
arm/aeabi_uldivmod.S
211-
arm/bswapdi2.S
212-
arm/bswapsi2.S
213-
arm/comparesf2.S
214-
arm/divdf3vfp.S
215-
arm/divmodsi4.S
216-
arm/divsf3vfp.S
217-
arm/divsi3.S
218-
arm/eqdf2vfp.S
219-
arm/eqsf2vfp.S
220-
arm/extendsfdf2vfp.S
221-
arm/fixdfsivfp.S
222-
arm/fixsfsivfp.S
223-
arm/fixunsdfsivfp.S
224-
arm/fixunssfsivfp.S
225-
arm/floatsidfvfp.S
226-
arm/floatsisfvfp.S
227-
arm/floatunssidfvfp.S
228-
arm/floatunssisfvfp.S
229-
arm/gedf2vfp.S
230-
arm/gesf2vfp.S
231-
arm/gtdf2vfp.S
232-
arm/gtsf2vfp.S
233-
arm/ledf2vfp.S
234-
arm/lesf2vfp.S
235-
arm/ltdf2vfp.S
236-
arm/ltsf2vfp.S
237-
arm/modsi3.S
238-
arm/muldf3vfp.S
239-
arm/mulsf3vfp.S
240-
arm/nedf2vfp.S
241-
arm/negdf2vfp.S
242-
arm/negsf2vfp.S
243-
arm/nesf2vfp.S
244-
arm/restore_vfp_d8_d15_regs.S
245-
arm/save_vfp_d8_d15_regs.S
246-
arm/subdf3vfp.S
247-
arm/subsf3vfp.S
248-
arm/switch16.S
249-
arm/switch32.S
250-
arm/switch8.S
251-
arm/switchu8.S
252-
arm/sync_synchronize.S
253-
arm/truncdfsf2vfp.S
254-
arm/udivmodsi4.S
255-
arm/udivsi3.S
256-
arm/umodsi3.S
257-
arm/unorddf2vfp.S
258-
arm/unordsf2vfp.S
259-
${GENERIC_SOURCES})
260-
261-
if (NOT WIN32)
262-
foreach(arch x86_64 i386 arm)
263-
if(CAN_TARGET_${arch})
264-
add_compiler_rt_static_runtime(clang_rt.${arch} ${arch}
265-
SOURCES ${${arch}_SOURCES}
266-
CFLAGS "-std=c99")
267-
endif()
268-
endforeach()
269-
endif()
36+
add_subdirectory(builtins)
27037

27138
# Generate configs for running lit and unit tests.
27239
configure_lit_site_cfg(

compiler-rt/lib/Makefile.mk

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -7,27 +7,16 @@
77
#
88
#===------------------------------------------------------------------------===#
99

10-
ModuleName := builtins
1110
SubDirs :=
1211

13-
# Add arch specific optimized implementations.
14-
SubDirs += i386 ppc x86_64 arm
15-
16-
# Add other submodules.
12+
# Add submodules.
1713
SubDirs += asan
14+
SubDirs += builtins
15+
SubDirs += dfsan
1816
SubDirs += interception
17+
SubDirs += lsan
18+
SubDirs += msan
1919
SubDirs += profile
2020
SubDirs += sanitizer_common
2121
SubDirs += tsan
22-
SubDirs += msan
2322
SubDirs += ubsan
24-
SubDirs += lsan
25-
SubDirs += dfsan
26-
27-
# Define the variables for this specific directory.
28-
Sources := $(foreach file,$(wildcard $(Dir)/*.c),$(notdir $(file)))
29-
ObjNames := $(Sources:%.c=%.o)
30-
Implementation := Generic
31-
32-
# FIXME: use automatic dependencies?
33-
Dependencies := $(wildcard $(Dir)/*.h)

0 commit comments

Comments
 (0)