Revert "don't simplify st in _recursive_lazyop when unbind (#4011)" (#4013)

This reverts commit 2b704d7452.
This commit is contained in:
chenyu
2024-03-30 17:36:17 -04:00
committed by GitHub
parent 2b704d7452
commit bee8eeae55

View File

@@ -33,13 +33,13 @@ def _recursive_lazyop(buf:LazyBuffer, membufs:List[LazyBuffer], var_vals:Dict[Va
# consts are always fused and generated
if buf.op is LoadOps.CONST:
unbound_st, st_var_vals = st.unbind()
unbound_st, st_var_vals = st.simplify().unbind()
var_vals.update(st_var_vals)
return LazyOp(BufferOps.CONST, (), ConstBuffer(buf.arg, buf.dtype, unbound_st))
# if we aren't fusing it, it's a load and we add it to the inputs
if buf.realized or (buf in realizes and not first):
unbound_st, st_var_vals = st.unbind()
unbound_st, st_var_vals = st.simplify().unbind()
var_vals.update(st_var_vals)
if assign_to is not None and buf is assign_to:
assert assign_idx is not None