Add dual .NET Core/desktop CLR runtime test
authorMike McLaughlin <mikem@microsoft.com>
Sat, 4 Jan 2020 03:32:34 +0000 (19:32 -0800)
committerMike McLaughlin <mikem@microsoft.com>
Sun, 5 Jan 2020 07:20:16 +0000 (23:20 -0800)
Added an desktop host native DLL that the modified WebApp3 debuggee
optionally pinvokes to start the desktop CLR. An modified SymbolTestDll
is the managed assembly that this desktop host loads and runs.

Fixed bug in GetClrModuleImages.

15 files changed:
src/SOS/CMakeLists.txt
src/SOS/SOS.UnitTests/ConfigFiles/Windows/Debugger.Tests.Config.txt
src/SOS/SOS.UnitTests/Debuggees/DesktopClrHost/CMakeLists.txt [new file with mode: 0644]
src/SOS/SOS.UnitTests/Debuggees/DesktopClrHost/DesktopClrHost.cpp [new file with mode: 0644]
src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestApp/SymbolTestApp.cs
src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestDll/SymbolTestDll.csproj
src/SOS/SOS.UnitTests/Debuggees/SymbolTestApp/SymbolTestDll/TestClass.cs
src/SOS/SOS.UnitTests/Debuggees/WebApp3/Program.cs
src/SOS/SOS.UnitTests/Debuggees/WebApp3/Properties/launchSettings.json
src/SOS/SOS.UnitTests/SOS.cs
src/SOS/SOS.UnitTests/SOSRunner.cs
src/SOS/SOS.UnitTests/Scripts/DualRuntimes.script [new file with mode: 0644]
src/inc/MSCOREE.IDL
src/pal/prebuilt/inc/mscoree.h
src/pal/prebuilt/inc/mscorsvc.h

index 4d567398e6b0c6b2f70809a6bbee19691e8bd20b..07cf24bd60b846bf213fbbe965a8b79cf20fb668 100644 (file)
@@ -11,6 +11,7 @@ if(WIN32)
   add_compile_options(/Zl) # omit default library name in .OBJ
 
   add_subdirectory(runcommand)
+  add_subdirectory(SOS.UnitTests/Debuggees/DesktopClrHost)
 endif(WIN32)
 
 add_definitions(-D_SECURE_SCL=0)
index a6221d512badea16b64099a657b25d053f1ea638..ef06736e0c8b579e3dfbf518a998cbeb9d51fbff 100644 (file)
@@ -22,6 +22,7 @@
   <DumpDir>$(RootBinDir)\tmp\$(TargetConfiguration)\dumps</DumpDir>
   <CDBPath>$(RootBinDir)\bin\SOS.UnitTests\$(TargetConfiguration)\netcoreapp2.0\publish\runtimes\win-$(TargetArchitecture)\native\cdb.exe</CDBPath>
   <CDBHelperExtension>$(InstallDir)\runcommand.dll</CDBHelperExtension>
+  <DesktopFramework>net462</DesktopFramework>
 
   <DebuggeeSourceRoot>$(RepoRootDir)\src\SOS\SOS.UnitTests\Debuggees</DebuggeeSourceRoot>
   <DebuggeeBuildProcess>sdk.prebuilt</DebuggeeBuildProcess>
           <FrameworkVersion>$(AspNetCoreVersion21)</FrameworkVersion>
         </Option>
         <!--
-            SOS.WebApp3 (runs on 3.0, 3.1 and latest aspnetcore)
+            SOS.WebApp3 and SOS.DualRuntimes (runs on 3.0, 3.1 and latest aspnetcore)
           -->
         <Option>
-          <TestName>SOS.WebApp3</TestName>
+          <Options>
+            <Option>
+              <TestName>SOS.WebApp3</TestName>
+            </Option>
+            <Option>
+              <TestName>SOS.DualRuntimes</TestName>
+              <!-- The assembly path, class and function name of the desktop test code to load/run -->
+              <DesktopTestParameters>$(RootBinDir)\bin\SymbolTestDll\$(TargetConfiguration)\$(DesktopFramework)\publish\SymbolTestDll.dll SymbolTestDll.TestClass ThrowException</DesktopTestParameters>
+            </Option>
+          </Options>
           <Options>
             <Option>
               <!-- Build the debuggee for 3.0 but run it on latest -->
       <TestProduct>Desktop</TestProduct>
       <DebuggeeBuildProcess>cli</DebuggeeBuildProcess>
       <DebuggeeBuildRoot>$(RootBinDir)\Debuggees</DebuggeeBuildRoot>
