From: Tom St Denis <tom.stdenis-5C7GfCeVMHo@public.gmane.org>
To: amd-gfx mailing list
<amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org>
Subject: umr can now VM decode on systems with IOMMU enabled
Date: Tue, 8 Aug 2017 13:22:33 -0400 [thread overview]
Message-ID: <879a425c-2705-8ab4-307c-135023e98912@amd.com> (raw)
Hi all,
I've pushed changes to umr (master) and our linux (amd-staging-4.12
should be on
https://cgit.freedesktop.org/~agd5f/linux/log/?h=amd-staging-4.12
soonish) trees that allow in limited circumstances to VM decode through
IOMMU which has been tested for both iommu active and inactive.
umr previously could not fully resolve addresses when IOMMU is active
since the GPU is programmed with dma mapped addresses. As such reading
IBs or shaders or VM decoding in general would fail.
The change to the kernel adds a tracepoint which logs all dma map/unmap
operations (via the TTM) which umr can read and use to access physical
memory behind the mappings.
To enable this you need to enable two trace points:
echo 1 >
/sys/kernel/debug/tracing/events/amdgpu/amdgpu_ttm_tt_populate/enable
echo 1 >
/sys/kernel/debug/tracing/events/amdgpu/amdgpu_ttm_tt_unpopulate/enable
You need to enable the traces before running your test case/application.
If the trace file can't hold enough for your application you can tail it
to ~/trace which umr will read preferentially (make sure you delete this
file when done or you will be reading old mappings).
cat /sys/kernel/debug/tracing/trace_pipe > ~/trace
umr can process the traces fairly quickly (at about 1,500,000+ lines/sec
on my Carrizo...) so theoretically heavy workloads should be manageable.
The traces contain PCI information which umr uses to match mappings so
multiple GPU systems should work fine as well. Though testing would be
appreciated.
Cheers,
Tom
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
reply other threads:[~2017-08-08 17:22 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=879a425c-2705-8ab4-307c-135023e98912@amd.com \
--to=tom.stdenis-5c7gfcevmho@public.gmane.org \
--cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.