[Mesa-dev] [PATCH] mesa: remove separate enable for KHR_robust_buffer_access_behavior

Ilia Mirkin imirkin at alum.mit.edu
Tue May 24 02:44:51 UTC 2016


This extension appears to be a strict subset of the ARB version. Also
remove it from GL3.txt since it doesn't seem relevant.

Signed-off-by: Ilia Mirkin <imirkin at alum.mit.edu>
---

Let me know if you think I'm missing something. From the KHR spec:

    3) How does this extension differ from
       ARB_robust_buffer_access_behavior?

       - It is written against OpenGL ES 3.1 instead of GL 4.2, and can
         be implemented for OpenGL ES 2.0 contexts as well.
       - References to GL_CONTEXT_FLAG_ROBUST_ACCESS_BIT_ARB are
         removed, since there is no query for context creation flags in
         any version of OpenGL ES.
       - For OpenGL ES implementations only, it widens the scope of possible
         return values from OOB buffer reads to (0,0,0,x) where x is zero,
         one, or MAXINT for integer types.

So the differences are all in ES. Nothing that seems like it would particularly
require a separate enable flag. If people feel strongly, I can instead flip
the gallium cap to enable the KHR variant explicitly.

 docs/GL3.txt                                 | 1 -
 src/mesa/drivers/dri/i965/intel_extensions.c | 1 -
 src/mesa/main/extensions_table.h             | 2 +-
 src/mesa/main/mtypes.h                       | 1 -
 4 files changed, 1 insertion(+), 4 deletions(-)

diff --git a/docs/GL3.txt b/docs/GL3.txt
index aa58e4a..4a9cf0b 100644
--- a/docs/GL3.txt
+++ b/docs/GL3.txt
@@ -218,7 +218,6 @@ GL 4.5, GLSL 4.50:
   GL_ARB_shader_texture_image_samples                   DONE (i965, nv50, nvc0, r600, radeonsi)
   GL_ARB_texture_barrier                                DONE (i965, nv50, nvc0, r600, radeonsi)
   GL_KHR_context_flush_control                          DONE (all - but needs GLX/EGL extension to be useful)
-  GL_KHR_robust_buffer_access_behavior                  DONE (i965)
   GL_KHR_robustness                                     not started (90% done with the ARB variant)
   GL_EXT_shader_integer_mix                             DONE (all drivers that support GLSL)
 
diff --git a/src/mesa/drivers/dri/i965/intel_extensions.c b/src/mesa/drivers/dri/i965/intel_extensions.c
index 6ed55036..feea6ca 100644
--- a/src/mesa/drivers/dri/i965/intel_extensions.c
+++ b/src/mesa/drivers/dri/i965/intel_extensions.c
@@ -372,7 +372,6 @@ intelInitExtensions(struct gl_context *ctx)
 
    if (brw->gen >= 8 || brw->is_haswell || brw->is_baytrail) {
       ctx->Extensions.ARB_robust_buffer_access_behavior = true;
-      ctx->Extensions.KHR_robust_buffer_access_behavior = true;
    }
 
    if (brw->intelScreen->has_mi_math_and_lrr) {
diff --git a/src/mesa/main/extensions_table.h b/src/mesa/main/extensions_table.h
index 7bfc268..3eaea18 100644
--- a/src/mesa/main/extensions_table.h
+++ b/src/mesa/main/extensions_table.h
@@ -280,7 +280,7 @@ EXT(INTEL_performance_query                 , INTEL_performance_query
 
 EXT(KHR_context_flush_control               , dummy_true                             , GLL, GLC,  x , ES2, 2014)
 EXT(KHR_debug                               , dummy_true                             , GLL, GLC,  11, ES2, 2012)
-EXT(KHR_robust_buffer_access_behavior       , KHR_robust_buffer_access_behavior      , GLL, GLC,  x , ES2, 2014)
+EXT(KHR_robust_buffer_access_behavior       , ARB_robust_buffer_access_behavior      , GLL, GLC,  x , ES2, 2014)
 EXT(KHR_texture_compression_astc_hdr        , KHR_texture_compression_astc_hdr       , GLL, GLC,  x , ES2, 2012)
 EXT(KHR_texture_compression_astc_ldr        , KHR_texture_compression_astc_ldr       , GLL, GLC,  x , ES2, 2012)
 
diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
index 29d7a4f..b7b3ede 100644
--- a/src/mesa/main/mtypes.h
+++ b/src/mesa/main/mtypes.h
@@ -3901,7 +3901,6 @@ struct gl_extensions
    GLboolean INTEL_performance_query;
    GLboolean KHR_texture_compression_astc_hdr;
    GLboolean KHR_texture_compression_astc_ldr;
-   GLboolean KHR_robust_buffer_access_behavior;
    GLboolean MESA_pack_invert;
    GLboolean MESA_ycbcr_texture;
    GLboolean NV_conditional_render;
-- 
2.7.3



More information about the mesa-dev mailing list