-      <BuildProjectFramework>net462</BuildProjectFramework>
+      <BuildProjectFramework>$(DesktopFramework)</BuildProjectFramework>
       <BuildProjectRuntime>win-$(TargetArchitecture)</BuildProjectRuntime>
       <DebugType>full</DebugType>
       <FrameworkDirPath Condition="$(TargetArchitecture) == x64">$(WinDir)\Microsoft.Net\Framework64\v4.0.30319\</FrameworkDirPath>
diff --git a/src/SOS/SOS.UnitTests/Debuggees/DesktopClrHost/CMakeLists.txt b/src/SOS/SOS.UnitTests/Debuggees/DesktopClrHost/CMakeLists.txt
new file mode 100644 (file)
index 0000000..27f25d9
--- /dev/null
@@ -0,0 +1,35 @@
+project(DesktopClrHost)
+
+set(CMAKE_INCLUDE_CURRENT_DIR ON)
+
+include_directories(inc)
+include_directories("$ENV{VSInstallDir}/DIA SDK/include")
+
+add_definitions(-DUSE_STL)
+add_definitions(-MT) 
+
+set(DESKTOPCLRHOST_SOURCES
+    DesktopClrHost.cpp
+)
+  
+set(DESKTOPCLRHOST_LIBRARY
+    ${STATIC_MT_CRT_LIB}
+    ${STATIC_MT_CPP_LIB}
+    ${STATIC_MT_VCRT_LIB}
+    kernel32.lib
+    user32.lib
+    ole32.lib
+    oleaut32.lib
+    uuid.lib
+    version.lib
+    advapi32.lib
+    psapi.lib
+    ntdll.lib
+    mscoree.lib
+)
+
+add_library_clr(DesktopClrHost SHARED ${DESKTOPCLRHOST_SOURCES})
+
+target_link_libraries(DesktopClrHost ${DESKTOPCLRHOST_LIBRARY})
+
+install(TARGETS DesktopClrHost DESTINATION ${CLR_MANAGED_BINARY_DIR}/WebApp3/${CLR_BUILD_TYPE}/netcoreapp3.0)
diff --git a/src/SOS/SOS.UnitTests/Debuggees/DesktopClrHost/DesktopClrHost.cpp b/src/SOS/SOS.UnitTests/Debuggees/DesktopClrHost/DesktopClrHost.cpp
new file mode 100644 (file)
index 0000000..a5f7b66
--- /dev/null
@@ -0,0 +1,73 @@
+// Licensed to the .NET Foundation under one or more agreements.
+// The .NET Foundation licenses this file to you under the MIT license.
+// See the LICENSE file in the project root for more information.
+
+// Windows Header Files
+#include <windows.h>
+#include <stdio.h>
+#include <metahost.h>
+#include <objbase.h>
+#include <mscoree.h>
+#include <tchar.h>
+#include <strsafe.h>
+
+#define CLR_VERSION L"v4.0.30319"
+
+EXTERN_C __declspec(dllexport) HRESULT __cdecl 
+InitializeDesktopClrHost(
+    LPCWSTR assemblyPath,
+    LPCWSTR className,
+    LPCWSTR functionName,
+    LPCWSTR argument)
+{
+    ICLRRuntimeHost* clrHost = NULL;
+    HRESULT hr = S_OK;
+    DWORD ret;
+
+    hr = CoInitializeEx(NULL, COINIT_APARTMENTTHREADED);
+    if (SUCCEEDED(hr) || hr == RPC_E_CHANGED_MODE) {
+
+        // Loads the CLR and then initializes the managed debugger extensions.
+        ICLRMetaHost* metaHost;
+        hr = CLRCreateInstance(CLSID_CLRMetaHost, IID_ICLRMetaHost, (PVOID*)&metaHost);
+        if (SUCCEEDED(hr) && metaHost != NULL) {
+
+            ICLRRuntimeInfo* runtimeInfo;
+            hr = metaHost->GetRuntime(CLR_VERSION, IID_ICLRRuntimeInfo, (PVOID*)&runtimeInfo);
+            if (SUCCEEDED(hr) && runtimeInfo != NULL) {
+
+                hr = runtimeInfo->GetInterface(CLSID_CLRRuntimeHost, IID_ICLRRuntimeHost, (PVOID*)&clrHost);
+                if (SUCCEEDED(hr) && clrHost != NULL) {
+
+                    hr = clrHost->Start();
+                    if (SUCCEEDED(hr)) {
+
+                        // Initialize the managed code
+                        hr = clrHost->ExecuteInDefaultAppDomain(assemblyPath, className, functionName, argument, (DWORD *)&ret);
+                        if (FAILED(hr)) {
+                            printf("InitializeDesktopClrHost: InitializeExtensions failed 0x%X\r\n", hr);
+                        }
+                    }
+                    else {
+                        printf("InitializeDesktopClrHost: ICLRRuntimeHost::Start failed 0x%X\r\n", hr);
+                    }
+                }
+                else {
+                    printf("InitializeDesktopClrHost: ICLRRuntimeInfo::GetInterface failed 0x%X\r\n", hr);
+                }
+            }
+            else {
+                printf("InitializeDesktopClrHost: ICLRMetaHost::GetRuntime failed 0x%X\r\n", hr);
+            }
+        }
+        else {
+            printf("InitializeDesktopClrHost: CLRCreateInstance failed 0x%X\r\n", hr);
+        }
+    }
+    else {
+        printf("InitializeDesktopClrHost: CoInitializeEx failed. 0x%X\r\n", hr);
+    }
+
+    return hr;
+}
+
index f576c5d37b7cca34047e586dec3b1f82cfcaa0af..dd09f37e75f600cfa01e38521b8c04d37c51dcf7 100644 (file)
@@ -51,7 +51,7 @@ namespace SymbolTestApp
 #endif
             Type dllType = assembly.GetType("SymbolTestDll.TestClass");
             MethodInfo dllMethod = dllType.GetMethod("ThrowException");
