-
Notifications
You must be signed in to change notification settings - Fork 30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for AMD Zen 4 processors #65
Open
sandip4n
wants to merge
8
commits into
intel:main
Choose a base branch
from
sandip4n:zen4-dev
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add capabilities for discovering uncore PMUs on modern AMD platforms and filtering events accordingly. The prefix used in the PMU name is "amd_" instead of "uncore_". The PMUs are also different. Co-developed-by: Phaneeshwar M <[email protected]> Signed-off-by: Sandipan Das <[email protected]>
Add initial support for collecting events on Zen 4 based AMD server SoCs codenamed "Genoa" and "Bergamo". The events used are defined in the "Guidance for Common Performance Statistics with Complex Event Selects" and "Guidance for Pipeline Utilization Analysis Statistics" tables in the Processor Programming Reference (PPR) for AMD Family 19h Model 11h, Revision B1 processors. Link: https://bugzilla.kernel.org/attachment.cgi?id=303986 Signed-off-by: Sandipan Das <[email protected]>
Add capabilities for filtering AMD uncore PMU events on the basis of the mode in which data was collected. Co-developed-by: Phaneeshwar M <[email protected]> Signed-off-by: Sandipan Das <[email protected]>
Add initial support for generating metrics on Zen 4 based AMD server SoCs codenamed "Genoa" and "Bergamo". The metrics used are defined in the "Guidance for Common Performance Statistics with Complex Event Selects" and "Guidance for Pipeline Utilization Analysis Statistics" tables in the Processor Programming Reference (PPR) for AMD Family 19h Model 11h, Revision B1 processors. Link: https://bugzilla.kernel.org/attachment.cgi?id=303986 Signed-off-by: Sandipan Das <[email protected]>
The metrics used in the HTML report can vary on the basis of the microarchitecture. The graphs can also be different. Hence, move the current base html as it only caters to Intel processors in preparation for adding support for processors from other vendors. Signed-off-by: Sandipan Das <[email protected]>
Add initial support for showing charts and graphs which specifically cater to Zen 4 based AMD server SoCs codenamed "Genoa" and "Bergamo". Signed-off-by: Sandipan Das <[email protected]>
The event encoding format for Data Fabric (amd_df) events has changed in Zen 4 processors such as Genoa and Bergamo. Even if an older kernel runs on these processors, it might be programming the counters incorrectly and this can lead to unexpected results. There is no easy way to detect this using kernel versions as distro kernels, while using an older base, may have backports of the upstream patches. Hence, use strict checks for the event and umask formats that the kernel advertises for the device. Signed-off-by: Sandipan Das <[email protected]>
On AMD platforms, uncore events will not be used in the following cases. * Running the tool inside a guest (VM). * Running the tool on bare-metal but without the "amd-uncore" driver. * Running the tool on bare-metal with the "amd-uncore" driver but it is found that the driver does not have the right level of support for the uncore PMUs specific to the processor. For all these cases, the tool assumes that it is running inside a VM and applies additional event filtering as seen in commit 9b62dfc ("limit cycles filter to vm only (not in older kernels)"). This breaks grouping if "cpu-cycles" is the last event in a group as such groups get merged with the next group because the entire line, which contains both the event and the group separator, is ignored. As a result, some groups are too large, as in, they have more events than the number of available hardware counters, and hence are invalid, or as perf tool reports, "<not supported>", as they can never be scheduled in. For such groups, redefine the cpu-cycles event as "ls_not_halted_cyc", its architectural alias, so that it does not get filtered out. Signed-off-by: Sandipan Das <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Add support for AMD Genoa and Bergamo processors (EPYC 4th generation) based on the Zen 4 microarchitecture. The series includes discovery of AMD uncore PMUs, addition of platform-specific events and metrics, reporting of these metrics and some paltform-specific quirks.