From d96c67b2bf887967e4a6656e5d152f49b5d04044 Mon Sep 17 00:00:00 2001 From: Rachida Kebichi Date: Fri, 17 Jul 2020 16:31:51 -0400 Subject: [PATCH] Dump memcpy info for hsa Change-Id: Ia7ae7f15939a5544f2e846afc049023cadcc0e62 [ROCm/rocprofiler commit: dabb49661bd3a3b81d0985b24b96593d4f411b63] --- projects/rocprofiler/bin/mem_manager.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/projects/rocprofiler/bin/mem_manager.py b/projects/rocprofiler/bin/mem_manager.py index d9ee301ff5..8b616cc6ca 100755 --- a/projects/rocprofiler/bin/mem_manager.py +++ b/projects/rocprofiler/bin/mem_manager.py @@ -122,10 +122,6 @@ class MemManager: tid = recvals[3] select_expr = '"Index" = ' + str(recordid) + ' AND "proc-id" = ' + str(procid) - async_copy_recvals = self.db.table_get_record('COPY', select_expr) #List of async copy record fields - async_copy_start_time = async_copy_recvals[0] - async_copy_end_time = async_copy_recvals[1] - async_copy_tid = async_copy_recvals[4] # hipMemcpy(void* dst, const void* src, size_t sizeBytes, hipMemcpyKind kind) hipMemcpy_ptrn = re.compile(r'\(dst\((.*)\) src\((.*)\) sizeBytes\((\d+)\).*\)') @@ -145,7 +141,11 @@ class MemManager: m_array = hipMemcpy_ptrn3.match(args) is_async = 1 if async_event_ptrn.search(event) else 0 - if is_async: tid = async_copy_tid + if is_async: + async_copy_recvals = self.db.table_get_record('COPY', select_expr) #List of async copy record fields + async_copy_start_time = async_copy_recvals[0] + async_copy_end_time = async_copy_recvals[1] + tid = async_copy_recvals[4] copy_line = '' size = 0