-            dllMethod.Invoke(null, null);
+            dllMethod.Invoke(null, new object[] { "This is the exception message" });
         }
     }
 }
index 7fcc86a6e79ca8b5d8d71a6230410006d144e47c..112935f6d3fd7973cb788b1a52f4545fc53f8ceb 100644 (file)
@@ -2,6 +2,7 @@
   <PropertyGroup>
     <OutputType>Library</OutputType>
     <TargetFramework Condition="'$(BuildProjectFramework)' != ''">$(BuildProjectFramework)</TargetFramework>
-    <TargetFrameworks Condition="'$(BuildProjectFramework)' == ''">netcoreapp2.1;netcoreapp3.0</TargetFrameworks>
+    <TargetFrameworks Condition="'$(BuildProjectFramework)' == '' and '$(OS)' != 'Windows_NT'">netcoreapp2.1;netcoreapp3.0</TargetFrameworks>
+    <TargetFrameworks Condition="'$(BuildProjectFramework)' == '' and '$(OS)' == 'Windows_NT'">net462;netcoreapp2.1;netcoreapp3.0</TargetFrameworks>
   </PropertyGroup>
 </Project>
index c9a260356323ed8d8558501f2ab17f69019cbfe4..a1baa97be68c4cee123284e477db221d269d2fc4 100644 (file)
@@ -1,31 +1,37 @@
 using System;
-using System.Collections.Generic;
-using System.Linq;
-using System.Threading.Tasks;
+using System.Threading;
 
 namespace SymbolTestDll
 {
     public class TestClass
     {
-        public static void ThrowException()
+        public static int ThrowException(string argument)
         {
-            Foo5(56);
+            Foo5(56, argument);
+            return 0;
         }
 
-        static int Foo5(int x)
+        static int Foo5(int x, string argument)
         {
-            return Foo6(x);
+            return Foo6(x, argument);
         }
 
-        static int Foo6(int x)
+        static int Foo6(int x, string argument)
         {
-            Foo7();
+            Foo7(argument);
             return x;
         }
 
-        static void Foo7()
+        static void Foo7(string argument)
         {
-            throw new Exception();
-       }
+            if (argument != null)
+            {
+                throw new Exception(argument);
+            }
+            else
+            {
+                Thread.Sleep(-1);
+            }
+        }
     }
 }
index 409056854dd69ef5bcf041846099ff6ffac35659..01ec09e6042410f150bb1a3f14f990a4ad8a87b0 100644 (file)
@@ -2,11 +2,16 @@ using Microsoft.AspNetCore.Hosting;
 using Microsoft.Extensions.Hosting;
 using System;
 using System.Net.Http;
