Summary: | [PNV Bisected]Ogles2conform ES2-CTS.gtf.GL2ExtensionTests.texture_float.texture_float segfault | ||
---|---|---|---|
Product: | Mesa | Reporter: | lu hua <huax.lu> |
Component: | Drivers/DRI/i915 | Assignee: | Tapani Pälli <lemody> |
Status: | VERIFIED FIXED | QA Contact: | mesa-dev |
Severity: | normal | ||
Priority: | medium | CC: | kondapallykalyancontribute, lemody |
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux (All) | ||
Whiteboard: | |||
i915 platform: | i915 features: | ||
Attachments: |
patch to fix the issue
patch to fix the issue |
Description
lu hua
2015-02-02 05:26:42 UTC
It sounds like floating-point formats are some how being allowed when the extension is not enabled. Created attachment 113390 [details] [review] patch to fix the issue It looks like internal format adjustment is made always, even when extension is not enabled. Does this patch help/fix the issue? Comment on attachment 113390 [details] [review] patch to fix the issue Review of attachment 113390 [details] [review]: ----------------------------------------------------------------- I think the problem is that adjust_for_oes_float_texture is called even when internalFormat is not GL_FLOAT, GL_HALF_FLOAT_OES, or GL_HALF_FLOAT. It seems like this would be better: if (_mesa_is_gles(ctx) && format == internalFormat) { if (type == GL_FLOAT) { texObj->_IsFloat = GL_TRUE; internalFormat = adjust_for_oes_float_texture(format, type); } else if (type == GL_HALF_FLOAT_OES || type == GL_HALF_FLOAT) { texObj->_IsHalfFloat = GL_TRUE; internalFormat = adjust_for_oes_float_texture(format, type); } } (In reply to Ian Romanick from comment #3) > Comment on attachment 113390 [details] [review] [review] > patch to fix the issue > > Review of attachment 113390 [details] [review] [review]: > ----------------------------------------------------------------- > > I think the problem is that adjust_for_oes_float_texture is called even when > internalFormat is not GL_FLOAT, GL_HALF_FLOAT_OES, or GL_HALF_FLOAT. > > It seems like this would be better: > > if (_mesa_is_gles(ctx) && format == internalFormat) { Also, I think the check here should be ctx->API == API_OPENGLES2. We don't want to do this in GLES 1.1. > if (type == GL_FLOAT) { > texObj->_IsFloat = GL_TRUE; > internalFormat = adjust_for_oes_float_texture(format, type); > } else if (type == GL_HALF_FLOAT_OES || type == GL_HALF_FLOAT) { > texObj->_IsHalfFloat = GL_TRUE; > internalFormat = adjust_for_oes_float_texture(format, type); > } > } (In reply to Ian Romanick from comment #3) > Comment on attachment 113390 [details] [review] [review] > patch to fix the issue > > Review of attachment 113390 [details] [review] [review]: > ----------------------------------------------------------------- > > I think the problem is that adjust_for_oes_float_texture is called even when > internalFormat is not GL_FLOAT, GL_HALF_FLOAT_OES, or GL_HALF_FLOAT. Nothing happens in the function if format was not one of these formats so not calling it does not seem to change existing functionality. I think extension check seems very relevant here because these things should happen only because of the extension is enabled, not because you are running ES2. i965 should be only driver currently supporting this extension on ES2. I've sent updated patch to the list for review. Created attachment 113864 [details] [review] patch to fix the issue Updated patch. QA, please test with this patch. Test on the latest Mesa master branch, the core dumped issue goes away. output: dEQP Core GL-CTS-2.0 (0x0052484b) starting.. target implementation = 'X11' Test case 'ES2-CTS.gtf.GL2ExtensionTests.texture_float.texture_float'.. GL_OES_texture_float is not supported. Mesa 10.6.0-devel implementation error: unexpected format GL_RGB32F in _mesa_choose_tex_format() Please report at https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa #+ glTexImage2D: Got GL_NO_ERROR with internalformat=GL_RGB & type=GL_FLOAT. Expected GL_INVALID_ENUM Fail (Fail) DONE! Test run totals: Passed: 0/1 (0.00%) Failed: 1/1 (100.00%) Not supported: 0/1 (0.00%) Warnings: 0/1 (0.00%) Verified.Fixed. The test still fails though, will you open a separate bug for that or will we handle it in the same one? (In reply to Tapani Pälli from comment #10) > The test still fails though, will you open a separate bug for that or will > we handle it in the same one? It always fail, So closed this bug. Reported bug 89389 to track the fail. |
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.