[Mesa-dev] [PATCH 0/7] Fix ralloc/rzalloc usage v2

Ilia Mirkin imirkin at alum.mit.edu
Tue Jun 14 15:07:02 UTC 2016


I assume you've only tested this with i965? ralloc is also used by
st/mesa, freedreno, and vc4. Should probably try to coordinate with
the responsible developers before making the big switch.

  -ilia

On Tue, Jun 14, 2016 at 10:58 AM, Juha-Pekka Heikkila
<juhapekka.heikkila at gmail.com> wrote:
> Here is fixed version of this ralloc set. Now I got to run this on many
> different machines thanks to Mark Janes. There didn't show up any
> regressions on different gen hw. On my IVB I've been running also many
> different traces with Apitrace while having Valgrind running on background
> but Valgrind did seem to be happy with my changes.
>
> As a performance test I did shader-db compile runs 10 times and compare
> timing results against what Mesa master does on my IVB. To my surprise this
> does bring reasonable gain which also seem to be repeatable, on my IVB
> shader compile time is around 5% faster with these changes.
>
> /Juha-Pekka
>
> Juha-Pekka Heikkila (7):
>   glsl: Fix reading of uninitialized memory
>   util: use rzalloc instead on ralloc in _mesa_hash_table_create()
>   util: use rzalloc instead on ralloc in _mesa_set_create(()
>   nir: zero allocated memory where needed
>   i965/vec4: zero allocated memory where needed
>   i965/fs: fill allocated memory with zeros where needed
>   util: Fix ralloc to use malloc instead of calloc
>
>  src/compiler/glsl/ast_to_hir.cpp                   |  2 +-
>  src/compiler/glsl/glcpp/glcpp-parse.y              |  4 +-
>  src/compiler/glsl/link_uniform_blocks.cpp          |  2 +-
>  src/compiler/glsl_types.cpp                        |  2 +-
>  src/compiler/nir/nir.c                             |  6 +--
>  src/compiler/nir/nir_opt_dce.c                     |  2 +-
>  src/compiler/nir/nir_phi_builder.c                 |  2 +-
>  src/compiler/nir/nir_search.c                      |  2 +-
>  src/compiler/nir/nir_to_ssa.c                      |  2 +-
>  src/compiler/nir/nir_worklist.c                    |  2 +-
>  .../drivers/dri/i965/brw_fs_copy_propagation.cpp   |  2 +-
>  .../dri/i965/brw_fs_dead_code_eliminate.cpp        |  4 +-
>  .../dri/i965/brw_vec4_dead_code_eliminate.cpp      |  4 +-
>  src/util/hash_table.c                              |  2 +-
>  src/util/ralloc.c                                  | 49 +++++++++++++++-------
>  src/util/ralloc.h                                  |  2 +-
>  src/util/set.c                                     |  2 +-
>  17 files changed, 54 insertions(+), 37 deletions(-)
>
> --
> 1.9.1
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list