+using System.Runtime.InteropServices;
+using System.Threading;
 
 namespace WebApp3
 {
     public class Program
     {
+        [DllImport("DesktopClrHost.dll", CharSet = CharSet.Unicode, CallingConvention = CallingConvention.Cdecl)]
+        private static extern int InitializeDesktopClrHost(string assemblyPath, string className, string functionName, string argument);
+
         public static string PipeServerName;
 
         public static void Main(string[] args)
@@ -15,6 +20,20 @@ namespace WebApp3
             {
                 PipeServerName = args[0];
                 Console.WriteLine("Pipe server: {0}", PipeServerName);
+
+                if (args.Length > 3)
+                {
+                    var thread = new Thread(() =>
+                    {
+                        Console.WriteLine("Starting desktop CLR: '{0} {1} {2}'", args[1], args[2], args[3]);
+                        int hr = InitializeDesktopClrHost(args[1], args[2], args[3], args.Length > 4 ? args[4] : null);
+                        if (hr != 0)
+                        {
+                            Console.WriteLine("Desktop CLR initialization FAILED: {0:X8}", hr);
+                        }
+                    });
+                    thread.Start();
+                }
             }
 
             using (IHost host = CreateHostBuilder(args).Build())
index d2d3863b7f1f510fd86637481e11fb01c11095cc..11bb3c80e739d2e86a395625ee467f2c53dd1ff7 100644 (file)
   "profiles": {
     "IIS Express": {
       "commandName": "IISExpress",
-      "launchBrowser": true,
+      "commandLineArgs": "\"\" \"C:\\ssd\\diagnostics\\artifacts\\bin\\SymbolTestDll\\Debug\\net462\\publish\\SymbolTestDll.dll\" SymbolTestDll.TestClass ThrowException",
       "environmentVariables": {
         "ASPNETCORE_ENVIRONMENT": "Development"
-      }
+      },
+      "nativeDebugging": false
     },
     "WebApp3": {
       "commandName": "Project",
-      "launchBrowser": true,
-      "applicationUrl": "https://localhost:5001;http://localhost:5000",
+      "commandLineArgs": "\"\" \"C:\\ssd\\diagnostics\\artifacts\\bin\\SymbolTestDll\\Debug\\net462\\publish\\SymbolTestDll.dll\" SymbolTestDll.TestClass ThrowException",
       "environmentVariables": {
         "ASPNETCORE_ENVIRONMENT": "Development"
-      }
+      },
+      "nativeDebugging": true,
+      "applicationUrl": "https://localhost:5001;http://localhost:5000"
     }
   }
 }
\ No newline at end of file
index 38d56fde64a5606e693825a410ef0d2bb54117d3..b667cde6266bb13f97676baf18740a7af6440e4d 100644 (file)
@@ -211,6 +211,25 @@ public class SOS
         });
     }
 
+    [SkippableTheory, MemberData(nameof(GetConfigurations), "TestName", "SOS.DualRuntimes")]
+    public async Task DualRuntimes(TestConfiguration config)
+    {
+        // The assembly path, class and function name of the desktop test code to load/run
+        string desktopTestParameters = TestConfiguration.MakeCanonicalPath(config.GetValue("DesktopTestParameters"));
+        if (string.IsNullOrEmpty(desktopTestParameters))
+        {
+            throw new SkipTestException("DesktopTestParameters config value does not exists");
+        }
+        await RunTest("DualRuntimes.script", testLive: false, information: new SOSRunner.TestInformation {
+            TestConfiguration = config,
+            TestName = "SOS.DualRuntimes",
+            DebuggeeName = "WebApp3",
+            DebuggeeArguments = desktopTestParameters,
+            UsePipeSync = true,
+            DumpGenerator = SOSRunner.DumpGenerator.DotNetDump
+        }); ;
+    }
+
     [SkippableTheory, MemberData(nameof(Configurations))]
     public async Task LLDBPluginTests(TestConfiguration config)
     {
index de87100f8735057f8f1fe09b7fbdc7ccb3c552be..0c84c29966c5c8e1a7a5537547a7955a9b8d4bf3 100644 (file)
@@ -228,11 +228,6 @@ public class SOSRunner : IDisposable
                     }
                     arguments.Append(debuggeeConfig.BinaryExePath);
                 }
-                if (!string.IsNullOrWhiteSpace(information.DebuggeeArguments))
-                {
-                    arguments.Append(" ");
-                    arguments.Append(information.DebuggeeArguments);
-                }
 
                 // Setup a pipe server for the debuggee to connect to sync when to take a dump
                 if (information.UsePipeSync)
@@ -244,6 +239,13 @@ public class SOSRunner : IDisposable
                     arguments.Append(pipeName);
                 }
 
