Fix AssertionDsc::Equals OAK_NO_THROW's handling
authorMike Danes <onemihaid@hotmail.com>
Thu, 9 Mar 2017 20:04:53 +0000 (22:04 +0200)
committerMike Danes <onemihaid@hotmail.com>
Thu, 9 Mar 2017 20:04:53 +0000 (22:04 +0200)
commit75ebce8882c52e08f17dfabc16b61fe1f2028df2
tree3496f2445f5c565d792af60c1feaced8ca4fd067
parentdbf716acd1868e4f43686f98ade9da6cd87b47ee
Fix AssertionDsc::Equals OAK_NO_THROW's handling

op2 of a OAK_NO_THROW assertions is O2K_INVALID and HasSameOp2 always returns false for O2K_INVALID. As a result OAK_NO_THROW assertions always compare unequal and duplicate assertions are generated that waste space in the assertion table.

Also, HasSameOp1 only checks op1.vn but that is bogus for OAK_NO_THROW assertions, most of the time is 0.

Commit migrated from https://github.com/dotnet/coreclr/commit/12820c1c9deb3783573f02ba6a94246e7081c290
src/coreclr/src/jit/compiler.h