GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Skip GNU backtrace test on Arm 32-bit by diegorusso · Pull Request #149493 · python/cpython

Conversation

@diegorusso

@diegorusso diegorusso commented May 7, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor

backtrace() and GDB use different unwinding paths.

On AArch64, runtime unwinding normally uses DWARF CFI in .eh_frame / .eh_frame_hdr.
On 32-bit ARM EABI, the runtime unwind format is .ARM.exidx / .ARM.extab, as specified by the Arm EHABI (https://github.com/ARM-software/abi-aa/blob/main/ehabi32/ehabi32.rst#the-object-producer-interface)

GDB can still unwind the 32-bit ARM binary because it can read debugger-only DWARF CFI from .debug_frame, while glibc backtrace() runs inside the process and needs runtime unwind metadata.

Without -funwind-tables, the 32-bit ARM build has effectively empty runtime unwind metadata:

  .ARM.exidx contains 1 entry:
    _start: cantunwind

With -funwind-tables, GCC emits the ARM EHABI runtime unwind tables needed by backtrace().
GCC documents -funwind-tables as generating the needed static unwind data without otherwise changing generated code.

This PR skips the GNU backtrace unwind test only on 32-bit Arm builds that lack -funwind-tables, instead of skipping all 32-bit Arm builds.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@diegorusso
Skip GNU backtrace test on Arm 32-bit without unwind tables
3358e2d
backtrace() on 32-bit ARM EABI depends on runtime unwind tables
emitted as .ARM.exidx/.ARM.extab. Without -funwind-tables,
glibc can return an empty stack even though GDB can still unwind using
debug-only .debug_frame data.

Only skip the GNU backtrace unwind test on Arm 32-bit builds that lack
-funwind-tables, instead of skipping all Arm 32-bit builds.
@bedevere-app bedevere-app Bot added tests Tests in the Lib/test dir awaiting core review labels May 7, 2026
@diegorusso diegorusso added skip issue skip news labels May 7, 2026
@encukou

encukou commented May 7, 2026

Copy link
Copy Markdown
Member

!buildbot ARM Raspbian

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-bot

bedevere-bot commented May 7, 2026

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @encukou for commit 3358e2d 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F149493%2Fmerge

The command will test the builders whose names match following regular expression: ARM Raspbian

The builders matched are:

  • ARM Raspbian PR
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@diegorusso
diegorusso requested a review from pablogsal May 7, 2026 12:43
@diegorusso diegorusso mentioned this pull request May 7, 2026
gh-149202: Fix frame pointer unwinding on ppc64le and armv7/clang #149409
Merged
@diegorusso

diegorusso commented May 7, 2026

Copy link
Copy Markdown
Contributor Author

still failing...

encukou reacted with confused emoji
All reactions
  • 😕 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

encukou
encukou reviewed May 7, 2026
View reviewed changes
Comment thread Lib/test/test_frame_pointer_unwind.py Outdated


def _gnu_backtrace_requires_unwind_tables(machine):
if not (sys.maxsize < 2**32 and machine.startswith("arm")):

@encukou encukou May 7, 2026 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

AFAIK it's an aarch64 machine, with a 32-bit Python build?

Suggested change
if not (sys.maxsize < 2**32 and machine.startswith("arm")):
if not (sys.maxsize < 2**32 and machine.startswith(("arm", "aarch"))):

But we're deep into overfitting to Buildbot workers here :/

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@diegorusso diegorusso May 7, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mmm I don't think this is the right approach. We need to base the condition about the build of Python

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@diegorusso
Refine ARM GNU backtrace unwind-table detection
cb52a24
@diegorusso

diegorusso commented May 7, 2026

Copy link
Copy Markdown
Contributor Author

!buildbot ARM Raspbian

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-bot

bedevere-bot commented May 7, 2026

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @diegorusso for commit cb52a24 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F149493%2Fmerge

The command will test the builders whose names match following regular expression: ARM Raspbian

The builders matched are:

  • ARM Raspbian PR
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

encukou
encukou reviewed May 7, 2026
View reviewed changes
Comment thread Lib/test/test_frame_pointer_unwind.py Outdated
Comment on lines +118 to +130
for option in options:
if option == "-funwind-tables":
unwind_tables = True
elif option == "-fno-unwind-tables":
unwind_tables = False
elif option == "-fasynchronous-unwind-tables":
asynchronous_unwind_tables = True
elif option == "-fno-asynchronous-unwind-tables":
asynchronous_unwind_tables = False
elif option == "-fexceptions":
exceptions = True
elif option == "-fno-exceptions":
exceptions = False

@encukou encukou May 7, 2026

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's a lot of untested logic.
Should we skip the test for any 32-bit Arm?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@diegorusso diegorusso May 7, 2026

Copy link
Copy Markdown
Contributor Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tend to agree with you. On Arm 32bit you can have unwind data with any of these flags: -funwind-tables, -fasynchronous-unwind-tables, -fexceptions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

encukou reacted with thumbs up emoji
All reactions
  • 👍 1 reaction
@diegorusso
Skip GNU backtrace tests on 32-bit Arm
61015e1
GNU backtrace() can return an empty stack on 32-bit Arm
when the build lacks suitable runtime unwind tables.
Rather than trying to infer the effective unwind-table
compiler flags in the test, skip the GNU backtrace tests
on all 32-bit Arm builds.
@diegorusso

diegorusso commented May 7, 2026

Copy link
Copy Markdown
Contributor Author

!buildbot ARM Raspbian

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-bot

bedevere-bot commented May 7, 2026

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @diegorusso for commit 61015e1 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F149493%2Fmerge

The command will test the builders whose names match following regular expression: ARM Raspbian

The builders matched are:

  • ARM Raspbian PR
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@diegorusso
Merge branch 'main' into backtrace-arm
04bd87a
@diegorusso

diegorusso commented May 7, 2026

Copy link
Copy Markdown
Contributor Author

!buildbot ARM Raspbian

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@StanFromIreland

StanFromIreland commented May 7, 2026

Copy link
Copy Markdown
Member

Updating to fix some errors we introduced on the main branch.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@StanFromIreland
Merge branch 'main' into backtrace-arm
42177ce
@diegorusso

diegorusso commented May 8, 2026

Copy link
Copy Markdown
Contributor Author

!buildbot ARM Raspbian

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-bot

bedevere-bot commented May 8, 2026

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @diegorusso for commit 42177ce 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F149493%2Fmerge

The command will test the builders whose names match following regular expression: ARM Raspbian

The builders matched are:

  • ARM Raspbian PR
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@diegorusso
diegorusso requested a review from markshannon May 8, 2026 10:36
markshannon
markshannon approved these changes May 8, 2026
View reviewed changes

@markshannon markshannon left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good, and much simpler now

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@bedevere-app bedevere-app Bot added awaiting merge and removed awaiting core review labels May 8, 2026
@diegorusso diegorusso changed the title Skip GNU backtrace test on Arm 32-bit without unwind tables Skip GNU backtrace test on Arm 32-bit May 8, 2026
@diegorusso
diegorusso merged commit 2a8cece into python:main May 8, 2026
54 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-app bedevere-app Bot removed the awaiting merge label May 8, 2026
@diegorusso diegorusso added the needs backport to 3.15 bugs and security fixes label May 8, 2026
@miss-islington-app

miss-islington-app Bot commented May 8, 2026

Copy link
Copy Markdown

Thanks @diegorusso for the PR 🌮🎉.. I'm working now to backport this PR to: 3.15.
🐍🍒⛏🤖

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-app

bedevere-app Bot commented May 8, 2026

Copy link
Copy Markdown

GH-149562 is a backport of this pull request to the 3.15 branch.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-app bedevere-app Bot removed the needs backport to 3.15 bugs and security fixes label May 8, 2026
@diegorusso
diegorusso deleted the backtrace-arm branch May 8, 2026 13:07
diegorusso pushed a commit that referenced this pull request May 8, 2026
@miss-islington
[3.15] Skip GNU backtrace test on Arm 32-bit (GH-149493) (#149562)
54a187d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@encukou encukou encukou left review comments
@markshannon markshannon markshannon approved these changes
@pablogsal pablogsal Awaiting requested review from pablogsal

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

skip issue skip news tests Tests in the Lib/test dir

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

5 participants

@diegorusso @encukou @bedevere-bot @StanFromIreland @markshannon
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.