+                // Add any additional test specific arguments after the pipe name (if one).
+                if (!string.IsNullOrWhiteSpace(information.DebuggeeArguments))
+                {
+                    arguments.Append(" ");
+                    arguments.Append(information.DebuggeeArguments);
+                }
+
                 // Create the debuggee process runner
                 ProcessRunner processRunner = new ProcessRunner(exePath, ReplaceVariables(variables, arguments.ToString())).
                     WithLog(new TestRunner.TestLogger(outputHelper.IndentedOutput)).
@@ -901,7 +903,7 @@ public class SOSRunner : IDisposable
         TestConfiguration config = information.TestConfiguration;
         string dumpRoot = action == DebuggerAction.GenerateDump ? config.DebuggeeDumpOutputRootDir() : config.DebuggeeDumpInputRootDir();
         if (!string.IsNullOrEmpty(dumpRoot)) {
-            return Path.Combine(dumpRoot, Path.GetFileNameWithoutExtension(debuggeeName) + "." + information.DumpType.ToString() + ".dmp");
+            return Path.Combine(dumpRoot, information.TestName + "." + information.DumpType.ToString() + ".dmp");
         }
         return null;
     }
diff --git a/src/SOS/SOS.UnitTests/Scripts/DualRuntimes.script b/src/SOS/SOS.UnitTests/Scripts/DualRuntimes.script
new file mode 100644 (file)
index 0000000..e54fa09
--- /dev/null
@@ -0,0 +1,106 @@
+#
+# Tests an app with both the .NET Core and Desktop runtimes
+#
+
+CONTINUE
+
+LOADSOS
+
+SOSCOMMAND:SetSymbolServer -ms
+
+#
+# First test the .NET Core runtime that WebApp3 was started
+#
+
+# Verify that ClrStack with no options works
+SOSCOMMAND:ClrStack
+VERIFY:.*OS Thread Id:\s+0x<HEXVAL>\s+.*
+VERIFY:\s+Child\s+SP\s+IP\s+Call Site\s+
+
+# Verify that ClrStack for all threads works
+SOSCOMMAND:ClrStack -all
+
+# Verify that ClrStack with managed/native mixed works
+SOSCOMMAND:ClrStack -f
+VERIFY:.*OS Thread Id:\s+0x<HEXVAL>\s+.*
+VERIFY:\s+Child\s+SP\s+IP\s+Call Site\s+
+
+# Verify that ClrStack all option works (locals/params)
+SOSCOMMAND:ClrStack -a
+VERIFY:.*OS Thread Id:\s+0x<HEXVAL>\s+.*
+VERIFY:\s+Child\s+SP\s+IP\s+Call Site\s+
+
+# Issue: https://github.com/dotnet/diagnostics/issues/504
+!IFDEF:ALPINE
+
+# Verify that ClrStack with the ICorDebug options works
+SOSCOMMAND:ClrStack -i
+VERIFY:.*\s+Dumping managed stack and managed variables using ICorDebug.\s+
+VERIFY:.*\s+Child\s+SP\s+IP\s+Call Site\s+
+VERIFY:.*\s+Stack walk complete.\s+
+
+ENDIF:ALPINE
+
+# Verify that Threads (clrthreads) works
+IFDEF:DOTNETDUMP
+SOSCOMMAND:clrthreads
+ENDIF:DOTNETDUMP
+!IFDEF:DOTNETDUMP
+SOSCOMMAND:Threads
+ENDIF:DOTNETDUMP
+VERIFY:\s*ThreadCount:\s+<DECVAL>\s+
+VERIFY:\s+UnstartedThread:\s+<DECVAL>\s+
+VERIFY:\s+BackgroundThread:\s+<DECVAL>\s+
+VERIFY:\s+PendingThread:\s+<DECVAL>\s+
+VERIFY:\s+DeadThread:\s+<DECVAL>\s+
+VERIFY:\s+Hosted Runtime:\s+no\s+
+VERIFY:\s+ID\s+OSID\s+ThreadOBJ\s+State.*\s+
+VERIFY:\s+<DECVAL>\s+<DECVAL>\s+<HEXVAL>\s+<HEXVAL>.*\s+
+
+SOSCOMMAND:DumpHeap -stat
+VERIFY:\s*Statistics:\s+
+VERIFY:\s+MT\s+Count\s+TotalSize\s+Class Name\s+
+VERIFY:\s*<HEXVAL>\s+<DECVAL>\s+<DECVAL>\s+.*
+VERIFY:\s*Total\s+<DECVAL>\s+objects\s+
+!VERIFY:.*UNKNOWN.*
+
+#
+# Now switch to and test the desktop runtime state (SymbolTestDll)
+#
+
+SOSCOMMAND:SOSStatus
+VERIFY:.*\.NET Core runtime at.*\s+
+
+SOSCOMMAND:SOSStatus -desktop
+VERIFY:\s*Switched to desktop CLR runtime successfully\s+
+
+# Currently not on a desktop CLR thread so using the -all option to dump it.
+SOSCOMMAND:ClrStack -all
+VERIFY:.*OS Thread Id:\s+0x<HEXVAL>\s+.*
+VERIFY:\s+Child\s+SP\s+IP\s+Call Site\s+
+VERIFY:.*\s+<HEXVAL>\s+<HEXVAL>.*\s+SymbolTestDll\.TestClass\.Foo7\(System\.String\)\s+\[(?i:.*[\\|/]TestClass\.cs) @ (33)\]\s*
+VERIFY:\s+<HEXVAL>\s+<HEXVAL>\s+SymbolTestDll\.TestClass\.Foo6\(.*\)\s+\[(?i:.*[\\|/]TestClass\.cs) @ 21\]\s*
+VERIFY:\s+<HEXVAL>\s+<HEXVAL>\s+SymbolTestDll\.TestClass\.Foo5\(.*\)\s+\[(?i:.*[\\|/]TestClass\.cs) @ 16\]\s*
+VERIFY:\s+<HEXVAL>\s+<HEXVAL>\s+SymbolTestDll\.TestClass\.ThrowException\(.*\)\s+\[(?i:.*[\\|/]TestClass\.cs) @ 10\]\s*
+
+IFDEF:DOTNETDUMP
+SOSCOMMAND:clrthreads
+ENDIF:DOTNETDUMP
+!IFDEF:DOTNETDUMP
+SOSCOMMAND:Threads
+ENDIF:DOTNETDUMP
+VERIFY:\s*ThreadCount:\s+<DECVAL>\s+
+VERIFY:\s+UnstartedThread:\s+<DECVAL>\s+
+VERIFY:\s+BackgroundThread:\s+<DECVAL>\s+
+VERIFY:\s+PendingThread:\s+<DECVAL>\s+
+VERIFY:\s+DeadThread:\s+<DECVAL>\s+
+VERIFY:\s+Hosted Runtime:\s+no\s+
+VERIFY:\s+ID\s+OSID\s+ThreadOBJ\s+State.*\s+
+VERIFY:\s+<DECVAL>\s+<DECVAL>\s+<HEXVAL>\s+<HEXVAL>.*\s+
+
+SOSCOMMAND:DumpHeap
+VERIFY:\s*Statistics:\s+
+VERIFY:\s+MT\s+Count\s+TotalSize\s+Class Name\s+
+VERIFY:\s*<HEXVAL>\s+<DECVAL>\s+<DECVAL>\s+.*
+VERIFY:\s*Total\s+<DECVAL>\s+objects\s+
+!VERIFY:.*UNKNOWN.*
\ No newline at end of file
index ce368f3f80a6d1f7398d86997b6860eec235c961..f6aad57955dfc4b4db433827a57222daed544569 100644 (file)
@@ -32,6 +32,9 @@ interface ICLRControl;
 // CLSID ComCallUnmarshal2
 cpp_quote("EXTERN_GUID(CLSID_ComCallUnmarshalV4, 0x45fb4600,0xe6e8,0x4928,0xb2,0x5e,0x50,0x47,0x6f,0xf7,0x94,0x25);")
 
