Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-24 Thread Afzal Mohammed
Hi, On Mon, Aug 24, 2015 at 04:31:13PM +0800, yalin wang wrote: > > i only submit the bit reverse patch for arm / arm64 arch, yes, saw later git blaming it on you :) > > Not for this case, but once measured on ARM, iirc, a 32-bit asm bit > > reversal as compared to doing it in C was taking 1

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-24 Thread yalin wang
> On Aug 22, 2015, at 15:53, Afzal Mohammed wrote: > > Hi, > > On Fri, Aug 21, 2015 at 11:01:41AM +0300, Tomi Valkeinen wrote: > Possibly the patches are still good for x86 also, but that needs to be proven. >>> not exactly, because x86_64 don’t have hardware instruction to do

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-24 Thread Afzal Mohammed
Hi, On Mon, Aug 24, 2015 at 04:31:13PM +0800, yalin wang wrote: i only submit the bit reverse patch for arm / arm64 arch, yes, saw later git blaming it on you :) Not for this case, but once measured on ARM, iirc, a 32-bit asm bit reversal as compared to doing it in C was taking 1 cycle

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-24 Thread yalin wang
On Aug 22, 2015, at 15:53, Afzal Mohammed afzal.mohd...@gmail.com wrote: Hi, On Fri, Aug 21, 2015 at 11:01:41AM +0300, Tomi Valkeinen wrote: Possibly the patches are still good for x86 also, but that needs to be proven. not exactly, because x86_64 don’t have hardware instruction to

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-22 Thread Afzal Mohammed
Hi, On Fri, Aug 21, 2015 at 11:01:41AM +0300, Tomi Valkeinen wrote: > >> Possibly the patches are still good for x86 also, but that needs to be > >> proven. > >> > > not exactly, because x86_64 don’t have hardware instruction to do rbit OP, > > i compile by test : > > For old drivers i386 may

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-22 Thread Afzal Mohammed
Hi, On Fri, Aug 21, 2015 at 11:01:41AM +0300, Tomi Valkeinen wrote: Possibly the patches are still good for x86 also, but that needs to be proven. not exactly, because x86_64 don’t have hardware instruction to do rbit OP, i compile by test : For old drivers i386 may be more relevant

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-21 Thread Tomi Valkeinen
On 21/08/15 10:46, yalin wang wrote: >>> i investigate on arm64 platforms: >> >> Ok. So is any arm64 platform actually using these devices? If these >> devices are mostly used by 32bit x86 platforms, optimizing them for >> arm64 doesn't make any sense. >> >> Possibly the patches are still good

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-21 Thread yalin wang
> On Aug 21, 2015, at 14:41, Tomi Valkeinen wrote: > > > > On 20/08/15 14:30, yalin wang wrote: >> >>> On Aug 20, 2015, at 19:02, Tomi Valkeinen wrote: >>> >>> >>> On 10/08/15 13:12, yalin wang wrote: This change to use swab32(bitrev32()) to implement reverse_order() function,

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-21 Thread Tomi Valkeinen
On 20/08/15 14:30, yalin wang wrote: > >> On Aug 20, 2015, at 19:02, Tomi Valkeinen wrote: >> >> >> On 10/08/15 13:12, yalin wang wrote: >>> This change to use swab32(bitrev32()) to implement reverse_order() >>> function, have better performance on some platforms. >> >> Which platforms?

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-21 Thread Tomi Valkeinen
On 20/08/15 14:30, yalin wang wrote: On Aug 20, 2015, at 19:02, Tomi Valkeinen tomi.valkei...@ti.com wrote: On 10/08/15 13:12, yalin wang wrote: This change to use swab32(bitrev32()) to implement reverse_order() function, have better performance on some platforms. Which platforms?

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-21 Thread yalin wang
On Aug 21, 2015, at 14:41, Tomi Valkeinen tomi.valkei...@ti.com wrote: On 20/08/15 14:30, yalin wang wrote: On Aug 20, 2015, at 19:02, Tomi Valkeinen tomi.valkei...@ti.com wrote: On 10/08/15 13:12, yalin wang wrote: This change to use swab32(bitrev32()) to implement

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-21 Thread Tomi Valkeinen
On 21/08/15 10:46, yalin wang wrote: i investigate on arm64 platforms: Ok. So is any arm64 platform actually using these devices? If these devices are mostly used by 32bit x86 platforms, optimizing them for arm64 doesn't make any sense. Possibly the patches are still good for x86 also,

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-20 Thread yalin wang
> On Aug 20, 2015, at 19:02, Tomi Valkeinen wrote: > > > On 10/08/15 13:12, yalin wang wrote: >> This change to use swab32(bitrev32()) to implement reverse_order() >> function, have better performance on some platforms. > > Which platforms? Presuming you tested this, roughly how much better >

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-20 Thread Tomi Valkeinen
On 10/08/15 13:12, yalin wang wrote: > This change to use swab32(bitrev32()) to implement reverse_order() > function, have better performance on some platforms. Which platforms? Presuming you tested this, roughly how much better performance? If you didn't, how do you know it's faster? >

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-20 Thread yalin wang
On Aug 20, 2015, at 19:02, Tomi Valkeinen tomi.valkei...@ti.com wrote: On 10/08/15 13:12, yalin wang wrote: This change to use swab32(bitrev32()) to implement reverse_order() function, have better performance on some platforms. Which platforms? Presuming you tested this, roughly how

Re: [RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-20 Thread Tomi Valkeinen
On 10/08/15 13:12, yalin wang wrote: This change to use swab32(bitrev32()) to implement reverse_order() function, have better performance on some platforms. Which platforms? Presuming you tested this, roughly how much better performance? If you didn't, how do you know it's faster?

[RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-10 Thread yalin wang
This change to use swab32(bitrev32()) to implement reverse_order() function, have better performance on some platforms. Signed-off-by: yalin wang --- drivers/video/fbdev/riva/fbdev.c | 19 ++- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git

[RFC] fbdev/riva:change to use generice function to implement reverse_order()

2015-08-10 Thread yalin wang
This change to use swab32(bitrev32()) to implement reverse_order() function, have better performance on some platforms. Signed-off-by: yalin wang yalin.wang2...@gmail.com --- drivers/video/fbdev/riva/fbdev.c | 19 ++- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git