[release/9.0] Fix devirtualization across genericness in the hierarchy by MichalStrehovsky · Pull Request #108470 · dotnet/runtime

@MichalStrehovsky

This code was trying to answer question: "Was this method overriden by something else in a more derived class"? It was walking the base hierarchy in canonical form, but that was leading to methods not resolving at all. The fix is to walk the non-canonical hierarchy and canonicalize after we resolved everything.

I ran into this in dotnet#108379 that unlocked more whole program devirtualization and `StringSearchValuesBase` is in this shape.

jeffschwMSFT

@jeffschwMSFT

This was referenced

Oct 3, 2024