From 2acb86c9b086bdb9a3897db0b93820652e07cb59 Mon Sep 17 00:00:00 2001 From: marha Date: Sun, 8 Jun 2014 14:33:00 +0200 Subject: xwininfo libX11 mesa mkfontscale xserver git updated 8 June 2014 xserver commit e27a839bf0488d5b1cc2e2a887f2ea0e3d790790 libxcb commit d978a4f69b30b630f28d07f1003cf290284d24d8 libxcb/xcb-proto commit 389889e2f95af19e7fc7ac89e7faeb2f28652415 xkeyboard-config commit bc3ac1b0d152e929b3532a541596cf9fe286bb9e libX11 commit d81fed46144d089bdfa1d916a28dffc9ebffe1e4 libXdmcp commit fe8eab93e9bcdbe8bb8052434bb5e676e3a0ee8f libXext commit 11aad96bd689d54156064d2e81213dc827a689d1 libfontenc commit 0037a42107b952c9d903719615747e760e4e7247 libXinerama commit edd95182b26eb5d576d4878c559e0f17dddaa909 libXau commit 1e4635be11154dd8262f37b379511bd627defa2a xkbcomp commit d4e02a09258063c6d024c3ccd42d6b22212e6e18 pixman commit 9cd283b2eb8279824406bfd47b020d21fc00cf82 xextproto commit 66afec3f49e8eb0d4c2e9af7088fc3116d4bafd7 randrproto commit a4a6694c059d74247c16527eef4a0ec9f56bbef6 glproto commit f84853d97d5749308992412a215fa518b6536eb3 mkfontscale commit 48e541dc2f2fc3f4e99d3e168c28241ff5adff4d xwininfo commit 017b3736489985999d8dcf4d9e473e1fd6dd3647 libXft commit 214f9b5306d833e2787c75fe41dfdc9228fcb738 libXmu commit 22d9c590901e121936f50dee97dc60c4f7defb63 libxtrans commit a57a7f62242e1ea972b81414741729bf3dbae0a4 fontconfig commit f44bfad235e63bb792c38e16ae1fbd281ec1453b mesa commit eb58aa9cf015e79a0fcf2e088676e6aa1d5dabce --- mesalib/src/mesa/drivers/common/meta_blit.c | 3 +++ mesalib/src/mesa/main/get.c | 16 +++++++++++++++- mesalib/src/mesa/main/get_hash_generator.py | 2 +- mesalib/src/mesa/main/get_hash_params.py | 4 ++-- mesalib/src/mesa/main/hash.c | 10 ++++++++++ mesalib/src/mesa/main/performance_monitor.c | 5 +++++ mesalib/src/mesa/program/prog_hash_table.c | 8 ++++++++ mesalib/src/mesa/state_tracker/st_atom_texture.c | 11 ++--------- 8 files changed, 46 insertions(+), 13 deletions(-) (limited to 'mesalib/src/mesa') diff --git a/mesalib/src/mesa/drivers/common/meta_blit.c b/mesalib/src/mesa/drivers/common/meta_blit.c index 5929619f3..f26ef93c1 100644 --- a/mesalib/src/mesa/drivers/common/meta_blit.c +++ b/mesalib/src/mesa/drivers/common/meta_blit.c @@ -430,6 +430,9 @@ blitframebuffer_texture(struct gl_context *ctx, srcLevel = 0; target = meta_temp_texture->Target; texObj = _mesa_lookup_texture(ctx, meta_temp_texture->TexObj); + if (texObj == NULL) { + return false; + } _mesa_meta_setup_copypix_texture(ctx, meta_temp_texture, srcX0, srcY0, diff --git a/mesalib/src/mesa/main/get.c b/mesalib/src/mesa/main/get.c index 80a5839b5..9b56edb74 100644 --- a/mesalib/src/mesa/main/get.c +++ b/mesalib/src/mesa/main/get.c @@ -847,6 +847,16 @@ find_custom_value(struct gl_context *ctx, const struct value_desc *d, union valu v->value_int = ctx->Array.VAO->IndexBufferObj->Name; break; + /* ARB_vertex_array_bgra */ + case GL_COLOR_ARRAY_SIZE: + array = &ctx->Array.VAO->VertexAttrib[VERT_ATTRIB_COLOR0]; + v->value_int = array->Format == GL_BGRA ? GL_BGRA : array->Size; + break; + case GL_SECONDARY_COLOR_ARRAY_SIZE: + array = &ctx->Array.VAO->VertexAttrib[VERT_ATTRIB_COLOR1]; + v->value_int = array->Format == GL_BGRA ? GL_BGRA : array->Size; + break; + /* ARB_copy_buffer */ case GL_COPY_READ_BUFFER: v->value_int = ctx->CopyReadBuffer->Name; @@ -995,7 +1005,11 @@ find_custom_value(struct gl_context *ctx, const struct value_desc *d, union valu break; /* GL_ARB_shader_atomic_counters */ case GL_ATOMIC_COUNTER_BUFFER_BINDING: - v->value_int = ctx->AtomicBuffer->Name; + if (ctx->AtomicBuffer) { + v->value_int = ctx->AtomicBuffer->Name; + } else { + v->value_int = 0; + } break; /* GL_ARB_draw_indirect */ case GL_DRAW_INDIRECT_BUFFER_BINDING: diff --git a/mesalib/src/mesa/main/get_hash_generator.py b/mesalib/src/mesa/main/get_hash_generator.py index 96bc49587..b200d1973 100644 --- a/mesalib/src/mesa/main/get_hash_generator.py +++ b/mesalib/src/mesa/main/get_hash_generator.py @@ -52,7 +52,7 @@ def print_header(): (prime_factor, prime_step) def print_params(params): - print "static struct value_desc values[] = {" + print "static const struct value_desc values[] = {" for p in params: print " { %s, %s }," % (p[0], p[1]) diff --git a/mesalib/src/mesa/main/get_hash_params.py b/mesalib/src/mesa/main/get_hash_params.py index d40fa0778..c7a6e02af 100644 --- a/mesalib/src/mesa/main/get_hash_params.py +++ b/mesalib/src/mesa/main/get_hash_params.py @@ -199,7 +199,7 @@ descriptor=[ [ "NORMAL_ARRAY_TYPE", "ARRAY_ENUM(VertexAttrib[VERT_ATTRIB_NORMAL].Type), NO_EXTRA" ], [ "NORMAL_ARRAY_STRIDE", "ARRAY_INT(VertexAttrib[VERT_ATTRIB_NORMAL].Stride), NO_EXTRA" ], [ "COLOR_ARRAY", "ARRAY_BOOL(VertexAttrib[VERT_ATTRIB_COLOR0].Enabled), NO_EXTRA" ], - [ "COLOR_ARRAY_SIZE", "ARRAY_INT(VertexAttrib[VERT_ATTRIB_COLOR0].Size), NO_EXTRA" ], + [ "COLOR_ARRAY_SIZE", "LOC_CUSTOM, TYPE_INT, 0, NO_EXTRA" ], [ "COLOR_ARRAY_TYPE", "ARRAY_ENUM(VertexAttrib[VERT_ATTRIB_COLOR0].Type), NO_EXTRA" ], [ "COLOR_ARRAY_STRIDE", "ARRAY_INT(VertexAttrib[VERT_ATTRIB_COLOR0].Stride), NO_EXTRA" ], [ "TEXTURE_COORD_ARRAY", "LOC_CUSTOM, TYPE_BOOLEAN, offsetof(struct gl_client_array, Enabled), NO_EXTRA" ], @@ -552,7 +552,7 @@ descriptor=[ [ "SECONDARY_COLOR_ARRAY", "ARRAY_BOOL(VertexAttrib[VERT_ATTRIB_COLOR1].Enabled), NO_EXTRA" ], [ "SECONDARY_COLOR_ARRAY_TYPE", "ARRAY_ENUM(VertexAttrib[VERT_ATTRIB_COLOR1].Type), NO_EXTRA" ], [ "SECONDARY_COLOR_ARRAY_STRIDE", "ARRAY_INT(VertexAttrib[VERT_ATTRIB_COLOR1].Stride), NO_EXTRA" ], - [ "SECONDARY_COLOR_ARRAY_SIZE", "ARRAY_INT(VertexAttrib[VERT_ATTRIB_COLOR1].Size), NO_EXTRA" ], + [ "SECONDARY_COLOR_ARRAY_SIZE", "LOC_CUSTOM, TYPE_INT, 0, NO_EXTRA" ], # GL_EXT_fog_coord [ "CURRENT_FOG_COORDINATE", "CONTEXT_FLOAT(Current.Attrib[VERT_ATTRIB_FOG][0]), extra_flush_current" ], diff --git a/mesalib/src/mesa/main/hash.c b/mesalib/src/mesa/main/hash.c index 23018e9da..674c29d65 100644 --- a/mesalib/src/mesa/main/hash.c +++ b/mesalib/src/mesa/main/hash.c @@ -115,10 +115,20 @@ _mesa_NewHashTable(void) if (table) { table->ht = _mesa_hash_table_create(NULL, uint_key_compare); + if (table->ht == NULL) { + free(table); + _mesa_error_no_memory(__func__); + return NULL; + } + _mesa_hash_table_set_deleted_key(table->ht, uint_key(DELETED_KEY_VALUE)); mtx_init(&table->Mutex, mtx_plain); mtx_init(&table->WalkMutex, mtx_plain); } + else { + _mesa_error_no_memory(__func__); + } + return table; } diff --git a/mesalib/src/mesa/main/performance_monitor.c b/mesalib/src/mesa/main/performance_monitor.c index 21b9423e0..9d1a6b4d8 100644 --- a/mesalib/src/mesa/main/performance_monitor.c +++ b/mesalib/src/mesa/main/performance_monitor.c @@ -1036,6 +1036,11 @@ _mesa_CreatePerfQueryINTEL(GLuint queryId, GLuint *queryHandle) } m = new_performance_monitor(ctx, first); + if (m == NULL) { + _mesa_error_no_memory(__func__); + return; + } + _mesa_HashInsert(ctx->PerfMonitor.Monitors, first, m); *queryHandle = first; diff --git a/mesalib/src/mesa/program/prog_hash_table.c b/mesalib/src/mesa/program/prog_hash_table.c index f45ed46af..2445d8434 100644 --- a/mesalib/src/mesa/program/prog_hash_table.c +++ b/mesalib/src/mesa/program/prog_hash_table.c @@ -142,6 +142,10 @@ hash_table_insert(struct hash_table *ht, void *data, const void *key) struct hash_node *node; node = calloc(1, sizeof(*node)); + if (node == NULL) { + _mesa_error_no_memory(__func__); + return; + } node->data = data; node->key = key; @@ -167,6 +171,10 @@ hash_table_replace(struct hash_table *ht, void *data, const void *key) } hn = calloc(1, sizeof(*hn)); + if (hn == NULL) { + _mesa_error_no_memory(__func__); + return false; + } hn->data = data; hn->key = key; diff --git a/mesalib/src/mesa/state_tracker/st_atom_texture.c b/mesalib/src/mesa/state_tracker/st_atom_texture.c index 928a4ffd2..e2d26ee24 100644 --- a/mesalib/src/mesa/state_tracker/st_atom_texture.c +++ b/mesalib/src/mesa/state_tracker/st_atom_texture.c @@ -358,7 +358,7 @@ update_textures(struct st_context *st, { const GLuint old_max = *num_textures; GLbitfield samplers_used = prog->SamplersUsed; - GLuint unit, new_count; + GLuint unit; if (samplers_used == 0x0 && old_max == 0) return; @@ -387,16 +387,9 @@ update_textures(struct st_context *st, pipe_sampler_view_reference(&(sampler_views[unit]), sampler_view); } - /* Ex: if old_max = 3 and *num_textures = 1, we need to pass an - * array of views={X, NULL, NULL} to unref the old texture views - * at positions [1] and [2]. - */ - new_count = MAX2(*num_textures, old_max); - assert(new_count <= max_units); - cso_set_sampler_views(st->cso_context, shader_stage, - new_count, + *num_textures, sampler_views); } -- cgit v1.2.3