summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/freedreno
diff options
context:
space:
mode:
authorRob Clark <[email protected]>2016-11-10 16:08:39 -0500
committerRob Clark <[email protected]>2016-11-12 08:57:03 -0500
commitdfc001dccc7a29b1acf8d1ecf8072223aa98bc1b (patch)
tree76e07fa2b4bf7d4cc0124fddfa8657c91365d93f /src/gallium/drivers/freedreno
parent2e2562cabbe9a1d3fb997ccaccc20ba31b2006c3 (diff)
freedreno/ir3: fixup ralloc fallout
Fixes fallout from acc23b04 ("ralloc: remove memset from ralloc_size"). We were still depending on zero'd allocations in a couple of places. Signed-off-by: Rob Clark <[email protected]>
Diffstat (limited to 'src/gallium/drivers/freedreno')
-rw-r--r--src/gallium/drivers/freedreno/ir3/ir3.c2
-rw-r--r--src/gallium/drivers/freedreno/ir3/ir3_compiler_nir.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/gallium/drivers/freedreno/ir3/ir3.c b/src/gallium/drivers/freedreno/ir3/ir3.c
index 9f2116a520f..c0a39d70def 100644
--- a/src/gallium/drivers/freedreno/ir3/ir3.c
+++ b/src/gallium/drivers/freedreno/ir3/ir3.c
@@ -46,7 +46,7 @@ void * ir3_alloc(struct ir3 *shader, int sz)
struct ir3 * ir3_create(struct ir3_compiler *compiler,
unsigned nin, unsigned nout)
{
- struct ir3 *shader = ralloc(compiler, struct ir3);
+ struct ir3 *shader = rzalloc(compiler, struct ir3);
shader->compiler = compiler;
shader->ninputs = nin;
diff --git a/src/gallium/drivers/freedreno/ir3/ir3_compiler_nir.c b/src/gallium/drivers/freedreno/ir3/ir3_compiler_nir.c
index b1b9d6b9734..f4d92650595 100644
--- a/src/gallium/drivers/freedreno/ir3/ir3_compiler_nir.c
+++ b/src/gallium/drivers/freedreno/ir3/ir3_compiler_nir.c
@@ -235,7 +235,7 @@ static void
declare_var(struct ir3_compile *ctx, nir_variable *var)
{
unsigned length = glsl_get_length(var->type) * 4; /* always vec4, at least with ttn */
- struct ir3_array *arr = ralloc(ctx, struct ir3_array);
+ struct ir3_array *arr = rzalloc(ctx, struct ir3_array);
arr->id = ++ctx->num_arrays;
arr->length = length;
arr->var = var;