Fix some interactions between tiering and multi-core JIT (#40948)
Fix some interactions between tiering and multi-core JIT
Issues:
- When a multi-core JIT profile includes a method for which prejitted code is available, and the method contains a loop, when playing back the profile the multi-core JIT of the method disables call counting for the method, then when the method gets called the prejitted code is used but does not get tiered up later. Also hits assertion failures.
- Tier 1 rejits also record the method in the multi-core JIT profile, another case where the above situation can occur
Fixes:
- Only record a method in the multi-core JIT profile for the default code version and only once for the code version
- When playing back a profile, don't disable call counting for a method immediately. Just record some info that may be used later when the method is actually gets called, if the multi-core jitted code gets used, to disable call counting if necessary.
12 files changed: