Landing: 8add70670447

Project / Subsystem

gcc / x86

Date

2026-07-15

Author

H.J. Lu

Commit

8add706704470554130f04b63e6ea440a171b747

Source

github

Perf win

Yes

Breaking

No

All attributes

project
gcc
subsystem
x86
patch_id
commit_hash
8add706704470554130f04b63e6ea440a171b747
source_type
github
headline
x86: Avoid misaligned prologue if count <= epilogue size
tldr
Prevents misaligned prologue generation for small memory blocks on x86.
author
H.J. Lu
outcome
committed
performance_win
true
breaking_change
false
series_id
series_parts
[]
tags
  • x86
  • optimization
  • code generation
discussion_id_link
bugzilla_pr
date
2026-07-15T00:00:00.000Z

The x86 backend now prevents the use of a misaligned prologue when handling memory copy or set operations (ix86_expand_set_or_cpymem) if the block size is less than or equal to the epilogue size. This change addresses issues where vector instructions, designed for aligned data, could be used inappropriately on smaller blocks, potentially leading to performance degradation or incorrect behavior.