1# $FreeBSD$ 2 3CRTARCH= ${MACHINE_CPUARCH:C/amd64/x86_64/} 4 5CRTSRC= ${SRCTOP}/contrib/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 21SRCF+= clear_cache 22SRCF+= clzdi2 23SRCF+= clzsi2 24SRCF+= clzti2 25SRCF+= cmpdi2 26SRCF+= cmpti2 27SRCF+= ctzdi2 28SRCF+= ctzsi2 29SRCF+= ctzti2 30SRCF+= divdc3 31SRCF+= divdi3 32SRCF+= divmoddi4 33SRCF+= divmodsi4 34SRCF+= divsc3 35SRCF+= divtc3 36SRCF+= divti3 37SRCF+= divxc3 38SRCF+= enable_execute_stack 39SRCF+= eprintf 40SRCF+= extendhfsf2 41SRCF+= ffsdi2 42SRCF+= ffsti2 43SRCF+= fixdfdi 44SRCF+= fixdfti 45SRCF+= fixsfdi 46SRCF+= fixsfti 47SRCF+= fixunsdfdi 48SRCF+= fixunsdfsi 49SRCF+= fixunsdfti 50SRCF+= fixunssfdi 51SRCF+= fixunssfsi 52SRCF+= fixunssfti 53SRCF+= fixunsxfdi 54SRCF+= fixunsxfsi 55SRCF+= fixunsxfti 56SRCF+= fixxfdi 57SRCF+= fixxfti 58SRCF+= floatdidf 59SRCF+= floatdisf 60SRCF+= floatditf 61SRCF+= floatdixf 62SRCF+= floatsitf 63SRCF+= floattidf 64SRCF+= floattisf 65SRCF+= floattixf 66SRCF+= floatundidf 67SRCF+= floatundisf 68SRCF+= floatunditf 69SRCF+= floatundixf 70SRCF+= floatunsidf 71SRCF+= floatunsisf 72SRCF+= floatuntidf 73SRCF+= floatuntisf 74SRCF+= floatuntixf 75SRCF+= gcc_personality_v0 76SRCF+= int_util 77SRCF+= lshrdi3 78SRCF+= lshrti3 79SRCF+= moddi3 80SRCF+= modti3 81SRCF+= muldc3 82SRCF+= muldi3 83SRCF+= mulodi4 84SRCF+= mulosi4 85SRCF+= muloti4 86SRCF+= mulsc3 87SRCF+= multi3 88SRCF+= mulvdi3 89SRCF+= mulvsi3 90SRCF+= mulvti3 91SRCF+= multc3 92SRCF+= mulxc3 93SRCF+= negdf2 94SRCF+= negdi2 95SRCF+= negsf2 96SRCF+= negti2 97SRCF+= negvdi2 98SRCF+= negvsi2 99SRCF+= negvti2 100SRCF+= paritydi2 101SRCF+= paritysi2 102SRCF+= parityti2 103SRCF+= popcountdi2 104SRCF+= popcountsi2 105SRCF+= popcountti2 106SRCF+= powidf2 107SRCF+= powisf2 108SRCF+= powitf2 109SRCF+= powixf2 110SRCF+= subvdi3 111SRCF+= subvsi3 112SRCF+= subvti3 113SRCF+= trampoline_setup 114SRCF+= truncdfhf2 115SRCF+= truncsfhf2 116SRCF+= ucmpdi2 117SRCF+= ucmpti2 118SRCF+= udivdi3 119SRCF+= udivmoddi4 120SRCF+= udivmodsi4 121SRCF+= udivmodti4 122SRCF+= udivti3 123SRCF+= umoddi3 124SRCF+= umodti3 125 126# 128-bit quad precision long double support, only used on arm64 127.if ${MACHINE_CPUARCH} == "aarch64" 128SRCF+= addtf3 129SRCF+= comparetf2 130SRCF+= divtf3 131SRCF+= extenddftf2 132SRCF+= extendsftf2 133SRCF+= fixtfdi 134SRCF+= fixtfsi 135SRCF+= fixtfti 136SRCF+= fixunstfdi 137SRCF+= fixunstfsi 138SRCF+= fixunstfti 139SRCF+= floatunsitf 140SRCF+= multf3 141SRCF+= subtf3 142SRCF+= trunctfdf2 143SRCF+= trunctfsf2 144.endif 145 146# These are already shipped by libc.a on arm and mips 147.if ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips" 148SRCF+= adddf3 149SRCF+= addsf3 150SRCF+= divdf3 151SRCF+= divsf3 152SRCF+= extendsfdf2 153SRCF+= fixdfsi 154SRCF+= fixsfsi 155SRCF+= floatsidf 156SRCF+= floatsisf 157SRCF+= muldf3 158SRCF+= mulsf3 159SRCF+= subdf3 160SRCF+= subsf3 161SRCF+= truncdfsf2 162.endif 163 164.if ${MACHINE_CPUARCH} != "arm" 165SRCF+= comparedf2 166SRCF+= comparesf2 167.endif 168 169.if ${MACHINE_CPUARCH} != "mips" 170SRCF+= divsi3 171SRCF+= modsi3 172SRCF+= udivsi3 173SRCF+= umodsi3 174.endif 175 176# FreeBSD-specific atomic intrinsics. 177.if ${MACHINE_CPUARCH} == "arm" || ${MACHINE_CPUARCH} == "armv6" 178.PATH: ${SRCTOP}/sys/arm/arm 179 180SRCF+= stdatomic 181CFLAGS+= -DEMIT_SYNC_ATOMICS 182.elif ${MACHINE_CPUARCH} == "mips" 183.PATH: ${SRCTOP}/sys/mips/mips 184 185SRCF+= stdatomic 186.endif 187 188.for file in ${SRCF} 189.if ${MACHINE_ARCH:Marmv6*} && (!defined(CPUTYPE) || ${CPUTYPE:M*soft*} == "") \ 190 && exists(${CRTSRC}/${CRTARCH}/${file}vfp.S) 191SRCS+= ${file}vfp.S 192. elif exists(${CRTSRC}/${CRTARCH}/${file}.S) 193SRCS+= ${file}.S 194. else 195SRCS+= ${file}.c 196. endif 197.endfor 198 199.if ${MACHINE_CPUARCH} == "arm" 200SRCS+= aeabi_div0.c 201SRCS+= aeabi_idivmod.S 202SRCS+= aeabi_ldivmod.S 203SRCS+= aeabi_memcmp.S 204SRCS+= aeabi_memcpy.S 205SRCS+= aeabi_memmove.S 206SRCS+= aeabi_memset.S 207SRCS+= aeabi_uidivmod.S 208SRCS+= aeabi_uldivmod.S 209SRCS+= bswapdi2.S 210SRCS+= bswapsi2.S 211SRCS+= switch16.S 212SRCS+= switch32.S 213SRCS+= switch8.S 214SRCS+= switchu8.S 215SRCS+= sync_synchronize.S 216.endif 217