[Intel-gfx] patches for occlusion query fix on sandybridge

2010-12-13 Thread Zhenyu Wang
It appears Sandybridge PIPE_CONTROL write out buffer need to be set as cached, currently LLC cached, in order to read back correct counter. Otherwise I can always be possible to get corrupted 64-bit PS_DEPTH_COUNT from PIPE_CONTROL write. So below patches try to add new flag during bo create with

Re: [Intel-gfx] patches for occlusion query fix on sandybridge

2010-12-14 Thread Eric Anholt
On Tue, 14 Dec 2010 12:55:59 +0800, Zhenyu Wang wrote: > It appears Sandybridge PIPE_CONTROL write out buffer need > to be set as cached, currently LLC cached, in order to read > back correct counter. Otherwise I can always be possible to > get corrupted 64-bit PS_DEPTH_COUNT from PIPE_CONTROL wri

Re: [Intel-gfx] patches for occlusion query fix on sandybridge

2010-12-14 Thread Daniel Vetter
On Tue, Dec 14, 2010 at 12:55:59PM +0800, Zhenyu Wang wrote: > It appears Sandybridge PIPE_CONTROL write out buffer need > to be set as cached, currently LLC cached, in order to read > back correct counter. Otherwise I can always be possible to > get corrupted 64-bit PS_DEPTH_COUNT from PIPE_CONTRO

Re: [Intel-gfx] patches for occlusion query fix on sandybridge

2010-12-14 Thread david may
Hello Eric, Tuesday, December 14, 2010, 5:58:58 PM, you wrote: > On Tue, 14 Dec 2010 12:55:59 +0800, Zhenyu Wang > wrote: >> It appears Sandybridge PIPE_CONTROL write out buffer need >> to be set as cached, currently LLC cached, in order to read >> back correct counter. Otherwise I can always b

Re: [Intel-gfx] patches for occlusion query fix on sandybridge

2010-12-14 Thread Chris Wilson
On Tue, 14 Dec 2010 20:59:09 +, david may wrote: > Hello Eric, > > Tuesday, December 14, 2010, 5:58:58 PM, you wrote: > > > Why don't we just keep all of our BOs LLC cached? This was supposed to > > be a big win of the new chipset, as it means we don't need to clflush. > > Ohh,the implicat

Re: [Intel-gfx] patches for occlusion query fix on sandybridge

2010-12-14 Thread Zhenyu Wang
On 2010.12.14 21:47:45 +, Chris Wilson wrote: > On Tue, 14 Dec 2010 20:59:09 +, david may > wrote: > > Hello Eric, > > > > Tuesday, December 14, 2010, 5:58:58 PM, you wrote: > > > > > Why don't we just keep all of our BOs LLC cached? This was supposed to > > > be a big win of the new c

Re: [Intel-gfx] patches for occlusion query fix on sandybridge

2010-12-14 Thread Zhenyu Wang
On 2010.12.14 19:13:22 +0100, Daniel Vetter wrote: > On Tue, Dec 14, 2010 at 12:55:59PM +0800, Zhenyu Wang wrote: > > It appears Sandybridge PIPE_CONTROL write out buffer need > > to be set as cached, currently LLC cached, in order to read > > back correct counter. Otherwise I can always be possibl