Commit 3c271d5e authored by Krzysztof Karas's avatar Krzysztof Karas Committed by Jim Harris
Browse files

scripts/bpf/trace.py: enable printing relations for NativeProvider



Currently the only way to see the relations, while using trace.py script,
is to feed it a JSON formatted file. This patch allows trace.py
to do the same for the for the binary trace files.

Change-Id: I7237896ede608080d3bec896a43586e34c297b04
Signed-off-by: default avatarKrzysztof Karas <krzysztof.karas@intel.com>
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/9906


Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: default avatarKonrad Sztyber <konrad.sztyber@gmail.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
parent 5594c7c8
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -405,10 +405,15 @@ class NativeProvider(TraceProvider):
            else:
                poller_id = None

            if pe.related_type != OBJECT_NONE:
                related = '{}{}'.format(self._objects[pe.related_type], pe.related_index)
            else:
                related = None

            yield TraceEntry(tpoint=tpoint, lcore=lcore, tsc=entry.tsc,
                             size=entry.size, object_id=object_id,
                             object_ptr=entry.object_id, poller=poller_id, time=ts,
                             args=args, related=None)
                             args=args, related=related)


class Trace: