On 26 June 2013 14:57, Anuj Phogat <anuj.pho...@gmail.com> wrote: > On Tue, Jun 25, 2013 at 10:27 AM, Paul Berry <stereotype...@gmail.com> > wrote: > > This seems like a lot of work to accomplish what is effectively a lookup > > table. If this winds up becoming a performance bottleneck, you might > want > > to consider passing the table in via a push constant, and using indirect > > addressing to convert sample index to sample number. > > > Yes, that would be helpful. Is it acceptable to do this optimization as a > follow up patch? >
Yes, that seems completely reasonable. > > > I'm confused why we need loops from 0 to 7 here. It looks like you're > > trying to interpolate each component of the SIMD8 register separately. > That > > shouldn't be necessary. > > > Output of each SIMD16 sampler instruction (send) is written to 8 grf > registers. > So, I'm looping from 0 to 7 to interpolate all these 8 registers. If we > lower > the loop counter, we end up with color data 'not-interpolated' in few color > channels. Does this explain your concern? > Aha! The 8 comes from 4 color channels * 2 registers each (since we're doing SIMD16, and a register holds only 8 values). I get it now. A comment to explain this would probably be useful. Thanks, Anuj!
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev