<div dir="ltr"><br><div class="gmail_extra"><div class="gmail_quote">On Sun, Oct 13, 2013 at 2:50 PM, Frank Henigman <span dir="ltr"><<a href="mailto:fjhenigman@google.com" target="_blank">fjhenigman@google.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">On Fri, Oct 11, 2013 at 10:00 PM, Chad Versace<br>
<<a href="mailto:chad.versace@linux.intel.com">chad.versace@linux.intel.com</a>> wrote:<br>
> On 10/11/2013 10:17 AM, Courtney Goeltzenleuchter wrote:<br>
>><br>
>> Support all levels of a supported texture format.<br>
>> ---<br>
>> src/mesa/drivers/dri/i965/intel_tex_subimage.c | 13 +++++++++++--<br>
>> 1 file changed, 11 insertions(+), 2 deletions(-)<br>
>><br>
>> diff --git a/src/mesa/drivers/dri/i965/intel_tex_subimage.c<br>
>> b/src/mesa/drivers/dri/i965/intel_tex_subimage.c<br>
>> index 4aec05d..5e46760 100644<br>
>> --- a/src/mesa/drivers/dri/i965/intel_tex_subimage.c<br>
>> +++ b/src/mesa/drivers/dri/i965/intel_tex_subimage.c<br>
>> @@ -541,14 +541,13 @@ intel_texsubimage_tiled_memcpy(struct gl_context *<br>
>> ctx,<br>
>> uint32_t cpp;<br>
>> mem_copy_fn mem_copy = NULL;<br>
>><br>
>> - /* This fastpath is restricted to specific texture types: level 0 of<br>
>> + /* This fastpath is restricted to specific texture types:<br>
>> * a 2D BGRA, RGBA, L8 or A8 texture. It could be generalized to<br>
>> support<br>
>> * more types.<br>
>> */<br>
>> if (!brw->has_llc ||<br>
>> type != GL_UNSIGNED_BYTE ||<br>
>> texImage->TexObject->Target != GL_TEXTURE_2D ||<br>
>> - texImage->Level != 0 ||<br>
>> pixels == NULL ||<br>
>> _mesa_is_bufferobj(packing->BufferObj) ||<br>
>> packing->Alignment > 4 ||<br>
>> @@ -616,6 +615,16 @@ intel_texsubimage_tiled_memcpy(struct gl_context *<br>
>> ctx,<br>
>> DBG("%s: level=%d offset=(%d,%d) (w,h)=(%d,%d)\n",<br>
>> __FUNCTION__, texImage->Level, xoffset, yoffset, width, height);<br>
>><br>
>> + /* Adjust x and y offset based on miplevel<br>
>> + */<br>
>> + if (texImage->Level) {<br>
>> + GLuint xlevel, ylevel;<br>
>> + intel_miptree_get_image_offset(image->mt, texImage->Level, 0,<br>
>> + &xlevel, &ylevel);<br>
>> + xoffset += xlevel;<br>
>> + yoffset += ylevel;<br>
>> + }<br>
>> +<br>
>> linear_to_tiled(<br>
>> xoffset * cpp, (xoffset + width) * cpp,<br>
>> yoffset, yoffset + height,<br>
>><br>
><br>
> Usually when we commit performance patches like this, we state in the<br>
> commit message what the observed relative performance gain.<br>
><br>
> What gain did you see? Hardware? Benchmark? Kernel version? How many<br>
> runs?<br>
<br>
</div></div>We could quote from my patch, as this is just opening more paths into that code.<br>
Or do you think this calls for different testing?<br>
</blockquote></div><br>Smokin' Guns goes down this path (and when it's wrong you can see it :-).</div><div class="gmail_extra"><br></div><div class="gmail_extra">I'll check piglit.<br clear="all"><div><br></div>
-- <br><div dir="ltr">Courtney Goeltzenleuchter<br><div>LunarG</div><div><img src="http://media.lunarg.com/wp-content/themes/LunarG/images/logo.png" width="96" height="65"><br></div></div>
</div></div>