Improve removal of dead calls to allocator helpers.
authorEugene Rozenfeld <erozen@microsoft.com>
Sun, 16 Dec 2018 20:07:42 +0000 (12:07 -0800)
committerEugene Rozenfeld <erozen@microsoft.com>
Sat, 22 Dec 2018 06:38:52 +0000 (22:38 -0800)
commit8580d9ee898e8792e92f51658e82b9d895885581
tree44ce574aa4cfc5a46dabc3ab7b1ef49060237265
parent2dd8fa65e8173a73f3acccf490c699a07deebd60
Improve removal of dead calls to allocator helpers.

This change improves detection of allocators with side effects.
Allocators can cause side effects if the allocated object may have a finalizer.
This change adds a pHasSideEffects parameter to getNewHelper JitEE interface
method. It's used by the jit to check for allocator side effects instead of
guessing from helper ids.

Fixes dotnet/coreclr#21530.

Commit migrated from https://github.com/dotnet/coreclr/commit/eea057675de7914af12c6168db0f3bebea35be5b
23 files changed:
src/coreclr/src/ToolBox/superpmi/superpmi-shared/icorjitinfoimpl.h
src/coreclr/src/ToolBox/superpmi/superpmi-shared/lwmlist.h
src/coreclr/src/ToolBox/superpmi/superpmi-shared/methodcontext.cpp
src/coreclr/src/ToolBox/superpmi/superpmi-shared/methodcontext.h
src/coreclr/src/ToolBox/superpmi/superpmi-shim-collector/icorjitinfo.cpp
src/coreclr/src/ToolBox/superpmi/superpmi-shim-counter/icorjitinfo.cpp
src/coreclr/src/ToolBox/superpmi/superpmi-shim-simple/icorjitinfo.cpp
src/coreclr/src/ToolBox/superpmi/superpmi/icorjitinfo.cpp
src/coreclr/src/inc/corinfo.h
src/coreclr/src/jit/ICorJitInfo_API_wrapper.hpp
src/coreclr/src/jit/compiler.h
src/coreclr/src/jit/compiler.hpp
src/coreclr/src/jit/gentree.cpp
src/coreclr/src/jit/gentree.h
src/coreclr/src/jit/objectalloc.cpp
src/coreclr/src/jit/utils.cpp
src/coreclr/src/jit/utils.h
src/coreclr/src/vm/jitinterface.cpp
src/coreclr/src/vm/jitinterface.h
src/coreclr/src/vm/methodtable.cpp
src/coreclr/src/vm/methodtable.h
src/coreclr/src/zap/zapinfo.cpp
src/coreclr/src/zap/zapinfo.h