llvmpipe: Remove redundant alignments.
authorJosé Fonseca <jfonseca@vmware.com>
Wed, 14 Jul 2010 13:53:35 +0000 (14:53 +0100)
committerJosé Fonseca <jfonseca@vmware.com>
Wed, 14 Jul 2010 13:53:35 +0000 (14:53 +0100)
The lp_rast_shader_inputs' alignment is irrelevant now that it contains
pointers instead of actual data.

Likewise, lp_rast_triangle's size alignment is meaningless.

src/gallium/drivers/llvmpipe/lp_rast.h
src/gallium/drivers/llvmpipe/lp_setup_tri.c

index 0991344cce92e35b99bd2e72e11ae19853a38664..eaf2a6f33450b752148735ec0fb67d4c5ada2fe6 100644 (file)
@@ -117,7 +117,7 @@ struct lp_rast_plane {
  */
 struct lp_rast_triangle {
    /* inputs for the shader */
-   PIPE_ALIGN_VAR(16) struct lp_rast_shader_inputs inputs;
+   struct lp_rast_shader_inputs inputs;
 
    int step[3][16];
 
index 4ceb789b7754b40692ebeb1a5d183198cf0bd919..7e432503c126028d33c8034c59d3fbdf06dab686 100644 (file)
@@ -342,8 +342,6 @@ alloc_triangle(struct lp_scene *scene,
    unsigned tri_bytes, bytes;
    char *inputs;
 
-   assert(sizeof(*tri) % 16 == 0);
-
    tri_bytes = align(Offset(struct lp_rast_triangle, plane[nr_planes]), 16);
    bytes = tri_bytes + (3 * input_array_sz);