+// CLSID CLRRuntimeHost
+cpp_quote("EXTERN_GUID(CLSID_CLRRuntimeHost, 0x90F1A06E, 0x7712, 0x4762, 0x86, 0xB5, 0x7A, 0x5E, 0xBA, 0x6B, 0xDB, 0x02);")
+
 // IID ICLRRuntimeHost: uuid(90F1A06C-7712-4762-86B5-7A5EBA6BDB02)
 cpp_quote("EXTERN_GUID(IID_ICLRRuntimeHost, 0x90F1A06C, 0x7712, 0x4762, 0x86, 0xB5, 0x7A, 0x5E, 0xBA, 0x6B, 0xDB, 0x02);")
 
index ab7bbb0d0c714d346fdb970e1dace07f0760e7ab..67df991516afbe2510a395b491d5b0b6e3fad9f5 100644 (file)
@@ -1,12 +1,19 @@
-// Licensed to the .NET Foundation under one or more agreements.
-// The .NET Foundation licenses this file to you under the MIT license.
-// See the LICENSE file in the project root for more information.
 
 
 /* this ALWAYS GENERATED file contains the definitions for the interfaces */
 
 
- /* File created by MIDL compiler version 8.00.0603 */
+ /* File created by MIDL compiler version 8.01.0622 */
+/* at Mon Jan 18 19:14:07 2038
+ */
+/* Compiler settings for C:/ssd/diagnostics/src/inc/mscoree.idl:
+    Oicf, W1, Zp8, env=Win32 (32b run), target_arch=X86 8.01.0622 
+    protocol : dce , ms_ext, c_ext, robust
+    error checks: allocation ref bounds_check enum stub_data 
+    VC __declspec() decoration level: 
+         __declspec(uuid()), __declspec(selectany), __declspec(novtable)
+         DECLSPEC_UUID(), MIDL_INTERFACE()
+*/
 /* @@MIDL_FILE_HEADING(  ) */
 
 #pragma warning( disable: 4049 )  /* more than 64k source lines */
