This is an archive of the discontinued LLVM Phabricator instance.

[AArch64] Move FeatureSpecRestrict into core 8.0-R architecture.
ClosedPublic

Authored by simon_tatham on Mar 2 2022, 9:33 AM.

Details

Summary

It was included in HasV8_0rOps when D88660 first introduced that
architecture definition. In D118045 I moved it out of there and into
ProcessorFeatures.R82, so that -mcpu=cortex-r82 would continue to
behave the same as before but -march=armv8-r would include only the
mandatory parts of the architecture.

In fact, that was a mistake. Firstly, Cortex-R82 _doesn't_ implement
that feature, so it makes no sense to deliberately enable it for that
CPU in particular. But also, it's an extension that only adds system
registers, and we're generally more relaxed about where we enable
those (because kernel developers find it useful to write sysreg-access
instructions after runtime checking, and because sysreg accesses
aren't manufactured during code generation so the risk is small).

So, in line with that usual AArch64 policy, FeatureSpecRestrict ought
to be considered part of 8.0-R for LLVM purposes. So I'm moving it
back into HasV8_0rOps, where it started out.

Diff Detail

Event Timeline

simon_tatham created this revision.Mar 2 2022, 9:33 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 2 2022, 9:33 AM
simon_tatham requested review of this revision.Mar 2 2022, 9:33 AM
Herald added a project: Restricted Project. · View Herald TranscriptMar 2 2022, 9:33 AM
lenary accepted this revision.Mar 7 2022, 7:51 AM

LGTM. Sorry for the delay, this code is a minefield.

This revision is now accepted and ready to land.Mar 7 2022, 7:51 AM
This revision was landed with ongoing or failed builds.Mar 7 2022, 7:55 AM
This revision was automatically updated to reflect the committed changes.