From f82f5af5e212373230b8df4dedbd8e1c950e1cc1 Mon Sep 17 00:00:00 2001 From: Vasyl Teliman Date: Thu, 29 Apr 2021 11:44:59 +0300 Subject: [PATCH] Invalidate DefUse analysis (#4255) Fixes #4252. --- source/reduce/change_operand_to_undef_reduction_opportunity.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/source/reduce/change_operand_to_undef_reduction_opportunity.cpp b/source/reduce/change_operand_to_undef_reduction_opportunity.cpp index 8e33da66..7cc06a03 100644 --- a/source/reduce/change_operand_to_undef_reduction_opportunity.cpp +++ b/source/reduce/change_operand_to_undef_reduction_opportunity.cpp @@ -35,6 +35,7 @@ void ChangeOperandToUndefReductionOpportunity::Apply() { assert(operand_type_id); auto undef_id = FindOrCreateGlobalUndef(context_, operand_type_id); inst_->SetOperand(operand_index_, {undef_id}); + context_->InvalidateAnalyses(opt::IRContext::kAnalysisDefUse); } } // namespace reduce