From: Tvrtko Ursulin <tvrtko.ursulin@linux.intel.com>
To: bradley.d.volkin@intel.com, intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915: Use hash tables for the command parser
Date: Mon, 12 May 2014 15:49:02 +0100 [thread overview]
Message-ID: <5370DF5E.5020808@linux.intel.com> (raw)
In-Reply-To: <1399756243-30974-1-git-send-email-bradley.d.volkin@intel.com>
On 05/10/2014 10:10 PM, bradley.d.volkin@intel.com wrote:
> From: Brad Volkin <bradley.d.volkin@intel.com>
>
> For clients that submit large batch buffers the command parser has
> a substantial impact on performance. On my HSW ULT system performance
> drops as much as ~20% on some tests. Most of the time is spent in the
> command lookup code. Converting that from the current naive search to
> a hash table lookup reduces the performance drop to ~10%.
>
> The choice of value for I915_CMD_HASH_ORDER allows all commands
> currently used in the parser tables to hash to their own bucket (except
> for one collision on the render ring). The tradeoff is that it wastes
> memory. Because the opcodes for the commands in the tables are not
> particularly well distributed, reducing the order still leaves many
> buckets empty. The increased collisions don't seem to have a huge
> impact on the performance gain, but for now anyhow, the parser trades
> memory for performance.
>
> NB: Ville noticed that the error paths through the ring init code
> will leak memory. I've not addressed that here. We can do a follow
> up pass to handle all of the leaks.
>
> v2: improved comment describing selection of hash key mask (Damien)
> replace a BUG_ON() with an error return (Tvrtko, Ville)
> commit message improvements
>
> Signed-off-by: Brad Volkin <bradley.d.volkin@intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Regards,
Tvrtko
next prev parent reply other threads:[~2014-05-12 14:49 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-10 21:10 [PATCH] drm/i915: Use hash tables for the command parser bradley.d.volkin
2014-05-12 13:47 ` Damien Lespiau
2014-05-12 14:49 ` Tvrtko Ursulin [this message]
2014-05-12 16:49 ` Daniel Vetter
-- strict thread matches above, loose matches on Subject: below --
2014-04-28 15:22 bradley.d.volkin
2014-04-28 15:42 ` Daniel Vetter
2014-04-28 16:01 ` Volkin, Bradley D
2014-04-28 15:48 ` Volkin, Bradley D
2014-04-28 15:53 ` Daniel Vetter
2014-04-28 16:07 ` Volkin, Bradley D
2014-04-28 16:11 ` Daniel Vetter
2014-05-07 16:34 ` Volkin, Bradley D
2014-05-08 9:56 ` Tvrtko Ursulin
2014-05-08 11:44 ` Damien Lespiau
2014-05-08 12:25 ` Tvrtko Ursulin
2014-05-08 13:02 ` Damien Lespiau
2014-05-08 13:24 ` Tvrtko Ursulin
2014-05-08 13:52 ` Damien Lespiau
2014-05-08 15:27 ` Volkin, Bradley D
2014-05-08 15:45 ` Ville Syrjälä
2014-05-08 16:02 ` Volkin, Bradley D
2014-05-12 16:24 ` Daniel Vetter
2014-05-12 16:41 ` Volkin, Bradley D
2014-05-12 17:47 ` Daniel Vetter
2014-05-08 15:50 ` Tvrtko Ursulin
2014-05-08 16:04 ` Volkin, Bradley D
2014-05-08 13:05 ` Damien Lespiau
2014-05-08 13:15 ` Damien Lespiau
2014-05-08 15:53 ` Volkin, Bradley D
2014-05-08 15:59 ` Damien Lespiau
2014-05-08 13:42 ` Tvrtko Ursulin
2014-05-08 15:40 ` Volkin, Bradley D
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=5370DF5E.5020808@linux.intel.com \
--to=tvrtko.ursulin@linux.intel.com \
--cc=bradley.d.volkin@intel.com \
--cc=intel-gfx@lists.freedesktop.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