@@ -80,6 +87,7 @@ struct IHostControl;
 struct ICLRControl;
 
 EXTERN_GUID(CLSID_ComCallUnmarshalV4, 0x45fb4600,0xe6e8,0x4928,0xb2,0x5e,0x50,0x47,0x6f,0xf7,0x94,0x25);
+EXTERN_GUID(CLSID_CLRRuntimeHost, 0x90F1A06E, 0x7712, 0x4762, 0x86, 0xB5, 0x7A, 0x5E, 0xBA, 0x6B, 0xDB, 0x02);
 EXTERN_GUID(IID_ICLRRuntimeHost, 0x90F1A06C, 0x7712, 0x4762, 0x86, 0xB5, 0x7A, 0x5E, 0xBA, 0x6B, 0xDB, 0x02);
 EXTERN_GUID(IID_ICLRRuntimeHost2, 0x712AB73F, 0x2C22, 0x4807, 0xAD, 0x7E, 0xF5, 0x01, 0xD7, 0xb7, 0x2C, 0x2D);
 EXTERN_GUID(IID_ICLRRuntimeHost4, 0x64F6D366, 0xD7C2, 0x4F1F, 0xB4, 0xB2, 0xE8, 0x16, 0x0C, 0xAC, 0x43, 0xAF);
@@ -229,7 +237,7 @@ enum __MIDL___MIDL_itf_mscoree_0000_0000_0009
         eExitProcess   = ( eRudeUnloadAppDomain + 1 ) ,
         eFastExitProcess       = ( eExitProcess + 1 ) ,
         eRudeExitProcess       = ( eFastExitProcess + 1 ) ,
-        MaxPolicyAction        = (eRudeExitProcess + 1 )
+        MaxPolicyAction        = ( eRudeExitProcess + 1 ) 
     }  EPolicyAction;
 
 
index c51d8bdc9ac62af0165904d0aba158d16c264bfa..5fe232dbcdf901716d0607d84bbfebef53e266ed 100644 (file)
@@ -1,13 +1,19 @@
-// Licensed to the .NET Foundation under one or more agreements.
-// The .NET Foundation licenses this file to you under the MIT license.
-// See the LICENSE file in the project root for more information.
-
 
 
 /* this ALWAYS GENERATED file contains the definitions for the interfaces */
 
 
- /* File created by MIDL compiler version 8.00.0603 */
+ /* File created by MIDL compiler version 8.01.0622 */
+/* at Mon Jan 18 19:14:07 2038
+ */
+/* Compiler settings for C:/ssd/diagnostics/src/inc/mscorsvc.idl:
+    Oicf, W1, Zp8, env=Win32 (32b run), target_arch=X86 8.01.0622 
+    protocol : dce , ms_ext, c_ext, robust
+    error checks: allocation ref bounds_check enum stub_data 
+    VC __declspec() decoration level: 
+         __declspec(uuid()), __declspec(selectany), __declspec(novtable)
+         DECLSPEC_UUID(), MIDL_INTERFACE()
+*/
 /* @@MIDL_FILE_HEADING(  ) */
 
 #pragma warning( disable: 4049 )  /* more than 64k source lines */
@@ -23,7 +29,7 @@
 
 #ifndef __RPCNDR_H_VERSION__
 #error this stub requires an updated version of <rpcndr.h>
