This is an archive of the discontinued LLVM Phabricator instance.

[AArch64][MC] Merge FeaturePMU into FeaturePerfMon
ClosedPublic

Authored by vhscampos on Sep 3 2021, 10:00 AM.

Details

Summary

FeaturePMU was created in AArch64 to accommodate one missing system
register, PMMIR_EL1, in commit ffcd7698aea7bcbb2b4edffc484793e1ff47b85d.

However, the Performance Monitors extension already had a target
feature, which is called FeaturePerfMon. Therefore, FeaturePMU is
redundant.

This patch removes FeaturePMU and merges its contents into
FeaturePerfMon.

Diff Detail

Unit TestsFailed

Event Timeline

vhscampos created this revision.Sep 3 2021, 10:00 AM
vhscampos requested review of this revision.Sep 3 2021, 10:00 AM
Herald added a project: Restricted Project. · View Herald TranscriptSep 3 2021, 10:00 AM
dnsampaio accepted this revision.Sep 3 2021, 1:24 PM

LGTM.

This revision is now accepted and ready to land.Sep 3 2021, 1:24 PM
This revision was landed with ongoing or failed builds.Sep 6 2021, 6:57 AM
This revision was automatically updated to reflect the committed changes.

Sorry to ask about an already-closed ticket, but: it looks like this makes the register unconditionally available, rather than making it conditional on FeaturePerfMon. Is that the intended behaviour? GNU as does still require v8.4 for this register.

Also, I think the register should be marked read-only rather than read-write.

Hi. Yes, it is intended behaviour. New system registers are usually available unconditionally. Typically only instructions are conditioned on target features.

For example, all the remaining PMU system registers are widely available.

About being read-only, it seems you are right. This is a bug. Thanks for noticing.

llvm/test/MC/AArch64/basic-a64-instructions.s