Landing: 6d5d980f76c3
Project / Subsystem
gcc / match.pd
Date
2026-07-16
Author
Philipp Tomsich
Commit
6d5d980f76c3057cc90b1343a679e7eea3ad2a50
Source
github
Perf win
No
Breaking
No
All attributes
- project
- gcc
- subsystem
- match.pd
- patch_id
- —
- commit_hash
- 6d5d980f76c3057cc90b1343a679e7eea3ad2a50
- source_type
- github
- headline
- match.pd: Make vector abs conversion rules float-safe.
- tldr
- Vector abs conversion rules use element precision to prevent compiler crashes.
- author
- Philipp Tomsich
- outcome
- committed
- performance_win
- false
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • optimization
- • match.pd
- • vector
- • floating-point
- • bugfix
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-07-16T00:00:00.000Z
This commit makes the match.pd optimization rules for vectorized absolute value (abs) conversions safe for floating-point types. Previously, these rules evaluated TYPE_PRECISION on vector types after a conversion, leading to an Internal Compiler Error (ICE) during optimization. By switching to element_precision and adding a check for target support of ABS on the narrow vector type, the compiler can now correctly transform these operations without crashing. This fix ensures that conversions from narrower to wider vector types followed by an abs operation are handled robustly.