diff --git a/src/coreclr/jit/morph.cpp b/src/coreclr/jit/morph.cpp index 8fbce8a586e79..a3879b8ea2b5e 100644 --- a/src/coreclr/jit/morph.cpp +++ b/src/coreclr/jit/morph.cpp @@ -17226,10 +17226,6 @@ void Compiler::fgMorphBlocks() block = block->bbNext; } while (block != nullptr); - // We are done with the global morphing phase - fgGlobalMorph = false; - compCurBB = nullptr; - // Under OSR, we no longer need to specially protect the original method entry // if (opts.IsOSR() && (fgEntryBB != nullptr) && (fgEntryBB->bbFlags & BBF_IMPORTED)) @@ -17247,6 +17243,10 @@ void Compiler::fgMorphBlocks() fgDispBasicBlocks(true); } #endif + + // We are done with the global morphing phase + fgGlobalMorph = false; + compCurBB = nullptr; } //------------------------------------------------------------------------