Mesa (master): mesa: Remove unneeded bitfield widths from the VAO.

GitLab Mirror gitlab-mirror at kemper.freedesktop.org
Wed Nov 21 05:59:12 UTC 2018


Module: Mesa
Branch: master
Commit: 2d3c466add25e49692bd833742bf2a3aac0d3801
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=2d3c466add25e49692bd833742bf2a3aac0d3801

Author: Mathias Fröhlich <mathias.froehlich at web.de>
Date:   Sat Nov 17 07:13:11 2018 +0100

mesa: Remove unneeded bitfield widths from the VAO.

With the current VAO layout we do not need to make these
fields a bitfield. We get a tight struct layout with this change
for VAO attributes.

v2: Change unsigned char -> GLubyte.

Reviewed-by: Brian Paul <brianp at vmware.com>
Reviewed-by: Marek Olšák <marek.olsak at amd.com>
Signed-off-by: Mathias Fröhlich <Mathias.Froehlich at web.de>

---

 src/mesa/main/mtypes.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
index 62d3b75a36..157d45bc0b 100644
--- a/src/mesa/main/mtypes.h
+++ b/src/mesa/main/mtypes.h
@@ -1439,7 +1439,7 @@ struct gl_array_attributes
    /** Stride as specified with gl*Pointer() */
    GLshort Stride;
    /** Index into gl_vertex_array_object::BufferBinding[] array */
-   unsigned BufferBindingIndex:6;
+   GLubyte BufferBindingIndex;
 
    /**
     * Derived effective buffer binding index
@@ -1454,7 +1454,7 @@ struct gl_array_attributes
     * Note that _mesa_update_vao_derived_arrays is called when binding
     * the VAO to Array._DrawVAO.
     */
-   unsigned _EffBufferBindingIndex:6;
+   GLubyte _EffBufferBindingIndex;
    /**
     * Derived effective relative offset.
     *




More information about the mesa-commit mailing list