kovdan01 wrote:

@ojhunt Thanks for an update! With the latest fixes, we only have one trivial 
issue which prevents Linux tests from passing (and I believe that it was 
introduced accidentally and it looks like that we need literally zero effort to 
fix that). With that being fixed, tests are passing on Linux in the following 
configurations:

1. Pauthtest for both runtime libraries and executables
2. Pac-ret for both runtime libraries and executables
3. Pac-ret for executables but not runtime libraries
4. No pauth at all (on aarch64)

Besides that, there are several other small issues here and there. See the list 
below.

Please let me know if any help with fixing these issues is needed - I would be 
glad to provide any support.

1. Use a check against `_LIBUNWIND_TARGET_AARCH64_AUTHENTICATED_UNWINDING` 
against a check against arm64e: 
https://github.com/llvm/llvm-project/pull/143230#discussion_r2407141767
   This is the only thing which prevents linux tests from passing.

2. Avoid UB in `get_handler_function`: 
https://github.com/llvm/llvm-project/pull/143230#discussion_r2406229405
   Similar issue should also be addressed in 
https://github.com/llvm/llvm-project/pull/161027#discussion_r2388230955

3. It looks like that while `_LIBUNWIND_TARGET_AARCH64_AUTHENTICATED_UNWINDING` 
macro was added (and it's used in some places), in most cases we still have 
plain checks against `__has_feature(ptrauth_calls)` and 
`__has_feature(ptrauth_returns)`. As discussed earlier, it's better to use this 
macro for such checks. See thread 
https://github.com/llvm/llvm-project/pull/143230#discussion_r2369029642 and 
proposed fix 
[644405b](https://github.com/llvm/llvm-project/commit/644405b56cfa59dd3787119182df087dff6e756c)

4. Add a comment explaining conditionals regarding 
`__ptrauth_restricted_intptr` qualifier to make it clearer for thouse not 
familiar with Apple's clang specific. I've provided an example comments, see 
https://github.com/llvm/llvm-project/pull/143230#discussion_r2407114846

5. `__ptrauth_unwind_pacret_personality_disc` should probably be renamed to 
`__ptrauth_unwind_pauthtest_personality_disc`. It's clearly not related to 
pac-ret which is about LR signing only. See 
https://github.com/llvm/llvm-project/pull/143230#discussion_r2406175800

Looking forward for further updates and hope that this could be finally merged 
relatively soon :)



https://github.com/llvm/llvm-project/pull/143230
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to