-#endif // __RPCNDR_H_VERSION__
+#endif /* __RPCNDR_H_VERSION__ */
 
 #ifndef COM_NO_WINDOWS_H
 #include "windows.h"
@@ -81,13 +87,6 @@ typedef interface ICorSvcRepository ICorSvcRepository;
 #endif         /* __ICorSvcRepository_FWD_DEFINED__ */
 
 
-#ifndef __ICorSvcAppX_FWD_DEFINED__
-#define __ICorSvcAppX_FWD_DEFINED__
-typedef interface ICorSvcAppX ICorSvcAppX;
-
-#endif         /* __ICorSvcAppX_FWD_DEFINED__ */
-
-
 #ifndef __ICorSvcLogger_FWD_DEFINED__
 #define __ICorSvcLogger_FWD_DEFINED__
 typedef interface ICorSvcLogger ICorSvcLogger;
@@ -982,96 +981,6 @@ EXTERN_C const IID IID_ICorSvcRepository;
 #endif         /* __ICorSvcRepository_INTERFACE_DEFINED__ */
 
 
-#ifndef __ICorSvcAppX_INTERFACE_DEFINED__
-#define __ICorSvcAppX_INTERFACE_DEFINED__
-
-/* interface ICorSvcAppX */
-/* [unique][uuid][object] */ 
-
-
-EXTERN_C const IID IID_ICorSvcAppX;
-
-#if defined(__cplusplus) && !defined(CINTERFACE)
-    
-    MIDL_INTERFACE("5c814791-559e-4f7f-83ce-184a4ccbae24")
-    ICorSvcAppX : public IUnknown
-    {
-    public:
-        virtual HRESULT STDMETHODCALLTYPE SetPackage( 
-            /* [in] */ BSTR pPackageFullName) = 0;
-        
-        virtual HRESULT STDMETHODCALLTYPE SetLocalAppDataDirectory( 
-            /* [in] */ BSTR pLocalAppDataDirectory) = 0;
-        
-    };
-    
-    
-#else  /* C style interface */
-
-    typedef struct ICorSvcAppXVtbl
-    {
-        BEGIN_INTERFACE
-        
-        HRESULT ( STDMETHODCALLTYPE *QueryInterface )( 
-            ICorSvcAppX * This,
-            /* [in] */ REFIID riid,
-            /* [annotation][iid_is][out] */ 
-            _COM_Outptr_  void **ppvObject);
-        
-        ULONG ( STDMETHODCALLTYPE *AddRef )( 
-            ICorSvcAppX * This);
-        
-        ULONG ( STDMETHODCALLTYPE *Release )( 
-            ICorSvcAppX * This);
-        
-        HRESULT ( STDMETHODCALLTYPE *SetPackage )( 
-            ICorSvcAppX * This,
-            /* [in] */ BSTR pPackageFullName);
-        
-        HRESULT ( STDMETHODCALLTYPE *SetLocalAppDataDirectory )( 
-            ICorSvcAppX * This,
-            /* [in] */ BSTR pLocalAppDataDirectory);
-        
-        END_INTERFACE
-    } ICorSvcAppXVtbl;
-
-    interface ICorSvcAppX
-    {
-        CONST_VTBL struct ICorSvcAppXVtbl *lpVtbl;
-    };
-
-    
-
-#ifdef COBJMACROS
-
-
-#define ICorSvcAppX_QueryInterface(This,riid,ppvObject)        \
-    ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) 
-
-#define ICorSvcAppX_AddRef(This)       \
-    ( (This)->lpVtbl -> AddRef(This) ) 
-
-#define ICorSvcAppX_Release(This)      \
-    ( (This)->lpVtbl -> Release(This) ) 
-
-
-#define ICorSvcAppX_SetPackage(This,pPackageFullName)  \
-    ( (This)->lpVtbl -> SetPackage(This,pPackageFullName) ) 
-
-#define ICorSvcAppX_SetLocalAppDataDirectory(This,pLocalAppDataDirectory)      \
-    ( (This)->lpVtbl -> SetLocalAppDataDirectory(This,pLocalAppDataDirectory) ) 
-
-#endif /* COBJMACROS */
-
-
-#endif         /* C style interface */
-
-
-
-
-#endif         /* __ICorSvcAppX_INTERFACE_DEFINED__ */
-
-
 #ifndef __ICorSvcLogger_INTERFACE_DEFINED__
 #define __ICorSvcLogger_INTERFACE_DEFINED__