Jit: fix for broken type equality optimization
authorAndy Ayers <andya@microsoft.com>
Mon, 13 Feb 2017 19:05:02 +0000 (11:05 -0800)
committerAndy Ayers <andya@microsoft.com>
Mon, 13 Feb 2017 20:22:26 +0000 (12:22 -0800)
commita26e2c670fc7a793794f4a499212a115c5d5a4b3
treebb0a48bccdee9c34ead108010bd16e51e4a7f0b4
parent8f3b42948fd24d13666ddd1bcfcbd4a5ac74a9ab
Jit: fix for broken type equality optimization

The jit relies on a particular tree remaining intact during importation
to optimize type equality tests commonly found in generics.

In #7909 the jit started aggressively spilling the evaluation stack before
calls, which broke up the trees needed for the optimizations.

In the special cases pertaining to type tests the trees can safely remain
intact because we know the calls can't interact with the computations on
the stack. Recognize these cases and selectively suppress spilling.

Closes #9552.
src/jit/importer.cpp