summaryrefslogtreecommitdiff
path: root/compiler_and_linker/unsorted/IroPropagate.c
diff options
context:
space:
mode:
authorAsh Wolf <ninji@wuffs.org>2023-01-13 01:38:15 +0000
committerAsh Wolf <ninji@wuffs.org>2023-01-13 01:38:15 +0000
commit08d21a052b9afc37292ec3fad390502610e2cb32 (patch)
tree270737c790f5d1bb05f68498f8233640ada6a0c5 /compiler_and_linker/unsorted/IroPropagate.c
parent54628993e0038c7bea9c064491974985b6699502 (diff)
parent9d985413ce2b60a1a8cf001913ee8dac81c03aac (diff)
downloadMWCC-08d21a052b9afc37292ec3fad390502610e2cb32.tar.gz
MWCC-08d21a052b9afc37292ec3fad390502610e2cb32.zip
Merge remote-tracking branch 'origin/main'
Diffstat (limited to 'compiler_and_linker/unsorted/IroPropagate.c')
-rw-r--r--compiler_and_linker/unsorted/IroPropagate.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler_and_linker/unsorted/IroPropagate.c b/compiler_and_linker/unsorted/IroPropagate.c
index fb3a9ad..401250c 100644
--- a/compiler_and_linker/unsorted/IroPropagate.c
+++ b/compiler_and_linker/unsorted/IroPropagate.c
@@ -509,7 +509,7 @@ void IRO_ExpressionPropagation(void) {
if (IRO_IsVariable(linear) && !(linear->flags & IROLF_Assigned)) {
if ((var = IRO_FindVar(linear->u.monadic->u.node->data.objref, 0, 1))) {
- for (ass = IRO_LastAssign; ass; ass = ass->next) {
+ for (ass = IRO_FirstAssign; ass; ass = ass->next) {
if (ass->varIndex == var->index && Bv_IsBitSet(ass->index, IRO_Avail) && !PropagationHasDefsInUnorderedRegions(linear, ass->linear2)) {
if (ass->linear2->type == IROLinearOperand && IRO_is_CPtypeequal(linear->rtype, ass->linear->u.diadic.left->rtype)) {
ENode *enode = IRO_NewENode(ass->linear2->u.node->type);