summaryrefslogtreecommitdiff
path: root/src/vm/ilstubresolver.cpp
diff options
context:
space:
mode:
authorBruce Forstall <brucefo@microsoft.com>2016-10-26 15:52:06 -0700
committerBruce Forstall <brucefo@microsoft.com>2016-10-27 12:08:20 -0700
commite72536c32676b412cfead025b577d4e8c18d1c2f (patch)
tree41c0b6f18262cdacc29070e5fa880c6ba82c1081 /src/vm/ilstubresolver.cpp
parent675622bb85f3c78de1967a78052d7280a2834611 (diff)
downloadcoreclr-e72536c32676b412cfead025b577d4e8c18d1c2f.tar.gz
coreclr-e72536c32676b412cfead025b577d4e8c18d1c2f.tar.bz2
coreclr-e72536c32676b412cfead025b577d4e8c18d1c2f.zip
Introduce new CORJIT_FLAGS type
The "JIT flags" currently passed between the EE and the JIT have traditionally been bit flags in a 32-bit word. Recently, a second 32-bit word was added to accommodate additional flags, but that set of flags is definitely "2nd class": they are not universally passed, and require using a separate set of bit definitions, and comparing those bits against the proper, 2nd word. This change replaces all uses of bare DWORD or 'unsigned int' types representing flags with CORJIT_FLAGS, which is now an opaque type. All flag names were renamed from CORJIT_FLG_* to CORJIT_FLAG_* to ensure all cases were changed to use the new names, which are also scoped within the CORJIT_FLAGS type itself. Another motivation to do this, besides cleaner code, is to allow enabling the SSE/AVX flags for x86. For x86, we had fewer bits available in the "first word", so would have to either put them in the "second word", which, as stated, was very much 2nd class and not plumbed through many usages, or we could move other bits to the "second word", with the same issues. Neither was a good option. RyuJIT compiles with both COR_JIT_EE_VERSION > 460 and <= 460. I introduced a JitFlags adapter class in jitee.h to handle both JIT flag types. All JIT code uses this JitFlags type, which operates identically to the new CORJIT_FLAGS type. In addition to introducing the new CORJIT_FLAGS type, the SSE/AVX flags are enabled for x86. The JIT-EE interface GUID is changed, as this is a breaking change.
Diffstat (limited to 'src/vm/ilstubresolver.cpp')
-rw-r--r--src/vm/ilstubresolver.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/vm/ilstubresolver.cpp b/src/vm/ilstubresolver.cpp
index 64ff99f67e..5ba6c8a3b0 100644
--- a/src/vm/ilstubresolver.cpp
+++ b/src/vm/ilstubresolver.cpp
@@ -299,7 +299,7 @@ ILStubResolver::ILStubResolver() :
m_pStubMD(dac_cast<PTR_MethodDesc>(nullptr)),
m_pStubTargetMD(dac_cast<PTR_MethodDesc>(nullptr)),
m_type(Unassigned),
- m_dwJitFlags(0)
+ m_jitFlags()
{
LIMITED_METHOD_CONTRACT;
@@ -488,16 +488,16 @@ bool ILStubResolver::IsILGenerated()
return (dac_cast<TADDR>(m_pCompileTimeState) != ILNotYetGenerated);
}
-void ILStubResolver::SetJitFlags(DWORD dwFlags)
+void ILStubResolver::SetJitFlags(CORJIT_FLAGS jitFlags)
{
LIMITED_METHOD_CONTRACT;
- m_dwJitFlags = dwFlags;
+ m_jitFlags = jitFlags;
}
-DWORD ILStubResolver::GetJitFlags()
+CORJIT_FLAGS ILStubResolver::GetJitFlags()
{
LIMITED_METHOD_CONTRACT;
- return m_dwJitFlags;
+ return m_jitFlags;
}
// static