[interp] Enable inlining of object constructors (#15665)
commit009b0dd4c307f60e2b7d0b7e512fe8cf97ffb34f
authorVlad Brezae <brezaevlad@gmail.com>
Mon, 22 Jul 2019 14:03:26 +0000 (22 17:03 +0300)
committerGitHub <noreply@github.com>
Mon, 22 Jul 2019 14:03:26 +0000 (22 17:03 +0300)
treebb1a3f55649a04d1163e8d6f092fea968e5f2784
parent3c2813deb7720c954554b11344915af803f84138
[interp] Enable inlining of object constructors (#15665)

* [interp] Split code for obj / vt newobj instruction

* [interp] Enable inlining of object constructors

If the ctor was inlined, the newobj instruction receives a max ushort as the data item for the index, so it doesn't execute the ctor in this case. Also, when inlining, we need to push on the stack the allocated object, once as argument for the ctor and the second needs to remain on the stack as the result of the IL newobj instruction.
mono/mini/interp/interp.c
mono/mini/interp/transform.c