Summary: | [GLSL 1.30]ivec2 textureSize(gsampler2D sampler, int lod) return with wrong value in vertex shader | ||
---|---|---|---|
Product: | Mesa | Reporter: | Ouping Zhang <ouping.zhang> |
Component: | Drivers/DRI/i965 | Assignee: | Kenneth Graunke <kenneth> |
Status: | RESOLVED FIXED | QA Contact: | |
Severity: | normal | ||
Priority: | medium | ||
Version: | git | ||
Hardware: | All | ||
OS: | Linux (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: |
Description
Ouping Zhang
2011-12-31 00:05:57 UTC
Confirmed. Looks like a bug in the i965 vertex shader backend. I have a patch that fixes the issue, and a lot of other oglconform tests, but it breaks a few, and I haven't yet figured out why. Similar but subtly different patches fix and break different sets of tests. It's been very confusing. For now, marking this assigned. Thanks for the piglit test! Patch on mailing list: [PATCH] i965/vs: Use the proper dimensionality for the sampler result register. commit fbbbc8c04e2462a0ae272d81e61eee5f85f08aa6 Author: Kenneth Graunke <kenneth@whitecape.org> Date: Mon Jan 2 15:51:58 2012 -0800 i965/vs: Use the proper dimensionality for the sampler result register. textureSize() returns an int, ivec2, or ivec3, but never an ivec4. Creating the destination register as an ivec4 triggered later failures, even though the register did hold the proper values. For example, piglit test vs-textureSize-compare calls textureSize on a 2D texture and compares the result to an expected value. Unfortunately, our generated code also tried to compare the third and fourth components which were undefined, and failed. Fixes piglit test vs-textureSize-compare as well as 19 subcases of oglconform's glsl-bif-tex-size test. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=44339 Signed-off-by: Kenneth Graunke <kenneth@whitecape.org> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com> Reviewed-by: Eric Anholt <eric@anholt.net> Ken, do you think Ouping's case should be added into piglit? Yes, definitely. I sent it out to the list a while ago, but hadn't received any comments. I just pushed it today. Thanks! |
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.