nir: Remove dead nir_const_value variables
nir_const_value variables in nir_const_value_for_int and nor_const_value_for_uint are unused resulting in unnecessary dead code. The unused-variable warning has been suppressed by the memset following their declarations. Reviewed-by: Faith Ekstrand <faith.ekstrand@collabora.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24851>
This commit is contained in:
@@ -313,9 +313,6 @@ nir_const_value_for_raw_uint(uint64_t x, unsigned bit_size)
|
|||||||
static inline nir_const_value
|
static inline nir_const_value
|
||||||
nir_const_value_for_int(int64_t i, unsigned bit_size)
|
nir_const_value_for_int(int64_t i, unsigned bit_size)
|
||||||
{
|
{
|
||||||
nir_const_value v;
|
|
||||||
memset(&v, 0, sizeof(v));
|
|
||||||
|
|
||||||
assert(bit_size <= 64);
|
assert(bit_size <= 64);
|
||||||
if (bit_size < 64) {
|
if (bit_size < 64) {
|
||||||
assert(i >= (-(1ll << (bit_size - 1))));
|
assert(i >= (-(1ll << (bit_size - 1))));
|
||||||
@@ -328,9 +325,6 @@ nir_const_value_for_int(int64_t i, unsigned bit_size)
|
|||||||
static inline nir_const_value
|
static inline nir_const_value
|
||||||
nir_const_value_for_uint(uint64_t u, unsigned bit_size)
|
nir_const_value_for_uint(uint64_t u, unsigned bit_size)
|
||||||
{
|
{
|
||||||
nir_const_value v;
|
|
||||||
memset(&v, 0, sizeof(v));
|
|
||||||
|
|
||||||
assert(bit_size <= 64);
|
assert(bit_size <= 64);
|
||||||
if (bit_size < 64)
|
if (bit_size < 64)
|
||||||
assert(u < (1ull << bit_size));
|
assert(u < (1ull << bit_size));
|
||||||
|
Reference in New Issue
Block a user