diff options
Diffstat (limited to 'src/compiler/nir/nir_deref.c')
-rw-r--r-- | src/compiler/nir/nir_deref.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/compiler/nir/nir_deref.c b/src/compiler/nir/nir_deref.c index e06fd07aeb2..09eaa524e42 100644 --- a/src/compiler/nir/nir_deref.c +++ b/src/compiler/nir/nir_deref.c @@ -657,10 +657,13 @@ rematerialize_deref_in_block(nir_deref_instr *deref, switch (deref->deref_type) { case nir_deref_type_var: case nir_deref_type_array_wildcard: - case nir_deref_type_cast: /* Nothing more to do */ break; + case nir_deref_type_cast: + new_deref->cast.ptr_stride = deref->cast.ptr_stride; + break; + case nir_deref_type_array: case nir_deref_type_ptr_as_array: assert(!nir_src_as_deref(deref->arr.index)); |