radeonsi: don't declare pointers to static strings
authorNicolai Hähnle <nicolai.haehnle@amd.com>
Thu, 6 Dec 2018 11:43:44 +0000 (12:43 +0100)
committerMarek Olšák <marek.olsak@amd.com>
Thu, 13 Jun 2019 00:28:23 +0000 (20:28 -0400)
The compiler should be able to optimize them away, but still. There's
no point in declaring those as pointers, and if the compiler *doesn't*
optimize them away, they add unnecessary load-time relocations.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/gallium/drivers/radeonsi/si_shader.c

index 21b2819c8570d3555dc5af916877a16b7bc66779..ad965a11750442cbbd829e0bf9489e6f6ea99f71 100644 (file)
 
 #include "compiler/nir/nir.h"
 
-static const char *scratch_rsrc_dword0_symbol =
+static const char scratch_rsrc_dword0_symbol[] =
        "SCRATCH_RSRC_DWORD0";
 
-static const char *scratch_rsrc_dword1_symbol =
+static const char scratch_rsrc_dword1_symbol[] =
        "SCRATCH_RSRC_DWORD1";
 
 struct si_shader_output_values