Page MenuHomeFreeBSD

sys/conf: Support building kasan with gcc on arm64
ClosedPublic

Authored by andrew on May 22 2024, 2:35 PM.
Tags
None
Referenced Files
F153540040: D45300.id144936.diff
Tue, Apr 21, 6:35 PM
Unknown Object (File)
Mon, Apr 20, 2:27 AM
Unknown Object (File)
Mon, Apr 20, 12:02 AM
Unknown Object (File)
Sun, Apr 19, 10:06 PM
Unknown Object (File)
Sat, Apr 18, 4:12 PM
Unknown Object (File)
Thu, Apr 16, 11:08 PM
Unknown Object (File)
Thu, Apr 16, 2:54 PM
Unknown Object (File)
Wed, Apr 15, 6:38 AM
Subscribers

Details

Summary
  • Remove -mllvm flags that don't exist in gcc
  • Set the shadow offset with -fasan-shadow-offset

This allows the arm64 GENERIC-KASAN kernel to build with gcc13.

Sponsored by: Arm Ltd

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

I wonder if we want a CFLAGS_GEN=${CFLAGS:N-flto*:N-fno-common:N-fsanitize*:N-fno-sanitize*:N-fasan-shadow-offset*} or maybe a CFLAGS_NOSAN in kern.pre.mk so we're not having to remove arguments in so many places?

This revision is now accepted and ready to land.Jun 5 2024, 4:51 PM