diff --git a/sys/arm64/conf/GENERIC-MORELLO-PURECAP-BENCHMARK b/sys/arm64/conf/GENERIC-MORELLO-PURECAP-BENCHMARK new file mode 100644 index 000000000000..984e1ad4448b --- /dev/null +++ b/sys/arm64/conf/GENERIC-MORELLO-PURECAP-BENCHMARK @@ -0,0 +1,24 @@ +# +# GENERIC-MORELLO-BENCHMARKABI -- Generic kernel configuration file for CheriBSD/Morello benchmark ABI kernel +# +# For more information on this file, please read the config(5) manual page, +# and/or the handbook section on Kernel Configuration Files: +# +# https://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html +# +# The handbook is also available locally in /usr/share/doc/handbook +# if you've installed the doc distribution, otherwise always see the +# FreeBSD World Wide Web server (https://www.FreeBSD.org/) for the +# latest information. +# +# An exhaustive list of options and more detailed explanations of the +# device lines is also present in the ../../conf/NOTES and NOTES files. +# If you are in doubt as to the purpose or necessity of a line, check first +# in NOTES. +# + +include "GENERIC-MORELLO-PURECAP" + +ident GENERIC-MORELLO-BENCHMARKABI + +machine arm64 aarch64cb diff --git a/sys/arm64/conf/GENERIC-MORELLO-PURECAP-BENCHMARK-NODEBUG b/sys/arm64/conf/GENERIC-MORELLO-PURECAP-BENCHMARK-NODEBUG new file mode 100644 index 000000000000..fd260f597160 --- /dev/null +++ b/sys/arm64/conf/GENERIC-MORELLO-PURECAP-BENCHMARK-NODEBUG @@ -0,0 +1,4 @@ +include "GENERIC-MORELLO-BENCHMARKABI" +include "../../conf/std.nodebug" + +ident GENERIC-MORELLO-BENCHMARKABI-NODEBUG diff --git a/sys/conf/kern.mk b/sys/conf/kern.mk index a23886b9e704..00fa777c35a0 100644 --- a/sys/conf/kern.mk +++ b/sys/conf/kern.mk @@ -151,7 +151,11 @@ CFLAGS+= -Xclang -morello-vararg=new -Xclang -morello-bounded-memargs .endif .if ${MACHINE_ARCH:Maarch*c*} +.if ${MACHINE_ARCH:Maarch*cb} +CFLAGS+= -mabi=purecap-benchmark +.else CFLAGS+= -mabi=purecap +.endif .else CFLAGS+= -mabi=aapcs .endif @@ -353,6 +357,7 @@ CCLDFLAGS+= -fuse-ld=${LD:[1]:S/^ld.//1W} # Set target-specific linker emulation name. LD_EMULATION_aarch64=aarch64elf LD_EMULATION_aarch64c=aarch64elf +LD_EMULATION_aarch64cb=aarch64elf LD_EMULATION_amd64=elf_x86_64_fbsd LD_EMULATION_arm=armelf_fbsd LD_EMULATION_armv6=armelf_fbsd