Linux, SOS: Setting breakpoint to managed code by file name + line number doesn't work
I use the same source and steps from dotnet/runtime#5750, but on Ubuntu 14.04 x64.
LLDB + libsosplugin doesn't support adding breakpoint by following command:
bpmd helloworld3.cs:10 File name:Line number not supported
It seems that symbols loading implemented only if FEATURE_PAL is not defined.
Am I right understand that we should read portable PDB to get this information on Linux?
Could you share your plans to enable this feature? Maybe you can suggest right way to implement it?
CC @kvochko, @Dmitri-Botcharnikov, @seanshpark, @mikem8361
Am I right understand that we should read portable PDB to get this information on Linux?
cc @mikem8361
Yes that is right but to read the portable PDB format is a lot of work and not planned for xplat in 1.0. The reader is written in managed code as part of System.Reflection.Metadata assembly. I just went through all the work to implement source/line info for Exception.StackTrace and that code is already managed (mostly). Calling the managed assembly from the native C++ SOS code is possible but there is too much work for now.
@mikem8361 We need this feature and we have resources. Could you please guide us to implement it? First, can we reuse System.Diagnostics.StackTrace.Symbols or need to write new assembly?
/cc @noahfalk, @tzwlai
System.Diagnostics.StackTraceSymbols (the code was moved to the System.Diagnostics.StackTrace assembly instead of a new one), is very specialized to the mscorlib’s StackTrace needs, but it can be used as a guide to using the System.Reflection.Metdata portable PDB reader.
The first step and concern is hosting managed code in SOS (the code in coreruncommon.cpp to initialize coreclr can be used as a guide). You need to use coreclr to do this and if you are still bringing coreclr on ARM up, it may not be working enough to run/host the managed code. You could test and get it all working under Linux x64 or even Windows (the hosting api for coreclr are there and the same for windows) and then getting work for ARM.
You will need to write a support assembly like System.Diagnositics.StackTrace using the portable pdb reader and create some simpler interop functions that can be called by native code (reverse-pinvokes which I think the hosting API coreclr_create_delegate) in SOS.
And depending how far you want to go, you can just support the bpmd source/line number (file/line to offset) and you could also support the clrstack, etc. commands dumping source/line info for managed code (IP/offset to source/line).
I’m not trying to discourage you all at from doing this work because it will be useful on all our xplat platforms, I just want to make sure you understand the scope.
mikem
@mikem8361 Thank you very much!
@mikem8361 We have some questions related to this feature implementation. Do we need to create&initialize new instance of coreclr for using managed symbol reader or we can use debugged coreclr instance? We had a success with creation of new coreclr instance into SymbolReader class (file src/ToolBox/SOS/Strike/util.h), but we don't know which exe file we should pass to coreclr_initialize. Could you suggest which exe file we should use?
Unfortunately, we failed to use debugged coreclr instance, because we don't know how to get hostHandle and domainId of debugged coreclr to create delegates in SOS. Can we get this information from SOS?
You can take a look at our experimental implementation with creation of new coreclr instance: https://github.com/lucenticus/coreclr/commit/fdbf4a9c99f006e02f978eaab54786d15a55815e
An empty string might work and if that doesn’t we can make it work with some slight changes to pal.cpp’s Initialize() function.
You can use the debugged coreclr instance hostHandle or domainId because it is in a different process.
From: Evgeny Pavlov [mailto:[email protected]] Sent: Friday, June 3, 2016 1:25 AM To: dotnet/coreclr [email protected] Cc: Mike McLaughlin [email protected]; Mention [email protected] Subject: Re: [dotnet/coreclr] Linux, SOS: Setting breakpoint to managed code by file name + line number doesn't work (#4798)
@mikem8361https://github.com/mikem8361 We have some questions related to this feature implementation. Do we need to create&initialize new instance of coreclr for using managed symbol reader or we can use debugged coreclr instance? We had a success with creation of new coreclr instance into SymbolReader class (file src/ToolBox/SOS/Strike/util.h), but we don't know which exe file we should pass to coreclr_initialize. Could you suggest which exe file we should use? Unfortunately, we failed to use debugged coreclr instance, because we don't know how to get hostHandle and domainId of debugged coreclr to create delegates in SOS. Can we get this information from SOS? You can take a look at our experimental implementation with creation of new coreclr instance: lucenticus@fdbf4a9https://github.com/lucenticus/coreclr/commit/fdbf4a9c99f006e02f978eaab54786d15a55815e
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/dotnet/coreclr/issues/4798#issuecomment-223520131, or mute the threadhttps://github.com/notifications/unsubscribe/AJ-Fa4mJXFEVOqQeYBF80OVu_heSvqwnks5qH-TFgaJpZM4IX-d7.
@mikem8361 I think you meant to write can not?
You can not use the debugged coreclr instance hostHandle or domainId because it is in a different process.
Yes I did.
From: noahfalk [mailto:[email protected]] Sent: Friday, June 3, 2016 3:20 PM To: dotnet/coreclr [email protected] Cc: Mike McLaughlin [email protected]; Mention [email protected] Subject: Re: [dotnet/coreclr] Linux, SOS: Setting breakpoint to managed code by file name + line number doesn't work (#4798)
@mikem8361https://github.com/mikem8361 I think you meant to write can not?
You can not use the debugged coreclr instance hostHandle or domainId because it is in a different process.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/dotnet/coreclr/issues/4798#issuecomment-223708270, or mute the threadhttps://github.com/notifications/unsubscribe/AJ-Fa_xkABwo74FcMCZbBarukY17B5hEks5qIKh4gaJpZM4IX-d7.
@mikem8361 Thanks for advice. With empty string and some changes in Initialize() function PAL_InitializeCoreCLR(exePath) successfully finished, but I've got an error in hr = host->Start() (unixinterface.cpp:208). During debugging I find that EEStartup function (ceemain.cpp:1447) failed to setup default domain.
Do you have any ideas the reason of this fail?
I don’t know why Start() would fail other than being called (coreclr_initialize) more than once.
I've checked whether coreclr_initialize called more than once, but it seems that it called only once. hr = host->Start() set hr to 0x800700cb (ERROR_ENVVAR_NOT_FOUND)
This error is generated only in src/pal/src/misc/environ.cpp in GetEnvironmentVariableA and SetEnvironmentVariableA (three places in total). So you can set a breapoint to those three places and see what env var was being requested.
I've added debug output, and it seems that COMPlus_legacyCorruptedStateExceptionsPolicy is not found
That should be ok, all the COMPlus_xxx vars are optional. It would be something else - I guess the last non-COMPlus one referenced before it fails.
The last non-COMPlus is CORECLR_ENABLE_PROFILING
I guess this is not very interesting envvar, I've also found MSCORDACWKS_DEBUG
Can you share the full output? I might be able to spot the culprit quickly.
Here is a full log of the debug session:
(lldb) target create corerun
Current executable set to 'corerun' (x86_64).
(lldb) settings set target.run-args ./helloworld3.exe
(lldb) plugin load libsosplugin.so
(lldb) process launch -s
Process 28709 launched: '/home/epavlov/coreclr-demo/runtime/corerun' (x86_64)
(lldb) process handle -s false SIGUSR1 SIGUSR2
NAME PASS STOP NOTIFY
=========== ===== ===== ======
SIGUSR1 true false true
SIGUSR2 true false true
(lldb) breakpoint set -n LoadLibraryExW
Breakpoint 1: no locations (pending).
WARNING: Unable to resolve breakpoint to any actual locations.
(lldb) process continue
1 location added to breakpoint 1
COMPlus_gcConcurrent is not found
COMPlus_gcServer is not found
COMPlus_GCRetainVM is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_EnforceEEThreadNotRequiredContracts is not found
COMPlus_MaxThreadRecord is not found
COMPlus_MaxStackDepth is not found
COMPlus_TestHooks is not found
COMPlus_StressLog is not found
COMPlus_LogFacility is not found
COMPlus_LogLevel is not found
COMPlus_StressLogSize is not found
COMPlus_TotalStressLogSize is not found
COMPlus_LogEnable is not found
COMPlus_LogFacility is not found
COMPlus_LogLevel is not found
COMPlus_LogFileAppend is not found
COMPlus_LogFlushFile is not found
COMPlus_LogToDebugger is not found
COMPlus_LogToFile is not found
COMPlus_LogToConsole is not found
COMPlus_LogFacility2 is not found
COMPlus_LogFile is not found
COMPlus_LogWithPid is not found
COMPlus_PerfMapEnabled is not found
COMPlus_FastGCStress is not found
COMPlus_GcCoverage is not found
COMPlus_GCLatencyMode is not found
COMPlus_ARMEnabled is not found
COMPlus_gcConcurrent is not found
COMPlus_AppDomainAgilityChecked is not found
COMPlus_GCStress is not found
COMPlus_GCStressMix is not found
COMPlus_GCStressStep is not found
COMPlus_HeapVerify is not found
COMPlus_GCSegmentSize is not found
COMPlus_GCgen0size is not found
COMPlus_GCRetainVM is not found
COMPlus_GCLOHCompact is not found
COMPlus_gcConservative is not found
COMPlus_gcAllowVeryLargeObjects is not found
COMPlus_GCBreakOnOOM is not found
COMPlus_InjectFatalError is not found
COMPlus_SaveThreadInfo is not found
COMPlus_SaveThreadInfoMask is not found
COMPlus_SkipGcCoverage is not found
COMPlus_gcForceCompact is not found
COMPlus_StressLog is not found
COMPlus_ForceEnc is not found
COMPlus_ZapRequire is not found
COMPlus_NgenBind_ZapForbid is not found
COMPlus_DisableNativeImageLoadList is not found
COMPlus_LoaderOptimization is not found
COMPlus_ZapBBInstr is not found
COMPlus_DisableStackwalkCache is not found
COMPlus_BreakOnClassLoad is not found
COMPlus_SpinInitialDuration is not found
COMPlus_SpinBackoffFactor is not found
COMPlus_SpinLimitProcCap is not found
COMPlus_SpinLimitProcFactor is not found
COMPlus_SpinLimitConstant is not found
COMPlus_SpinRetryCount is not found
COMPlus_JitFramed is not found
COMPlus_JitAlignLoops is not found
COMPlus_JITMinOpts is not found
COMPlus_JitOptimizeType is not found
COMPlus_AddRejitNops is not found
COMPlus_JitDebuggable is not found
COMPlus_StressOn is not found
COMPlus_APIThreadStress is not found
COMPlus_PrestubHalt is not found
COMPlus_InvokeHalt is not found
COMPlus_PrestubGC is not found
COMPlus_BreakOnClassBuild is not found
COMPlus_BreakOnInstantiation is not found
COMPlus_BreakOnMethodName is not found
COMPlus_DumpOnClassLoad is not found
COMPlus_BreakOnInteropStubSetup is not found
COMPlus_BreakOnComToClrNativeInfoInit is not found
COMPlus_BreakOnStructMarshalSetup is not found
COMPlus_AssertOnBadImageFormat is not found
COMPlus_AssertOnFailFast is not found
COMPlus_SuppressChecks is not found
COMPlus_ConditionalContracts is not found
COMPlus_EnableFullDebug is not found
COMPlus_VerifierOff is not found
COMPlus_JitVerificationDisable is not found
COMPlus_LogTransparencyErrors is not found
COMPlus_TlbImpSkipLoading is not found
COMPlus_ExposeExceptionsInCOM is not found
COMPlus_VerifyAllOnLoad is not found
COMPlus_ExpandAllOnLoad is not found
COMPlus_ADURetryCount is not found
COMPlus_StartupDelayMS is not found
COMPlus_TestDataConsistency is not found
COMPlus_SupressAllowUntrustedCallerChecks is not found
COMPlus_SuspendThreadDeadlockTimeoutMs is not found
COMPlus_SuspendDeadlockTimeout is not found
COMPlus_TraceIUnknown is not found
COMPlus_TraceWrap is not found
COMPlus_PerfTypesToLog is not found
COMPlus_PerfNumAllocsThreshold is not found
COMPlus_PerfAllocsSizeThreshold is not found
COMPlus_GenerateStubForHost is not found
COMPlus_InjectFault is not found
COMPlus_HostTestThreadAbort is not found
COMPlus_HostTestADUnload is not found
COMPlus_InteropValidatePinnedObjects is not found
COMPlus_InteropLogArguments is not found
COMPlus_NgenForceFailureMask is not found
COMPlus_NgenForceFailureCount is not found
COMPlus_NgenForceFailureKind is not found
COMPlus_GCPollType is not found
COMPlus_SuppressLockViolationsOnReentryFromOS is not found
COMPlus_UseMethodDataCache is not found
COMPlus_UseParentMethodData is not found
COMPlus_GenerateLongJumpDispatchStubRatio is not found
COMPlus_DiagnosticSuspend is not found
COMPlus_SleepOnExit is not found
COMPlus_EnableEventLog is not found
COMPlus_BreakOnEELoad is not found
COMPlus_ForceRelocs is not found
COMPlus_VirtualCallStubLogging is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_DebuggerBreakPoint is not found
COMPlus_DbgNoDebugger is not found
COMPlus_DbgExtraThreads is not found
COMPlus_DbgExtraThreadsIB is not found
COMPlus_DbgExtraThreadsCantStop is not found
COMPlus_DbgExtraThreadsOOB is not found
COMPlus_DbgWaitForDebuggerAttach is not found
COMPlus_DbgTransportLog is not found
COMPlus_DbgTransportLogClass is not found
COMPlus_DbgTransportFaultInject is not found
COMPlus_DbgDelayHelper is not found
CORECLR_ENABLE_PROFILING is not found
COMPlus_TestOnlyEnableSlowELTHooks is not found
COMPlus_TestOnlyEnableObjectAllocatedHook is not found
COMPlus_ProfAPI_TestOnlyEnableICorProfilerInfo is not found
COMPlus_DbgAttachOnStartup is not found
COMPlus_GCLogEnabled is not found
COMPlus_GCConfigLogEnabled is not found
COMPlus_GCMixLog is not found
COMPlus_BGCSpinCount is not found
COMPlus_BGCSpin is not found
COMPlus_ZapDisable is not found
COMPlus_MscorsnLogging is not found
COMPlus_NGenReserveForJumpStubs is not found
COMPlus_clearNativeImageStress is not found
COMPlus_InjectFault is not found
COMPlus_SBDumpOnNewIndex is not found
COMPlus_PauseOnLoad is not found
COMPlus_MiniMdBufferCapacity is not found
COMPlus_ConsistencyCheck is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_FeatureSIMD is not found
Process 28709 resuming
Process 28709 stopped
* thread dotnet/coreclr#1: tid = 28709, 0x00007ffff6799673 libcoreclr.so`::LoadLibraryExW(lpLibFileName=u"/home/epavlov/coreclr-demo/runtime/libclrjit.so", hFile=0x0000000000000000, dwFlags=0) + 35 at module.cpp:214, name = 'corerun', stop reason = breakpoint 1.1
frame #0: 0x00007ffff6799673 libcoreclr.so`::LoadLibraryExW(lpLibFileName=u"/home/epavlov/coreclr-demo/runtime/libclrjit.so", hFile=0x0000000000000000, dwFlags=0) + 35 at module.cpp:214
211 IN /*Reserved*/ HANDLE hFile,
212 IN DWORD dwFlags)
213 {
-> 214 if (dwFlags != 0)
215 {
216 // UNIXTODO: Implement this!
217 ASSERT("Needs Implementation!!!");
(lldb) bpmd helloworld3.cs:9
MSCORDACWKS_DEBUG is not found
COMPlus_DbgDACEnableAssert is not found
COMPlus_MD_EncDelta is not found
COMPlus_MD_MiniMDBreak is not found
COMPlus_MD_RegMetaBreak is not found
COMPlus_MD_KeepKnownCA is not found
Adding pending breakpoints...
(lldb) breakpoint delete 1
breakpoint delete 1
1 breakpoints deleted; 0 breakpoint locations disabled.
(lldb) c
c
Process 28709 resuming
(lldb) COMPlus_AltJitLimit is not found
COMPlus_AltJitSkipOnAssert is not found
COMPlus_BreakOnDumpToken is not found
COMPlus_DebugBreakOnVerificationFailure is not found
COMPlus_JitDiffableDasm is not found
COMPlus_JitLoopHoistStats is not found
COMPlus_JitMemStats is not found
COMPlus_DumpJittedMethods is not found
COMPlus_JitEnablePCRelAddr is not found
COMPlus_InterpreterFallback is not found
COMPlus_JitAssertOnMaxRAPasses is not found
COMPlus_JitBreakEmitOutputInstr is not found
COMPlus_JitBreakMorphTree is not found
COMPlus_JitBreakOnBadCode is not found
COMPlus_JITBreakOnMinOpts is not found
COMPlus_JitBreakOnUnsafeCode is not found
COMPlus_JitCanUseSSE2 is not found
COMPlus_JitCloneLoops is not found
COMPlus_JitDebugLogLoopCloning is not found
COMPlus_JitDefaultFill is not found
COMPlus_JitDirectAlloc is not found
COMPlus_JitDoAssertionProp is not found
COMPlus_JitDoCopyProp is not found
COMPlus_JitDoEarlyProp is not found
COMPlus_JitDoLoopHoisting is not found
COMPlus_JitDoRangeAnalysis is not found
COMPlus_JitDoSsa is not found
COMPlus_JitDoValueNumber is not found
COMPlus_JitDoubleAlign is not found
COMPlus_JitDumpASCII is not found
COMPlus_JitDumpFgDot is not found
COMPlus_JitDumpTerseLsra is not found
COMPlus_JitDumpToDebugger is not found
COMPlus_JitDumpVerboseSsa is not found
COMPlus_JitDumpVerboseTrees is not found
COMPlus_JitEmitPrintRefRegs is not found
COMPlus_JitExpensiveDebugCheckLevel is not found
COMPlus_JitForceFallback is not found
COMPlus_JitForceVer is not found
COMPlus_JitFullyInt is not found
COMPlus_JitFunctionTrace is not found
COMPlus_JitGCChecks is not found
COMPlus_JitGCInfoLogging is not found
COMPlus_JitHashBreak is not found
COMPlus_JitHashDump is not found
COMPlus_JitHashDumpIR is not found
COMPlus_JitHashHalt is not found
COMPlus_JitInlineAdditionalMultiplier is not found
COMPlus_JitInlinePrintStats is not found
COMPlus_JITInlineSize is not found
COMPlus_JITInlineDepth is not found
COMPlus_JitLongAddress is not found
COMPlus_JITMaxTempAssert is not found
COMPlus_JitMaxUncheckedOffset is not found
COMPlus_JITMinOpts is not found
COMPlus_JITMinOptsBbCount is not found
COMPlus_JITMinOptsCodeSize is not found
COMPlus_JITMinOptsInstrCount is not found
COMPlus_JITMinOptsLvNumcount is not found
COMPlus_JITMinOptsLvRefcount is not found
COMPlus_JitNoCMOV is not found
COMPlus_JitNoCSE is not found
COMPlus_JitNoCSE2 is not found
COMPlus_JitNoForceFallback is not found
COMPlus_JitNoHoist is not found
COMPlus_JitNoInline is not found
COMPlus_JitNoMemoryBarriers is not found
COMPlus_JitNoRegLoc is not found
COMPlus_JitNoStructPromotion is not found
COMPlus_JitNoUnroll is not found
COMPlus_JitOrder is not found
COMPlus_JITPInvokeCheckEnabled is not found
COMPlus_JITPInvokeEnabled is not found
COMPlus_JitPrintInlinedMethods is not found
COMPlus_JITRequired is not found
COMPlus_JITRoundFloat is not found
COMPlus_JitSkipArrayBoundCheck is not found
COMPlus_JitSlowDebugChecksEnabled is not found
COMPlus_JitSplitFunctionSize is not found
COMPlus_JitSsaStress is not found
COMPlus_JitStackChecks is not found
COMPlus_JitStress is not found
COMPlus_JitStressBBProf is not found
COMPlus_JitStressBiasedCSE is not found
COMPlus_JitStressFP is not found
COMPlus_JitStressModeNamesOnly is not found
COMPlus_JitStressRegs is not found
COMPlus_JitStrictCheckForNonVirtualCallToVirtualMethod is not found
COMPlus_JitVNMapSelLimit is not found
COMPlus_NgenHashDump is not found
COMPlus_NgenHashDumpIR is not found
COMPlus_NgenOrder is not found
COMPlus_RunAltJitCode is not found
COMPlus_JitComponentUnitTests is not found
COMPlus_InjectFault is not found
COMPlus_JitStackProbes is not found
COMPlus_StressCOMCall is not found
COMPlus_TailcallStress is not found
COMPlus_JitDumpBeforeAfterMorph is not found
COMPlus_JitBreak is not found
COMPlus_JitDebugBreak is not found
COMPlus_JitDisasm is not found
COMPlus_JitDump is not found
COMPlus_JitDumpIR is not found
COMPlus_JitEHDump is not found
COMPlus_JitExclude is not found
COMPlus_JitForceProcedureSplitting is not found
COMPlus_JitGCDump is not found
COMPlus_JitHalt is not found
COMPlus_JitImportBreak is not found
COMPlus_JitInclude is not found
COMPlus_JitLateDisasm is not found
COMPlus_JITMinOptsName is not found
COMPlus_JitNoProcedureSplitting is not found
COMPlus_JitNoProcedureSplittingEH is not found
COMPlus_JitStressOnly is not found
COMPlus_JitUnwindDump is not found
COMPlus_NgenDisasm is not found
COMPlus_NgenDump is not found
COMPlus_NgenDumpIR is not found
COMPlus_NgenEHDump is not found
COMPlus_NgenGCDump is not found
COMPlus_NgenUnwindDump is not found
COMPlus_JitDumpFg is not found
COMPlus_JitDumpFgDir is not found
COMPlus_JitDumpFgFile is not found
COMPlus_JitDumpFgPhase is not found
COMPlus_JitDumpIRFormat is not found
COMPlus_JitDumpIRPhase is not found
COMPlus_JITLateDisasmTo is not found
COMPlus_JitRange is not found
COMPlus_JitStressModeNames is not found
COMPlus_JitStressModeNamesNot is not found
COMPlus_JitStressRange is not found
COMPlus_NgenDumpFg is not found
COMPlus_NgenDumpFgDir is not found
COMPlus_NgenDumpFgFile is not found
COMPlus_NgenDumpIRFormat is not found
COMPlus_NgenDumpIRPhase is not found
COMPlus_AltJitAssertOnNYI is not found
COMPlus_EnableAVX is not found
COMPlus_JitEnableNoWayAssert is not found
COMPlus_JitAggressiveInlining is not found
COMPlus_JitELTHookEnabled is not found
COMPlus_JitInlineSIMDMultiplier is not found
COMPlus_JitRegisterFP is not found
COMPlus_JitTelemetry is not found
COMPlus_JitVNMapSelBudget is not found
COMPlus_TailCallLoopOpt is not found
COMPlus_AltJit is not found
COMPlus_AltJitNgen is not found
COMPlus_JitFuncInfoLogFile is not found
COMPlus_JitTimeLogCsv is not found
COMPlus_TailCallOpt is not found
COMPlus_JitInlineDumpData is not found
COMPlus_JitInlineDumpXml is not found
COMPlus_JitInlineLimit is not found
COMPlus_JitInlinePolicyDiscretionary is not found
COMPlus_JitInlinePolicyModel is not found
COMPlus_JitInlinePolicyFull is not found
COMPlus_JitInlinePolicySize is not found
COMPlus_JitInlinePolicyReplay is not found
COMPlus_JitNoInlineRange is not found
COMPlus_JitInlineReplayFile is not found
COMPlus_AltJit is not found
COMPlus_CodeHeapReserveForJumpStubs is not found
COMPlus_JitHeartbeat is not found
COMPlus_LogEnable is not found
COMPlus_LogToConsole is not found
COMPlus_LogLevel is not found
COMPlus_ManagedLogFacility is not found
COMPlus_BCLPerfWarnings is not found
COMPlus_BCLCorrectnessWarnings is not found
COMPlus_SafeHandleStackTraces is not found
COMPlus_CerLogging is not found
COMPlus_ADForceSB is not found
COMPlus_AlwaysUseMetadataInterfaceMapLayout is not found
COMPlus_DefaultSecurityRuleSet is not found
COMPlus_NGenForPartialTrust is not found
COMPlus_MD_EncDelta is not found
COMPlus_MD_MiniMDBreak is not found
COMPlus_MD_RegMetaBreak is not found
COMPlus_MD_KeepKnownCA is not found
COMPlus_gcConcurrent is not found
COMPlus_gcServer is not found
COMPlus_GCRetainVM is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_EnforceEEThreadNotRequiredContracts is not found
COMPlus_MaxThreadRecord is not found
COMPlus_MaxStackDepth is not found
COMPlus_TestHooks is not found
COMPlus_StressLog is not found
COMPlus_LogFacility is not found
COMPlus_LogLevel is not found
COMPlus_StressLogSize is not found
COMPlus_TotalStressLogSize is not found
COMPlus_LogEnable is not found
COMPlus_LogFacility is not found
COMPlus_LogLevel is not found
COMPlus_LogFileAppend is not found
COMPlus_LogFlushFile is not found
COMPlus_LogToDebugger is not found
COMPlus_LogToFile is not found
COMPlus_LogToConsole is not found
COMPlus_LogFacility2 is not found
COMPlus_LogFile is not found
COMPlus_LogWithPid is not found
COMPlus_PerfMapEnabled is not found
COMPlus_FastGCStress is not found
COMPlus_GcCoverage is not found
COMPlus_GCLatencyMode is not found
COMPlus_ARMEnabled is not found
COMPlus_gcConcurrent is not found
COMPlus_AppDomainAgilityChecked is not found
COMPlus_GCStress is not found
COMPlus_GCStressMix is not found
COMPlus_GCStressStep is not found
COMPlus_HeapVerify is not found
COMPlus_GCSegmentSize is not found
COMPlus_GCgen0size is not found
COMPlus_GCRetainVM is not found
COMPlus_GCLOHCompact is not found
COMPlus_gcConservative is not found
COMPlus_gcAllowVeryLargeObjects is not found
COMPlus_GCBreakOnOOM is not found
COMPlus_InjectFatalError is not found
COMPlus_SaveThreadInfo is not found
COMPlus_SaveThreadInfoMask is not found
COMPlus_SkipGcCoverage is not found
COMPlus_gcForceCompact is not found
COMPlus_StressLog is not found
COMPlus_ForceEnc is not found
COMPlus_ZapRequire is not found
COMPlus_NgenBind_ZapForbid is not found
COMPlus_DisableNativeImageLoadList is not found
COMPlus_LoaderOptimization is not found
COMPlus_ZapBBInstr is not found
COMPlus_DisableStackwalkCache is not found
COMPlus_BreakOnClassLoad is not found
COMPlus_SpinInitialDuration is not found
COMPlus_SpinBackoffFactor is not found
COMPlus_SpinLimitProcCap is not found
COMPlus_SpinLimitProcFactor is not found
COMPlus_SpinLimitConstant is not found
COMPlus_SpinRetryCount is not found
COMPlus_JitFramed is not found
COMPlus_JitAlignLoops is not found
COMPlus_JITMinOpts is not found
COMPlus_JitOptimizeType is not found
COMPlus_AddRejitNops is not found
COMPlus_JitDebuggable is not found
COMPlus_StressOn is not found
COMPlus_APIThreadStress is not found
COMPlus_PrestubHalt is not found
COMPlus_InvokeHalt is not found
COMPlus_PrestubGC is not found
COMPlus_BreakOnClassBuild is not found
COMPlus_BreakOnInstantiation is not found
COMPlus_BreakOnMethodName is not found
COMPlus_DumpOnClassLoad is not found
COMPlus_BreakOnInteropStubSetup is not found
COMPlus_BreakOnComToClrNativeInfoInit is not found
COMPlus_BreakOnStructMarshalSetup is not found
COMPlus_AssertOnBadImageFormat is not found
COMPlus_AssertOnFailFast is not found
COMPlus_SuppressChecks is not found
COMPlus_ConditionalContracts is not found
COMPlus_EnableFullDebug is not found
COMPlus_VerifierOff is not found
COMPlus_JitVerificationDisable is not found
COMPlus_LogTransparencyErrors is not found
COMPlus_TlbImpSkipLoading is not found
COMPlus_ExposeExceptionsInCOM is not found
COMPlus_VerifyAllOnLoad is not found
COMPlus_ExpandAllOnLoad is not found
COMPlus_ADURetryCount is not found
COMPlus_StartupDelayMS is not found
COMPlus_TestDataConsistency is not found
COMPlus_SupressAllowUntrustedCallerChecks is not found
COMPlus_SuspendThreadDeadlockTimeoutMs is not found
COMPlus_SuspendDeadlockTimeout is not found
COMPlus_TraceIUnknown is not found
COMPlus_TraceWrap is not found
COMPlus_PerfTypesToLog is not found
COMPlus_PerfNumAllocsThreshold is not found
COMPlus_PerfAllocsSizeThreshold is not found
COMPlus_GenerateStubForHost is not found
COMPlus_InjectFault is not found
COMPlus_HostTestThreadAbort is not found
COMPlus_HostTestADUnload is not found
COMPlus_InteropValidatePinnedObjects is not found
COMPlus_InteropLogArguments is not found
COMPlus_NgenForceFailureMask is not found
COMPlus_NgenForceFailureCount is not found
COMPlus_NgenForceFailureKind is not found
COMPlus_GCPollType is not found
COMPlus_SuppressLockViolationsOnReentryFromOS is not found
COMPlus_UseMethodDataCache is not found
COMPlus_UseParentMethodData is not found
COMPlus_GenerateLongJumpDispatchStubRatio is not found
COMPlus_DiagnosticSuspend is not found
COMPlus_SleepOnExit is not found
COMPlus_EnableEventLog is not found
COMPlus_BreakOnEELoad is not found
COMPlus_ForceRelocs is not found
COMPlus_VirtualCallStubLogging is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_LoaderHeapCallTracing is not found
COMPlus_DebuggerBreakPoint is not found
COMPlus_DbgNoDebugger is not found
COMPlus_DbgExtraThreads is not found
COMPlus_DbgExtraThreadsIB is not found
COMPlus_DbgExtraThreadsCantStop is not found
COMPlus_DbgExtraThreadsOOB is not found
COMPlus_DbgTransportLog is not found
COMPlus_DbgTransportLogClass is not found
COMPlus_DbgWaitForDebuggerAttach is not found
COMPlus_DbgTransportFaultInject is not found
COMPlus_DbgDelayHelper is not found
CORECLR_ENABLE_PROFILING is not found
COMPlus_TestOnlyEnableSlowELTHooks is not found
COMPlus_TestOnlyEnableObjectAllocatedHook is not found
COMPlus_ProfAPI_TestOnlyEnableICorProfilerInfo is not found
COMPlus_DbgAttachOnStartup is not found
COMPlus_GCLogEnabled is not found
COMPlus_GCConfigLogEnabled is not found
COMPlus_GCMixLog is not found
COMPlus_BGCSpinCount is not found
COMPlus_BGCSpin is not found
COMPlus_ZapDisable is not found
COMPlus_MscorsnLogging is not found
COMPlus_NGenReserveForJumpStubs is not found
COMPlus_clearNativeImageStress is not found
COMPlus_InjectFault is not found
COMPlus_SBDumpOnNewIndex is not found
COMPlus_PauseOnLoad is not found
COMPlus_MiniMdBufferCapacity is not found
COMPlus_ConsistencyCheck is not found
COMPlus_legacyCorruptedStateExceptionsPolicy is not found
COMPlus_BreakOnHR is not found
Error: Fail to initialize CoreCLR
Hmm, I am starting to think that the error code is incorrect. But since it comes from an exception, you can set a breakpoint at RaiseException and when you hit it, look at the call stack to see where it stems from.