Landing: 2502a459db59
Project / Subsystem
gcc / gcc
Date
2026-02-10
Author
Christopher Bazley
Commit
2502a459db595905f6406b7994a27729c1e99a1d
Source
github
Perf win
No
Breaking
No
All attributes
- project
- gcc
- subsystem
- gcc
- patch_id
- —
- commit_hash
- 2502a459db595905f6406b7994a27729c1e99a1d
- source_type
- github
- headline
- Adds warnings for potentially-uninitialized padding bits.
- tldr
- Introduces `-Wzero-init-padding-bits=` to warn about code relying on zero-initialized padding, following a change in default behavior.
- author
- Christopher Bazley
- outcome
- committed
- performance_win
- false
- breaking_change
- false
- series_id
- —
- series_parts
- []
- tags
-
- • warning
- • padding
- • initialization
- • compatibility
- discussion_id_link
- —
- bugzilla_pr
- —
- date
- 2026-02-10T00:00:00.000Z
Following a change that reduced the zeroing of union padding bits, this commit introduces the -Wzero-init-padding-bits= warning. This warning helps programmers identify code that might need recompilation with -fzero-init-padding-bits=unions or -fzero-init-padding-bits=all to maintain compatibility with older GCC versions or to ensure padding is explicitly zero-initialized.