Re: [PATCH 1/3] r600: add span support for 2D tiling

2010-05-27 Thread Brian Paul
Alex Deucher wrote: On Thu, May 27, 2010 at 10:55 AM, Matt Turner matts...@gmail.com wrote: +static inline GLint r600_log2(GLint n) +{ + GLint log2 = 0; + + while (n = 1) + ++log2; + return log2; +} Does mesa not provide something like this? The only one I

Re: [PATCH 1/3] r600: add span support for 2D tiling

2010-05-27 Thread Alan Cox
Note if it is known that x and y are less than or equal to 7 it can be done in 11 operations. And bsr is one instruction for x86, cntlzw for ppc Alan ___ dri-devel mailing list dri-devel@lists.freedesktop.org

Re: [PATCH 1/3] r600: add span support for 2D tiling

2010-05-27 Thread Conn Clark
On Thu, May 27, 2010 at 4:01 PM, Frieder Ferlemann frieder.ferlem...@web.de wrote: Hi, Am 28.05.2010 00:04, schrieb Conn Clark: On Thu, May 27, 2010 at 8:51 AM, Brian Paul bri...@vmware.com wrote: This code could be written with a faster algorithm requiring  just 13 operations +