Skip to content

chore: update 2023-02-09 + annotate local changes - #7

Merged
supervacuus merged 1 commit into
getsentry:masterfrom
supervacuus:chore/update_from_upstream
Feb 13, 2023
Merged

supervacuus merged 1 commit into
getsentry:masterfrom
supervacuus:chore/update_from_upstream

Conversation

@supervacuus

Copy link
Copy Markdown
Collaborator

includes commit 021c12c12495e553eb7d92ce7eaac302cac10b1b
last update was: 235e2604e2fa3c1f8f7a68c5e285f9622e741e64

https://android.googlesource.com/platform/system/unwinding/+log/refs/heads/master/libunwindstack

@supervacuus
supervacuus requested a review from Swatinem February 9, 2023 17:02
@supervacuus
supervacuus merged commit 1929f7b into getsentry:master Feb 13, 2023
jpnurmi added a commit that referenced this pull request Oct 29, 2026
`strip_pac()` only strips with a mask, and nothing sets one. The
`__bionic_clear_pac_bits()` fallback was compiled out because it is
not in the NDK, so a signed return address ended the unwind.

Strip with `xpaclri` like bionic does, spelled as `hint #7` for
assemblers without Armv8.3-A support. It is a NOP on older CPUs.

Pixel 8 Pro (Tensor G3, Android 17), `abort()` through two
`-mbranch-protection=pac-ret` functions, unwound from a SIGABRT
handler like sentry-native's inproc backend.

Before:
    #00 pc 000000000007fdc0  .../libc.so (abort+160)
    #1 pc 006e8cdf7ce216d0  <unknown>

After:
    #00 pc 000000000007fdc0  .../libc.so (abort+160)
    #1 pc 000000000002867c  .../pac_test (pac_crash()+12)
    #2 pc 000000000002868c  .../pac_test (pac_caller()+12)
    #3 pc 0000000000028708  .../pac_test (main+120)
    #4 pc 000000000007183c  .../libc.so (__libc_init+124)

Ref: getsentry/sentry-native#2258
jpnurmi added a commit that referenced this pull request Oct 29, 2026
`strip_pac()` only strips with a mask, and nothing sets one. The
`__bionic_clear_pac_bits()` fallback was compiled out because it is
not in the NDK, so a signed return address ended the unwind.

Strip with `xpaclri` like bionic does, spelled as `hint #7` for
assemblers without Armv8.3-A support. It is a NOP on older CPUs.

Pixel 8 Pro (Tensor G3, Android 17), `abort()` through two
`-mbranch-protection=pac-ret` functions, unwound from a SIGABRT
handler like sentry-native's inproc backend.

Before:
    #00 pc 000000000007fdc0  .../libc.so (abort+160)
    #1 pc 006e8cdf7ce216d0  <unknown>

After:
    #00 pc 000000000007fdc0  .../libc.so (abort+160)
    #1 pc 000000000002867c  .../pac_test (pac_crash()+12)
    #2 pc 000000000002868c  .../pac_test (pac_caller()+12)
    #3 pc 0000000000028708  .../pac_test (main+120)
    #4 pc 000000000007183c  .../libc.so (__libc_init+124)

Ref: getsentry/sentry-native#2258
jpnurmi added a commit that referenced this pull request Oct 30, 2026
* fix(arm64): unwind past PAC-signed return addresses

`strip_pac()` only strips with a mask, and nothing sets one. The
`__bionic_clear_pac_bits()` fallback was compiled out because it is
not in the NDK, so a signed return address ended the unwind.

Strip with `xpaclri` like bionic does, spelled as `hint #7` for
assemblers without Armv8.3-A support. It is a NOP on older CPUs.

Pixel 8 Pro (Tensor G3, Android 17), `abort()` through two
`-mbranch-protection=pac-ret` functions, unwound from a SIGABRT
handler like sentry-native's inproc backend.

Before:
    #00 pc 000000000007fdc0  .../libc.so (abort+160)
    #1 pc 006e8cdf7ce216d0  <unknown>

After:
    #00 pc 000000000007fdc0  .../libc.so (abort+160)
    #1 pc 000000000002867c  .../pac_test (pac_crash()+12)
    #2 pc 000000000002868c  .../pac_test (pac_caller()+12)
    #3 pc 0000000000028708  .../pac_test (main+120)
    #4 pc 000000000007183c  .../libc.so (__libc_init+124)

Ref: getsentry/sentry-native#2258

* link to arm developer docs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants