struct gl_context *ctx = batch->ctx;
int pos = 0;
int used = batch->used;
- uint8_t *buffer = batch->buffer;
+ uint64_t *buffer = batch->buffer;
_glapi_set_dispatch(ctx->CurrentServerDispatch);
while (pos < used) {
const struct marshal_cmd_base *cmd =
- (const struct marshal_cmd_base *)&buffer[pos];
+ (const struct marshal_cmd_base *)&buffer[pos / 8];
_mesa_unmarshal_dispatch[cmd->cmd_id](ctx, cmd);
pos += cmd->cmd_size;
int used;
/** Data contained in the command buffer. */
-#ifdef _MSC_VER
- __declspec(align(8))
-#else
- __attribute__((aligned(8)))
-#endif
- uint8_t buffer[MARSHAL_MAX_CMD_SIZE];
+ uint64_t buffer[MARSHAL_MAX_CMD_SIZE / 8];
};
struct glthread_client_attrib {
struct glthread_batch *next = glthread->next_batch;
const int aligned_size = align(size, 8);
struct marshal_cmd_base *cmd_base =
- (struct marshal_cmd_base *)&next->buffer[glthread->used];
+ (struct marshal_cmd_base *)&next->buffer[glthread->used / 8];
glthread->used += aligned_size;
cmd_base->cmd_id = cmd_id;
cmd_base->cmd_size = aligned_size;