This is an archive of the discontinued LLVM Phabricator instance.

[ARM] Fix assembly and disassembly for VMRS/VMSR
ClosedPublic

Authored by avieira on Aug 4 2017, 4:57 AM.

Details

Summary

This patch addresses two issues with assembly and disassembly for VMRS/VMSR:

  1. currently VMRS/VMSR instructions accessing fpsid, mvfr{0-2} and fpexc, are accepted for non ARMv8-A targets.
  1. all VMRS/VMSR instructions accept writing/reading to PC and SP, when only ARMv7-A and ARMv8-A should be allowed to write/read to SP and none to PC.

This patch addresses those issues and adds tests for these cases.

Cheers,
Andre

Diff Detail

Event Timeline

avieira created this revision.Aug 4 2017, 4:57 AM
t.p.northover accepted this revision.Aug 4 2017, 1:48 PM
t.p.northover added a subscriber: t.p.northover.

Looks reasonable to me, though please remember to add llvm-commits as a subscriber next time.

Tim.

This revision is now accepted and ready to land.Aug 4 2017, 1:48 PM
This revision was automatically updated to reflect the committed changes.
avieira reopened this revision.Aug 21 2017, 4:01 AM

Reopening as this was reverted earlier, submitting new version.

This revision is now accepted and ready to land.Aug 21 2017, 4:01 AM
avieira updated this revision to Diff 111945.Aug 21 2017, 4:03 AM

Now only access to MVFR2 requires Armv8, both A and M profiles, all other instructions are available for any Arm architecture.

avieira requested review of this revision.Sep 21 2017, 8:27 AM
avieira edited edge metadata.

The new version of the patch hasnt been reviewed.

t.p.northover accepted this revision.Sep 22 2017, 1:16 AM
Thanks, this new one looks good too.
This revision is now accepted and ready to land.Sep 22 2017, 1:16 AM
This revision was automatically updated to reflect the committed changes.