Set vtable offset as contained (#722)
authorDong-Heon Jung <clamp03@gmail.com>
Wed, 18 Dec 2019 01:01:37 +0000 (10:01 +0900)
committerSergey Andreenko <seandree@microsoft.com>
Wed, 18 Dec 2019 01:01:37 +0000 (17:01 -0800)
- Can remove a machine instruction which adds vtable offset

src/coreclr/src/jit/lower.cpp

index f8068a4..6322be6 100644 (file)
@@ -4138,6 +4138,7 @@ GenTree* Lowering::LowerVirtualVtableCall(GenTreeCall* call)
             BlockRange().InsertBefore(call, std::move(range));
 
             LIR::Range range2 = LIR::SeqTree(comp, lclvNodeStore2);
+            ContainCheckIndir(tmpTree->AsIndir());
             JITDUMP("result of obtaining pointer to virtual table 2nd level indirection:\n");
             DISPRANGE(range2);
             BlockRange().InsertAfter(lclvNodeStore, std::move(range2));