[Mesa-dev] [PATCH 3/4] nine: handle D3DISSUE_END without previous D3DISSUE_BEGIN

Marek Olšák maraeo at gmail.com
Sun Nov 23 02:51:01 PST 2014


A few Gallium queries don't need and it's invalid to call begin_query.
Those are PIPE_QUERY_GPU_FINISHED (D3DQUERYTYPE_EVENT) and
PIPE_QUERY_TIMESTAMP (D3DQUERYTYPE_TIMESTAMP).

The attached patch should fix this.

Marek

On Sat, Nov 22, 2014 at 9:48 AM, John Ettedgui <john.ettedgui at gmail.com> wrote:
> So I tried both code you thought of.
>
> 1) Always having end_query did not seem to get a different behavior from my
> patch. (I'm sure it does somewhere but I didn't see that in my quick test).
>
> 2) Your 2nd code is more problematic (adding the begin_query as needed)
> The game completely dies/freezes, and I see this in the log:
> "r600_query.c:444:r600_begin_query: Assertion `0' failed."
> (I have a radeon card).
> The assert comes from this if statement:
> "if (!r600_query_needs_begin(rquery->type)) "
> Logically I'd say it means that we are running a query_begin when it is not
> needed.
> The query type is 8 if that helps.
>
> Now there are 2 cases:
> 1- the radeon code is correct and so we should not add that extra
> begin_query
> 2- the radeon code is incorrect and maybe adding this query_begin is right.
>   The i915's code does not do anything for begin or end, so hard to compare
> there.
>   The svga code switches on the query type, and will assert on the wrong
> ones. I guess it is similar to the radeon's.
>   Nouveau also has switches on type, but it does not error on "wrong ones".
>
> What do you think?
>
> John
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-st-nine-handle-queries-without-begin.patch
Type: text/x-diff
Size: 1131 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20141123/8c384383/attachment.patch>


More information about the mesa-dev mailing list