Page MenuHomeFreeBSD

Update -ftrivial-auto-var-init flags for clang >= 16 and gcc >= 12
ClosedPublic

Authored by dim on May 22 2023, 4:56 PM.
Tags
None
Referenced Files
F102855734: D40208.diff
Mon, Nov 18, 1:22 AM
Unknown Object (File)
Sat, Nov 9, 1:26 PM
Unknown Object (File)
Fri, Nov 1, 3:15 PM
Unknown Object (File)
Oct 6 2024, 1:22 AM
Unknown Object (File)
Oct 6 2024, 1:22 AM
Unknown Object (File)
Oct 6 2024, 1:02 AM
Unknown Object (File)
Sep 24 2024, 2:15 PM
Unknown Object (File)
Sep 24 2024, 4:09 AM
Subscribers

Details

Summary

As of clang 16, the -ftrivial-auto-var-init=zero option no longer needs
-enable-trivial-auto-var-init-zero-knowing-it-will-be-removed-from-clang
to enable the option. Only add it for older clang versions.

Also, now that gcc 12 and later supports -ftrivial-auto-var-init, add it
to bsd.compiler.mk's "init-all" feature.

PR: 271047
MFC after: 3 days

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 51601
Build 48492: arc lint + arc unit

Event Timeline

dim requested review of this revision.May 22 2023, 4:56 PM

IMO bsd.compiler.mk (enabling for GCC) can be committed separately

This revision is now accepted and ready to land.May 22 2023, 6:36 PM