Re: [Intel-gfx] [PATCH 2/2] drm/i915: Limit the busy wait on requests to 2us not 10ms!

2015-12-03 Thread Pavel Machek
Hi! > Reported-by: Jens Axboe > Link: https://lkml.org/lkml/2015/11/12/621 > Cc: Jens Axboe > Cc; "Rogozhkin, Dmitry V" > Cc: Daniel Vetter > Cc: Tvrtko Ursulin > Cc: Eero Tamminen > Cc: "Rantala, Valtteri" > Cc: sta...@kernel.vger.org > --- > drivers/gpu/drm/i915/i915_gem.c | 28 +

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Limit the busy wait on requests to 2us not 10ms!

2015-11-17 Thread Jens Axboe
On 11/15/2015 06:32 AM, Chris Wilson wrote: When waiting for high frequency requests, the finite amount of time required to set up the irq and wait upon it limits the response rate. By busywaiting on the request completion for a short while we can service the high frequency waits as quick as poss

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Limit the busy wait on requests to 2us not 10ms!

2015-11-16 Thread Ville Syrjälä
On Mon, Nov 16, 2015 at 12:55:37PM +, Chris Wilson wrote: > On Mon, Nov 16, 2015 at 12:08:08PM +, Tvrtko Ursulin wrote: > > > > On 16/11/15 11:12, Chris Wilson wrote: > > >On Mon, Nov 16, 2015 at 10:24:45AM +, Tvrtko Ursulin wrote: > > >>On 15/11/15 13:32, Chris Wilson wrote: > > >>>+s

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Limit the busy wait on requests to 2us not 10ms!

2015-11-16 Thread Tvrtko Ursulin
On 16/11/15 12:55, Chris Wilson wrote: On Mon, Nov 16, 2015 at 12:08:08PM +, Tvrtko Ursulin wrote: On 16/11/15 11:12, Chris Wilson wrote: On Mon, Nov 16, 2015 at 10:24:45AM +, Tvrtko Ursulin wrote: On 15/11/15 13:32, Chris Wilson wrote: +static u64 local_clock_us(unsigned *cpu) +{ +

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Limit the busy wait on requests to 2us not 10ms!

2015-11-16 Thread Chris Wilson
On Mon, Nov 16, 2015 at 12:08:08PM +, Tvrtko Ursulin wrote: > > On 16/11/15 11:12, Chris Wilson wrote: > >On Mon, Nov 16, 2015 at 10:24:45AM +, Tvrtko Ursulin wrote: > >>On 15/11/15 13:32, Chris Wilson wrote: > >>>+static u64 local_clock_us(unsigned *cpu) > >>>+{ > >>>+ u64 t; > >>>+ > >>

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Limit the busy wait on requests to 2us not 10ms!

2015-11-16 Thread Tvrtko Ursulin
On 16/11/15 11:12, Chris Wilson wrote: On Mon, Nov 16, 2015 at 10:24:45AM +, Tvrtko Ursulin wrote: Hi, On 15/11/15 13:32, Chris Wilson wrote: When waiting for high frequency requests, the finite amount of time required to set up the irq and wait upon it limits the response rate. By busyw

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Limit the busy wait on requests to 2us not 10ms!

2015-11-16 Thread Chris Wilson
On Mon, Nov 16, 2015 at 10:24:45AM +, Tvrtko Ursulin wrote: > > Hi, > > On 15/11/15 13:32, Chris Wilson wrote: > >When waiting for high frequency requests, the finite amount of time > >required to set up the irq and wait upon it limits the response rate. By > >busywaiting on the request compl

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Limit the busy wait on requests to 2us not 10ms!

2015-11-16 Thread Tvrtko Ursulin
Hi, On 15/11/15 13:32, Chris Wilson wrote: When waiting for high frequency requests, the finite amount of time required to set up the irq and wait upon it limits the response rate. By busywaiting on the request completion for a short while we can service the high frequency waits as quick as pos

Re: [Intel-gfx] [PATCH 2/2] drm/i915: Limit the busy wait on requests to 2us not 10ms!

2015-11-15 Thread Chris Wilson
On Sun, Nov 15, 2015 at 01:32:44PM +, Chris Wilson wrote: > +static bool busywait_stop(u64 timeout, unsigned cpu) > +{ > + unsigned this_cpu; > + > + if (time_after64(local_clock_us(&this_cpu), timeout)) > + return true; Just a note to say that we can use the unsigned long

[Intel-gfx] [PATCH 2/2] drm/i915: Limit the busy wait on requests to 2us not 10ms!

2015-11-15 Thread Chris Wilson
When waiting for high frequency requests, the finite amount of time required to set up the irq and wait upon it limits the response rate. By busywaiting on the request completion for a short while we can service the high frequency waits as quick as possible. However, if it is a slow request, we wan