Landing: 95c85b404da4
Project / Subsystem
gcc / eh
Date
2026-09-02
Author
Andrea Pinski
Commit
95c85b404da4fe6eea7b7f3b51e1270b77f0dab8
Source
github
Perf win
No
Breaking
No
All attributes
- project
- gcc
- subsystem
- eh
- patch_id
- —
- commit_hash
- 95c85b404da4fe6eea7b7f3b51e1270b77f0dab8
- source_type
- github
- headline
- eh: Use `lhs_could_trap_p` for non-call exceptions in assignment.
- tldr
- Improved exception handling for assignments involving the 'this' pointer by using more precise trapping checks.
- author
- Andrea Pinski
- outcome
- committed
- performance_win
- false
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • eh
- • exception handling
- • optimization
- • this pointer
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-09-02T00:00:00.000Z
The exception handling subsystem now correctly accounts for non-call exceptions that can occur on the left-hand side (LHS) of assignments, particularly when the this pointer is involved. Previously, a fix for PR127133 incorrectly marked the this argument as non-trapping, leading to an oversight in exception analysis. This commit replaces checks for tree_could_throw_p with lhs_could_trap_p and tree_could_throw_1 in lower_eh_constructs_2 and related functions, ensuring that potential trapping on the LHS is properly identified, fixing PR127183.