Landing: 87c97883d659

Project / Subsystem

gcc / match.pd

Date

2026-07-30

Author

Kyrylo Tkachov

Commit

87c97883d659edc4b6d5cbece74d7ab7a3584a75

Source

github

Perf win

Yes

Breaking

No

All attributes

project
gcc
subsystem
match.pd
patch_id
—
commit_hash
87c97883d659edc4b6d5cbece74d7ab7a3584a75
source_type
github
headline
match.pd: Simplify promoted saturating arithmetic operations
tldr
Optimizes saturating addition and subtraction operations on promoted types, reducing instruction count.
author
Kyrylo Tkachov
outcome
committed
performance_win
true
breaking_change
false
series_id
—
series_parts
[]
tags
  • • optimization
  • • AArch64
  • • vectorization
discussion_id_link
—
bugzilla_pr
—
date
2026-07-30T00:00:00.000Z

This change simplifies specific patterns of promoted saturating addition and subtraction operations in the match.pd system. It rewrites operations involving intermediate wide types and clamping into more direct, narrower forms. This reduces the number of instructions generated, especially for vector types, leading to improved performance on targets like AArch64.