aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Airlie <[email protected]>2020-06-19 15:22:18 +1000
committerDave Airlie <[email protected]>2020-07-08 06:06:05 +1000
commitb4802d6ea13bf547b6e5f9fd0e4059965bf2794a (patch)
treec0857a41a799ae85b529b89cdf382cf6b10e3ae4
parent3e455d6ad31400f4733a2f859cc5ecade7efdbe1 (diff)
draw: use common exit path in pipeline finish.
I need to add a missing free here, and it seems pointless duplication Reviewed-by: Roland Scheidegger <[email protected]> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5555>
-rw-r--r--src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c b/src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c
index d9a5862e442..f2534709832 100644
--- a/src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c
+++ b/src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline_llvm.c
@@ -728,13 +728,7 @@ llvm_pipeline_generic(struct draw_pt_middle_end *middle,
if (prim_info->count == 0) {
debug_printf("GS/IA didn't emit any vertices!\n");
-
- FREE(vert_info->verts);
- if (free_prim_info) {
- FREE(tes_elts_out);
- FREE(prim_info->primitive_lengths);
- }
- return;
+ goto out;
}
draw_stats_clipper_primitives(draw, prim_info);
@@ -762,6 +756,7 @@ llvm_pipeline_generic(struct draw_pt_middle_end *middle,
emit( fpme->emit, vert_info, prim_info );
}
}
+out:
FREE(vert_info->verts);
if (free_prim_info) {
FREE(tes_elts_out);