All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v5 0/11] HMM profiler interface
@ 2022-06-28 14:50 Philip Yang
  2022-06-28 14:50 ` [PATCH v5 1/11] drm/amdkfd: Add KFD SMI event IDs and triggers Philip Yang
                   ` (10 more replies)
  0 siblings, 11 replies; 20+ messages in thread
From: Philip Yang @ 2022-06-28 14:50 UTC (permalink / raw)
  To: amd-gfx; +Cc: Philip Yang, Felix.Kuehling

This implements KFD profiling APIs to expose HMM migration and 
recoverable page fault profiling data. The ROCm profiler will shared 
link with application, to collect and expose the profiling data to 
application developers to tune the applications based on how the address 
range attributes affect the behavior and performance. Kernel perf and 
ftrace requires superuser permission to collect data, it is not suitable 
for ROCm profiler.

The profiling data is per process per device event uses the existing SMI 
(system management interface) event API. Each event log is one line of 
text with the event specific information.

For user space usage example:
patch 9/11, 10/11 Thunk libhsakmt is based on
https://github.com/RadeonOpenCompute/ROCT-Thunk-Interface

patch 11/11 ROCr Basic-SVM-profiler patch is based on
https://github.com/RadeonOpenCompute/ROCR-Runtime

v5:
 * Fix multi-thead profiling support
 * Added user space usage example Thunk and ROCr patch

v4:
 * Add event helper function
 * Rebase to 5.16 kernel

v3:
 * Changes from Felix's review

v2:
 * Keep existing events behaviour
 * Use ktime_get_boottime_ns() as timestamp to correlate with other APIs
 * Use compact message layout, stick with existing message convention
 * Add unmap from GPU event

Philip Yang (8):
  drm/amdkfd: Add KFD SMI event IDs and triggers
  drm/amdkfd: Enable per process SMI event
  drm/amdkfd: Add GPU recoverable fault SMI event
  drm/amdkfd: Add migration SMI event
  drm/amdkfd: Add user queue eviction restore SMI event
  drm/amdkfd: Add unmap from GPU SMI event
  drm/amdkfd: Asynchronously free smi_client
  drm/amdkfd: Bump KFD API version for SMI profiling event

 drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.h    |   2 +-
 .../gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c  |  12 +-
 drivers/gpu/drm/amd/amdkfd/kfd_chardev.c      |   4 +-
 drivers/gpu/drm/amd/amdkfd/kfd_device.c       |   4 +-
 drivers/gpu/drm/amd/amdkfd/kfd_migrate.c      |  53 +++++--
 drivers/gpu/drm/amd/amdkfd/kfd_migrate.h      |   5 +-
 drivers/gpu/drm/amd/amdkfd/kfd_priv.h         |   2 +-
 drivers/gpu/drm/amd/amdkfd/kfd_process.c      |  15 +-
 drivers/gpu/drm/amd/amdkfd/kfd_smi_events.c   | 134 ++++++++++++++++--
 drivers/gpu/drm/amd/amdkfd/kfd_smi_events.h   |  21 ++-
 drivers/gpu/drm/amd/amdkfd/kfd_svm.c          |  64 ++++++---
 drivers/gpu/drm/amd/amdkfd/kfd_svm.h          |   2 +-
 include/uapi/linux/kfd_ioctl.h                |  40 +++++-
 13 files changed, 293 insertions(+), 65 deletions(-)


^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2022-06-30 14:54 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-06-28 14:50 [PATCH v5 0/11] HMM profiler interface Philip Yang
2022-06-28 14:50 ` [PATCH v5 1/11] drm/amdkfd: Add KFD SMI event IDs and triggers Philip Yang
2022-06-30 14:46   ` Felix Kuehling
2022-06-28 14:50 ` [PATCH v5 2/11] drm/amdkfd: Enable per process SMI event Philip Yang
2022-06-28 14:50 ` [PATCH v5 3/11] drm/amdkfd: Add GPU recoverable fault " Philip Yang
2022-06-30 14:19   ` Felix Kuehling
2022-06-30 14:53     ` philip yang
2022-06-28 14:50 ` [PATCH v5 4/11] drm/amdkfd: Add migration " Philip Yang
2022-06-30 14:29   ` Felix Kuehling
2022-06-28 14:50 ` [PATCH v5 5/11] drm/amdkfd: Add user queue eviction restore " Philip Yang
2022-06-30 14:36   ` Felix Kuehling
2022-06-28 14:50 ` [PATCH v5 6/11] drm/amdkfd: Add unmap from GPU " Philip Yang
2022-06-30 14:39   ` Felix Kuehling
2022-06-28 14:50 ` [PATCH v5 7/11] drm/amdkfd: Asynchronously free smi_client Philip Yang
2022-06-30 14:45   ` Felix Kuehling
2022-06-28 14:50 ` [PATCH v5 8/11] drm/amdkfd: Bump KFD API version for SMI profiling event Philip Yang
2022-06-30 14:45   ` Felix Kuehling
2022-06-28 14:50 ` [PATCH 9/11] libhsakmt: hsaKmtGetNodeProperties add gpu_id Philip Yang
2022-06-28 14:50 ` [PATCH 10/11] libhsakmt: add open SMI event handle Philip Yang
2022-06-28 14:50 ` [PATCH 11/11] ROCR-Runtime Basic SVM profiler Philip Yang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.