From: Daniel Vetter <daniel@ffwll.ch>
To: Chris Wilson <chris@chris-wilson.co.uk>,
Daniel Vetter <daniel@ffwll.ch>,
Michel Thierry <michel.thierry@intel.com>,
intel-gfx@lists.freedesktop.org
Subject: Re: [RFC 00/38] PPGTT dynamic page allocations
Date: Wed, 5 Nov 2014 10:19:47 +0100 [thread overview]
Message-ID: <20141105091947.GV26941@phenom.ffwll.local> (raw)
In-Reply-To: <20141104130109.GP13658@nuc-i3427.alporthouse.com>
On Tue, Nov 04, 2014 at 01:01:09PM +0000, Chris Wilson wrote:
> On Tue, Nov 04, 2014 at 01:44:47PM +0100, Daniel Vetter wrote:
> > On Wed, Oct 08, 2014 at 08:13:33AM +0100, Chris Wilson wrote:
> > > On Tue, Oct 07, 2014 at 06:10:56PM +0100, Michel Thierry wrote:
> > > > This is based on the first 55 patches of Ben's 48b addressing work, taking
> > > > into consideration the latest changes in (mainly aliasing) ppgtt rules.
> > > >
> > > > Because of these changes in the tree, the first 17 patches of the original
> > > > series are no longer needed, and some patches required more rework than others.
> > > >
> > > > For GEN8, it has also been extended to work in logical ring submission (lrc)
> > > > mode, as it looks like it will be the preferred mode of operation.
> > > > I also tried to update the lrc code at the same time the ppgtt refactoring
> > > > occurred, leaving only one patch that is exclusively for lrc.
> > > >
> > > > I'm asking for comments, as this is the foundation for 48b virtual addressing
> > > > in Broadwell.
> > >
> > > I find the lack of activity tracking in the current ppgtt design severely
> > > limiting. We have a number of tests (both igt and mesa) that fail
> > > because the ppgtt pins gtt space for its lifetime. Transitioning the
> > > backing pages to a bo allows us to evict, and even shrink, vm along with
> > > regular objects. Plus the dynamic allocation here has also been
> > > discussed with the idea of sparse allocation of bo... Imo, we want to
> > > use bo (probably based on gemfs) for both.
> >
> > Picking up an old story ... I guess you're talking about the PD
> > reservation ppgtt needs on gen7 and which is stolen from the GGTT?
> >
> > One totally crazy idea I've had is to add an ->evict function to the vma
> > and just use the vma to track this stuff, with no object attached. That
> > should be enough for the shrinker, presuming we wrap enough code into the
> > optional ->evict callback. By default it'd do the normal bo evict. And
> > with a vfunc ->evict we could also subsume the pageflip stall and ctx
> > switch tricks into the same infrastructure.
> >
>
> Strangely enough, it already only uses the vma... It is simplest though
> just to reuse an obj to store the pages and dma addresses (reusing the
> common code), which then ties directly into the evicter over the GGTT,
> and shrinker for normal RAM. The only trick you then need is to create a
> special vma for the pde in ggtt. After my initial concern, with a little
> bit of care using the shmemfs for allocation is only marginally slower
> than alloc_page(). I am not yet convinced about teaching evict/shrink
> new tricks (or specialising the hammers).
Well the new trick would have been used mostly for pageflip and ctx
objects. But maybe not worth the trouble since especially with pageflips
that special type is interim ... We could abuse Tvrtko's ggtt_view stuff
though and hand out special ids for ppgtt pdes and act accordingly.
-Daniel
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2014-11-05 9:19 UTC|newest]
Thread overview: 53+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-07 17:10 [RFC 00/38] PPGTT dynamic page allocations Michel Thierry
2014-10-07 17:10 ` [RFC 01/38] drm/i915: Add some extra guards in evict_vm Michel Thierry
2014-10-08 13:36 ` Daniel Vetter
2014-10-07 17:10 ` [RFC 02/38] drm/i915/trace: Fix offsets for 64b Michel Thierry
2014-10-07 17:10 ` [RFC 03/38] drm/i915: Wrap VMA binding Michel Thierry
2014-10-07 17:11 ` [RFC 04/38] drm/i915: Make pin global flags explicit Michel Thierry
2014-10-08 13:36 ` Daniel Vetter
2014-10-07 17:11 ` [RFC 05/38] drm/i915: Split out aliasing binds Michel Thierry
2014-10-08 13:41 ` Daniel Vetter
2014-10-07 17:11 ` [RFC 06/38] drm/i915: fix gtt_total_entries() Michel Thierry
2014-10-08 13:52 ` Daniel Vetter
2014-10-07 17:11 ` [RFC 07/38] drm/i915: Rename to GEN8_LEGACY_PDPES Michel Thierry
2014-10-07 17:11 ` [RFC 08/38] drm/i915: Split out verbose PPGTT dumping Michel Thierry
2014-10-07 17:11 ` [RFC 09/38] drm/i915: s/pd/pdpe, s/pt/pde Michel Thierry
2014-10-08 13:55 ` Daniel Vetter
2014-10-07 17:11 ` [RFC 10/38] drm/i915: rename map/unmap to dma_map/unmap Michel Thierry
2014-10-07 17:11 ` [RFC 11/38] drm/i915: Setup less PPGTT on failed pagedir Michel Thierry
2014-10-07 17:11 ` [RFC 12/38] drm/i915: Un-hardcode number of page directories Michel Thierry
2014-10-07 17:11 ` [RFC 13/38] drm/i915: Make gen6_write_pdes gen6_map_page_tables Michel Thierry
2014-10-08 14:04 ` Daniel Vetter
2014-10-07 17:11 ` [RFC 14/38] drm/i915: Range clearing is PPGTT agnostic Michel Thierry
2014-10-07 17:11 ` [RFC 15/38] drm/i915: Page table helpers, and define renames Michel Thierry
2014-10-07 17:11 ` [RFC 16/38] drm/i915: construct page table abstractions Michel Thierry
2014-10-07 17:11 ` [RFC 17/38] drm/i915: Complete page table structures Michel Thierry
2014-10-07 17:11 ` [RFC 18/38] drm/i915: Create page table allocators Michel Thierry
2014-10-07 17:11 ` [RFC 19/38] drm/i915: Generalize GEN6 mapping Michel Thierry
2014-10-07 17:11 ` [RFC 20/38] drm/i915: Clean up pagetable DMA map & unmap Michel Thierry
2014-10-07 17:11 ` [RFC 21/38] drm/i915: Always dma map page table allocations Michel Thierry
2014-10-07 17:11 ` [RFC 22/38] drm/i915: Consolidate dma mappings Michel Thierry
2014-10-07 17:11 ` [RFC 23/38] drm/i915: Always dma map page directory allocations Michel Thierry
2014-10-07 17:11 ` [RFC 24/38] drm/i915: Track GEN6 page table usage Michel Thierry
2014-10-07 17:11 ` [RFC 25/38] drm/i915: Extract context switch skip logic Michel Thierry
2014-10-07 17:11 ` [RFC 26/38] drm/i915: Track page table reload need Michel Thierry
2014-10-07 17:11 ` [RFC 27/38] drm/i915: Initialize all contexts Michel Thierry
2014-10-07 17:11 ` [RFC 28/38] drm/i915: Finish gen6/7 dynamic page table allocation Michel Thierry
2014-10-07 17:11 ` [RFC 29/38] drm/i915/bdw: Use dynamic allocation idioms on free Michel Thierry
2014-10-07 17:11 ` [RFC 30/38] drm/i915/bdw: pagedirs rework allocation Michel Thierry
2014-10-07 17:11 ` [RFC 31/38] drm/i915/bdw: pagetable allocation rework Michel Thierry
2014-10-07 17:11 ` [RFC 32/38] drm/i915/bdw: Make the pdp switch a bit less hacky Michel Thierry
2014-10-07 17:11 ` [RFC 33/38] drm/i915: num_pd_pages/num_pd_entries isn't useful Michel Thierry
2014-10-07 17:11 ` [RFC 34/38] drm/i915: Extract PPGTT param from pagedir alloc Michel Thierry
2014-10-07 17:11 ` [RFC 35/38] drm/i915/bdw: Split out mappings Michel Thierry
2014-10-07 17:11 ` [RFC 36/38] drm/i915/bdw: begin bitmap tracking Michel Thierry
2014-10-07 17:11 ` [RFC 37/38] drm/i915/bdw: Dynamic page table allocations Michel Thierry
2014-10-07 17:11 ` [RFC 38/38] drm/i915/bdw: Dynamic page table allocations in lrc mode Michel Thierry
2014-10-08 7:13 ` [RFC 00/38] PPGTT dynamic page allocations Chris Wilson
2014-11-04 12:44 ` Daniel Vetter
2014-11-04 13:01 ` Chris Wilson
2014-11-05 9:19 ` Daniel Vetter [this message]
2014-11-05 9:50 ` Chris Wilson
2014-11-05 9:58 ` Chris Wilson
2014-11-04 12:54 ` Daniel Vetter
2014-11-04 16:29 ` Michel Thierry
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=20141105091947.GV26941@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=chris@chris-wilson.co.uk \
--cc=intel-gfx@lists.freedesktop.org \
--cc=michel.thierry@intel.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox