Re: [PATCH v2] drm/i915: use a separate context for gpu relocs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Quoting Daniele Ceraolo Spurio (2019-08-27 19:58:05)
> The CS pre-parser can pre-fetch commands across memory sync points and
> starting from gen12 it is able to pre-fetch across BB_START and BB_END
> boundaries as well, so when we emit gpu relocs the pre-parser might
> fetch the target location of the reloc before the memory write lands.
> 
> The parser can't pre-fetch across the ctx switch, so we use a separate
> context to guarantee that the memory is synchronized before the parser
> can get to it.
> 
> Note that there is no risk of the CS doing a lite restore from the reloc
> context to the user context, even if the two have the same hw_id,
> because since gen11 the CS also checks the LRCA when deciding if it can
> lite-restore.
> 
> v2: limit new context to gen12+, release in eb_destroy, add a comment
>     in emit_fini_breadcrumb (Chris).
> 
> Suggested-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
> Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@xxxxxxxxx>
> Cc: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>

Looks solid and the big explanatory reminders are very welcome. (I will
shift it to gen11_fini_breadcrumbs I think, so it's closer to the gen12
divide.) Subtle changes in behaviour are easily forgotten.

Reviewed-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux