Enable back-edge CFI by default on macOS (#4720)

Also, adjust the tests that are executed on that platform. Finally,
fix a bug with obtaining backtraces when back-edge CFI is enabled.

Copyright (c) 2022, Arm Limited.
This commit is contained in:
Anton Kirilov
2022-08-17 21:06:20 +01:00
committed by GitHub
parent 57dca934ad
commit 1481721c9d
9 changed files with 58 additions and 23 deletions

View File

@@ -128,6 +128,16 @@ impl<'a> Arbitrary<'a> for CodegenSettings {
test: is_aarch64_feature_detected,
std: "lse" => clif: "has_lse",
// even though the natural correspondence seems to be
// between "paca" and "has_pauth", the latter has no effect
// in isolation, so we actually use the setting that affects
// code generation
std: "paca" => clif: "sign_return_address",
// "paca" and "pacg" check for the same underlying
// architectural feature, so we use the latter to cover more
// code generation settings, of which we have chosen the one
// with the most significant effect
std: "pacg" => clif: "sign_return_address_all" ratio: 1 in 2,
},
};
return Ok(CodegenSettings::Target {