mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 04:17:35 +00:00
Kernel: Add -mgeneral-regs-only flag to aarch64 Kernel build
With the update to GCC 12.1.0, the compiler now vectorizes code with -O2. This causes vector ops to be emitted, which are not supported in the Kernel. Add the -mgeneral-regs-only flag to force the compiler to not emit floating-point and SIMD ops.
This commit is contained in:
parent
cc7723b6c4
commit
9f3303c869
1 changed files with 4 additions and 0 deletions
|
@ -461,9 +461,13 @@ endif()
|
|||
add_compile_options(-fsigned-char)
|
||||
add_compile_options(-Wno-unknown-warning-option -Wvla -Wnull-dereference)
|
||||
add_compile_options(-fno-rtti -ffreestanding -fbuiltin)
|
||||
|
||||
if ("${SERENITY_ARCH}" STREQUAL "i686" OR "${SERENITY_ARCH}" STREQUAL "x86_64")
|
||||
add_compile_options(-mno-80387 -mno-mmx -mno-sse -mno-sse2)
|
||||
elseif("${SERENITY_ARCH}" STREQUAL "aarch64")
|
||||
add_compile_options(-mgeneral-regs-only)
|
||||
endif()
|
||||
|
||||
add_compile_options(-fno-asynchronous-unwind-tables)
|
||||
add_compile_options(-fstack-protector-strong)
|
||||
add_compile_options(-fno-exceptions)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue