Landing: 729eb68a0021

Project / Subsystem

gcc / tree-optimization

Date

2026-08-14

Author

Naveen

Commit

729eb68a0021bd37acff6a07a505b89687b974b9

Source

github

Perf win

Yes

Breaking

No

All attributes

project
gcc
subsystem
tree-optimization
patch_id
—
commit_hash
729eb68a0021bd37acff6a07a505b89687b974b9
source_type
github
headline
Fold canonicalized vector min/max conditionals
tldr
Improves optimization of vector min/max expressions with conditional operations.
author
Naveen
outcome
committed
performance_win
true
breaking_change
false
series_id
—
series_parts
[]
tags
  • • optimization
  • • vectorization
  • • SIMD
  • • pattern matching
discussion_id_link
—
bugzilla_pr
—
date
2026-08-14T00:00:00.000Z

This commit enhances GCC’s ability to optimize vector conditional expressions involving minimum and maximum operations. It introduces new pattern matching rules in match.pd to recognize canonicalized forms of VEC_COND_EXPR for min/max, including those resulting from negative signed maximums or positive signed/unsigned minimums. The optimization handles both normal and reversed conditional arms and works with uniform and non-uniform vector constants. New test cases validate the improvements.