From: "Christian König" <ckoenig.leichtzumerken@gmail.com>
To: Chris Wilson <chris@chris-wilson.co.uk>,
dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org,
linaro-mm-sig@lists.linaro.org, linux-media@vger.kernel.org
Subject: Re: [PATCH 1/5] drm/i915: stop pruning reservation object after wait
Date: Tue, 6 Aug 2019 10:05:13 +0200 [thread overview]
Message-ID: <f8c213ea-a9ef-8ac1-39c0-0ea83ea2b118@gmail.com> (raw)
In-Reply-To: <156502405985.28464.7514823669359337891@skylake-alporthouse-com>
Am 05.08.19 um 18:54 schrieb Chris Wilson:
> Quoting Chris Wilson (2019-08-05 16:58:56)
>> Quoting Christian König (2019-08-05 16:45:50)
>>> The reservation object should be capable of handling its internal memory
>>> management itself. And since we search for a free slot to add the fence
>>> from the beginning this is actually a waste of time and only minimal helpful.
>> "From the beginning?" Attempting to prune signaled fences on insertion is
>> quite recent.
What I meant was from the beginning of the array :) Sorry for the confusion.
>> However, that doesn't help the cases where reservation_object keeps on
>> holding a reference to the fences for idle objects. It's an absolute
>> nightmare of a reference trap.
We only free up the fence objects, but not the array itself. And
userspace actually needs to call the wait function.
So to me this looks like it doesn't really helps much.
> Fwiw, it's a pet peeve, and not a fundamental object to removing some
> loops inside reservation_object. Here, the seqno is being used as a
> guide to avoid trying to take the lock if it's been externally modified,
> but it would equally work with just a plain trylock + test_rcu.
Ok, going to do this then for the meantime.
> Better yet would be autopruning, but that suggests a slightly different
> data structure an rbtree instead of an array and spinlocked cb_list
> manipulation instead of a plain refcount.
Yeah, that's exactly what I'm working on with this series.
Regards,
Christian.
> -Chris
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
prev parent reply other threads:[~2019-08-06 8:05 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-08-05 15:45 [PATCH 1/5] drm/i915: stop pruning reservation object after wait Christian König
2019-08-05 15:45 ` [PATCH 2/5] dma-buf: fix busy wait for new shared fences Christian König
2019-08-05 15:45 ` [PATCH 3/5] dma-buf: further relax reservation_object_add_shared_fence Christian König
2019-08-05 15:45 ` [PATCH 4/5] dma-buf: simplify reservation_object_get_fences_rcu a bit Christian König
2019-08-05 15:45 ` [PATCH 5/5] dma-buf: nuke reservation_object seq number Christian König
2019-08-05 16:07 ` Chris Wilson
2019-08-05 16:41 ` Daniel Vetter
2019-08-05 15:58 ` [PATCH 1/5] drm/i915: stop pruning reservation object after wait Chris Wilson
2019-08-05 16:54 ` Chris Wilson
2019-08-06 8:05 ` Christian König [this message]
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=f8c213ea-a9ef-8ac1-39c0-0ea83ea2b118@gmail.com \
--to=ckoenig.leichtzumerken@gmail.com \
--cc=chris@chris-wilson.co.uk \
--cc=christian.koenig@amd.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=linaro-mm-sig@lists.linaro.org \
--cc=linux-media@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).