Commit 67731b87 authored by Chris Wilson's avatar Chris Wilson
Browse files

drm/i915: Eliminate drm_gem_object_lookup during relocation



As we provide a list of all objects that will be accessed from the
batchbuffer, we can build a lut of the handles associated with those
objects for this invocation and use that to avoid the overhead of
looking up those objects again for every relocation.

The cost of building and searching a small hash table is much less than
that of acquiring a spinlock, searching a radix tree and manipulating an
atomic refcnt per relocation.

Signed-off-by: default avatarChris Wilson <chris@chris-wilson.co.uk>
parent ff7ea4c0
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment