Page MenuHomePhabricator

[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

TimeTest
1,600 msx64 debian > libarcher.races::task-dependency.c
Script: -- : 'RUN: at line 13'; /var/lib/buildkite-agent/builds/llvm-project/build/./bin/clang -fopenmp -pthread -fno-experimental-isel -g -O1 -fsanitize=thread -I /var/lib/buildkite-agent/builds/llvm-project/openmp/tools/archer/tests -I /var/lib/buildkite-agent/builds/llvm-project/build/projects/openmp/runtime/src -L /var/lib/buildkite-agent/builds/llvm-project/build/lib -Wl,-rpath,/var/lib/buildkite-agent/builds/llvm-project/build/lib /var/lib/buildkite-agent/builds/llvm-project/openmp/tools/archer/tests/races/task-dependency.c -o /var/lib/buildkite-agent/builds/llvm-project/build/projects/openmp/tools/archer/tests/races/Output/task-dependency.c.tmp -latomic && env TSAN_OPTIONS='ignore_noninstrumented_modules=0:ignore_noninstrumented_modules=1' /var/lib/buildkite-agent/builds/llvm-project/openmp/tools/archer/tests/deflake.bash /var/lib/buildkite-agent/builds/llvm-project/build/projects/openmp/tools/archer/tests/races/Output/task-dependency.c.tmp 2>&1 | tee /var/lib/buildkite-agent/builds/llvm-project/build/projects/openmp/tools/archer/tests/races/Output/task-dependency.c.tmp.log | /var/lib/buildkite-agent/builds/llvm-project/build/./bin/FileCheck /var/lib/buildkite-agent/builds/llvm-project/openmp/tools/archer/tests/races/task-dependency.c

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.