Hi, the commit: commit 96bbc627f369c0100b950f81531b1fe9ef586c34 Author: Christian König <deathsimple@vodafone.de> Date: Mon Feb 28 02:00:01 2011 +0100 r600g: implement instanced drawing support breaks the following two piglit tests on Evergreen: shaders/glsl-routing texturing/texrect-many btw. The draw-instanced piglit tests also fail on Evergreen with EE r600_asm.c:140 r600_bc_get_num_operands - Need instruction operand number for 0x9b.
Can you test with: http://cgit.freedesktop.org/mesa/mesa/commit/?id=5f44fab5a6ba99c287da8d01fa584763bff2565b
With that commit general/draw-instanced now passes clean on Evergreen. general/draw-instanced-divisor fails with some other errors: draw-instanced: instance 0 failed to draw correctly draw-instanced: color instance divisor = 2 And shaders/glsl-routing and texturing/texrect-many are still regressed.
I don't have an evergreen card at hand to reproduce the problem. So please run the following command: R600_DUMP_SHADERS=1 shaders/glsl-routing 2> shaders.out and attach the generated shader output.
Created attachment 43993 [details] shader output from glsl-routing piglit test
Created attachment 43994 [details] shader output from texrect-many piglit test
Created attachment 44035 [details] [review] Patch to dump the bytes of the fetch shader Ok please checkout the commit bce4f9ac395986ee0acae2702ed73448333d81b8 (the one before the offending commit) and apply the attached patch. Then rerun the tests with R600_DUMP_SHADERS=1 Attach the newly generated shader output. By comparing both we should be able to figure out what's going wrong here. Christian.
Created attachment 44037 [details] shader output from glsl-routing piglit test (before offending commit)
Created attachment 44038 [details] shader output from texrect-many piglit test (before offending commit)
Ok, the mega_fetch_count was wrong, if've fixed this and pushed it to the mainline. Please fetch and try again. The only problem is that i have no idea why this should affect only evergreen and not my RV710 for example.
Hi, still not fixed with that commit. I'll attach the new shader output
Created attachment 44041 [details] shader output from glsl-routing (latest)
Created attachment 44042 [details] shader output from texrect-many (latest)
Created attachment 44128 [details] [review] Possible fix Beside the different formatting the shaders now look completely identical. So it must be something else, please try the attached patch, if this still doesn't work there must be some other patch that interfere with this problem.
Created attachment 44129 [details] [review] Possible fix Ups, wrong patch, please use this one instead.
Hi, the patch has no effect here but with latest git master the regression is fixed and draw-instanced-divisor also passes now. I guess it was your commit r600g: fix fragment shader size calculation that fixed it. Thanks.
Yes, I finally figured out what was going wrong here. The alignment of the vertex fetch instructions weren't included in the shader size calculation. Thanks for the help, Christian.
Created attachment 44182 [details] [review] Use long long literal in calculation Didn't feel like opening a new bug fur this. But your recent commit, r600g: simplify instance addr calculation, breaks the draw-instanced-divisor piglit test here. I also noticed a warning about overflow during compilation: r600_asm.c:2105: warning: left shift count >= width of type Using a long long integer fixes the warning and the piglit test. Patch attached.
Thanks again, patch pushed.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.