Quoting Chris Wilson (2020-11-09 11:28:04)
> Quoting Matthew Auld (2020-11-09 11:12:49)
> > When performing an allocation we try split it down into the largest
> > possible power-of-two blocks/pages-sizes, and for the common case we
> > expect to allocate the blocks in descending order. This also naturally
> > fits with our GTT alignment tricks(including the hugepages selftest),
> > where we sometimes try to align to the largest possible GTT page-size
> > for the allocation, in the hope that translates to bigger GTT
> > page-sizes. Currently, we seem to incorrectly add the blocks in the
> > opposite order, which is definitely not the intended behaviour.
> 
> Right, so currently we end up with small -> large blocks, and you want
> to change it so that we use large -> small blocks, because we want to
> keep things aligned for as long as possible (if we start small, we
> immediately spoil the alignment provided for us).

Reviewed-by: Chris Wilson <ch...@chris-wilson.co.uk>
 
> How can we test this? Create a 2MiB + 4KiB object and ask if
> page_sizes.gtt has a 2MiB? I don't think it can be directly observed
> from userspace, right? Is it possible to generalise the characteristic
> we expect and prevent future errors?

But we should try and capture some testing :)
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

Reply via email to