Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix release build infinite loop (#49943)
The problem manifested as an infinite loop during the StackLevelSetter phase in the release build SuperPMI replay of the tests, but also occurs as a normal release build test run of the varargsupport.il test. The issue is we had corrupt LIR gtPrev links, with a cycle. The problem had nothing to do with StackLevelSetter -- it just happened to be the first phase that iterated in reverse over the gtPrev links. The corruption was introduced in the importer, in `verConvertBBToThrowVerificationException`. It required a verification failure in a filter (possibly also catch) clause where the JIT would throw away the currently imported code and convert the block to a call to the verification failure helper. This was a classic case of important, functional code being under `#ifdef DEBUG` that is needed in non-DEBUG as well. The result was we would end up adding an `ASG(LCL_VAR, CATCH_ARG)` to the statement list twice, with the same `CATCH_ARG` node. Fixes #45580
- Loading branch information