summaryrefslogtreecommitdiff
path: root/lib/libcompiler_rt
diff options
context:
space:
mode:
authorEd Maste <emaste@FreeBSD.org>2019-08-14 18:41:28 +0000
committerEd Maste <emaste@FreeBSD.org>2019-08-14 18:41:28 +0000
commitea0a30b14507592144d7f2218d75de0cf52a2b07 (patch)
tree3dc2585e30903f0a28d9e57b11dac5e2ccb286ca /lib/libcompiler_rt
parent331884f291f1de426e2e7a47f315eda85a6ba22f (diff)
downloadsrc-test-ea0a30b14507592144d7f2218d75de0cf52a2b07.tar.gz
src-test-ea0a30b14507592144d7f2218d75de0cf52a2b07.zip
compiler-rt: enable __bswapsi2/__bswapdi2 for RISC-V
As with other archs the compiler may emit calls to the byte swap routines under certain conditions. MFC after: 1 week Sponsored by: The FreeBSD Foundation
Notes
Notes: svn path=/head/; revision=351040
Diffstat (limited to 'lib/libcompiler_rt')
-rw-r--r--lib/libcompiler_rt/Makefile.inc3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/libcompiler_rt/Makefile.inc b/lib/libcompiler_rt/Makefile.inc
index 71b83c52cecab..b606abb41f4a1 100644
--- a/lib/libcompiler_rt/Makefile.inc
+++ b/lib/libcompiler_rt/Makefile.inc
@@ -234,7 +234,8 @@ SRCS+= sync_synchronize.S
.endif
# On some archs GCC-6.3 requires bswap32 built-in.
-.if ${MACHINE_CPUARCH} == "mips" || ${MACHINE_CPUARCH} == "sparc64"
+.if ${MACHINE_CPUARCH} == "mips" || ${MACHINE_CPUARCH} == "riscv" || \
+ ${MACHINE_CPUARCH} == "sparc64"
SRCS+= bswapdi2.c
SRCS+= bswapsi2.c
.endif