diff --git a/src/coreclr/jit/inductionvariableopts.cpp b/src/coreclr/jit/inductionvariableopts.cpp index a3487de6757b9..e4b03b49905a0 100644 --- a/src/coreclr/jit/inductionvariableopts.cpp +++ b/src/coreclr/jit/inductionvariableopts.cpp @@ -1169,8 +1169,9 @@ PhaseStatus Compiler::optInductionVariables() bool changed = false; - m_dfsTree = fgComputeDfs(); - m_loops = FlowGraphNaturalLoops::Find(m_dfsTree); + optReachableBitVecTraits = nullptr; + m_dfsTree = fgComputeDfs(); + m_loops = FlowGraphNaturalLoops::Find(m_dfsTree); LoopLocalOccurrences loopLocals(m_loops);