Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/dotnet/runtime.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike McLaughlin <mikem@microsoft.com>2021-02-21 00:51:39 +0300
committerGitHub <noreply@github.com>2021-02-21 00:51:39 +0300
commitf30a71824ed1c53848799b35d35cc0324e0752f1 (patch)
tree0da7848d02567864654605d9a9db1a228c4617bd /src/coreclr/md
parentbc9259e7a8a9a9aebd91f367117c6909db1aafcf (diff)
Enable Hot Reload API on Linux (#48497)
Enable Hot Reload API on Linux Only define EnC_SUPPORTED for vm/ee on xplat. Doesn't enable the ENC ICorDebug API. Enable hotreload api tests on Linux/MacOS. API not implemented on arm/arm64 Remove all the ENC_DELTA_HACK code. Remove more ENC_DELTA_HACK code from ilasm
Diffstat (limited to 'src/coreclr/md')
-rw-r--r--src/coreclr/md/ceefilegen/cceegen.cpp23
-rw-r--r--src/coreclr/md/compiler/disp.cpp52
2 files changed, 0 insertions, 75 deletions
diff --git a/src/coreclr/md/ceefilegen/cceegen.cpp b/src/coreclr/md/ceefilegen/cceegen.cpp
index 9be6c99ff9b..707d45ab83f 100644
--- a/src/coreclr/md/ceefilegen/cceegen.cpp
+++ b/src/coreclr/md/ceefilegen/cceegen.cpp
@@ -8,10 +8,6 @@
#include "corerror.h"
-#ifdef EnC_SUPPORTED
-#define ENC_DELTA_HACK
-#endif
-
//*****************************************************************************
// Creation for new CCeeGen instances
@@ -578,25 +574,6 @@ HRESULT CCeeGen::emitMetaData(IMetaDataEmit *emitter, CeeSection* section, DWORD
_ASSERTE(metaDataLen <= buffLen);
-#ifdef ENC_DELTA_HACK
- {
- extern int __cdecl fclose(FILE *);
- WCHAR szFileName[256];
- DWORD len = GetEnvironmentVariable(W("COMP_ENC_EMIT"), szFileName, ARRAYSIZE(szFileName));
- _ASSERTE(len < (ARRAYSIZE(szFileName) + 6)); // +6 for the .dmeta
- if (len > 0 && len < (ARRAYSIZE(szFileName) + 6))
- {
- wcscat_s(szFileName, ARRAYSIZE(szFileName), W(".dmeta"));
- FILE *pDelta;
- int ec = _wfopen_s(&pDelta, szFileName, W("wb"));
- if (FAILED(ec)) { return HRESULT_FROM_WIN32(ERROR_OPEN_FAILED); }
- fwrite(buffer, 1, metaDataLen, pDelta);
- fclose(pDelta);
- }
- }
-#endif
-
-
// Set meta virtual address to offset of metadata within .meta, and
// and add a reloc for this offset, which will get turned
// into an rva when the pewriter writes out the file.
diff --git a/src/coreclr/md/compiler/disp.cpp b/src/coreclr/md/compiler/disp.cpp
index 95c35063c71..6eecde4474d 100644
--- a/src/coreclr/md/compiler/disp.cpp
+++ b/src/coreclr/md/compiler/disp.cpp
@@ -16,10 +16,6 @@
#include <mdlog.h>
#include <mdcommon.h>
-#ifdef EnC_SUPPORTED
-#define ENC_DELTA_HACK
-#endif
-
//*****************************************************************************
// Ctor.
//*****************************************************************************
@@ -95,54 +91,6 @@ Disp::DefineScope(
IfFailGo(CLDB_E_FILE_OLDVER);
}
-#ifdef ENC_DELTA_HACK
-// Testers need this flag for their tests.
-
- DWORD len;
- EX_TRY{
- len = WszGetEnvironmentVariable(W("COMP_ENC_OPENSCOPE"), szFileNameSuffix);
- szFileName.Append(szFileNameSuffix);
- }
- EX_CATCH_HRESULT(hr);
-
- if (len > 0)
- {
- // _ASSERTE(!"ENC override on DefineScope");
-// m_OptionValue.m_UpdateMode = MDUpdateENC;
-// m_OptionValue.m_ErrorIfEmitOutOfOrder = MDErrorOutOfOrderDefault;
-// hr = OpenScope(szFileName, ofWrite, riid, ppIUnk);
-
- IMetaDataEmit *pMetaEmit;
- hr = OpenScope(szFileName, ofWrite, IID_IMetaDataEmit, (IUnknown **)&pMetaEmit);
- DWORD cb;
- CQuickBytes pbMetadata;
- hr = pMetaEmit->GetSaveSize(cssAccurate,&cb);
- _ASSERTE(SUCCEEDED(hr));
-
- IfFailGo(pbMetadata.ReSizeNoThrow(cb));
-
- hr = pMetaEmit->SaveToMemory(pbMetadata.Ptr(),cb);
- _ASSERTE(SUCCEEDED(hr));
-// hr = OpenScopeOnMemory( pbMetadata.Ptr(), cb, ofWrite|MDUpdateENC|MDUpdateDelta, riid, ppIUnk);
-
-
- VARIANT encOption;
- V_VT(&encOption) = VT_UI4;
- V_UI4(&encOption) = MDUpdateENC;
- SetOption(MetaDataSetENC, &encOption);
- V_UI4(&encOption) = MDErrorOutOfOrderDefault;
- SetOption(MetaDataErrorIfEmitOutOfOrder, &encOption);
- hr = OpenScopeOnMemory( pbMetadata.Ptr(), cb, ofWrite, riid, ppIUnk);
- _ASSERTE(SUCCEEDED(hr));
- BOOL fResult = SUCCEEDED(hr);
- // print out a message so people know what's happening
- printf("Defining scope for EnC using %S %s\n",
- static_cast<LPCWSTR>(szFileNameSuffix), fResult ? "succeeded" : "failed");
-
- goto ErrExit;
- }
-#endif // ENC_DELTA_HACK
-
// Create a new coclass for this.
pMeta = new (nothrow) RegMeta();
IfNullGo(pMeta);