Re: [Mesa-dev] [PATCH] mesa: fix display list 8-byte alignment issue

2015-01-30 Thread Brian Paul
On 01/30/2015 03:25 AM, Jose Fonseca wrote: Looks good to me. Just one minor suggestion: if we replaced sizeof(void *) == 8 with sizeof(void *) > sizeof(GLuint) Yes, or more accurately, sizeof(Node). we would avoid the magic number 8 and make the code correct for any pointer size.

Re: [Mesa-dev] [PATCH] mesa: fix display list 8-byte alignment issue

2015-01-30 Thread Jose Fonseca
Looks good to me. Just one minor suggestion: if we replaced sizeof(void *) == 8 with sizeof(void *) > sizeof(GLuint) we would avoid the magic number 8 and make the code correct for any pointer size. Jose On 28/01/15 03:06, Brian Paul wrote: The _mesa_dlist_alloc() function is only

Re: [Mesa-dev] [PATCH] mesa: fix display list 8-byte alignment issue

2015-01-29 Thread Brian Paul
Ping. I'll handle the cherry-pick to 10.4 since a small code change is needed. -Brian On 01/27/2015 08:06 PM, Brian Paul wrote: The _mesa_dlist_alloc() function is only guaranteed to return a pointer with 4-byte alignment. On 64-bit systems which don't support unaligned loads (e.g. SPARC or M

[Mesa-dev] [PATCH] mesa: fix display list 8-byte alignment issue

2015-01-27 Thread Brian Paul
The _mesa_dlist_alloc() function is only guaranteed to return a pointer with 4-byte alignment. On 64-bit systems which don't support unaligned loads (e.g. SPARC or MIPS) this could lead to a bus error in the VBO code. The solution is to add a new _mesa_dlist_alloc_aligned() function which will r