Makefile.inc (0b862b03998a292a18bcc7f9ac5b05c0303c5de3) Makefile.inc (46c8c5540fe4995e01fcf2e173c05761e7ba9488)
1# $FreeBSD$
2
1# $FreeBSD$
2
3.include <bsd.compiler.mk>
4
3CRTARCH= ${MACHINE_CPUARCH:C/amd64/x86_64/}
4
5CRTSRC= ${SRCTOP}/contrib/llvm-project/compiler-rt/lib/builtins
6
7.PATH: ${CRTSRC}/${CRTARCH}
8.PATH: ${CRTSRC}
9
10SRCF+= absvdi2
11SRCF+= absvsi2
12SRCF+= absvti2
13SRCF+= addvdi3
14SRCF+= addvsi3
15SRCF+= addvti3
16SRCF+= apple_versioning
17SRCF+= ashldi3
18SRCF+= ashlti3
19SRCF+= ashrdi3
20SRCF+= ashrti3
5CRTARCH= ${MACHINE_CPUARCH:C/amd64/x86_64/}
6
7CRTSRC= ${SRCTOP}/contrib/llvm-project/compiler-rt/lib/builtins
8
9.PATH: ${CRTSRC}/${CRTARCH}
10.PATH: ${CRTSRC}
11
12SRCF+= absvdi2
13SRCF+= absvsi2
14SRCF+= absvti2
15SRCF+= addvdi3
16SRCF+= addvsi3
17SRCF+= addvti3
18SRCF+= apple_versioning
19SRCF+= ashldi3
20SRCF+= ashlti3
21SRCF+= ashrdi3
22SRCF+= ashrti3
23SRCF+= atomic
24SRCF+= bswapdi2
25SRCF+= bswapsi2
21SRCF+= clear_cache
22SRCF+= clzdi2
23SRCF+= clzsi2
24SRCF+= clzti2
25SRCF+= cmpdi2
26SRCF+= cmpti2
27SRCF+= ctzdi2
28SRCF+= ctzsi2

--- 86 unchanged lines hidden (view full) ---

115SRCF+= udivmodsi4
116SRCF+= udivmodti4
117SRCF+= udivsi3
118SRCF+= udivti3
119SRCF+= umoddi3
120SRCF+= umodsi3
121SRCF+= umodti3
122
26SRCF+= clear_cache
27SRCF+= clzdi2
28SRCF+= clzsi2
29SRCF+= clzti2
30SRCF+= cmpdi2
31SRCF+= cmpti2
32SRCF+= ctzdi2
33SRCF+= ctzsi2

--- 86 unchanged lines hidden (view full) ---

120SRCF+= udivmodsi4
121SRCF+= udivmodti4
122SRCF+= udivsi3
123SRCF+= udivti3
124SRCF+= umoddi3
125SRCF+= umodsi3
126SRCF+= umodti3
127
128.if "${COMPILER_TYPE}" == "clang"
129CFLAGS.atomic.c+= -Wno-atomic-alignment
130.endif
131
123# Avoid using SSE2 instructions on i386, if unsupported.
124.if ${MACHINE_CPUARCH} == "i386" && empty(MACHINE_CPU:Msse2)
125SRCS+= floatdidf.c
126SRCS+= floatdisf.c
127SRCS+= floatdixf.c
128SRCS+= floatundidf.c
129SRCS+= floatundisf.c
130SRCS+= floatundixf.c

--- 76 unchanged lines hidden (view full) ---

207SRCF+= stdatomic
208CFLAGS+= -DEMIT_SYNC_ATOMICS
209.elif ${MACHINE_CPUARCH} == "mips"
210.PATH: ${SRCTOP}/sys/mips/mips
211
212SRCF+= stdatomic
213.endif
214
132# Avoid using SSE2 instructions on i386, if unsupported.
133.if ${MACHINE_CPUARCH} == "i386" && empty(MACHINE_CPU:Msse2)
134SRCS+= floatdidf.c
135SRCS+= floatdisf.c
136SRCS+= floatdixf.c
137SRCS+= floatundidf.c
138SRCS+= floatundisf.c
139SRCS+= floatundixf.c

--- 76 unchanged lines hidden (view full) ---

216SRCF+= stdatomic
217CFLAGS+= -DEMIT_SYNC_ATOMICS
218.elif ${MACHINE_CPUARCH} == "mips"
219.PATH: ${SRCTOP}/sys/mips/mips
220
221SRCF+= stdatomic
222.endif
223
215.if "${COMPILER_TYPE}" == "clang" && \
216 (${MACHINE_ARCH} == "powerpc" || ${MACHINE_ARCH} == "powerpcspe")
217SRCS+= atomic.c
218CFLAGS.atomic.c+= -Wno-atomic-alignment
219.endif
220
221.for file in ${SRCF}
222.if ${MACHINE_ARCH:Marmv[67]*} && (!defined(CPUTYPE) || ${CPUTYPE:M*soft*} == "") \
223 && exists(${CRTSRC}/${CRTARCH}/${file}vfp.S)
224SRCS+= ${file}vfp.S
225. elif exists(${CRTSRC}/${CRTARCH}/${file}.S)
226SRCS+= ${file}.S
227. else
228SRCS+= ${file}.c

--- 5 unchanged lines hidden (view full) ---

234SRCS+= aeabi_idivmod.S
235SRCS+= aeabi_ldivmod.S
236SRCS+= aeabi_memcmp.S
237SRCS+= aeabi_memcpy.S
238SRCS+= aeabi_memmove.S
239SRCS+= aeabi_memset.S
240SRCS+= aeabi_uidivmod.S
241SRCS+= aeabi_uldivmod.S
224.for file in ${SRCF}
225.if ${MACHINE_ARCH:Marmv[67]*} && (!defined(CPUTYPE) || ${CPUTYPE:M*soft*} == "") \
226 && exists(${CRTSRC}/${CRTARCH}/${file}vfp.S)
227SRCS+= ${file}vfp.S
228. elif exists(${CRTSRC}/${CRTARCH}/${file}.S)
229SRCS+= ${file}.S
230. else
231SRCS+= ${file}.c

--- 5 unchanged lines hidden (view full) ---

237SRCS+= aeabi_idivmod.S
238SRCS+= aeabi_ldivmod.S
239SRCS+= aeabi_memcmp.S
240SRCS+= aeabi_memcpy.S
241SRCS+= aeabi_memmove.S
242SRCS+= aeabi_memset.S
243SRCS+= aeabi_uidivmod.S
244SRCS+= aeabi_uldivmod.S
242SRCS+= bswapdi2.S
243SRCS+= bswapsi2.S
244SRCS+= switch16.S
245SRCS+= switch32.S
246SRCS+= switch8.S
247SRCS+= switchu8.S
248SRCS+= sync_synchronize.S
249.endif
250
245SRCS+= switch16.S
246SRCS+= switch32.S
247SRCS+= switch8.S
248SRCS+= switchu8.S
249SRCS+= sync_synchronize.S
250.endif
251
251# On some archs GCC-6.3 requires bswap32 built-in.
252.if ${MACHINE_CPUARCH} == "mips" || ${MACHINE_CPUARCH} == "riscv"
253SRCS+= bswapdi2.c
254SRCS+= bswapsi2.c
255.endif
256
257.if ${MACHINE_ARCH:Mriscv*sf}
258CFLAGS+= -D__SOFT_FP__
259.endif
252.if ${MACHINE_ARCH:Mriscv*sf}
253CFLAGS+= -D__SOFT_FP__
254.endif