This is an archive of the discontinued LLVM Phabricator instance.

[Driver][FreeBSD] Correct driver behavior if a triple is provided without a version
ClosedPublic

Authored by brad on Feb 18 2023, 10:10 PM.

Details

Summary

While looking at other usage of getOSMajorVersion() I noticed if a version number is not included in the FreeBSD triple it won't include the --hash-style=both linker option or not disable the use of .init_array. Without a version should be the latest.

FreeBSD 8 and 9 are no longer supported. So simplify things with the version handling as well.

Diff Detail

Event Timeline

brad created this revision.Feb 18 2023, 10:10 PM
Herald added a project: Restricted Project. · View Herald TranscriptFeb 18 2023, 10:10 PM
brad requested review of this revision.Feb 18 2023, 10:10 PM
brad retitled this revision from [Driver][FreeBSD] to [Driver][FreeBSD] Correct usage of --hash-style=both with triple without version.Feb 18 2023, 10:11 PM
brad updated this revision to Diff 498980.Feb 20 2023, 4:55 PM
brad retitled this revision from [Driver][FreeBSD] Correct usage of --hash-style=both with triple without version to [Driver][FreeBSD] Correct driver behavior if a triple is provided without a version.Feb 20 2023, 4:59 PM
brad edited the summary of this revision. (Show Details)

LGTM, but I'll let @dim and @emaste decide if FreeBSD 8 code is still needed.

brad updated this revision to Diff 499055.Feb 21 2023, 12:37 AM
brad edited the summary of this revision. (Show Details)
dim accepted this revision.Feb 21 2023, 2:04 AM

LGTM, but I'll let @dim and @emaste decide if FreeBSD 8 code is still needed.

No, these versions are ancient now and very much unsupported. So this is a nice cleanup! At the moment 12.x is the oldest supported version so the >= 12 checks should stay for a while.

This revision is now accepted and ready to land.Feb 21 2023, 2:04 AM
This revision was landed with ongoing or failed builds.Feb 21 2023, 11:14 AM
This revision was automatically updated to reflect the committed changes.