close
Skip to content

Processwatch: Add support for AMD Zen processors#13

Merged
matthew-olson-intel merged 1 commit into
intel:mainfrom
BangoriaRavi:main
May 1, 2024
Merged

Processwatch: Add support for AMD Zen processors#13
matthew-olson-intel merged 1 commit into
intel:mainfrom
BangoriaRavi:main

Conversation

@BangoriaRavi
Copy link
Copy Markdown

Processwatch uses software pmu cpu-clock event if it fails to detect the architecture. Although it works, cpu-clock event is imprecise. On AMD, ibs_op// pmu provides precise sampling, so port Processwatch to use ibs_op// on AMD platforms.

Processwatch uses software pmu cpu-clock event if it fails to detect
the architecture. Although it works, cpu-clock event is imprecise. On
AMD, ibs_op// pmu provides precise sampling, so port Processwatch to
use ibs_op// on AMD.

Notes:
o Processwatch with systemwide mode is supported with all versions of
  kernel. However, IBS on Linux supports per-process sampling only with
  v6.2 and later kernels. Thus processwatch with per-process mode
  (--pid=[pid] / -p option) is supported only with v6.2 and later.
o Processwatch fails to run with "WARNING: CPU xxx is offline." on AMD
  machines where some cores fused off in the hw. The issue is with how
  kernel exposes number of possible cpus in the sysfs. Below kernel
  patches fixed the issue.
  v5.16  aa06e20f1be6 ("x86/ACPI: Don't add CPUs that are not online
                        capable")
  v6.3   e2869bd7af60 ("x86/acpi/boot: Do not register processors that
                        cannot be onlined for x2APIC")
o Currently IBS is not supported in KVM guest and thus Processwatch
  falls back to cpu-clock event when run inside the KVM guest.
o TMA support is not added for AMD.

Signed-off-by: Ravi Bangoria <ravi.bangoria@amd.com>
Copy link
Copy Markdown
Contributor

@matthew-olson-intel matthew-olson-intel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks great! Thanks for doing this. I don't have access to a system to test it right now, but I'll take your word for it ;D

@matthew-olson-intel matthew-olson-intel merged commit ba83379 into intel:main May 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants