Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix multilib PACBTI mapping #501

Merged
merged 1 commit into from
Sep 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 8 additions & 8 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1874,8 +1874,8 @@ add_library_variants_for_cpu(
add_library_variants_for_cpu(
armv8.1m.main
SUFFIX soft_nofp_nomve_pacret_bti
COMPILE_FLAGS "-mfloat-abi=soft -march=armv8.1m.main+nomve+pacbti -mfpu=none -mbranch-protection=standard"
MULTILIB_FLAGS "--target=thumbv8.1m.main-unknown-none-eabi -mfpu=none -mbranch-protection=standard"
COMPILE_FLAGS "-mfloat-abi=soft -march=armv8.1m.main+nomve+pacbti -mfpu=none -mbranch-protection=pac-ret+bti"
MULTILIB_FLAGS "--target=thumbv8.1m.main-unknown-none-eabi -mfpu=none -mbranch-protection=pac-ret+bti"
PICOLIBC_BUILD_TYPE "release"
QEMU_MACHINE "mps3-an547"
QEMU_CPU "cortex-m55"
Expand All @@ -1890,8 +1890,8 @@ add_library_variants_for_cpu(
add_library_variants_for_cpu(
armv8.1m.main
SUFFIX hard_fp_nomve_pacret_bti
COMPILE_FLAGS "-mfloat-abi=hard -march=armv8.1m.main+nomve+pacbti -mfpu=fp-armv8-fullfp16-sp-d16 -mbranch-protection=standard"
MULTILIB_FLAGS "--target=thumbv8.1m.main-unknown-none-eabihf -march=thumbv8.1m.main+fp16 -mfpu=fp-armv8-fullfp16-sp-d16 -mbranch-protection=standard"
COMPILE_FLAGS "-mfloat-abi=hard -march=armv8.1m.main+nomve+pacbti -mfpu=fp-armv8-fullfp16-sp-d16 -mbranch-protection=pac-ret+bti"
MULTILIB_FLAGS "--target=thumbv8.1m.main-unknown-none-eabihf -march=thumbv8.1m.main+fp16 -mfpu=fp-armv8-fullfp16-sp-d16 -mbranch-protection=pac-ret+bti"
PICOLIBC_BUILD_TYPE "release"
QEMU_MACHINE "mps3-an547"
QEMU_CPU "cortex-m55"
Expand All @@ -1906,8 +1906,8 @@ add_library_variants_for_cpu(
add_library_variants_for_cpu(
armv8.1m.main
SUFFIX hard_fpdp_nomve_pacret_bti
COMPILE_FLAGS "-mfloat-abi=hard -march=armv8.1m.main+nomve+pacbti -mfpu=fp-armv8-fullfp16-d16 -mbranch-protection=standard"
MULTILIB_FLAGS "--target=thumbv8.1m.main-unknown-none-eabihf -march=thumbv8.1m.main+fp16 -mfpu=fp-armv8-fullfp16-d16 -mbranch-protection=standard"
COMPILE_FLAGS "-mfloat-abi=hard -march=armv8.1m.main+nomve+pacbti -mfpu=fp-armv8-fullfp16-d16 -mbranch-protection=pac-ret+bti"
MULTILIB_FLAGS "--target=thumbv8.1m.main-unknown-none-eabihf -march=thumbv8.1m.main+fp16 -mfpu=fp-armv8-fullfp16-d16 -mbranch-protection=pac-ret+bti"
PICOLIBC_BUILD_TYPE "release"
QEMU_MACHINE "mps3-an547"
QEMU_CPU "cortex-m55"
Expand All @@ -1922,8 +1922,8 @@ add_library_variants_for_cpu(
add_library_variants_for_cpu(
armv8.1m.main
SUFFIX hard_nofp_mve_pacret_bti
COMPILE_FLAGS "-mfloat-abi=hard -march=armv8.1m.main+mve+pacbti -mfpu=none -mbranch-protection=standard"
MULTILIB_FLAGS "--target=thumbv8.1m.main-unknown-none-eabihf -march=thumbv8.1m.main+mve -mfpu=none -mbranch-protection=standard"
COMPILE_FLAGS "-mfloat-abi=hard -march=armv8.1m.main+mve+pacbti -mfpu=none -mbranch-protection=pac-ret+bti"
MULTILIB_FLAGS "--target=thumbv8.1m.main-unknown-none-eabihf -march=thumbv8.1m.main+mve -mfpu=none -mbranch-protection=pac-ret+bti"
PICOLIBC_BUILD_TYPE "release"
QEMU_MACHINE "mps3-an547"
QEMU_CPU "cortex-m55"
Expand Down
2 changes: 1 addition & 1 deletion cmake/multilib.yaml.in
Original file line number Diff line number Diff line change
Expand Up @@ -174,6 +174,6 @@ Mappings:
- -march=thumbv8.1m.main+lob

# -mbranch-protection options
- Match: -mbranch-protection=(standard|pac-ret(\+leaf)?\+bti|bti\+pac-ret(\+leaf)?)
- Match: -mbranch-protection=(standard|pac-ret(\+leaf)?(\+bti)?|bti(\+pac-ret(\+leaf)?)?)
Flags:
- -mbranch-protection=pac-ret+bti
Loading