Delete dead/unused code (#21138)
authorJan Kotas <jkotas@microsoft.com>
Wed, 21 Nov 2018 16:23:30 +0000 (08:23 -0800)
committerGitHub <noreply@github.com>
Wed, 21 Nov 2018 16:23:30 +0000 (08:23 -0800)
48 files changed:
src/System.Private.CoreLib/Resources/Strings.resx
src/System.Private.CoreLib/System.Private.CoreLib.csproj
src/System.Private.CoreLib/src/System/AppContext/AppContext.cs
src/System.Private.CoreLib/src/System/AppContext/AppContextDefaultValues.cs
src/System.Private.CoreLib/src/System/AppDomain.cs
src/System.Private.CoreLib/src/System/AppDomainSetup.cs
src/System.Private.CoreLib/src/System/Object.cs
src/System.Private.CoreLib/src/System/Runtime/Loader/AssemblyLoadContext.cs
src/System.Private.CoreLib/src/System/Runtime/MemoryFailPoint.cs
src/System.Private.CoreLib/src/System/RuntimeHandles.cs
src/System.Private.CoreLib/src/System/SharedStatics.cs [deleted file]
src/inc/appxutil.h
src/inc/clrconfigvalues.h
src/inc/fusionsetup.h [deleted file]
src/inc/iappdomainsetup.h [deleted file]
src/strongname/api/CMakeLists.txt
src/strongname/api/strongnamecoreclr.cpp [deleted file]
src/strongname/inc/sncoreclr.h [deleted file]
src/vm/CMakeLists.txt
src/vm/appdomain.cpp
src/vm/assembly.cpp
src/vm/assembly.hpp
src/vm/assemblynative.cpp
src/vm/assemblynative.hpp
src/vm/ceeload.cpp
src/vm/classcompat.cpp
src/vm/classcompat.h
src/vm/clrprivbinderloadfile.h [deleted file]
src/vm/comcallablewrapper.cpp
src/vm/comcallablewrapper.h
src/vm/comdelegate.cpp
src/vm/compile.cpp
src/vm/crossgen/CMakeLists.txt
src/vm/crossgen_mscorlib/CMakeLists.txt
src/vm/domainfile.cpp
src/vm/ecalllist.h
src/vm/eeconfig.cpp
src/vm/eeconfig.h
src/vm/jithelpers.cpp
src/vm/methodtable.cpp
src/vm/methodtablebuilder.cpp
src/vm/mlinfo.cpp
src/vm/mscorlib.h
src/vm/object.h
src/vm/pefile.cpp
src/vm/pefile.h
src/vm/reflectioninvocation.cpp
src/vm/threads.h

index 4f17a28..83d712d 100644 (file)
   <data name="Argument_UnmatchingSymScope" xml:space="preserve">
     <value>Non-matching symbol scope.</value>
   </data>
-  <data name="Argument_UnrecognizedLoaderOptimization" xml:space="preserve">
-    <value>Unrecognized LOADER_OPTIMIZATION property value.  Supported values may include "SingleDomain", "MultiDomain", "MultiDomainHost", and "NotSpecified".</value>
-  </data>
   <data name="Argument_UTCOutOfRange" xml:space="preserve">
     <value>The UTC time represented when the offset is applied must be between year 0 and 10,000.</value>
   </data>
   <data name="NotSupported_DynamicAssembly" xml:space="preserve">
     <value>The invoked member is not supported in a dynamic assembly.</value>
   </data>
-  <data name="NotSupported_DynamicAssemblyNoRunAccess" xml:space="preserve">
-    <value>Cannot execute code on a dynamic assembly without run access.</value>
-  </data>
   <data name="NotSupported_DynamicMethodFlags" xml:space="preserve">
     <value>Wrong MethodAttributes or CallingConventions for DynamicMethod. Only public, static, standard supported</value>
   </data>
   <data name="Argument_PrecisionTooLarge" xml:space="preserve">
     <value>Precision cannot be larger than {0}.</value>
   </data>
-</root>
\ No newline at end of file
+</root>
index b3ca6ce..a4d5573 100644 (file)
     <Compile Include="$(BclSourcesRoot)\System\RtType.cs" />
     <Compile Include="$(BclSourcesRoot)\System\RuntimeArgumentHandle.cs" />
     <Compile Include="$(BclSourcesRoot)\System\RuntimeHandles.cs" />
-    <Compile Include="$(BclSourcesRoot)\System\SharedStatics.cs" />
     <Compile Include="$(BclSourcesRoot)\System\StartupHookProvider.cs" />
     <Compile Include="$(BclSourcesRoot)\System\StubHelpers.cs" />
     <Compile Include="$(BclSourcesRoot)\System\Type.CoreCLR.cs" />
index 7c7e74f..7b8e436 100644 (file)
@@ -4,6 +4,8 @@
 
 
 using System.Collections.Generic;
+using System.Reflection;
+using System.Runtime.Versioning;
 
 namespace System
 {
@@ -43,8 +45,9 @@ namespace System
         {
             get
             {
-                // Forward the value that is set on the current domain.
-                return AppDomain.CurrentDomain.SetupInformation.TargetFrameworkName;
+                // The Target framework is not the framework that the process is actually running on.
+                // It is the value read from the TargetFrameworkAttribute on the .exe that started the process.
+                return Assembly.GetEntryAssembly()?.GetCustomAttribute<TargetFrameworkAttribute>()?.FrameworkName;
             }
         }
 
index 8829844..bfbb989 100644 (file)
@@ -26,7 +26,7 @@ namespace System
         /// </summary>
         private static void ParseTargetFrameworkName(out string identifier, out string profile, out int version)
         {
-            string targetFrameworkMoniker = AppDomain.CurrentDomain.SetupInformation.TargetFrameworkName;
+            string targetFrameworkMoniker = AppContext.TargetFrameworkName;
 
             if (!TryParseFrameworkName(targetFrameworkMoniker, out identifier, out version, out profile))
             {
index be1330b..874aca5 100644 (file)
@@ -486,7 +486,7 @@ namespace System
                                                         string[] propertyNames,
                                                         string[] propertyValues)
         {
-            var newSetup = new AppDomainSetup(setup, copyDomainBoundData: false);
+            var newSetup = new AppDomainSetup(setup);
 
             // Remove the special AppDomainCompatSwitch entries from the set of name value pairs
             // And add them to the AppDomainSetup
@@ -532,7 +532,7 @@ namespace System
             var propertyValues = (string[])args[3]; // can contain null elements
 
             AppDomain ad = CurrentDomain;
-            var newSetup = new AppDomainSetup(setup, copyDomainBoundData: false);
+            var newSetup = new AppDomainSetup(setup);
 
             if (propertyNames != null && propertyValues != null)
             {
@@ -661,8 +661,6 @@ namespace System
         [MethodImpl(MethodImplOptions.InternalCall)]
         private extern void nSetupFriendlyName(string friendlyName);
 
-        public AppDomainSetup SetupInformation => new AppDomainSetup(FusionStore, copyDomainBoundData: true);
-
         [MethodImpl(MethodImplOptions.InternalCall)]
         internal extern string IsStringInterned(string str);
 
index b899954..f897e36 100644 (file)
@@ -11,67 +11,17 @@ namespace System
 {
     internal sealed class AppDomainSetup
     {
-        internal enum LoaderInformation
-        {
-            // If you add a new value, add the corresponding property
-            // to AppDomain.GetData() and SetData()'s switch statements,
-            // as well as fusionsetup.h.
-            ApplicationBaseValue = 0,  // LOADER_APPLICATION_BASE
-            ConfigurationFileValue = 1,  // LOADER_CONFIGURATION_BASE
-            DynamicBaseValue = 2,  // LOADER_DYNAMIC_BASE
-            DevPathValue = 3,  // LOADER_DEVPATH
-            ApplicationNameValue = 4,  // LOADER_APPLICATION_NAME
-            PrivateBinPathValue = 5,  // LOADER_PRIVATE_PATH
-            PrivateBinPathProbeValue = 6,  // LOADER_PRIVATE_BIN_PATH_PROBE
-            ShadowCopyDirectoriesValue = 7,  // LOADER_SHADOW_COPY_DIRECTORIES
-            ShadowCopyFilesValue = 8,  // LOADER_SHADOW_COPY_FILES
-            CachePathValue = 9,  // LOADER_CACHE_PATH
-            LicenseFileValue = 10, // LOADER_LICENSE_FILE
-            DisallowPublisherPolicyValue = 11, // LOADER_DISALLOW_PUBLISHER_POLICY
-            DisallowCodeDownloadValue = 12, // LOADER_DISALLOW_CODE_DOWNLOAD
-            DisallowBindingRedirectsValue = 13, // LOADER_DISALLOW_BINDING_REDIRECTS
-            DisallowAppBaseProbingValue = 14, // LOADER_DISALLOW_APPBASE_PROBING
-            ConfigurationBytesValue = 15, // LOADER_CONFIGURATION_BYTES
-            LoaderMaximum = 18  // LOADER_MAXIMUM
-        }
-
-        // Constants from fusionsetup.h.
-        private const string LOADER_OPTIMIZATION = "LOADER_OPTIMIZATION";
-
-        private const string ACTAG_APP_BASE_URL = "APPBASE";
-
-        // This class has an unmanaged representation so be aware you will need to make edits in vm\object.h if you change the order
-        // of these fields or add new ones.
-
-        private string[] _Entries;
-#pragma warning disable 169
-        private string _AppBase; // for compat with v1.1
-#pragma warning restore 169
+        private string _appBase;
 
         // A collection of strings used to indicate which breaking changes shouldn't be applied
         // to an AppDomain. We only use the keys, the values are ignored.
         private Dictionary<string, object> _CompatFlags;
 
-        internal AppDomainSetup(AppDomainSetup copy, bool copyDomainBoundData)
+        internal AppDomainSetup(AppDomainSetup copy)
         {
-            string[] mine = Value;
             if (copy != null)
             {
-                string[] other = copy.Value;
-                int mineSize = _Entries.Length;
-                int otherSize = other.Length;
-                int size = (otherSize < mineSize) ? otherSize : mineSize;
-
-                for (int i = 0; i < size; i++)
-                    mine[i] = other[i];
-
-                if (size < mineSize)
-                {
-                    // This case can happen when the copy is a deserialized version of
-                    // an AppDomainSetup object serialized by Everett.
-                    for (int i = size; i < mineSize; i++)
-                        mine[i] = null;
-                }
+                _appBase = copy._appBase;
 
                 if (copy._CompatFlags != null)
                 {
@@ -89,42 +39,27 @@ namespace System
             char[] sep = { '\\', '/' };
             int i = imageLocation.LastIndexOfAny(sep);
 
-            if (i == -1)
+            if (i != -1)
             {
-                ApplicationName = imageLocation;
-            }
-            else
-            {
-                ApplicationName = imageLocation.Substring(i + 1);
                 string appBase = imageLocation.Substring(0, i + 1);
 
                 if (imageLocationAlreadyNormalized)
-                    Value[(int)LoaderInformation.ApplicationBaseValue] = appBase;
+                    _appBase = appBase;
                 else
                     ApplicationBase = appBase;
             }
         }
 
-        internal string[] Value
-        {
-            get
-            {
-                if (_Entries == null)
-                    _Entries = new string[(int)LoaderInformation.LoaderMaximum];
-                return _Entries;
-            }
-        }
-
         public string ApplicationBase
         {
             get
             {
-                return Value[(int)LoaderInformation.ApplicationBaseValue];
+                return _appBase;
             }
 
             set
             {
-                Value[(int)LoaderInformation.ApplicationBaseValue] = (value == null || value.Length == 0)?null:Path.GetFullPath(value);
+                _appBase = (value == null || value.Length == 0)? null:Path.GetFullPath(value);
             }
         }
         
@@ -149,22 +84,5 @@ namespace System
                 _CompatFlags = null;
             }
         }
-
-        // The Target framework is not the framework that the process is actually running on.
-        // It is the value read from the TargetFrameworkAttribute on the .exe that started the process.
-        public string TargetFrameworkName => Assembly.GetEntryAssembly()?.GetCustomAttribute<TargetFrameworkAttribute>()?.FrameworkName;
-
-        public string ApplicationName
-        {
-            get
-            {
-                return Value[(int)LoaderInformation.ApplicationNameValue];
-            }
-
-            set
-            {
-                Value[(int)LoaderInformation.ApplicationNameValue] = value;
-            }
-        }
     }
 }
index 7cb584a..5cf1d0c 100644 (file)
 ** 
 ===========================================================*/
 
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+using System.Runtime.Versioning;
+
 namespace System
 {
-    using System;
-    using System.Diagnostics;
-    using System.Runtime;
-    using System.Runtime.InteropServices;
-    using System.Runtime.CompilerServices;
-    using System.Runtime.ConstrainedExecution;
-    using System.Runtime.Versioning;
-    using CultureInfo = System.Globalization.CultureInfo;
-    using FieldInfo = System.Reflection.FieldInfo;
-    using BindingFlags = System.Reflection.BindingFlags;
-
     // The Object is the root class for all object in the CLR System. Object 
     // is the super class for all other CLR objects and provide a set of methods and low level
     // services to subclasses.  These services include object synchronization and support for clone
@@ -38,7 +31,7 @@ namespace System
     public class Object
     {
         // Creates a new instance of an Object.
-        [System.Runtime.Versioning.NonVersionable]
+        [NonVersionable]
         public Object()
         {
         }
@@ -75,7 +68,7 @@ namespace System
             return objA.Equals(objB);
         }
 
-        [System.Runtime.Versioning.NonVersionable]
+        [NonVersionable]
         public static bool ReferenceEquals(object objA, object objB)
         {
             return objA == objB;
@@ -102,7 +95,7 @@ namespace System
 
         // Allow an object to free resources before the object is reclaimed by the GC.
         // 
-        [System.Runtime.Versioning.NonVersionable]
+        [NonVersionable]
         ~Object()
         {
         }
@@ -114,85 +107,6 @@ namespace System
         // 
         [MethodImplAttribute(MethodImplOptions.InternalCall)]
         protected extern object MemberwiseClone();
-
-
-        // Sets the value specified in the variant on the field
-        // 
-        private void FieldSetter(string typeName, string fieldName, object val)
-        {
-            Debug.Assert(typeName != null);
-            Debug.Assert(fieldName != null);
-
-            // Extract the field info object
-            FieldInfo fldInfo = GetFieldInfo(typeName, fieldName);
-
-            if (fldInfo.IsInitOnly)
-                throw new FieldAccessException(SR.FieldAccess_InitOnly);
-
-            // Make sure that the value is compatible with the type
-            // of field
-            Type pt = fldInfo.FieldType;
-            if (pt.IsByRef)
-            {
-                pt = pt.GetElementType();
-            }
-
-            if (!pt.IsInstanceOfType(val))
-            {
-                val = Convert.ChangeType(val, pt, CultureInfo.InvariantCulture);
-            }
-
-            // Set the value
-            fldInfo.SetValue(this, val);
-        }
-
-        // Gets the value specified in the variant on the field
-        // 
-        private void FieldGetter(string typeName, string fieldName, ref object val)
-        {
-            Debug.Assert(typeName != null);
-            Debug.Assert(fieldName != null);
-
-            // Extract the field info object
-            FieldInfo fldInfo = GetFieldInfo(typeName, fieldName);
-
-            // Get the value
-            val = fldInfo.GetValue(this);
-        }
-
-        // Gets the field info object given the type name and field name.
-        // 
-        private FieldInfo GetFieldInfo(string typeName, string fieldName)
-        {
-            Debug.Assert(typeName != null);
-            Debug.Assert(fieldName != null);
-
-            Type t = GetType();
-            while (null != t)
-            {
-                if (t.FullName.Equals(typeName))
-                {
-                    break;
-                }
-
-                t = t.BaseType;
-            }
-
-            if (null == t)
-            {
-                throw new ArgumentException();
-            }
-
-            FieldInfo fldInfo = t.GetField(fieldName, BindingFlags.Public |
-                                                      BindingFlags.Instance |
-                                                      BindingFlags.IgnoreCase);
-            if (null == fldInfo)
-            {
-                throw new ArgumentException();
-            }
-
-            return fldInfo;
-        }
     }
 
 
index 5738786..971b6a4 100644 (file)
@@ -33,9 +33,6 @@ namespace System.Runtime.Loader
         private InternalState state;
 
         [DllImport(JitHelpers.QCall, CharSet = CharSet.Unicode)]
-        private static extern bool CanUseAppPathAssemblyLoadContextInCurrentDomain();
-
-        [DllImport(JitHelpers.QCall, CharSet = CharSet.Unicode)]
         private static extern IntPtr InitializeAssemblyLoadContext(IntPtr ptrAssemblyLoadContext, bool fRepresentsTPALoadContext, bool isCollectible);
 
         [DllImport(JitHelpers.QCall, CharSet = CharSet.Unicode)]
@@ -422,16 +419,12 @@ namespace System.Runtime.Loader
             {
                 if (s_DefaultAssemblyLoadContext == null)
                 {
-                    // Try to initialize the default assembly load context with apppath one if we are allowed to
-                    if (AssemblyLoadContext.CanUseAppPathAssemblyLoadContextInCurrentDomain())
+                    // Synchronize access to initializing Default ALC
+                    lock (s_initLock)
                     {
-                        // Synchronize access to initializing Default ALC
-                        lock (s_initLock)
+                        if (s_DefaultAssemblyLoadContext == null)
                         {
-                            if (s_DefaultAssemblyLoadContext == null)
-                            {
-                                s_DefaultAssemblyLoadContext = new AppPathAssemblyLoadContext();
-                            }
+                            s_DefaultAssemblyLoadContext = new AppPathAssemblyLoadContext();
                         }
                     }
                 }
index 750e873..a6d8ab4 100644 (file)
@@ -136,8 +136,8 @@ namespace System.Runtime
         // use a MemoryFailPoint at the same time, and they both succeed, that
         // they don't trample over each other's memory.  Keep a process-wide
         // count of "reserved" memory, and decrement this in Dispose and
-        // in the critical finalizer.  See 
-        // SharedStatics.MemoryFailPointReservedMemory
+        // in the critical finalizer.
+        private static long s_failPointReservedMemory;
 
         private ulong _reservedMemory;  // The size of this request (from user)
         private bool _mustSubtractReservation; // Did we add data to SharedStatics?
@@ -196,7 +196,7 @@ namespace System.Runtime
                 // If we have enough room, then skip some stages.
                 // Note that multiple threads can still lead to a race condition for our free chunk
                 // of address space, which can't be easily solved.
-                ulong reserved = SharedStatics.MemoryFailPointReservedMemory;
+                ulong reserved = (ulong)Volatile.Read(ref s_failPointReservedMemory);
                 ulong segPlusReserved = segmentSize + reserved;
                 bool overflow = segPlusReserved < segmentSize || segPlusReserved < reserved;
                 bool needPageFile = availPageFile < (requestedSizeRounded + reserved + LowMemoryFudgeFactor) || overflow;
@@ -307,7 +307,7 @@ namespace System.Runtime
 
             RuntimeHelpers.PrepareConstrainedRegions();
 
-            SharedStatics.AddMemoryFailPointReservation((long)size);
+            Interlocked.Add(ref s_failPointReservedMemory, (long)size);
             _mustSubtractReservation = true;
 #endif
         }
@@ -412,7 +412,7 @@ namespace System.Runtime
             {
                 RuntimeHelpers.PrepareConstrainedRegions();
 
-                SharedStatics.AddMemoryFailPointReservation(-((long)_reservedMemory));
+                Interlocked.Add(ref s_failPointReservedMemory, -(long)_reservedMemory);
                 _mustSubtractReservation = false;
             }
 
index 030b9ab..bb1a010 100644 (file)
@@ -2,26 +2,15 @@
 // The .NET Foundation licenses this file to you under the MIT license.
 // See the LICENSE file in the project root for more information.
 
+using System.Diagnostics;
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+using System.Runtime.Serialization;
+using System.Threading;
 
 namespace System
 {
-    using System;
-    using System.Reflection;
-    using System.Reflection.Emit;
-    using System.Runtime;
-    using System.Runtime.ConstrainedExecution;
-    using System.Diagnostics;
-    using System.Runtime.Serialization;
-    using System.Runtime.CompilerServices;
-    using System.Runtime.InteropServices;
-    using System.Threading;
-    using System.Runtime.Versioning;
-    using System.Text;
-    using System.Globalization;
-    using System.Security;
-    using Microsoft.Win32.SafeHandles;
-    using StackCrawlMark = System.Threading.StackCrawlMark;
-
     public unsafe struct RuntimeTypeHandle : ISerializable
     {
         // Returns handle for interop with EE. The handle is guaranteed to be non-null.
@@ -1233,7 +1222,7 @@ namespace System
         }
 
         [MethodImplAttribute(MethodImplOptions.InternalCall)]
-        internal static extern IRuntimeMethodInfo GetDynamicMethod(DynamicMethod method, RuntimeModule module, string name, byte[] sig, Resolver resolver);
+        internal static extern IRuntimeMethodInfo GetDynamicMethod(System.Reflection.Emit.DynamicMethod method, RuntimeModule module, string name, byte[] sig, Resolver resolver);
 
         [MethodImplAttribute(MethodImplOptions.InternalCall)]
         internal static extern int GetToken(RuntimeModule module);
diff --git a/src/System.Private.CoreLib/src/System/SharedStatics.cs b/src/System.Private.CoreLib/src/System/SharedStatics.cs
deleted file mode 100644 (file)
index 8111b9b..0000000
+++ /dev/null
@@ -1,55 +0,0 @@
-// 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.
-
-/*=============================================================================
-**
-**
-**
-** Purpose: Container for statics that are shared across AppDomains.
-**
-**
-=============================================================================*/
-
-using System.Threading;
-using System.Security;
-using System.Runtime.CompilerServices;
-using System.Runtime.ConstrainedExecution;
-using System.Diagnostics;
-
-namespace System
-{
-    internal sealed class SharedStatics
-    {
-        // this is declared static but is actually forced to be the same object 
-        // for each AppDomain at AppDomain create time.
-        private static SharedStatics _sharedStatics;
-
-        // Note: Do not add any code in this ctor because it is not called 
-        // when we set up _sharedStatics via AppDomain::SetupSharedStatics
-        private SharedStatics()
-        {
-            Debug.Fail("SharedStatics..ctor() is never called.");
-        }
-
-        // This is the total amount of memory currently "reserved" via
-        // all MemoryFailPoints allocated within the process.
-        // Stored as a long because we need to use Interlocked.Add.
-        private long _memFailPointReservedMemory;
-
-        internal static long AddMemoryFailPointReservation(long size)
-        {
-            // Size can legitimately be negative - see Dispose.
-            return Interlocked.Add(ref _sharedStatics._memFailPointReservedMemory, (long)size);
-        }
-
-        internal static ulong MemoryFailPointReservedMemory
-        {
-            get
-            {
-                Debug.Assert(Volatile.Read(ref _sharedStatics._memFailPointReservedMemory) >= 0, "Process-wide MemoryFailPoint reserved memory was negative!");
-                return (ulong)Volatile.Read(ref _sharedStatics._memFailPointReservedMemory);
-            }
-        }
-    }
-}
index 312c486..411c18b 100644 (file)
@@ -10,7 +10,6 @@
 
 #include "clrtypes.h"
 #include "appmodel.h"
-#include "fusionsetup.h"
 
 #define PACKAGE_FILTER_CLR_DEFAULT (PACKAGE_FILTER_HEAD|PACKAGE_FILTER_DIRECT)
 
index c56c3cb..5a12b57 100644 (file)
@@ -443,12 +443,7 @@ RETAIL_CONFIG_DWORD_INFO(INTERNAL_InterpreterFallback, W("InterpreterFallback"),
 ///
 CONFIG_DWORD_INFO_DIRECT_ACCESS(INTERNAL_APIThreadStress, W("APIThreadStress"), "Used to test Loader for race conditions")
 RETAIL_CONFIG_DWORD_INFO_DIRECT_ACCESS(EXTERNAL_ForceLog, W("ForceLog"), "Fusion flag to enforce assembly binding log. Heavily used and documented in MSDN and BLOGS.")
-RETAIL_CONFIG_DWORD_INFO_DIRECT_ACCESS(EXTERNAL_LoaderOptimization, W("LoaderOptimization"), "Controls code sharing behavior")
 RETAIL_CONFIG_STRING_INFO(INTERNAL_CoreClrBinderLog, W("CoreClrBinderLog"), "Debug flag that enabled detailed log for new binder (similar to stress logging).")
-RETAIL_CONFIG_DWORD_INFO(EXTERNAL_DisableIJWVersionCheck, W("DisableIJWVersionCheck"), 0, "Don't perform the new version check that prevents unsupported IJW in-proc SxS.")
-RETAIL_CONFIG_DWORD_INFO(UNSUPPORTED_EnableFastBindClosure, W("EnableFastBindClosure"), 0, "If set to >0 the binder uses CFastAssemblyBindingClosure instances")
-RETAIL_CONFIG_DWORD_INFO(INTERNAL_DisableFXClosureWalk, W("DisableFXClosureWalk"), 0, "Disable full closure walks even in the presence of FX binding redirects")
-CONFIG_DWORD_INFO(INTERNAL_TagAssemblyNames, W("TagAssemblyNames"), 0, "Enable CAssemblyName::_tag field for more convenient debugging.")
 RETAIL_CONFIG_STRING_INFO(INTERNAL_WinMDPath, W("WinMDPath"), "Path for Windows WinMD files")
 
 ///
@@ -527,15 +522,12 @@ CONFIG_DWORD_INFO_EX(INTERNAL_NGenOnlyOneMethod, W("NGenOnlyOneMethod"), 0, "",
 CONFIG_DWORD_INFO_EX(INTERNAL_NgenOrder, W("NgenOrder"), 0, "", CLRConfig::REGUTIL_default)
 CONFIG_DWORD_INFO_EX(INTERNAL_partialNGenStress, W("partialNGenStress"), 0, "", CLRConfig::REGUTIL_default)
 CONFIG_DWORD_INFO_EX(INTERNAL_ZapDoNothing, W("ZapDoNothing"), 0, "", CLRConfig::REGUTIL_default)
-RETAIL_CONFIG_DWORD_INFO_DIRECT_ACCESS(EXTERNAL_HardPrejitEnabled, W("HardPrejitEnabled"), "")
-RETAIL_CONFIG_DWORD_INFO_EX(INTERNAL_EnableHardbinding, W("EnableHardbinding"), 0, "Enables the use of hardbinding", CLRConfig::REGUTIL_default)
 CONFIG_DWORD_INFO_EX(INTERNAL_NgenForceFailureMask, W("NgenForceFailureMask"), -1, "Bitmask used to control which locations will check and raise the failure (defaults to bits: -1)", CLRConfig::REGUTIL_default)
 CONFIG_DWORD_INFO_EX(INTERNAL_NgenForceFailureCount, W("NgenForceFailureCount"), 0, "If set to >0 and we have IBC data we will force a failure after we reference an IBC data item <value> times", CLRConfig::REGUTIL_default)
 CONFIG_DWORD_INFO_EX(INTERNAL_NgenForceFailureKind, W("NgenForceFailureKind"), 1, "If set to 1, We will throw a TypeLoad exception; If set to 2, We will cause an A/V", CLRConfig::REGUTIL_default)
 RETAIL_CONFIG_DWORD_INFO(UNSUPPORTED_NGenEnableCreatePdb, W("NGenEnableCreatePdb"), 0, "If set to >0 ngen.exe displays help on, recognizes createpdb in the command line")
 RETAIL_CONFIG_DWORD_INFO(INTERNAL_NGenSimulateDiskFull, W("NGenSimulateDiskFull"), 0, "If set to 1, ngen will throw a Disk full exception in ZapWriter.cpp:Save()")
 RETAIL_CONFIG_DWORD_INFO(INTERNAL_PartialNGen, W("PartialNGen"), -1, "Generate partial NGen images")
-RETAIL_CONFIG_DWORD_INFO(INTERNAL_NgenAllowMscorlibSoftbind, W("NgenAllowMscorlibSoftbind"), 0, "Disable forced hard-binding to mscorlib")
 
 CONFIG_DWORD_INFO(INTERNAL_NoASLRForNgen, W("NoASLRForNgen"), 0, "Turn off IMAGE_DLLCHARACTERISTICS_DYNAMIC_BASE bit in generated ngen images. Makes nidump output repeatable from run to run.")
 
@@ -816,7 +808,6 @@ RETAIL_CONFIG_STRING_INFO_DIRECT_ACCESS(UNSUPPORTED_ShimDatabaseVersion, W("Shim
 RETAIL_CONFIG_DWORD_INFO(UNSUPPORTED_SleepOnExit, W("SleepOnExit"), 0, "Used for lrak detection. I'd say deprecated by umdh.")
 CONFIG_DWORD_INFO_DIRECT_ACCESS(INTERNAL_StubLinkerUnwindInfoVerificationOn, W("StubLinkerUnwindInfoVerificationOn"), "")
 RETAIL_CONFIG_DWORD_INFO_EX(UNSUPPORTED_SuccessExit, W("SuccessExit"), 0, "", CLRConfig::REGUTIL_default)
-CONFIG_DWORD_INFO(INTERNAL_SupressAllowUntrustedCallerChecks, W("SupressAllowUntrustedCallerChecks"), 0, "Disable APTCA")
 RETAIL_CONFIG_DWORD_INFO_DIRECT_ACCESS(EXTERNAL_SymbolReadingPolicy, W("SymbolReadingPolicy"), "Specifies when PDBs may be read")
 RETAIL_CONFIG_DWORD_INFO(UNSUPPORTED_TestDataConsistency, W("TestDataConsistency"), FALSE, "Allows ensuring the left side is not holding locks (and may thus be in an inconsistent state) when inspection occurs")
 RETAIL_CONFIG_DWORD_INFO_EX(EXTERNAL_ThreadGuardPages, W("ThreadGuardPages"), 0, "", CLRConfig::REGUTIL_default)
diff --git a/src/inc/fusionsetup.h b/src/inc/fusionsetup.h
deleted file mode 100644 (file)
index 87b3e44..0000000
+++ /dev/null
@@ -1,63 +0,0 @@
-// 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.
-
-
-
-/*============================================================
-**
-** Header:  FusionSetup.h
-**
-** Purpose: Defines that are used in both managed and unmanged
-**          code
-**
-**
-===========================================================*/
-#ifndef _FUSIONSETUP_H
-#define _FUSIONSETUP_H
-
-#define DYNAMIC_DIRECTORY                   L"DYNAMIC_DIRECTORY"
-#define LOADER_OPTIMIZATION                 L"LOADER_OPTIMIZATION"
-#define LICENSE_FILE                        L"LICENSE_FILE"
-#define APPENV_BASE                         L"APPBASE"
-#define APPENV_RELATIVEPATH                 L"RELPATH"
-#define APPENV_GLOBALPATH                   L"CORPATH"
-#define APPENV_DEVPATH                      L"DEVPATH"
-#define APPENV_RUNFROMSOURCE                L"__FUSION_RUN_FROM_SOURCE__"
-#define CONFIGURATION_EXTENSION             L".config"
-#define MACHINE_CONFIGURATION_FILE          L"config\\machine.config"
-#define MANIFEST_FILE_PATH                  L"MANIFEST_FILE_PATH"
-#define VERSIONING_MANIFEST_BASE            L"VERSIONING_MANIFEST_BASE"
-
-#ifndef ACTAG_HOST_CONFIG_FILE
-#define ACTAG_HOST_CONFIG_FILE              L"HOST_CONFIG"
-#endif 
-
-// These are defines instead of enums because they are
-// used to change FusionSetup.cs as well as being used in
-// unmanaged code.
-// If you add a new value, add the corresponding enum value
-// to AppDomainSetup+LoaderInformation, and add the corresponding
-// property value to AppDomain.GetData() and SetData()'s switch
-// statements.
-#define  LOADER_APPLICATION_BASE            0
-#define  LOADER_CONFIGURATION_BASE          1
-#define  LOADER_DYNAMIC_BASE                2
-#define  LOADER_DEVPATH                     3
-#define  LOADER_APPLICATION_NAME            4
-#define  LOADER_PRIVATE_PATH                5
-#define  LOADER_PRIVATE_BIN_PATH_PROBE      6
-#define  LOADER_SHADOW_COPY_DIRECTORIES     7
-#define  LOADER_SHADOW_COPY_FILES           8
-#define  LOADER_CACHE_PATH                  9
-#define  LOADER_LICENSE_FILE               10
-#define  LOADER_DISALLOW_PUBLISHER_POLICY  11
-#define  LOADER_DISALLOW_CODE_DOWNLOAD     12
-#define  LOADER_DISALLOW_BINDING_REDIRECTS 13
-#define  LOADER_DISALLOW_APPBASE_PROBING   14
-#define  LOADER_CONFIGURATION_BYTES        15
-#define  LOADER_MANIFEST_FILE_PATH         16
-#define  LOADER_VERSIONING_MANIFEST_BASE   17
-#define  LOADER_MAXIMUM                    18
-
-#endif
diff --git a/src/inc/iappdomainsetup.h b/src/inc/iappdomainsetup.h
deleted file mode 100644 (file)
index ef8d9a3..0000000
+++ /dev/null
@@ -1,612 +0,0 @@
-// 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.
-
-// 
-
-// ********************************************************
-// ********************************************************
-// ********************************************************
-//
-// !!!! DON'T USE THIS FILE, IT WILL BE OBSOLETE SOON !!!!
-//
-// ********************************************************
-// ********************************************************
-// ********************************************************
-
-
-
-
-#ifndef FEATURE_COMINTEROP
-#error FEATURE_COMINTEROP is required for this file
-#endif // FEATURE_COMINTEROP
-
-
-
-#ifdef _MSC_VER
-#pragma warning( disable: 4049 )  /* more than 64k source lines */
-#endif
-
-/* this ALWAYS GENERATED file contains the definitions for the interfaces */
-
-
- /* File created by MIDL compiler version 6.00.0338 */
-/* at Wed Jan 17 16:59:41 2001
- */
-/* Compiler settings for IAppDomainSetup.idl:
-    Os, W1, Zp8, env=Win32 (32b run)
-    protocol : dce , ms_ext, c_ext
-    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(  )
-
-
-/* verify that the <rpcndr.h> version is high enough to compile this file*/
-#ifndef __REQUIRED_RPCNDR_H_VERSION__
-#define __REQUIRED_RPCNDR_H_VERSION__ 440
-#endif
-
-#include "rpc.h"
-#include "rpcndr.h"
-
-#ifndef __RPCNDR_H_VERSION__
-#error this stub requires an updated version of <rpcndr.h>
-#endif // __RPCNDR_H_VERSION__
-
-#ifndef COM_NO_WINDOWS_H
-#include "windows.h"
-#include "ole2.h"
-#endif /*COM_NO_WINDOWS_H*/
-
-#ifndef __IAppDomainSetup_h__
-#define __IAppDomainSetup_h__
-
-#if defined(_MSC_VER) && (_MSC_VER >= 1020)
-#pragma once
-#endif
-
-/* Forward Declarations */ 
-
-#ifndef __IAppDomainSetup_FWD_DEFINED__
-#define __IAppDomainSetup_FWD_DEFINED__
-typedef interface IAppDomainSetup IAppDomainSetup;
-#endif         /* __IAppDomainSetup_FWD_DEFINED__ */
-
-
-/* header files for imported files */
-#include "unknwn.h"
-
-#ifdef __cplusplus
-extern "C"{
-#endif 
-
-void * __RPC_USER MIDL_user_allocate(size_t);
-void __RPC_USER MIDL_user_free( void * ); 
-
-#ifndef __IAppDomainSetup_INTERFACE_DEFINED__
-#define __IAppDomainSetup_INTERFACE_DEFINED__
-
-/* interface IAppDomainSetup */
-/* [object][oleautomation][version][uuid] */ 
-
-
-EXTERN_C const IID IID_IAppDomainSetup;
-
-#if defined(__cplusplus) && !defined(CINTERFACE)
-    
-    MIDL_INTERFACE("27FFF232-A7A8-40DD-8D4A-734AD59FCD41")
-    IAppDomainSetup : public IUnknown
-    {
-    public:
-        virtual /* [propget] */ HRESULT __stdcall get_ApplicationBase( 
-            /* [retval][out] */ BSTR *pRetVal) = 0;
-        
-        virtual /* [propput] */ HRESULT __stdcall put_ApplicationBase( 
-            /* [in] */ BSTR pRetVal) = 0;
-        
-        virtual /* [propget] */ HRESULT __stdcall get_ApplicationName( 
-            /* [retval][out] */ BSTR *pRetVal) = 0;
-        
-        virtual /* [propput] */ HRESULT __stdcall put_ApplicationName( 
-            /* [in] */ BSTR pRetVal) = 0;
-        
-        virtual /* [propget] */ HRESULT __stdcall get_CachePath( 
-            /* [retval][out] */ BSTR *pRetVal) = 0;
-        
-        virtual /* [propput] */ HRESULT __stdcall put_CachePath( 
-            /* [in] */ BSTR pRetVal) = 0;
-        
-        virtual /* [propget] */ HRESULT __stdcall get_ConfigurationFile( 
-            /* [retval][out] */ BSTR *pRetVal) = 0;
-        
-        virtual /* [propput] */ HRESULT __stdcall put_ConfigurationFile( 
-            /* [in] */ BSTR pRetVal) = 0;
-        
-        virtual /* [propget] */ HRESULT __stdcall get_DynamicBase( 
-            /* [retval][out] */ BSTR *pRetVal) = 0;
-        
-        virtual /* [propput] */ HRESULT __stdcall put_DynamicBase( 
-            /* [in] */ BSTR pRetVal) = 0;
-        
-        virtual /* [propget] */ HRESULT __stdcall get_LicenseFile( 
-            /* [retval][out] */ BSTR *pRetVal) = 0;
-        
-        virtual /* [propput] */ HRESULT __stdcall put_LicenseFile( 
-            /* [in] */ BSTR pRetVal) = 0;
-        
-        virtual /* [propget] */ HRESULT __stdcall get_PrivateBinPath( 
-            /* [retval][out] */ BSTR *pRetVal) = 0;
-        
-        virtual /* [propput] */ HRESULT __stdcall put_PrivateBinPath( 
-            /* [in] */ BSTR pRetVal) = 0;
-        
-        virtual /* [propget] */ HRESULT __stdcall get_PrivateBinPathProbe( 
-            /* [retval][out] */ BSTR *pRetVal) = 0;
-        
-        virtual /* [propput] */ HRESULT __stdcall put_PrivateBinPathProbe( 
-            /* [in] */ BSTR pRetVal) = 0;
-        
-        virtual /* [propget] */ HRESULT __stdcall get_ShadowCopyDirectories( 
-            /* [retval][out] */ BSTR *pRetVal) = 0;
-        
-        virtual /* [propput] */ HRESULT __stdcall put_ShadowCopyDirectories( 
-            /* [in] */ BSTR pRetVal) = 0;
-        
-        virtual /* [propget] */ HRESULT __stdcall get_ShadowCopyFiles( 
-            /* [retval][out] */ BSTR *pRetVal) = 0;
-        
-        virtual /* [propput] */ HRESULT __stdcall put_ShadowCopyFiles( 
-            /* [in] */ BSTR pRetVal) = 0;
-        
-    };
-    
-#else  /* C style interface */
-
-    typedef struct IAppDomainSetupVtbl
-    {
-        BEGIN_INTERFACE
-        
-        HRESULT ( STDMETHODCALLTYPE *QueryInterface )( 
-            IAppDomainSetup * This,
-            /* [in] */ REFIID riid,
-            /* [iid_is][out] */ void **ppvObject);
-        
-        ULONG ( STDMETHODCALLTYPE *AddRef )( 
-            IAppDomainSetup * This);
-        
-        ULONG ( STDMETHODCALLTYPE *Release )( 
-            IAppDomainSetup * This);
-        
-        /* [propget] */ HRESULT ( __stdcall *get_ApplicationBase )( 
-            IAppDomainSetup * This,
-            /* [retval][out] */ BSTR *pRetVal);
-        
-        /* [propput] */ HRESULT ( __stdcall *put_ApplicationBase )( 
-            IAppDomainSetup * This,
-            /* [in] */ BSTR pRetVal);
-        
-        /* [propget] */ HRESULT ( __stdcall *get_ApplicationName )( 
-            IAppDomainSetup * This,
-            /* [retval][out] */ BSTR *pRetVal);
-        
-        /* [propput] */ HRESULT ( __stdcall *put_ApplicationName )( 
-            IAppDomainSetup * This,
-            /* [in] */ BSTR pRetVal);
-        
-        /* [propget] */ HRESULT ( __stdcall *get_CachePath )( 
-            IAppDomainSetup * This,
-            /* [retval][out] */ BSTR *pRetVal);
-        
-        /* [propput] */ HRESULT ( __stdcall *put_CachePath )( 
-            IAppDomainSetup * This,
-            /* [in] */ BSTR pRetVal);
-        
-        /* [propget] */ HRESULT ( __stdcall *get_ConfigurationFile )( 
-            IAppDomainSetup * This,
-            /* [retval][out] */ BSTR *pRetVal);
-        
-        /* [propput] */ HRESULT ( __stdcall *put_ConfigurationFile )( 
-            IAppDomainSetup * This,
-            /* [in] */ BSTR pRetVal);
-        
-        /* [propget] */ HRESULT ( __stdcall *get_DynamicBase )( 
-            IAppDomainSetup * This,
-            /* [retval][out] */ BSTR *pRetVal);
-        
-        /* [propput] */ HRESULT ( __stdcall *put_DynamicBase )( 
-            IAppDomainSetup * This,
-            /* [in] */ BSTR pRetVal);
-        
-        /* [propget] */ HRESULT ( __stdcall *get_LicenseFile )( 
-            IAppDomainSetup * This,
-            /* [retval][out] */ BSTR *pRetVal);
-        
-        /* [propput] */ HRESULT ( __stdcall *put_LicenseFile )( 
-            IAppDomainSetup * This,
-            /* [in] */ BSTR pRetVal);
-        
-        /* [propget] */ HRESULT ( __stdcall *get_PrivateBinPath )( 
-            IAppDomainSetup * This,
-            /* [retval][out] */ BSTR *pRetVal);
-        
-        /* [propput] */ HRESULT ( __stdcall *put_PrivateBinPath )( 
-            IAppDomainSetup * This,
-            /* [in] */ BSTR pRetVal);
-        
-        /* [propget] */ HRESULT ( __stdcall *get_PrivateBinPathProbe )( 
-            IAppDomainSetup * This,
-            /* [retval][out] */ BSTR *pRetVal);
-        
-        /* [propput] */ HRESULT ( __stdcall *put_PrivateBinPathProbe )( 
-            IAppDomainSetup * This,
-            /* [in] */ BSTR pRetVal);
-        
-        /* [propget] */ HRESULT ( __stdcall *get_ShadowCopyDirectories )( 
-            IAppDomainSetup * This,
-            /* [retval][out] */ BSTR *pRetVal);
-        
-        /* [propput] */ HRESULT ( __stdcall *put_ShadowCopyDirectories )( 
-            IAppDomainSetup * This,
-            /* [in] */ BSTR pRetVal);
-        
-        /* [propget] */ HRESULT ( __stdcall *get_ShadowCopyFiles )( 
-            IAppDomainSetup * This,
-            /* [retval][out] */ BSTR *pRetVal);
-        
-        /* [propput] */ HRESULT ( __stdcall *put_ShadowCopyFiles )( 
-            IAppDomainSetup * This,
-            /* [in] */ BSTR pRetVal);
-        
-        END_INTERFACE
-    } IAppDomainSetupVtbl;
-
-    interface IAppDomainSetup
-    {
-        CONST_VTBL struct IAppDomainSetupVtbl *lpVtbl;
-    };
-
-    
-
-#ifdef COBJMACROS
-
-
-#define IAppDomainSetup_QueryInterface(This,riid,ppvObject)    \
-    (This)->lpVtbl -> QueryInterface(This,riid,ppvObject)
-
-#define IAppDomainSetup_AddRef(This)   \
-    (This)->lpVtbl -> AddRef(This)
-
-#define IAppDomainSetup_Release(This)  \
-    (This)->lpVtbl -> Release(This)
-
-
-#define IAppDomainSetup_get_ApplicationBase(This,pRetVal)      \
-    (This)->lpVtbl -> get_ApplicationBase(This,pRetVal)
-
-#define IAppDomainSetup_put_ApplicationBase(This,pRetVal)      \
-    (This)->lpVtbl -> put_ApplicationBase(This,pRetVal)
-
-#define IAppDomainSetup_get_ApplicationName(This,pRetVal)      \
-    (This)->lpVtbl -> get_ApplicationName(This,pRetVal)
-
-#define IAppDomainSetup_put_ApplicationName(This,pRetVal)      \
-    (This)->lpVtbl -> put_ApplicationName(This,pRetVal)
-
-#define IAppDomainSetup_get_CachePath(This,pRetVal)    \
-    (This)->lpVtbl -> get_CachePath(This,pRetVal)
-
-#define IAppDomainSetup_put_CachePath(This,pRetVal)    \
-    (This)->lpVtbl -> put_CachePath(This,pRetVal)
-
-#define IAppDomainSetup_get_ConfigurationFile(This,pRetVal)    \
-    (This)->lpVtbl -> get_ConfigurationFile(This,pRetVal)
-
-#define IAppDomainSetup_put_ConfigurationFile(This,pRetVal)    \
-    (This)->lpVtbl -> put_ConfigurationFile(This,pRetVal)
-
-#define IAppDomainSetup_get_DynamicBase(This,pRetVal)  \
-    (This)->lpVtbl -> get_DynamicBase(This,pRetVal)
-
-#define IAppDomainSetup_put_DynamicBase(This,pRetVal)  \
-    (This)->lpVtbl -> put_DynamicBase(This,pRetVal)
-
-#define IAppDomainSetup_get_LicenseFile(This,pRetVal)  \
-    (This)->lpVtbl -> get_LicenseFile(This,pRetVal)
-
-#define IAppDomainSetup_put_LicenseFile(This,pRetVal)  \
-    (This)->lpVtbl -> put_LicenseFile(This,pRetVal)
-
-#define IAppDomainSetup_get_PrivateBinPath(This,pRetVal)       \
-    (This)->lpVtbl -> get_PrivateBinPath(This,pRetVal)
-
-#define IAppDomainSetup_put_PrivateBinPath(This,pRetVal)       \
-    (This)->lpVtbl -> put_PrivateBinPath(This,pRetVal)
-
-#define IAppDomainSetup_get_PrivateBinPathProbe(This,pRetVal)  \
-    (This)->lpVtbl -> get_PrivateBinPathProbe(This,pRetVal)
-
-#define IAppDomainSetup_put_PrivateBinPathProbe(This,pRetVal)  \
-    (This)->lpVtbl -> put_PrivateBinPathProbe(This,pRetVal)
-
-#define IAppDomainSetup_get_ShadowCopyDirectories(This,pRetVal)        \
-    (This)->lpVtbl -> get_ShadowCopyDirectories(This,pRetVal)
-
-#define IAppDomainSetup_put_ShadowCopyDirectories(This,pRetVal)        \
-    (This)->lpVtbl -> put_ShadowCopyDirectories(This,pRetVal)
-
-#define IAppDomainSetup_get_ShadowCopyFiles(This,pRetVal)      \
-    (This)->lpVtbl -> get_ShadowCopyFiles(This,pRetVal)
-
-#define IAppDomainSetup_put_ShadowCopyFiles(This,pRetVal)      \
-    (This)->lpVtbl -> put_ShadowCopyFiles(This,pRetVal)
-
-#endif /* COBJMACROS */
-
-
-#endif         /* C style interface */
-
-
-
-/* [propget] */ HRESULT __stdcall IAppDomainSetup_get_ApplicationBase_Proxy( 
-    IAppDomainSetup * This,
-    /* [retval][out] */ BSTR *pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_get_ApplicationBase_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propput] */ HRESULT __stdcall IAppDomainSetup_put_ApplicationBase_Proxy( 
-    IAppDomainSetup * This,
-    /* [in] */ BSTR pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_put_ApplicationBase_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propget] */ HRESULT __stdcall IAppDomainSetup_get_ApplicationName_Proxy( 
-    IAppDomainSetup * This,
-    /* [retval][out] */ BSTR *pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_get_ApplicationName_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propput] */ HRESULT __stdcall IAppDomainSetup_put_ApplicationName_Proxy( 
-    IAppDomainSetup * This,
-    /* [in] */ BSTR pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_put_ApplicationName_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propget] */ HRESULT __stdcall IAppDomainSetup_get_CachePath_Proxy( 
-    IAppDomainSetup * This,
-    /* [retval][out] */ BSTR *pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_get_CachePath_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propput] */ HRESULT __stdcall IAppDomainSetup_put_CachePath_Proxy( 
-    IAppDomainSetup * This,
-    /* [in] */ BSTR pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_put_CachePath_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propget] */ HRESULT __stdcall IAppDomainSetup_get_ConfigurationFile_Proxy( 
-    IAppDomainSetup * This,
-    /* [retval][out] */ BSTR *pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_get_ConfigurationFile_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propput] */ HRESULT __stdcall IAppDomainSetup_put_ConfigurationFile_Proxy( 
-    IAppDomainSetup * This,
-    /* [in] */ BSTR pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_put_ConfigurationFile_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propget] */ HRESULT __stdcall IAppDomainSetup_get_DynamicBase_Proxy( 
-    IAppDomainSetup * This,
-    /* [retval][out] */ BSTR *pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_get_DynamicBase_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propput] */ HRESULT __stdcall IAppDomainSetup_put_DynamicBase_Proxy( 
-    IAppDomainSetup * This,
-    /* [in] */ BSTR pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_put_DynamicBase_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propget] */ HRESULT __stdcall IAppDomainSetup_get_LicenseFile_Proxy( 
-    IAppDomainSetup * This,
-    /* [retval][out] */ BSTR *pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_get_LicenseFile_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propput] */ HRESULT __stdcall IAppDomainSetup_put_LicenseFile_Proxy( 
-    IAppDomainSetup * This,
-    /* [in] */ BSTR pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_put_LicenseFile_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propget] */ HRESULT __stdcall IAppDomainSetup_get_PrivateBinPath_Proxy( 
-    IAppDomainSetup * This,
-    /* [retval][out] */ BSTR *pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_get_PrivateBinPath_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propput] */ HRESULT __stdcall IAppDomainSetup_put_PrivateBinPath_Proxy( 
-    IAppDomainSetup * This,
-    /* [in] */ BSTR pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_put_PrivateBinPath_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propget] */ HRESULT __stdcall IAppDomainSetup_get_PrivateBinPathProbe_Proxy( 
-    IAppDomainSetup * This,
-    /* [retval][out] */ BSTR *pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_get_PrivateBinPathProbe_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propput] */ HRESULT __stdcall IAppDomainSetup_put_PrivateBinPathProbe_Proxy( 
-    IAppDomainSetup * This,
-    /* [in] */ BSTR pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_put_PrivateBinPathProbe_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propget] */ HRESULT __stdcall IAppDomainSetup_get_ShadowCopyDirectories_Proxy( 
-    IAppDomainSetup * This,
-    /* [retval][out] */ BSTR *pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_get_ShadowCopyDirectories_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propput] */ HRESULT __stdcall IAppDomainSetup_put_ShadowCopyDirectories_Proxy( 
-    IAppDomainSetup * This,
-    /* [in] */ BSTR pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_put_ShadowCopyDirectories_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propget] */ HRESULT __stdcall IAppDomainSetup_get_ShadowCopyFiles_Proxy( 
-    IAppDomainSetup * This,
-    /* [retval][out] */ BSTR *pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_get_ShadowCopyFiles_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-/* [propput] */ HRESULT __stdcall IAppDomainSetup_put_ShadowCopyFiles_Proxy( 
-    IAppDomainSetup * This,
-    /* [in] */ BSTR pRetVal);
-
-
-void __RPC_STUB IAppDomainSetup_put_ShadowCopyFiles_Stub(
-    IRpcStubBuffer *This,
-    IRpcChannelBuffer *_pRpcChannelBuffer,
-    PRPC_MESSAGE _pRpcMessage,
-    DWORD *_pdwStubPhase);
-
-
-
-#endif         /* __IAppDomainSetup_INTERFACE_DEFINED__ */
-
-
-/* Additional Prototypes for ALL interfaces */
-
-unsigned long             __RPC_USER  BSTR_UserSize(     unsigned long *, unsigned long            , BSTR * ); 
-unsigned char * __RPC_USER  BSTR_UserMarshal(  unsigned long *, unsigned char *, BSTR * ); 
-unsigned char * __RPC_USER  BSTR_UserUnmarshal(unsigned long *, unsigned char *, BSTR * ); 
-void                      __RPC_USER  BSTR_UserFree(     unsigned long *, BSTR * ); 
-
-/* end of Additional Prototypes */
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
-
-
index 079d9a5..4efcdb9 100644 (file)
@@ -12,7 +12,6 @@ add_definitions(-DSTRONGNAME_IN_VM -DSNAPI_INTERNAL)
 
 set(STRONGNAME_SOURCES
   strongname.cpp
-  strongnamecoreclr.cpp
   strongnameinternal.cpp
 )
 
diff --git a/src/strongname/api/strongnamecoreclr.cpp b/src/strongname/api/strongnamecoreclr.cpp
deleted file mode 100644 (file)
index 2b9b4b8..0000000
+++ /dev/null
@@ -1,95 +0,0 @@
-// 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.
-
-//
-// Several strong name tools are in a special scenario because they build in the CoreCLR build process, but
-// are expected to run against the desktop VM. Because of this, we need to setup the callback structure that
-// Utilcode asks for to point to callbacks that shim to the desktop.  These methods provide that shimming functionality.
-//
-
-#include "common.h"
-
-CoreClrCallbacks *GetCoreClrCallbacks();
-
-//
-// Get a pointer to an API out of the shim
-//
-// Arguments:
-//    szApiName - name of the API to get a pointer to
-//
-//
-
-template<typename FunctionPointer>
-FunctionPointer ApiShim(LPCSTR szApiName)
-{
-    static FunctionPointer pfnApi = NULL;
-
-    if (pfnApi == NULL)
-    {
-        CoreClrCallbacks *pCallbacks = GetCoreClrCallbacks();
-        pfnApi = reinterpret_cast<FunctionPointer>(GetProcAddress(pCallbacks->m_hmodCoreCLR, szApiName));
-        _ASSERTE(pfnApi != NULL);
-    }
-
-    return pfnApi;
-}
-
-//
-// Shim APIs, passing off into the desktop VM
-//
-
-IExecutionEngine* SnIEE()
-{
-    typedef IExecutionEngine* (* IEEFn_t)();
-    return ApiShim<IEEFn_t>("IEE")();
-}
-
-HRESULT SnGetCorSystemDirectory(SString&  pbuffer)
-{
-    typedef HRESULT (*GetCorSystemDirectoryFn_t)(SString&);
-    return ApiShim<GetCorSystemDirectoryFn_t>("GetCORSystemDirectory")(pbuffer);
-}
-
-//
-// Initialize a set of CoreCLR callbacks for utilcode to call into the VM with
-//
-// Return Value:
-//    CoreClrCallbacks for UtilCode
-//
-// Notes:
-//    Will not return NULL
-//
-
-CoreClrCallbacks *GetCoreClrCallbacks()
-{
-    static CoreClrCallbacks coreClrCallbacks = { 0 };
-    if (coreClrCallbacks.m_hmodCoreCLR == NULL)
-    {
-        // Run against the desktop CLR
-        coreClrCallbacks.m_hmodCoreCLR = WszLoadLibrary(W("mscoree.dll"));
-        coreClrCallbacks.m_pfnIEE = SnIEE;
-        coreClrCallbacks.m_pfnGetCORSystemDirectory = SnGetCorSystemDirectory;
-        coreClrCallbacks.m_pfnGetCLRFunction = NULL;
-    }
-
-    return &coreClrCallbacks;
-}
-
-// Initialize Utilcode
-//
-// Notes:
-//    Should only be called once
-//
-
-void InitUtilcode()
-{
-#ifdef _DEBUG
-    static bool fAlreadyInitialized = false;
-    _ASSERTE(!fAlreadyInitialized);
-    fAlreadyInitialized = true;
-#endif
-
-    InitUtilcode(*GetCoreClrCallbacks());
-}
-
diff --git a/src/strongname/inc/sncoreclr.h b/src/strongname/inc/sncoreclr.h
deleted file mode 100644 (file)
index 1b84a32..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-// 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.
-
-#ifndef _SNCORECLR_H
-#define _SNCORECLR_H
-
-
-void InitUtilcode();
-
-#endif // _SNCORECLR_H
index 1a94d82..06532b3 100644 (file)
@@ -407,7 +407,6 @@ set(VM_HEADERS_WKS
     ceemain.h
     clrconfignative.h
     clrex.h
-    clrprivbinderloadfile.h
     clrvarargs.h
     comdatetime.h
     comdependenthandle.h
index cb94f3b..bbbad02 100644 (file)
@@ -5877,35 +5877,7 @@ void AppDomain::SetupSharedStatics()
     // Because we are allocating/referencing objects, need to be in cooperative mode
     GCX_COOP();
 
-    static OBJECTHANDLE hSharedStaticsHandle = NULL;
-
-    if (hSharedStaticsHandle == NULL) {
-        // Note that there is no race here since the default domain is always set up first
-        _ASSERTE(IsDefaultDomain());
-
-        MethodTable *pMT = MscorlibBinder::GetClass(CLASS__SHARED_STATICS);
-        _ASSERTE(pMT->IsClassPreInited());
-
-        hSharedStaticsHandle = CreateGlobalHandle(AllocateObject(pMT));
-    }
-
-    DomainLocalModule *pLocalModule;
-
-    if (IsSingleAppDomain())
-    {
-        pLocalModule = MscorlibBinder::GetModule()->GetDomainLocalModule();
-    }
-    else
-    {
-        pLocalModule = GetDomainLocalBlock()->GetModuleSlot(
-            MscorlibBinder::GetModule()->GetModuleIndex());
-    }
-
-    FieldDesc *pFD = MscorlibBinder::GetField(FIELD__SHARED_STATICS__SHARED_STATICS);
-
-    OBJECTREF* pHandle = (OBJECTREF*)
-        ((TADDR)pLocalModule->GetPrecomputedGCStaticsBasePointer()+pFD->GetOffset());
-    SetObjectReference( pHandle, ObjectFromHandle(hSharedStaticsHandle), this );
+    DomainLocalModule *pLocalModule = MscorlibBinder::GetModule()->GetDomainLocalModule();
 
     // This is a convenient place to initialize String.Empty.
     // It is treated as intrinsic by the JIT as so the static constructor would never run.
index a7315b3..0f12539 100644 (file)
@@ -104,37 +104,26 @@ enum ReasonForNotSharing
 // in Assembly::Init()
 //----------------------------------------------------------------------------------------------
 Assembly::Assembly(BaseDomain *pDomain, PEAssembly* pFile, DebuggerAssemblyControlFlags debuggerFlags, BOOL fIsCollectible) :
-    m_FreeFlag(0),
     m_pDomain(pDomain),
     m_pClassLoader(NULL),
     m_pEntryPoint(NULL),
     m_pManifest(NULL),
     m_pManifestFile(clr::SafeAddRef(pFile)),
-    m_pOnDiskManifest(NULL),
     m_pFriendAssemblyDescriptor(NULL),
-    m_pbStrongNameKeyPair(NULL),
-    m_pwStrongNameKeyContainer(NULL),
     m_isDynamic(false),
 #ifdef FEATURE_COLLECTIBLE_TYPES
     m_isCollectible(fIsCollectible),
 #endif
-    m_needsToHideManifestForEmit(FALSE),
-    m_dwDynamicAssemblyAccess(ASSEMBLY_ACCESS_RUN),
     m_nextAvailableModuleIndex(1),
     m_pLoaderAllocator(NULL),
     m_isDisabledPrivateReflection(0),
 #ifdef FEATURE_COMINTEROP
-    m_pITypeLib(NULL),
     m_winMDStatus(WinMDStatus_Unknown),
     m_pManifestWinMDImport(NULL),
 #endif // FEATURE_COMINTEROP
     m_fIsDomainNeutral(pDomain == SharedDomain::GetDomain()),
-#ifdef FEATURE_LOADER_OPTIMIZATION
-    m_bMissingDependenciesCheckDone(FALSE),
-#endif // FEATURE_LOADER_OPTIMIZATION
     m_debuggerFlags(debuggerFlags),
-    m_fTerminated(FALSE),
-    m_HostAssemblyId(0)
+    m_fTerminated(FALSE)
 #ifdef FEATURE_COMINTEROP
     , m_InteropAttributeStatus(INTEROP_ATTRIBUTE_UNSET)
 #endif
@@ -286,17 +275,6 @@ Assembly::~Assembly()
     if (m_pFriendAssemblyDescriptor != NULL && m_pFriendAssemblyDescriptor != NO_FRIEND_ASSEMBLIES_MARKER)
         delete m_pFriendAssemblyDescriptor;
 
-    if (m_pbStrongNameKeyPair && (m_FreeFlag & FREE_KEY_PAIR))
-        delete[] m_pbStrongNameKeyPair;
-    if (m_pwStrongNameKeyContainer && (m_FreeFlag & FREE_KEY_CONTAINER))
-        delete[] m_pwStrongNameKeyContainer;
-
-    if (IsDynamic()) {
-        if (m_pOnDiskManifest)
-            // clear the on disk manifest if it is not cleared yet.
-            m_pOnDiskManifest = NULL;
-    }
-
     if (m_pManifestFile)
     {
         m_pManifestFile->Release();
@@ -363,26 +341,6 @@ void Assembly::StartUnload()
         ProfilerCallAssemblyUnloadStarted(this);
     }
 #endif
-
-    // we need to release tlb files eagerly
-#ifdef FEATURE_COMINTEROP
-    if(g_fProcessDetach == FALSE)
-    {
-        DefaultCatchFilterParam param; param.pv = COMPLUS_EXCEPTION_EXECUTE_HANDLER;
-        PAL_TRY(Assembly *, pThis, this)
-        {
-            if (pThis->m_pITypeLib && pThis->m_pITypeLib != (ITypeLib*)-1) {
-                pThis->m_pITypeLib->Release();
-                pThis->m_pITypeLib = NULL;
-            }
-        }
-        PAL_EXCEPT_FILTER(DefaultCatchFilter)
-        {
-        }
-        PAL_ENDTRY
-    }
-#endif // FEATURE_COMINTEROP
-
 }
 
 void Assembly::Terminate( BOOL signalProfiler )
@@ -717,30 +675,21 @@ Assembly *Assembly::CreateDynamic(AppDomain *pDomain, CreateDynamicAssemblyArgs
 
         pAssem->m_isDynamic = true;
 
-        pAssem->m_dwDynamicAssemblyAccess = args->access;
-
-        // Set the additional strong name information
-
-        pAssem->SetStrongNameLevel(Assembly::SN_NONE);
-
         if (publicKey.GetSize() > 0)
         {
-            pAssem->SetStrongNameLevel(Assembly::SN_PUBLIC_KEY);
+            // Since we have no way to validate the public key of a dynamic assembly we don't allow 
+            // partial trust code to emit a dynamic assembly with an arbitrary public key.
+            // Ideally we shouldn't allow anyone to emit a dynamic assembly with only a public key,
+            // but we allow a couple of exceptions to reduce the compat risk: full trust, caller's own key.
+            // As usual we treat anonymously hosted dynamic methods as partial trust code.
+            DomainAssembly* pCallerDomainAssembly = pCallerAssembly->GetDomainAssembly(pCallersDomain);
+            if (pCallerDomainAssembly == pCallersDomain->GetAnonymouslyHostedDynamicMethodsAssembly())
             {
-                // Since we have no way to validate the public key of a dynamic assembly we don't allow 
-                // partial trust code to emit a dynamic assembly with an arbitrary public key.
-                // Ideally we shouldn't allow anyone to emit a dynamic assembly with only a public key,
-                // but we allow a couple of exceptions to reduce the compat risk: full trust, caller's own key.
-                // As usual we treat anonymously hosted dynamic methods as partial trust code.
-                DomainAssembly* pCallerDomainAssembly = pCallerAssembly->GetDomainAssembly(pCallersDomain);
-                if (pCallerDomainAssembly == pCallersDomain->GetAnonymouslyHostedDynamicMethodsAssembly())
-                {
-                    DWORD cbKey = 0;
-                    const void* pKey = pCallerAssembly->GetPublicKey(&cbKey);
+                DWORD cbKey = 0;
+                const void* pKey = pCallerAssembly->GetPublicKey(&cbKey);
 
-                    if (!publicKey.Equals((const BYTE *)pKey, cbKey))
-                        COMPlusThrow(kInvalidOperationException, W("InvalidOperation_StrongNameKeyPairRequired"));
-                }
+                if (!publicKey.Equals((const BYTE *)pKey, cbKey))
+                    COMPlusThrow(kInvalidOperationException, W("InvalidOperation_StrongNameKeyPairRequired"));
             }
         }
 
@@ -2184,21 +2133,6 @@ GetAssembliesByName(LPCWSTR  szAppBase,
 
 #ifdef FEATURE_LOADER_OPTIMIZATION
 
-void Assembly::SetMissingDependenciesCheckDone()
-{
-    LIMITED_METHOD_CONTRACT;
-    m_bMissingDependenciesCheckDone=TRUE;
-};
-
-BOOL Assembly::MissingDependenciesCheckDone()
-{
-    LIMITED_METHOD_CONTRACT;
-    return m_bMissingDependenciesCheckDone;
-};
-
-
-
-
 BOOL Assembly::CanBeShared(DomainAssembly *pDomainAssembly)
 {
     PTR_PEAssembly pFile=pDomainAssembly->GetFile();
@@ -2349,49 +2283,6 @@ void DECLSPEC_NORETURN Assembly::ThrowBadImageException(LPCUTF8 pszNameSpace,
 
 
 #ifdef FEATURE_COMINTEROP
-//
-// Manage an ITypeLib pointer for this Assembly.
-//
-ITypeLib* Assembly::GetTypeLib()
-{
-    CONTRACTL
-    {
-        NOTHROW;
-        GC_TRIGGERS;
-        FORBID_FAULT;
-    }
-    CONTRACTL_END
-
-    // Get the value we are going to return.
-    ITypeLib *pResult = m_pITypeLib;
-    // If there is a value, AddRef() it.
-    if (pResult && pResult != (ITypeLib*)-1)
-        pResult->AddRef();
-    return pResult;
-} // ITypeLib* Assembly::GetTypeLib()
-
-void Assembly::SetTypeLib(ITypeLib *pNew)
-{
-    CONTRACTL
-    {
-        NOTHROW;
-        GC_TRIGGERS;
-        FORBID_FAULT;
-    }
-    CONTRACTL_END
-
-    ITypeLib *pOld;
-    pOld = InterlockedExchangeT(&m_pITypeLib, pNew);
-    // TypeLibs are refcounted pointers.
-    if (pNew != pOld)
-    {
-        if (pNew && pNew != (ITypeLib*)-1)
-            pNew->AddRef();
-        if (pOld && pOld != (ITypeLib*)-1)
-            pOld->Release();
-    }
-} // void Assembly::SetTypeLib()
-
 Assembly::WinMDStatus Assembly::GetWinMDStatus()
 {
     LIMITED_METHOD_CONTRACT;
index 7a25d03..cd34c70 100644 (file)
@@ -290,35 +290,6 @@ public:
         return GetManifestFile()->GetFlags();
     }
 
-
-    // Level of strong name support (dynamic assemblies only).
-    enum StrongNameLevel {
-        SN_NONE = 0,
-        SN_PUBLIC_KEY = 1,
-        SN_FULL_KEYPAIR_IN_ARRAY = 2,
-        SN_FULL_KEYPAIR_IN_CONTAINER = 3
-    };
-
-    StrongNameLevel GetStrongNameLevel()
-    {
-        LIMITED_METHOD_CONTRACT;
-        return m_eStrongNameLevel;
-    }
-
-    void SetStrongNameLevel(StrongNameLevel eLevel)
-    {
-        LIMITED_METHOD_CONTRACT;
-        m_eStrongNameLevel = eLevel;
-    }
-
-    // returns whether CAS policy needs to be resolved for this assembly
-    // or whether it's safe to skip that step.
-    BOOL CanSkipPolicyResolution()
-    {
-        WRAPPER_NO_CONTRACT;
-        return IsSystem() || (m_isDynamic && !(m_dwDynamicAssemblyAccess & ASSEMBLY_ACCESS_RUN));
-    }
-
     PTR_LoaderHeap GetLowFrequencyHeap();
     PTR_LoaderHeap GetHighFrequencyHeap();
     PTR_LoaderHeap GetStubHeap();
@@ -330,17 +301,6 @@ public:
         return m_pManifest;
     }
 
-    ReflectionModule* GetOnDiskManifestModule()
-    {
-        LIMITED_METHOD_CONTRACT;
-        return m_pOnDiskManifest;
-    }
-
-    BOOL NeedsToHideManifestForEmit()
-    {
-        return m_needsToHideManifestForEmit;
-    }
-
     PTR_PEAssembly GetManifestFile()
     {
         LIMITED_METHOD_CONTRACT;
@@ -464,12 +424,6 @@ public:
 
     FORCEINLINE BOOL IsDynamic() { LIMITED_METHOD_CONTRACT; return m_isDynamic; }
     FORCEINLINE BOOL IsCollectible() { LIMITED_METHOD_DAC_CONTRACT; return m_isCollectible; }
-    FORCEINLINE BOOL HasRunAccess() {
-        LIMITED_METHOD_CONTRACT; 
-        SUPPORTS_DAC;
-        return m_dwDynamicAssemblyAccess & ASSEMBLY_ACCESS_RUN; 
-    }
-    FORCEINLINE BOOL HasSaveAccess() {LIMITED_METHOD_CONTRACT; return m_dwDynamicAssemblyAccess & ASSEMBLY_ACCESS_SAVE; }
 
     DWORD GetNextModuleIndex() { LIMITED_METHOD_CONTRACT; return m_nextAvailableModuleIndex++; }
 
@@ -497,11 +451,6 @@ public:
 
     BOOL CanBeShared(DomainAssembly *pAsAssembly);
 
-#ifdef FEATURE_LOADER_OPTIMIZATION
-    BOOL MissingDependenciesCheckDone();
-    void SetMissingDependenciesCheckDone();
-#endif // FEATURE_LOADER_OPTIMIZATION
-
     void SetDomainNeutral() { LIMITED_METHOD_CONTRACT; m_fIsDomainNeutral = TRUE; }
     BOOL IsDomainNeutral() { LIMITED_METHOD_DAC_CONTRACT; return m_fIsDomainNeutral; }
 
@@ -512,18 +461,6 @@ public:
     BOOL IsInstrumentedHelper();
 #endif // FEATURE_PREJIT
 
-    HRESULT AllocateStrongNameSignature(ICeeFileGen  *pCeeFileGen,
-                                        HCEEFILE      ceeFile);
-    HRESULT SignWithStrongName(LPCWSTR wszFileName);
-
-
-#ifdef FEATURE_COMINTEROP
-    // Get any cached ITypeLib* for the assembly.
-    ITypeLib *GetTypeLib();
-    // Cache the ITypeLib*, if one is not already cached.
-    void SetTypeLib(ITypeLib *pITLB);
-#endif // FEATURE_COMINTEROP
-
 #ifndef DACCESS_COMPILE
 
     void DECLSPEC_NORETURN ThrowTypeLoadException(LPCUTF8 pszFullName, UINT resIDWhy);
@@ -551,12 +488,6 @@ public:
                                                   LPCUTF8 pszTypeName,
                                                   UINT resIDWhy);
 
-    UINT64 GetHostAssemblyId() const
-    {
-        LIMITED_METHOD_CONTRACT;
-        return m_HostAssemblyId;
-    }
-
 #endif // #ifndef DACCESS_COMPILE
 
     //****************************************************************************************
@@ -602,14 +533,6 @@ public:
 
 
 protected:
-
-    enum {
-        FREE_KEY_PAIR = 4,
-        FREE_KEY_CONTAINER = 8,
-    };
-
-    void ReportAssemblyUse();
-
 #ifdef FEATURE_COMINTEROP
     enum WinMDStatus
     {
@@ -657,9 +580,6 @@ protected:
     }
 #endif // FEATURE_INTEROP
 
-    // Keep track of the vars that need to be freed.
-    short int m_FreeFlag;
-
 private:
 
     //****************************************************************************************
@@ -678,35 +598,18 @@ private:
     PTR_MethodDesc        m_pEntryPoint;    // Method containing the entry point
     PTR_Module            m_pManifest;
     PTR_PEAssembly        m_pManifestFile;
-    ReflectionModule*     m_pOnDiskManifest;  // This is the module containing the on disk manifest.
-    BOOL                  m_fEmbeddedManifest;
 
     FriendAssemblyDescriptor *m_pFriendAssemblyDescriptor;
 
-    // Strong name key info for reflection emit
-    PBYTE                 m_pbStrongNameKeyPair;
-    DWORD                 m_cbStrongNameKeyPair;
-    LPWSTR                m_pwStrongNameKeyContainer;
-    StrongNameLevel       m_eStrongNameLevel;
-
     BOOL                  m_isDynamic;
 #ifdef FEATURE_COLLECTIBLE_TYPES
     BOOL                  m_isCollectible;
 #endif // FEATURE_COLLECTIBLE_TYPES
-    // this boolean is used by Reflection.Emit to determine when to hide m_pOnDiskManifest.
-    // Via reflection emit m_pOnDiskManifest may be explicitly defined by the user and thus available
-    // or created implicitly via Save in which case it needs to be hidden from the user for
-    // backward compatibility reason.
-    // This is a bit of a workaround however and that whole story should be understood a bit better...
-    BOOL                  m_needsToHideManifestForEmit;
-    DWORD                 m_dwDynamicAssemblyAccess;
     DWORD                 m_nextAvailableModuleIndex;
     PTR_LoaderAllocator   m_pLoaderAllocator;
     DWORD                 m_isDisabledPrivateReflection;
 
 #ifdef FEATURE_COMINTEROP
-    // If a TypeLib is ever required for this module, cache the pointer here.
-    ITypeLib              *m_pITypeLib;
     InteropAttributeStatus m_InteropAttributeStatus;
 
     WinMDStatus            m_winMDStatus;
@@ -714,18 +617,12 @@ private:
 #endif // FEATURE_COMINTEROP
 
     BOOL                   m_fIsDomainNeutral;
-#ifdef FEATURE_LOADER_OPTIMIZATION
-    BOOL m_bMissingDependenciesCheckDone;
-#endif // FEATURE_LOADER_OPTIMIZATION
 
     DebuggerAssemblyControlFlags m_debuggerFlags;
 
     BOOL                  m_fTerminated;
 
     BOOL                  m_fIsSIMDVectorAssembly;
-    UINT64                m_HostAssemblyId;
-
-    DWORD                 m_dwReliabilityContract;
 
 #ifdef FEATURE_PREJIT
     enum IsInstrumentedStatus {
index 117507e..f95a181 100644 (file)
@@ -658,16 +658,12 @@ void QCALLTYPE AssemblyNative::GetModules(QCall::AssemblyHandle pAssembly, BOOL
 
     modules.Append(pAssembly);
 
-    ReflectionModule *pOnDiskManifest = NULL;
-    if (pAssembly->GetAssembly()->NeedsToHideManifestForEmit())
-        pOnDiskManifest = pAssembly->GetAssembly()->GetOnDiskManifestModule();
-
     mdFile mdFile;
     while (pAssembly->GetMDImport()->EnumNext(&phEnum, &mdFile))
     {
         DomainFile *pModule = pAssembly->GetModule()->LoadModule(GetAppDomain(), mdFile, fGetResourceModules, !fLoadIfNotFound);
 
-        if (pModule && pModule->GetModule() != pOnDiskManifest) {
+        if (pModule) {
             modules.Append(pModule);
         }
     }
@@ -1295,65 +1291,6 @@ void QCALLTYPE AssemblyNative::PrepareForAssemblyLoadContextRelease(INT_PTR ptrN
 }
 
 /*static*/
-BOOL QCALLTYPE AssemblyNative::OverrideDefaultAssemblyLoadContextForCurrentDomain(INT_PTR ptrNativeAssemblyLoadContext)
-{
-    QCALL_CONTRACT;
-    
-    BOOL fOverrodeDefaultLoadContext = FALSE;
-    
-    BEGIN_QCALL;
-    
-    AppDomain *pCurDomain = AppDomain::GetCurrentDomain();
-    
-    if (pCurDomain->LockBindingModel())
-    {
-        // Only one thread will ever enter here - it will be the ones that actually locked the binding model
-        //
-        // AssemblyLoadContext should have a binder associated with it
-        IUnknown *pOverrideBinder = reinterpret_cast<IUnknown *>(ptrNativeAssemblyLoadContext);
-        _ASSERTE(pOverrideBinder != NULL);
-        
-        // Get reference to the current default context binder
-        
-        IUnknown * pCurrentDefaultContextBinder = pCurDomain->GetFusionContext();
-        
-        // The default context binder can never be null since the runtime always sets one up
-        _ASSERTE(pCurrentDefaultContextBinder != NULL);
-        
-        // The default context should also be the same as TPABinder context
-        _ASSERTE(pCurrentDefaultContextBinder == pCurDomain->GetTPABinderContext());
-        
-        // Override the default context binder in the VM
-        pCurDomain->OverrideDefaultContextBinder(pOverrideBinder);
-        
-        fOverrodeDefaultLoadContext = TRUE;
-    }
-    
-    END_QCALL;
-    
-    return fOverrodeDefaultLoadContext;
-}
-
-BOOL QCALLTYPE AssemblyNative::CanUseAppPathAssemblyLoadContextInCurrentDomain()
-{
-    QCALL_CONTRACT;
-    
-    BOOL fCanUseAppPathAssemblyLoadContext = FALSE;
-    
-    BEGIN_QCALL;
-
-    AppDomain *pCurDomain = AppDomain::GetCurrentDomain();
-
-    pCurDomain->LockBindingModel();
-        
-    fCanUseAppPathAssemblyLoadContext = !pCurDomain->IsHostAssemblyResolverInUse();
-
-    END_QCALL;
-    
-    return fCanUseAppPathAssemblyLoadContext;
-}
-
-/*static*/
 INT_PTR QCALLTYPE AssemblyNative::GetLoadContextForAssembly(QCall::AssemblyHandle pAssembly)
 {
     QCALL_CONTRACT;
index 8ae1fe5..433469f 100644 (file)
@@ -121,8 +121,6 @@ public:
 
     static INT_PTR QCALLTYPE InitializeAssemblyLoadContext(INT_PTR ptrManagedAssemblyLoadContext, BOOL fRepresentsTPALoadContext, BOOL fIsCollectible);
     static void QCALLTYPE PrepareForAssemblyLoadContextRelease(INT_PTR ptrNativeAssemblyLoadContext, INT_PTR ptrManagedStrongAssemblyLoadContext);
-    static BOOL QCALLTYPE OverrideDefaultAssemblyLoadContextForCurrentDomain(INT_PTR ptrNativeAssemblyLoadContext);
-    static BOOL QCALLTYPE CanUseAppPathAssemblyLoadContextInCurrentDomain();
     static void QCALLTYPE LoadFromPath(INT_PTR ptrNativeAssemblyLoadContext, LPCWSTR pwzILPath, LPCWSTR pwzNIPath, QCall::ObjectHandleOnStack retLoadedAssembly);
     static INT_PTR QCALLTYPE InternalLoadUnmanagedDllFromPath(LPCWSTR unmanagedLibraryPath);
     static void QCALLTYPE LoadFromStream(INT_PTR ptrNativeAssemblyLoadContext, INT_PTR ptrAssemblyArray, INT32 cbAssemblyArrayLength, INT_PTR ptrSymbolArray, INT32 cbSymbolArrayLength, QCall::ObjectHandleOnStack retLoadedAssembly);
index 9c272e9..bebd400 100644 (file)
@@ -3947,16 +3947,6 @@ BOOL Module::IsSymbolReadingEnabled()
     }
     CONTRACTL_END;
 
-    // The only time we need symbols available is for debugging and taking stack traces,
-    // neither of which can be done if the assembly can't run. The advantage of being strict
-    // is that there is a perf penalty adding types to a module if you must support reading
-    // symbols at any time. If symbols don't need to be accesible then we can
-    // optimize by only commiting symbols when the assembly is saved to disk. See DDB 671107.
-    if(!GetAssembly()->HasRunAccess())
-    {
-        return FALSE;
-    }
-
     // If the module has symbols in-memory (eg. RefEmit) that are in ILDB
     // format, then there isn't any reason not to supply them.  The reader
     // code is always available, and we trust it's security.
@@ -4247,12 +4237,6 @@ BOOL Module::IsVisibleToDebugger()
         return FALSE;
     }
 
-    // If for whatever other reason, we can't run it, then don't notify the debugger about it.
-    Assembly * pAssembly = GetAssembly();
-    if (!pAssembly->HasRunAccess())
-    {
-        return FALSE;
-    }
     return TRUE;
 }
 
index 4c38303..e96ed2a 100644 (file)
@@ -232,7 +232,6 @@ InteropMethodTableData *MethodTableBuilder::BuildInteropVTable(AllocMemTracker *
     CheckPointHolder cph(pThread->m_MarshalAlloc.GetCheckpoint()); //hold checkpoint for autorelease
 
     HRESULT hr = S_OK;
-    BaseDomain *bmtDomain = pThisMT->GetDomain();
     Module *pModule = pThisMT->GetModule();
     mdToken cl = pThisMT->GetCl();
     MethodTable *pParentMethodTable = pThisMT->GetParentMethodTable();
@@ -273,7 +272,6 @@ InteropMethodTableData *MethodTableBuilder::BuildInteropVTable(AllocMemTracker *
     }
     
     SetBMTData(
-        bmtDomain,
         &bmtError,
         &bmtProp,
         &bmtVT,
@@ -336,7 +334,7 @@ InteropMethodTableData *MethodTableBuilder::BuildInteropVTable(AllocMemTracker *
 
     // resolve unresolved interfaces, determine an upper bound on the size of the interface map,
     // and determine the size of the largest interface (in # slots)
-    BuildInteropVTable_ResolveInterfaces(bmtDomain, pBuildingInterfaceList, &bmtType, &bmtInterface, &bmtVT, &bmtParent, bmtError);
+    BuildInteropVTable_ResolveInterfaces(pBuildingInterfaceList, &bmtType, &bmtInterface, &bmtVT, &bmtParent, bmtError);
 
     // Enumerate this class's members
     EnumerateMethodImpls();
@@ -387,7 +385,7 @@ InteropMethodTableData *MethodTableBuilder::BuildInteropVTable(AllocMemTracker *
     }
 
     // Determine vtable placement for each member in this class
-    BuildInteropVTable_PlaceMembers(bmtDomain,&bmtType, wNumInterfaces, pBuildingInterfaceList, &bmtMethod,
+    BuildInteropVTable_PlaceMembers(&bmtType, wNumInterfaces, pBuildingInterfaceList, &bmtMethod,
                                     &bmtError, &bmtProp, &bmtParent, &bmtInterface, &bmtMethodImpl, &bmtVT);
 
     // First copy what we can leverage from the parent's interface map.
@@ -450,7 +448,6 @@ InteropMethodTableData *MethodTableBuilder::BuildInteropVTable(AllocMemTracker *
             &bmtParent);
 
         BuildInteropVTable_PlaceMethodImpls(
-            bmtDomain,
             &bmtType,
             &bmtMethodImpl,
             &bmtError,
@@ -683,7 +680,6 @@ VOID MethodTableBuilder::BuildInteropVTable_InterfaceList(
 #pragma warning(disable:21000) // Suppress PREFast warning about overly large function
 #endif
 VOID MethodTableBuilder::BuildInteropVTable_PlaceMembers(
-    BaseDomain *bmtDomain,
     bmtTypeInfo* bmtType,
                            DWORD numDeclaredInterfaces,
                            BuildingInterfaceInfo_t *pBuildingInterfaceList, 
@@ -1039,7 +1035,6 @@ VOID MethodTableBuilder::BuildInteropVTable_PlaceMembers(
 // Resolve unresolved interfaces, determine an upper bound on the size of the interface map,
 // and determine the size of the largest interface (in # slots)
 VOID MethodTableBuilder::BuildInteropVTable_ResolveInterfaces(
-                                BaseDomain *bmtDomain, 
                                 BuildingInterfaceInfo_t *pBuildingInterfaceList, 
                                 bmtTypeInfo* bmtType, 
                                 bmtInterfaceInfo* bmtInterface, 
@@ -1052,7 +1047,6 @@ VOID MethodTableBuilder::BuildInteropVTable_ResolveInterfaces(
     {
         STANDARD_VM_CHECK;
         PRECONDITION(CheckPointer(this));
-        PRECONDITION(CheckPointer(bmtDomain));
         PRECONDITION(CheckPointer(bmtInterface));
         PRECONDITION(CheckPointer(bmtVT));
         PRECONDITION(CheckPointer(bmtParent));
@@ -1545,7 +1539,6 @@ VOID MethodTableBuilder::BuildInteropVTable_PlaceVtableMethods(
 // We should have collected all the method impls. Cycle through them creating the method impl
 // structure that holds the information about which slots are overridden.
 VOID MethodTableBuilder::BuildInteropVTable_PlaceMethodImpls(
-        BaseDomain *bmtDomain,
         bmtTypeInfo* bmtType,
         bmtMethodImplInfo* bmtMethodImpl,
         bmtErrorInfo* bmtError, 
@@ -2954,7 +2947,6 @@ VOID    MethodTableBuilder::AllocateMethodWorkingMemory()
     {
         STANDARD_VM_CHECK;
         PRECONDITION(CheckPointer(this));
-        PRECONDITION(CheckPointer(bmtDomain));
         PRECONDITION(CheckPointer(bmtMethod));
         PRECONDITION(CheckPointer(bmtVT));
         PRECONDITION(CheckPointer(bmtInterface));
@@ -3561,7 +3553,6 @@ MethodNameHash *MethodTableBuilder::CreateMethodChainHash(MethodTable *pMT)
 
 //*******************************************************************************
 void MethodTableBuilder::SetBMTData(
-    BaseDomain *bmtDomain,
     bmtErrorInfo *bmtError,
     bmtProperties *bmtProp,
     bmtVtable *bmtVT,
@@ -3572,7 +3563,6 @@ void MethodTableBuilder::SetBMTData(
     bmtMethodImplInfo *bmtMethodImpl)
 {
     LIMITED_METHOD_CONTRACT;
-    this->bmtDomain = bmtDomain;
     this->bmtError = bmtError;
     this->bmtProp = bmtProp;
     this->bmtVT = bmtVT;
@@ -3587,7 +3577,6 @@ void MethodTableBuilder::SetBMTData(
 void MethodTableBuilder::NullBMTData()
 {
     LIMITED_METHOD_CONTRACT;
-    this->bmtDomain = NULL;
     this->bmtError = NULL;
     this->bmtProp = NULL;
     this->bmtVT = NULL;
index 02c86e0..a958a30 100644 (file)
@@ -268,7 +268,6 @@ private:
     BOOL IsDelegate() { LIMITED_METHOD_CONTRACT; return bmtProp->fIsDelegate; } 
     Module *GetModule() { LIMITED_METHOD_CONTRACT; return bmtType->pModule; } 
     Assembly *GetAssembly() { WRAPPER_NO_CONTRACT; return GetModule()->GetAssembly(); } 
-    BaseDomain *GetDomain() { LIMITED_METHOD_CONTRACT; return bmtDomain; } 
     ClassLoader *GetClassLoader() { WRAPPER_NO_CONTRACT; return GetModule()->GetClassLoader(); } 
     IMDInternalImport* GetMDImport()  { WRAPPER_NO_CONTRACT; return GetModule()->GetMDImport(); } 
 #ifdef _DEBUG
@@ -566,7 +565,6 @@ private:
     // Look at the struct definitions for a detailed list of all parameters available
     // to BuildMethodTable.
 
-    BaseDomain *bmtDomain;
     bmtErrorInfo *bmtError;
     bmtProperties *bmtProp;
     bmtVtable *bmtVT;
@@ -577,7 +575,6 @@ private:
     bmtMethodImplInfo *bmtMethodImpl;
 
     void SetBMTData(
-        BaseDomain *bmtDomain,
         bmtErrorInfo *bmtError,
         bmtProperties *bmtProp,
         bmtVtable *bmtVT,
@@ -704,7 +701,6 @@ private:
         WORD *pcBuildingInterfaceList);
 
     VOID BuildInteropVTable_PlaceMembers(
-        BaseDomain *bmtDomain,
         bmtTypeInfo* bmtType,
         DWORD numDeclaredInterfaces,
         BuildingInterfaceInfo_t *pBuildingInterfaceList,
@@ -717,7 +713,6 @@ private:
         bmtVtable* bmtVT);
 
     VOID BuildInteropVTable_ResolveInterfaces(
-        BaseDomain *bmtDomain,
         BuildingInterfaceInfo_t *pBuildingInterfaceList,
         bmtTypeInfo* bmtType,
         bmtInterfaceInfo* bmtInterface,
@@ -751,7 +746,6 @@ private:
         bmtParentInfo* bmtParent);
 
     VOID BuildInteropVTable_PlaceMethodImpls(
-        BaseDomain *bmtDomain,
         bmtTypeInfo* bmtType,
         bmtMethodImplInfo* bmtMethodImpl,
         bmtErrorInfo* bmtError,
diff --git a/src/vm/clrprivbinderloadfile.h b/src/vm/clrprivbinderloadfile.h
deleted file mode 100644 (file)
index 0aa2f33..0000000
+++ /dev/null
@@ -1,160 +0,0 @@
-// 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.
-
-
-
-#pragma once
-
-#include "holder.h"
-#include "internalunknownimpl.h"
-#include "clrprivbinding.h"
-#include "clrprivruntimebinders.h"
-#include "clrprivbinderfusion.h"
-#include "clrprivbinderutil.h"
-
-class PEAssembly;
-
-//=====================================================================================================================
-class CLRPrivBinderLoadFile : 
-    public IUnknownCommon<ICLRPrivBinder>
-{
-
-public:
-    //=============================================================================================
-    // ICLRPrivBinder methods
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(BindAssemblyByName)(
-        IAssemblyName * pAssemblyName,
-        ICLRPrivAssembly ** ppAssembly);
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(VerifyBind)(
-        IAssemblyName *pAssemblyName,
-        ICLRPrivAssembly *pAssembly,
-        ICLRPrivAssemblyInfo *pAssemblyInfo);
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(GetBinderFlags)(
-        DWORD *pBinderFlags)
-    {
-        LIMITED_METHOD_CONTRACT;
-        *pBinderFlags = BINDER_NONE;
-        return S_OK;
-    }
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(GetBinderID)(
-        UINT_PTR *pBinderId);
-
-    //---------------------------------------------------------------------------------------------
-    // FindAssemblyBySpec is not supported by this binder.    
-    STDMETHOD(FindAssemblyBySpec)(
-        LPVOID pvAppDomain,
-        LPVOID pvAssemblySpec,
-        HRESULT * pResult,
-        ICLRPrivAssembly ** ppAssembly)
-    { STATIC_CONTRACT_WRAPPER; return E_FAIL; }
-
-    STDMETHOD(GetLoaderAllocator)(
-        /* [retval][out] */ LoaderAllocator** pLoaderAllocator)
-    { STATIC_CONTRACT_WRAPPER; return E_FAIL; }
-
-    //=============================================================================================
-    // Class methods
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(BindAssemblyExplicit)(
-        PEImage* pImage,
-        IAssemblyName **ppAssemblyName,
-        ICLRPrivAssembly ** ppAssembly);
-
-    //---------------------------------------------------------------------------------------------
-    static
-    CLRPrivBinderLoadFile * GetOrCreateBinder();
-
-    //---------------------------------------------------------------------------------------------
-    ~CLRPrivBinderLoadFile();
-
-private:
-    //---------------------------------------------------------------------------------------------
-    CLRPrivBinderLoadFile();
-
-    //---------------------------------------------------------------------------------------------
-    ReleaseHolder<CLRPrivBinderFusion> m_pFrameworkBinder;
-
-    //---------------------------------------------------------------------------------------------
-    static CLRPrivBinderLoadFile * s_pSingleton;
-};
-
-class CLRPrivAssemblyLoadFile :
-    public IUnknownCommon<ICLRPrivAssembly>
-{
-protected:
-    ReleaseHolder<CLRPrivBinderLoadFile> m_pBinder;
-    ReleaseHolder<CLRPrivBinderFusion> m_pFrameworkBinder;
-    ReleaseHolder<CLRPrivBinderUtil::CLRPrivResourcePathImpl> m_pPathResource;
-
-public:
-    //---------------------------------------------------------------------------------------------
-    CLRPrivAssemblyLoadFile(
-        CLRPrivBinderLoadFile* pBinder,
-        CLRPrivBinderFusion* pFrameworkBinder,
-        CLRPrivBinderUtil::CLRPrivResourcePathImpl* pPathResource);
-
-    //=============================================================================================
-    // ICLRPrivAssembly methods
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(BindAssemblyByName)(
-        IAssemblyName * pAssemblyName,
-        ICLRPrivAssembly ** ppAssembly);
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(VerifyBind)(
-        IAssemblyName *pAssemblyName,
-        ICLRPrivAssembly *pAssembly,
-        ICLRPrivAssemblyInfo *pAssemblyInfo);
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(GetBinderFlags)(
-        DWORD *pBinderFlags)
-    {
-        LIMITED_METHOD_CONTRACT;
-        return m_pBinder->GetBinderFlags(pBinderFlags);
-    }
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(GetBinderID)(
-        UINT_PTR *pBinderId);
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(IsShareable)(
-        BOOL * pbIsShareable);
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(GetAvailableImageTypes)(
-        LPDWORD pdwImageTypes);
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(GetImageResource)(
-        DWORD dwImageType,
-        DWORD *pdwImageType,
-        ICLRPrivResource ** ppIResource);
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(FindAssemblyBySpec)(
-        LPVOID pvAppDomain,
-        LPVOID pvAssemblySpec,
-        HRESULT * pResult,
-        ICLRPrivAssembly ** ppAssembly)
-    { STATIC_CONTRACT_WRAPPER; return m_pBinder->FindAssemblyBySpec(pvAppDomain, pvAssemblySpec, pResult, ppAssembly); }
-
-    //---------------------------------------------------------------------------------------------
-    STDMETHOD(GetLoaderAllocator)(
-        LoaderAllocator** pLoaderAllocator)
-    {
-        WRAPPER_NO_CONTRACT;
-        return m_pBinder->GetLoaderAllocator(pLoaderAllocator);
-    }
-};
index 06a99e1..9b3d997 100644 (file)
@@ -1096,14 +1096,6 @@ VOID SimpleComCallWrapper::Cleanup()
         m_pCPList = NULL;
     }
     
-    // if this object was made agile, then we will have stashed away the original handle
-    // so we must release it if the AD wasn't unloaded
-    if (IsAgile() && m_hOrigDomainHandle)
-    {  
-        DestroyRefcountedHandle(m_hOrigDomainHandle);
-        m_hOrigDomainHandle = NULL;
-    }
-
     if (m_pTemplate)
     {
         m_pTemplate->Release();
@@ -1264,13 +1256,12 @@ void SimpleComCallWrapper::InitNew(OBJECTREF oref, ComCallWrapperCache *pWrapper
     m_pWrapperCache = pWrapperCache;
     m_pTemplate = pTemplate;
     m_pTemplate->AddRef();
-    
+
     m_pOuter = NULL;
 
     m_pSyncBlock = pSyncBlock;
     m_pContext = pContext;
     m_dwDomainId = pContext->GetDomain()->GetId();
-    m_hOrigDomainHandle = NULL;
 
     //@TODO: CTS, when we transition into the correct context before creating a wrapper
     // then uncomment the next line
@@ -2156,19 +2147,6 @@ BOOL ComCallWrapper::IsAggregated()
 
 
 //--------------------------------------------------------------------------
-// BOOL ComCallWrapper::IsObjectTP()
-// check if the wrapper is to a TP object
-//--------------------------------------------------------------------------
-BOOL ComCallWrapper::IsObjectTP()
-{
-    WRAPPER_NO_CONTRACT;
-    
-    return GetSimpleWrapper()->IsObjectTP();
-}
-
-
-
-//--------------------------------------------------------------------------
 // BOOL ComCallWrapper::IsExtendsCOMObject(()
 // check if the wrapper is to a managed object that extends a com object
 //--------------------------------------------------------------------------
@@ -2618,15 +2596,7 @@ ComCallWrapper* ComCallWrapper::CreateWrapper(OBJECTREF* ppObj, ComCallWrapperTe
         COMPlusThrow(kNotSupportedException, W("NotSupported_CollectibleCOM"));
     }
 
-    if (thClass.IsDomainNeutral())
-    {
-        pWrapperCache = SystemDomain::System()->DefaultDomain()->GetComCallWrapperCache();
-    }
-    else
-    {
-        pWrapperCache = pContext->GetDomain()->GetComCallWrapperCache();
-    }
-
+    pWrapperCache = pContext->GetDomain()->GetComCallWrapperCache();
 
     {
         // check if somebody beat us to it    
@@ -3547,12 +3517,10 @@ IUnknown* ComCallWrapper::GetComIPFromCCW(ComCallWrapper *pWrap, REFIID riid, Me
     }
 
     // COM plus objects that extend from COM guys are special
-    // unless the CCW points a TP in which case the COM object
-    // is remote, so let the calls go through the CCW
-    // Also, if we're being asked for just an IInspectable, we don't need to do this (we may be in the process
+    // If we're being asked for just an IInspectable, we don't need to do this (we may be in the process
     // of activating our aggregated object so can't use the RCW yet) - this is analagous to how IUnkown is handled
     // specially with GetBasicIP at the top of this function.
-    if (pWrap->IsExtendsCOMObject() && !pWrap->IsObjectTP() && !IsEqualGUID(riid, IID_IInspectable))
+    if (pWrap->IsExtendsCOMObject() && !IsEqualGUID(riid, IID_IInspectable))
     {
         IUnknown * pIntf = GetComIPFromCCW_HandleExtendsCOMObject(pWrap, riid, pIntfMT,
                                 pTemplate, imapIndex, intfIndex);
@@ -3833,57 +3801,6 @@ IDispatch* ComCallWrapper::GetIDispatchIP()
     }
 }
 
-// MakeAgile needs the object passed in because it has to set it in the new handle
-// If the original handle is from an unloaded appdomain, it will no longer be valid
-// so we won't be able to get the object.
-void ComCallWrapper::MakeAgile(OBJECTREF pObj)
-{
-    CONTRACTL
-    {
-        WRAPPER(THROWS);
-        GC_TRIGGERS;
-        MODE_COOPERATIVE;
-
-        // if this assert fires, then we've called addref from a place where we need to
-        // make the object agile but we haven't supplied the object. Need to change the caller.
-        PRECONDITION(pObj != NULL);
-    }
-    CONTRACTL_END;
-
-    OBJECTHANDLE origHandle = m_ppThis;
-    RCOBJECTHANDLEHolder agileHandle = SharedDomain::GetDomain()->CreateRefcountedHandle(pObj);
-    _ASSERTE(agileHandle);
-
-    SimpleComCallWrapper *pSimpleWrap = GetSimpleWrapper();
-    ComCallWrapperCache *pWrapperCache = pSimpleWrap->GetWrapperCache();
-
-    
-    // lock the wrapper cache so nobody else can update to agile while we are
-    {
-        ComCallWrapperCache::LockHolder lh(pWrapperCache);
-
-        if (pSimpleWrap->IsAgile()) 
-        {
-            // someone beat us to it - let the holder destroy it and return
-            return;
-        }
-
-        // Update all the wrappers to use the agile handle.
-        ComCallWrapper *pWrap = this;
-        while (pWrap)
-        {
-            pWrap->m_ppThis = agileHandle;
-            pWrap = GetNext(pWrap);
-        }
-            
-        // so all the handles are updated - now update the simple wrapper
-        // keep the lock so someone else doesn't try to
-        pSimpleWrap->MakeAgile(origHandle);
-    }
-
-    agileHandle.SuppressRelease();
-}
-
 //--------------------------------------------------------------------------
 // ComCallable wrapper manager
 // constructor
@@ -3898,7 +3815,6 @@ ComCallWrapperCache::ComCallWrapperCache() :
     
 }
 
-
 //-------------------------------------------------------------------
 // ComCallable wrapper manager
 // destructor
index 17ef014..56ebc94 100644 (file)
@@ -1041,9 +1041,6 @@ public:
     BOOL NeedToSwitchDomains(Thread *pThread);
     BOOL NeedToSwitchDomains(ADID appdomainID);
 
-    void MakeAgile(OBJECTREF pObj);
-    void CheckMakeAgile(OBJECTREF pObj);
-
     VOID ResetHandleStrength();
     VOID MarkHandleWeak();
 
@@ -1214,9 +1211,6 @@ public:
     // is the object aggregated by a COM component
     BOOL IsAggregated();
 
-    // is the object a transparent proxy
-    BOOL IsObjectTP();
-
     // is the object extends from (aggregates) a COM component
     BOOL IsExtendsCOMObject();
 
@@ -1495,8 +1489,8 @@ private:
         enum_IsAggregated                      = 0x1,
         enum_IsExtendsCom                      = 0x2,
         enum_IsHandleWeak                      = 0x4,
-        enum_IsObjectTP                        = 0x8,
-        enum_IsAgile                           = 0x10,
+        // unused                              = 0x8,
+        // unused                              = 0x10,
         enum_IsPegged                          = 0x80,
         // unused                              = 0x100,
         enum_CustomQIRespondsToIMarshal        = 0x200,
@@ -1638,9 +1632,6 @@ public:
             MODE_ANY;
         }
         CONTRACTL_END;
-        
-        if (IsAgile())
-            return GetThread()->GetDomain()->GetId();
 
         return m_dwDomainId;
     }
@@ -1651,82 +1642,15 @@ public:
         return m_dwDomainId;
     }
 
-#ifndef CROSSGEN_COMPILE
     inline BOOL NeedToSwitchDomains(Thread *pThread, ADID *pTargetADID, Context **ppTargetContext)
     {
-        CONTRACTL
-        {
-            NOTHROW;
-            WRAPPER(GC_TRIGGERS);
-            MODE_ANY;
-            SUPPORTS_DAC;
-        }
-        CONTRACTL_END;
-        
-        if (IsAgile())
-            return FALSE;
-
-        if (m_dwDomainId == pThread->GetDomain()->GetId() && m_pContext == pThread->GetContext())
-            return FALSE;
-
-        // we intentionally don't provide any other way to read m_pContext so the caller always
-        // gets ADID & Context that are guaranteed to be in sync (note that GetDomainID() lies
-        // if the CCW is agile and using it together with m_pContext leads to issues)
-        *pTargetADID = m_dwDomainId;
-        *ppTargetContext = m_pContext;
-
-        return TRUE;
+        LIMITED_METHOD_DAC_CONTRACT;
+        return FALSE;
     }
-
-    // if you call this you must either pass TRUE for throwIfUnloaded or check
-    // after the result before accessing any pointers that may be invalid.
     inline BOOL NeedToSwitchDomains(ADID appdomainID)
     {
         LIMITED_METHOD_DAC_CONTRACT;
-        // Check for a direct domain ID match first -- this is more common than agile wrappers.
-        return (m_dwDomainId != appdomainID) && !IsAgile();
-    }
-#endif //CROSSGEN_COMPILE
-
-    BOOL ShouldBeAgile()
-    {
-        CONTRACTL
-        {
-            WRAPPER(THROWS);
-            WRAPPER(GC_TRIGGERS);
-            MODE_ANY;
-        }
-        CONTRACTL_END;
-        
-        return (!IsAgile() && GetThread()->GetDomain()->GetId()!= m_dwDomainId);
-    }
-
-    void MakeAgile(OBJECTHANDLE origHandle)
-    {
-        CONTRACTL
-        {
-            WRAPPER(THROWS);
-            WRAPPER(GC_TRIGGERS);
-            MODE_COOPERATIVE;
-        }
-        CONTRACTL_END;
-        
-        m_hOrigDomainHandle = origHandle;
-        FastInterlockOr((ULONG*)&m_flags, enum_IsAgile);
-    }
-
-    BOOL IsAgile()
-    {
-        LIMITED_METHOD_CONTRACT;
-        
-        return m_flags & enum_IsAgile;
-    }
-
-    BOOL IsObjectTP()
-    {
-        LIMITED_METHOD_CONTRACT;
-        
-        return m_flags & enum_IsObjectTP;
+        return FALSE;
     }
 
     // is the object aggregated by a COM component
@@ -2218,12 +2142,6 @@ private:
     ComCallWrapperCache*            m_pWrapperCache;    
     PTR_ComCallWrapperTemplate      m_pTemplate;
     
-    // when we make the object agile, need to save off the original handle so we can clean
-    // it up when the object goes away.
-    // <TODO>Would be nice to overload one of the other values with this, but then
-    // would have to synchronize on it too</TODO>
-    OBJECTHANDLE                    m_hOrigDomainHandle;
-
     // Points to uncommonly used data that are dynamically allocated
     VolatilePtr<SimpleCCWAuxData>   m_pAuxData;         
 
@@ -2289,8 +2207,6 @@ inline ComCallWrapper* __stdcall ComCallWrapper::InlineGetWrapper(OBJECTREF* ppO
     else
         pMainWrap = pWrap;
 
-    pMainWrap->CheckMakeAgile(*ppObj);
-
     pWrap->AddRef();
     
     RETURN pWrap;
@@ -2336,21 +2252,6 @@ inline ADID ComCallWrapper::GetDomainID()
     return GetSimpleWrapper()->GetDomainID();
 }
 
-
-inline void ComCallWrapper::CheckMakeAgile(OBJECTREF pObj)
-{
-    CONTRACTL
-    {
-        WRAPPER(THROWS);
-        WRAPPER(GC_TRIGGERS);
-        MODE_COOPERATIVE;
-    }
-    CONTRACTL_END;
-    
-    if (GetSimpleWrapper()->ShouldBeAgile())
-        MakeAgile(pObj);
-}
-
 inline ULONG ComCallWrapper::GetRefCount()
 {
     CONTRACTL
index 6ffa267..24c1213 100644 (file)
@@ -687,13 +687,6 @@ FCIMPL5(FC_BOOL_RET, COMDelegate::BindToMethodName,
 
     TypeHandle methodType = gc.refMethodType->GetType();
 
-    //We should thrown an exception if the assembly doesn't have run access.
-    //That would be a breaking change from V2.
-    //
-    //Assembly *pAssem = methodType.GetAssembly();
-    //if (pAssem->IsDynamic() && !pAssem->HasRunAccess())
-    //    FCThrowRes(kNotSupportedException, W("NotSupported_DynamicAssemblyNoRunAccess"));
-
     MethodDesc *pMatchingMethod = NULL;
 
     HELPER_METHOD_FRAME_BEGIN_RET_PROTECT(gc);
@@ -819,13 +812,6 @@ FCIMPL5(FC_BOOL_RET, COMDelegate::BindToMethodInfo, Object* refThisUNSAFE, Objec
     MethodTable *pMethMT = gc.refMethodType->GetType().GetMethodTable();
     MethodDesc *method = gc.refMethod->GetMethod();
 
-    //We should thrown an exception if the assembly doesn't have run access.
-    //That would be a breaking change from V2.
-    //
-    //Assembly *pAssem = pMethMT->GetAssembly();
-    //if (pAssem->IsDynamic() && !pAssem->HasRunAccess())
-    //    FCThrowRes(kNotSupportedException, W("NotSupported_DynamicAssemblyNoRunAccess"));
-
     HELPER_METHOD_FRAME_BEGIN_RET_PROTECT(gc);
 
     // Assert to track down VS#458689.
index 491aecc..6cdcf67 100644 (file)
@@ -135,15 +135,7 @@ HRESULT CEECompileInfo::CreateDomain(ICorCompilationDomain **ppDomain,
 
     COOPERATIVE_TRANSITION_BEGIN();
 
-#ifndef CROSSGEN_COMPILE
-    AppDomainCreationHolder<CompilationDomain> pCompilationDomain;
-
-    pCompilationDomain.Assign(new CompilationDomain(fForceDebug,
-                                                    fForceProfiling,
-                                                    fForceInstrument));
-#else
     CompilationDomain * pCompilationDomain = theDomain;
-#endif
 
     {
         SystemDomain::LockHolder lh;
@@ -175,10 +167,6 @@ HRESULT CEECompileInfo::CreateDomain(ICorCompilationDomain **ppDomain,
 
             pCompilationDomain->SetFriendlyName(W("Compilation Domain"));
             SystemDomain::System()->LoadDomain(pCompilationDomain);
-
-#ifndef CROSSGEN_COMPILE
-            pCompilationDomain.DoneCreating();
-#endif
         }
         END_DOMAIN_TRANSITION;
     }
@@ -412,13 +400,6 @@ HRESULT CEECompileInfo::LoadAssemblyByPath(
             if (spec.CanUseWithBindingCache() && pDomainAssembly->CanUseWithBindingCache())
                 pDomain->AddAssemblyToCache(&spec, pDomainAssembly);
 
-
-            {
-                // Mark the assembly before it gets fully loaded and NGen image dependencies are verified. This is necessary
-                // to allow skipping compilation if there is NGen image already.
-                pDomainAssembly->GetFile()->SetSafeToHardBindTo();
-            }
-
             pAssembly = pDomain->LoadAssembly(&spec, pAssemblyHolder, FILE_LOADED);
 
             // Add a dependency to the current assembly.  This is done to match the behavior
@@ -602,10 +583,7 @@ HRESULT CEECompileInfo::SetCompilationTarget(CORINFO_ASSEMBLY_HANDLE     assembl
 
         if (!IsReadyToRunCompilation() && !SystemDomain::SystemFile()->HasNativeImage())
         {
-            if (!CLRConfig::GetConfigValue(CLRConfig::INTERNAL_NgenAllowMscorlibSoftbind))
-            {
-                return NGEN_E_SYS_ASM_NI_MISSING;
-            }
+            return NGEN_E_SYS_ASM_NI_MISSING;
         }
     }
 
@@ -788,9 +766,6 @@ void GetLoadHint(ASSEMBLY * pAssembly, ASSEMBLY *pAssemblyDependency,
 
     *loadHint = LoadDefault;
 
-    if (g_pConfig->NgenHardBind() == EEConfig::NGEN_HARD_BIND_ALL)
-        *loadHint = LoadAlways;
-
     const BYTE  *pbAttr;                // Custom attribute data as a BYTE*.
     ULONG       cbAttr;                 // Size of custom attribute data.
     mdToken     mdAssembly;
@@ -855,11 +830,6 @@ void GetLoadHint(ASSEMBLY * pAssembly, ASSEMBLY *pAssemblyDependency,
             UINT32 u4 = 0;
             IfFailThrow(cap.GetU4(&u4));
 
-            if (pAssemblyDependency->IsSystem() && CLRConfig::GetConfigValue(CLRConfig::INTERNAL_NgenAllowMscorlibSoftbind))
-            {
-                u4 = LoadDefault;
-            }
-
             if (defaultLoadHint)
                 *defaultLoadHint = (LoadHintEnum) u4;
             else
@@ -4586,11 +4556,6 @@ CEEPreloader::CEEPreloader(Module *pModule,
     GetAppDomain()->ToCompilationDomain()->SetTargetImage(m_image, this);
 
     m_methodCompileLimit = pModule->GetMDImport()->GetCountWithTokenKind(mdtMethodDef) * 10;
-
-#ifdef FEATURE_FULL_NGEN
-    m_fSpeculativeTriage = FALSE;
-    m_fDictionariesPopulated = FALSE;
-#endif
 }
 
 CEEPreloader::~CEEPreloader()
@@ -4693,38 +4658,14 @@ CORINFO_METHOD_HANDLE CEEPreloader::NextUncompiledMethod()
     // that we are about to save.
     if (m_uncompiledMethods.GetCount() == 0)
     {
-#ifdef FEATURE_FULL_NGEN
-        if (!m_fSpeculativeTriage)
-        {
-            // We take one shot at smarter elimination of speculative instantiations
-            // that are guaranteed to be found in other modules
-            TriageSpeculativeInstantiations();
-            m_fSpeculativeTriage = TRUE;
-        }
-#endif
+        // The subsequent populations are done in non-expansive way (won't load new types)
+        m_image->GetModule()->PrepopulateDictionaries(m_image, TRUE);
 
-        if (m_uncompiledMethods.GetCount() == 0)
-        {
-#ifdef FEATURE_FULL_NGEN
-            if (!m_fDictionariesPopulated)
-            {
-                // Prepopulate dictionaries. Only the first population is done in expansive way.
-                m_image->GetModule()->PrepopulateDictionaries(m_image, FALSE);
-                m_fDictionariesPopulated = TRUE;
-            }
-            else
-#endif
-            {
-                // The subsequent populations are done in non-expansive way (won't load new types)
-                m_image->GetModule()->PrepopulateDictionaries(m_image, TRUE);
-            }
-            
-            // Make sure that we have generated code for all instantiations that we are going to save
-            // The new items that we encounter here were most likely side effects of verification or failed inlining,
-            // so do not try to save them eagerly.
-            while (TriageForZap(FALSE)) {
-                // Loop as long as new types are added
-            }
+        // Make sure that we have generated code for all instantiations that we are going to save
+        // The new items that we encounter here were most likely side effects of verification or failed inlining,
+        // so do not try to save them eagerly.
+        while (TriageForZap(FALSE)) {
+            // Loop as long as new types are added
         }
     }
 
index 9c76175..1d1eb23 100644 (file)
@@ -103,7 +103,6 @@ set(VM_CROSSGEN_HEADERS
   ../class.inl
   ../classhash.h
   ../clrex.h
-  ../clrprivbinderloadfile.h
   ../clsload.hpp
   ../clsload.inl
   ../codeman.h
index 12fdf90..c67c567 100644 (file)
@@ -4,7 +4,6 @@ include(${CLR_DIR}/crossgen.cmake)
 add_definitions(
     -DEnC_SUPPORTED
     -DFEATURE_EVENT_TRACE=1
-    -DFEATURE_LOADER_OPTIMIZATION
     -DFEATURE_MULTICOREJIT
     -DFEATURE_VERSIONING_LOG
 )
index 2a1b5e5..a5b7a77 100644 (file)
@@ -406,8 +406,7 @@ BOOL DomainAssembly::IsVisibleToDebugger()
     WRAPPER_NO_CONTRACT;
     SUPPORTS_DAC;
 
-    // If you can't run an assembly, then don't send notifications to the debugger.
-    return ((GetAssembly() != NULL) ? GetAssembly()->HasRunAccess() : FALSE);
+    return (GetAssembly() != NULL);
 }
 
 #ifndef DACCESS_COMPILE
@@ -1739,7 +1738,7 @@ void DomainAssembly::FindNativeImage()
 
         ReleaseHolder<PEImage> pNativeImage = GetFile()->GetNativeImageWithRef();
 
-        if(!IsSystem() && !SystemDomain::System()->SystemFile()->HasNativeImage() && !CLRConfig::GetConfigValue(CLRConfig::INTERNAL_NgenAllowMscorlibSoftbind))
+        if(!IsSystem() && !SystemDomain::System()->SystemFile()->HasNativeImage())
         {
             m_dwReasonForRejectingNativeImage = ReasonForRejectingNativeImage_MscorlibNotNative;
             STRESS_LOG2(LF_ZAP,LL_INFO100,"Rejecting native file %p, because mscolib has not NI - reason 0x%x\n",pNativeImage.GetValue(),m_dwReasonForRejectingNativeImage);
@@ -1983,9 +1982,6 @@ void DomainAssembly::Allocate()
                 // <TODO> We will need to pass a valid OBJECREF* here in the future when we implement SCU </TODO>
                 assemblyHolder = pAssembly = Assembly::Create(pSharedDomain, GetFile(), GetDebuggerInfoBits(), this->IsCollectible(), pamTracker, this->IsCollectible() ? this->GetLoaderAllocator() : NULL);
 
-                if (MissingDependenciesCheckDone())
-                    pAssembly->SetMissingDependenciesCheckDone();
-
                 // Compute the closure assembly dependencies
                 // of the code & layout of given assembly.
                 //
index 6f812b3..9c8ef0b 100644 (file)
@@ -550,7 +550,6 @@ FCFuncStart(gAssemblyLoadContextFuncs)
     QCFuncElement("PrepareForAssemblyLoadContextRelease", AssemblyNative::PrepareForAssemblyLoadContextRelease)
     QCFuncElement("LoadFromPath", AssemblyNative::LoadFromPath)
     QCFuncElement("InternalLoadUnmanagedDllFromPath", AssemblyNative::InternalLoadUnmanagedDllFromPath)
-    QCFuncElement("CanUseAppPathAssemblyLoadContextInCurrentDomain", AssemblyNative::CanUseAppPathAssemblyLoadContextInCurrentDomain)
     QCFuncElement("LoadFromStream", AssemblyNative::LoadFromStream)
     QCFuncElement("GetLoadContextForAssembly", AssemblyNative::GetLoadContextForAssembly)
 #if defined(FEATURE_MULTICOREJIT)
index f48ba43..db8d1a8 100644 (file)
@@ -230,8 +230,6 @@ HRESULT EEConfig::Init()
 
     fNgenBindOptimizeNonGac = false;
     fStressLog = false;
-    fCacheBindingFailures = true;
-    fDisableCommitThreadStack = false;
     fProbeForStackOverflow = true;
     
     INDEBUG(fStressLog = true;)
@@ -253,7 +251,6 @@ HRESULT EEConfig::Init()
     fJitVerificationDisable= false;
     fVerifierOff           = false;
 
-    fDoAllowUntrustedCallerChecks = true;
 #ifdef ENABLE_STARTUP_DELAY
     iStartupDelayMS = 0;
 #endif
@@ -300,24 +297,14 @@ HRESULT EEConfig::Init()
 
     iRequireZaps = REQUIRE_ZAPS_NONE;
 
-    // new loader behavior switches
-
-    m_fDeveloperInstallation = false;
-
     pZapSet = DEFAULT_ZAP_SET;
 
-#ifdef FEATURE_LOADER_OPTIMIZATION
-    dwSharePolicy = AppDomain::SHARE_POLICY_UNSPECIFIED;
-#endif
-
 #if defined(_TARGET_X86_) || defined(_TARGET_AMD64_)
     dwDisableStackwalkCache = 0;
 #else // _TARGET_X86_
     dwDisableStackwalkCache = 1;
 #endif // _TARGET_X86_
 
-    fUseNewCrossDomainRemoting = 1;
-    
     szZapBBInstr     = NULL;
     szZapBBInstrDir  = NULL;
 
@@ -330,7 +317,6 @@ HRESULT EEConfig::Init()
     m_TraceWrapper = 0;
 #endif
 
-    iNgenHardBind = NGEN_HARD_BIND_DEFAULT;
 #ifdef _DEBUG
     dwNgenForceFailureMask  = 0;
     dwNgenForceFailureCount = 0;
@@ -955,10 +941,6 @@ HRESULT EEConfig::sync()
     }
 #endif
 
-#ifdef FEATURE_LOADER_OPTIMIZATION
-    dwSharePolicy           = GetConfigDWORD_DontUse_(CLRConfig::EXTERNAL_LoaderOptimization, dwSharePolicy);
-#endif
-
 #ifdef FEATURE_DOUBLE_ALIGNMENT_HINT
     DoubleArrayToLargeObjectHeapThreshold = GetConfigDWORD_DontUse_(CLRConfig::UNSUPPORTED_DoubleArrayToLargeObjectHeap, DoubleArrayToLargeObjectHeapThreshold);
 #endif
@@ -1131,10 +1113,6 @@ HRESULT EEConfig::sync()
     fTestDataConsistency = (CLRConfig::GetConfigValue(CLRConfig::UNSUPPORTED_TestDataConsistency) !=0);
 #endif
 
-    fDoAllowUntrustedCallerChecks =  
-        (CLRConfig::GetConfigValue(CLRConfig::INTERNAL_SupressAllowUntrustedCallerChecks) != 1);
-
-
     m_SuspendThreadDeadlockTimeoutMs = CLRConfig::GetConfigValue(CLRConfig::INTERNAL_SuspendThreadDeadlockTimeoutMs);
     m_SuspendDeadlockTimeout = CLRConfig::GetConfigValue(CLRConfig::INTERNAL_SuspendDeadlockTimeout);
 #endif // _DEBUG
index 2c6622f..fea1211 100644 (file)
@@ -497,38 +497,6 @@ public:
     unsigned int  GetDoubleArrayToLargeObjectHeapThreshold() const { LIMITED_METHOD_CONTRACT; return DoubleArrayToLargeObjectHeapThreshold; }
 #endif
 
-#ifdef FEATURE_LOADER_OPTIMIZATION
-    inline DWORD DefaultSharePolicy() const
-    {
-        LIMITED_METHOD_CONTRACT;
-        return dwSharePolicy;
-    }
-#endif
-
-    inline bool CacheBindingFailures() const
-    {
-        LIMITED_METHOD_CONTRACT;
-        return fCacheBindingFailures;
-    }
-
-    inline bool UseLegacyIdentityFormat() const
-    {
-        LIMITED_METHOD_CONTRACT;
-        return fUseLegacyIdentityFormat;
-    }
-
-    inline void SetDisableCommitThreadStack(bool val)
-    {
-        LIMITED_METHOD_CONTRACT; 
-        fDisableCommitThreadStack = val;
-    }
-
-    inline bool GetDisableCommitThreadStack() const
-    {
-        LIMITED_METHOD_CONTRACT; 
-        return fDisableCommitThreadStack;
-    }
-
     inline bool ProbeForStackOverflow() const
     {
         LIMITED_METHOD_CONTRACT;
@@ -552,9 +520,6 @@ public:
     }
 #endif
 
-    inline bool DeveloperInstallation() const
-    {LIMITED_METHOD_CONTRACT;  return m_fDeveloperInstallation; }
-
 #ifdef TEST_DATA_CONSISTENCY
     // get the value of fTestDataConsistency, which controls whether we test that we can correctly detect
     // held locks in DAC builds. This is determined by an environment variable. 
@@ -581,9 +546,6 @@ public:
     inline bool SuppressChecks() const
     {LIMITED_METHOD_CONTRACT;  return fSuppressChecks; }
 
-    inline bool Do_AllowUntrustedCaller_Checks()
-    {LIMITED_METHOD_CONTRACT;  return fDoAllowUntrustedCallerChecks; }
-
     inline bool EnableFullDebug() const
     {LIMITED_METHOD_CONTRACT;  return fEnableFullDebug; }
 
@@ -725,7 +687,6 @@ public:
     LPUTF8  GetZapBBInstr()                 const { LIMITED_METHOD_CONTRACT; return szZapBBInstr; }
     LPWSTR  GetZapBBInstrDir()              const { LIMITED_METHOD_CONTRACT; return szZapBBInstrDir; }
     DWORD   DisableStackwalkCache()         const {LIMITED_METHOD_CONTRACT;  return dwDisableStackwalkCache; }
-    DWORD   UseNewCrossDomainRemoting()     const { LIMITED_METHOD_CONTRACT; return fUseNewCrossDomainRemoting; }
 
     bool    StressLog()                     const { LIMITED_METHOD_CONTRACT; return fStressLog; }
     bool    ForceEnc()                      const { LIMITED_METHOD_CONTRACT; return fForceEnc; }
@@ -787,18 +748,6 @@ public:
 
 #endif // _DEBUG
 
-    enum NgenHardBindType
-    {
-        NGEN_HARD_BIND_NONE,    // Do not hardbind at all
-        NGEN_HARD_BIND_LIST,    // Only hardbind to what is specified by CustomAttributes (and any default assemblies specified by the CLR)
-        NGEN_HARD_BIND_ALL,     // Hardbind to any existing ngen images if possible
-        NGEN_HARD_BIND_COUNT,
-        
-        NGEN_HARD_BIND_DEFAULT = NGEN_HARD_BIND_LIST,
-    };
-    
-    NgenHardBindType NgenHardBind()   { LIMITED_METHOD_CONTRACT; return iNgenHardBind;    }
-
 #ifdef _DEBUG
     DWORD  NgenForceFailureMask()     { LIMITED_METHOD_CONTRACT; return dwNgenForceFailureMask; }
     DWORD  NgenForceFailureCount()    { LIMITED_METHOD_CONTRACT; return dwNgenForceFailureCount; }
@@ -832,12 +781,6 @@ public:
 
 private: //----------------------------------------------------------------
 
-    // @TODO - Fusion needs to be able to read this value, but they are unable to
-    // pull in all of the appropriate headers for all of the #defines found below.
-    // As long as this is defined at the top of the object, the "incorrect offsets" that
-    // will come as a result won't matter.
-    bool fCacheBindingFailures;
-    bool fUseLegacyIdentityFormat;
     bool fInited;                   // have we synced to the registry at least once?
 
     // Jit-config
@@ -919,13 +862,6 @@ private: //----------------------------------------------------------------
     unsigned int DoubleArrayToLargeObjectHeapThreshold;  // double arrays of more than this number of elems go in large object heap
 #endif
 
-#ifdef FEATURE_LOADER_OPTIMIZATION
-    DWORD  dwSharePolicy;               // Default policy for loading assemblies into the domain neutral area
-#endif
-
-    // Only developer machines are allowed to use DEVPATH. This value is set when there is an appropriate entry
-    // in the machine configuration file. This should not be sent out in the redist.
-    bool   m_fDeveloperInstallation;      // We are on a developers machine
     bool   fAppDomainUnload;            // Enable appdomain unloading
     
     DWORD  dwADURetryCount;
@@ -939,8 +875,6 @@ private: //----------------------------------------------------------------
     // Verifier
     bool fVerifierOff;
 
-    bool fDoAllowUntrustedCallerChecks; // do AllowUntrustedCallerChecks
-
 #ifdef WIN64EXCEPTIONS
     bool fSuppressLockViolationsOnReentryFromOS;
 #endif
@@ -1041,14 +975,10 @@ private: //----------------------------------------------------------------
 
     bool fStressLog;
     bool fForceEnc;
-    bool fDisableCommitThreadStack;
     bool fProbeForStackOverflow;
     
     // Stackwalk optimization flag
     DWORD dwDisableStackwalkCache;
-
-    // New cross domain remoting
-    DWORD fUseNewCrossDomainRemoting;
     
     LPUTF8 szZapBBInstr;
     LPWSTR szZapBBInstrDir;
@@ -1073,8 +1003,6 @@ private: //----------------------------------------------------------------
     // New configuration
     ConfigList  m_Configuration;
 
-    BOOL fEnableHardbinding;
-    NgenHardBindType iNgenHardBind;
 #ifdef _DEBUG
     DWORD dwNgenForceFailureMask;
     DWORD dwNgenForceFailureCount;
index 165073b..e60ffae 100644 (file)
@@ -6253,17 +6253,6 @@ void InitJitHelperLogging()
 #endif
 #endif // _TARGET_X86_
 
-        if (g_pConfig->NgenHardBind() == EEConfig::NGEN_HARD_BIND_NONE)
-        {
-            _ASSERTE(g_pConfig->NgenHardBind() != EEConfig::NGEN_HARD_BIND_NONE && "You are "
-                        "trying to log JIT helper method calls while you have NGEN HARD BINDING "
-                        "set to 0. This probably means you're really trying to NGEN something for "
-                        "logging purposes, NGEN breaks with JitHelperLogging turned on!!!! Please "
-                        "set JitHelperLogging=0 while you NGEN, or unset HardPrejitEnabled while "
-                        "running managed code.");
-            return;
-        }
-
         // Make the static hlpFuncTable read/write for purposes of writing the logging thunks
         DWORD dwOldProtect;
         if (!ClrVirtualProtect((LPVOID)hlpFuncTable, (sizeof(VMHELPDEF) * CORINFO_HELP_COUNT), PAGE_EXECUTE_READWRITE, &dwOldProtect))
index b80f1e8..7491bfd 100644 (file)
@@ -553,7 +553,7 @@ BOOL  MethodTable::IsInitError()
 void MethodTable::SetClassInited()
 {
     WRAPPER_NO_CONTRACT;
-    _ASSERTE(!IsClassPreInited() || MscorlibBinder::IsClass(this, CLASS__SHARED_STATICS));
+    _ASSERTE(!IsClassPreInited());
     GetDomainLocalModule()->SetClassInitialized(this);
 }
 
index b452f3b..105ffb2 100644 (file)
@@ -10153,7 +10153,7 @@ MethodTableBuilder::SetupMethodTable2(
         {
             Module * pModule = GetModule();
             Module * pParentModule = GetParentMethodTable()->GetModule();
-            if (pModule != pParentModule && !pModule->HasUnconditionalActiveDependency(pParentModule))
+            if (pModule != pParentModule)
             {
                 pMT->SetHasModuleDependencies();
             }
index 43b39d1..608d2b7 100644 (file)
@@ -1356,16 +1356,6 @@ UriMarshalingInfo *EEMarshalingData::GetUriMarshalingInfo()
         }
     }
 
-#ifdef _DEBUG
-    BaseDomain *pUriDomain = m_pUriInfo->GetSystemUriType().GetDomain();
-    if (pUriDomain != m_pDomain)
-    {
-        // Make sure that Uri marshaling data is initialized in its own (shared) domain as well.
-        // This allows us to perform quick checks in code:EEMarshalingData.IsUriHelperMethod.
-        (void) pUriDomain->GetMarshalingData()->GetUriMarshalingInfo();
-    }
-#endif // _DEBUG
-
     RETURN m_pUriInfo;
 }
 
@@ -1394,16 +1384,6 @@ EventArgsMarshalingInfo *EEMarshalingData::GetEventArgsMarshalingInfo()
         }
     }
 
-#ifdef _DEBUG
-    BaseDomain *pEventArgsDomain = m_pEventArgsInfo->GetSystemNCCEventArgsType().GetDomain();
-    if (pEventArgsDomain != m_pDomain)
-    {
-        // Make sure that EventArgs marshaling data is initialized in its own (shared) domain as well.
-        // This allows us to perform quick checks in code:EEMarshalingData.IsEventArgsHelperMethod.
-        (void) pEventArgsDomain->GetMarshalingData()->GetEventArgsMarshalingInfo();
-    }
-#endif // _DEBUG
-
     RETURN m_pEventArgsInfo;
 }
 
@@ -1432,16 +1412,6 @@ OleColorMarshalingInfo *EEMarshalingData::GetOleColorMarshalingInfo()
         }
     }
 
-#ifdef _DEBUG
-    BaseDomain *pColorDomain = m_pOleColorInfo->GetColorType().GetDomain();
-    if (pColorDomain != m_pDomain)
-    {
-        // Make sure that Color marshaling data is initialized in its own (shared) domain as well.
-        // This allows us to perform quick checks in code:EEMarshalingData.IsOleColorHelperMethod.
-        (void) pColorDomain->GetMarshalingData()->GetOleColorMarshalingInfo();
-    }
-#endif // _DEBUG
-
     RETURN m_pOleColorInfo;
 }
 #endif // FEATURE_COMINTEROP
index 36394e5..b8262f8 100644 (file)
@@ -109,10 +109,6 @@ DEFINE_FIELD_U(typeKind,        TypeNameNative,             typeKind)
 #endif
 
 DEFINE_CLASS(APPDOMAIN_SETUP,       System,                 AppDomainSetup)
-DEFINE_CLASS_U(System,       AppDomainSetup,                 AppDomainSetupObject)
-DEFINE_FIELD_U(_Entries,                           AppDomainSetupObject,   m_Entries)
-DEFINE_FIELD_U(_AppBase,                           AppDomainSetupObject,   m_AppBase)
-DEFINE_FIELD_U(_CompatFlags,                       AppDomainSetupObject,   m_CompatFlags)
 
 DEFINE_CLASS(ARG_ITERATOR,          System,                 ArgIterator)
 DEFINE_CLASS_U(System,              ArgIterator,            VARARGS)  // Includes a SigPointer.
@@ -647,8 +643,6 @@ DEFINE_METHOD(OBJECT,               TO_STRING,              ToString,
 DEFINE_METHOD(OBJECT,               GET_TYPE,               GetType,                    IM_RetType)
 DEFINE_METHOD(OBJECT,               GET_HASH_CODE,          GetHashCode,                IM_RetInt)
 DEFINE_METHOD(OBJECT,               EQUALS,                 Equals,                     IM_Obj_RetBool)
-DEFINE_METHOD(OBJECT,               FIELD_SETTER,           FieldSetter,                IM_Str_Str_Obj_RetVoid)
-DEFINE_METHOD(OBJECT,               FIELD_GETTER,           FieldGetter,                IM_Str_Str_RefObj_RetVoid)
 
 // DEFINE_CLASS(DOUBLE,                System,                 Double)
 DEFINE_METHOD(DOUBLE,               GET_HASH_CODE,          GetHashCode, IM_RetInt)
@@ -815,11 +809,6 @@ DEFINE_CLASS(SAFE_TYPENAMEPARSER_HANDLE,    System,         SafeTypeNameParserHa
 
 DEFINE_CLASS(SECURITY_EXCEPTION,    Security,               SecurityException)
 
-
-DEFINE_CLASS(SHARED_STATICS,        System,                 SharedStatics)
-DEFINE_FIELD(SHARED_STATICS,        SHARED_STATICS,         _sharedStatics)
-
-
 DEFINE_CLASS_U(Diagnostics,                StackFrameHelper,   StackFrameHelper)
 DEFINE_FIELD_U(targetThread,               StackFrameHelper,   targetThread)
 DEFINE_FIELD_U(rgiOffset,                  StackFrameHelper,   rgiOffset)
index ba97df3..01b0d48 100644 (file)
@@ -1625,28 +1625,6 @@ class AppDomainBaseObject : public MarshalByRefObjectBaseObject
     }
 };
 
-
-// The managed definition of AppDomainSetup is in BCL\System\AppDomainSetup.cs
-class AppDomainSetupObject : public Object
-{
-    friend class MscorlibBinder;
-
-  protected:
-    PTRARRAYREF m_Entries;
-    STRINGREF m_AppBase;
-    OBJECTREF m_CompatFlags;
-
-  protected:
-    AppDomainSetupObject() { LIMITED_METHOD_CONTRACT; }
-   ~AppDomainSetupObject() { LIMITED_METHOD_CONTRACT; }
-};
-typedef DPTR(AppDomainSetupObject) PTR_AppDomainSetupObject;
-#ifdef USE_CHECKED_OBJECTREFS
-typedef REF<AppDomainSetupObject> APPDOMAINSETUPREF;
-#else
-typedef AppDomainSetupObject*     APPDOMAINSETUPREF;
-#endif
-
 // AssemblyBaseObject 
 // This class is the base class for assemblies
 //  
index 69dd4d0..d485e19 100644 (file)
@@ -2140,8 +2140,7 @@ PEAssembly *PEAssembly::DoOpenSystem(IUnknown * pAppCtx)
 #ifndef CROSSGEN_COMPILE
 /* static */
 PEAssembly *PEAssembly::OpenMemory(PEAssembly *pParentAssembly,
-                                   const void *flat, COUNT_T size,
-                                   CLRPrivBinderLoadFile* pBinderToUse)
+                                   const void *flat, COUNT_T size)
 {
     STANDARD_VM_CONTRACT;
 
@@ -2149,7 +2148,7 @@ PEAssembly *PEAssembly::OpenMemory(PEAssembly *pParentAssembly,
 
     EX_TRY
     {
-        result = DoOpenMemory(pParentAssembly, flat, size, pBinderToUse);
+        result = DoOpenMemory(pParentAssembly, flat, size);
     }
     EX_HOOK
     {
@@ -2180,7 +2179,7 @@ public:
     void Invoke()
     {
         WRAPPER_NO_CONTRACT;
-        PEAssemblyHolder result(PEAssembly::OpenMemory(pParentAssembly, flat, size, FALSE));
+        PEAssemblyHolder result(PEAssembly::OpenMemory(pParentAssembly, flat, size));
     }
 };
 
@@ -2188,8 +2187,7 @@ public:
 PEAssembly *PEAssembly::DoOpenMemory(
     PEAssembly *pParentAssembly,
     const void *flat,
-    COUNT_T size,
-    CLRPrivBinderLoadFile* pBinderToUse)
+    COUNT_T size)
 {
     CONTRACT(PEAssembly *)
     {
index 699b4e4..4596743 100644 (file)
@@ -47,8 +47,6 @@ class PEModule;
 class PEAssembly;
 class SimpleRWLock;
 
-class CLRPrivBinderLoadFile;
-
 typedef VPTR(PEModule) PTR_PEModule;
 typedef VPTR(PEAssembly) PTR_PEAssembly;
 
@@ -669,14 +667,12 @@ class PEAssembly : public PEFile
     static PEAssembly *OpenMemory(
         PEAssembly *pParentAssembly,
         const void *flat,
-        COUNT_T size, 
-        CLRPrivBinderLoadFile* pBinderToUse = NULL);
+        COUNT_T size);
 
     static PEAssembly *DoOpenMemory(
         PEAssembly *pParentAssembly,
         const void *flat,
-        COUNT_T size,
-        CLRPrivBinderLoadFile* pBinderToUse);
+        COUNT_T size);
 
   private:
     // Private helpers for crufty exception handling reasons
index a8d2aa7..09dd119 100644 (file)
@@ -168,11 +168,6 @@ FCIMPL5(Object*, RuntimeFieldHandle::GetValue, ReflectFieldObject *pFieldUNSAFE,
         pAssem = declaringType.GetAssembly();
     }
 
-    // We should throw NotSupportedException here. 
-    // But for backward compatibility we are throwing FieldAccessException instead.
-    if (pAssem->IsDynamic() && !pAssem->HasRunAccess())
-        FCThrow(kFieldAccessException);
-
     OBJECTREF rv = NULL; // not protected
 
     HELPER_METHOD_FRAME_BEGIN_RET_PROTECT(gc);
@@ -328,11 +323,6 @@ FCIMPL7(void, RuntimeFieldHandle::SetValue, ReflectFieldObject *pFieldUNSAFE, Ob
         pAssem = declaringType.GetAssembly();
     }
 
-    // We should throw NotSupportedException here. 
-    // But for backward compatibility we are throwing FieldAccessException instead.
-    if (pAssem->IsDynamic() && !pAssem->HasRunAccess())
-        FCThrowVoid(kFieldAccessException);
-
     FC_GC_POLL_NOT_NEEDED();
 
     FieldDesc* pFieldDesc = gc.refField->GetField();
@@ -417,9 +407,6 @@ FCIMPL6(Object*, RuntimeTypeHandle::CreateInstance, ReflectClassBaseObject* refT
 
     Assembly *pAssem = thisTH.GetAssembly();
 
-    if (pAssem->IsDynamic() && !pAssem->HasRunAccess())
-        FCThrowRes(kNotSupportedException, W("NotSupported_DynamicAssemblyNoRunAccess"));
-
     HELPER_METHOD_FRAME_BEGIN_RET_2(rv, refThis);
 
     MethodTable* pVMT;
@@ -573,7 +560,6 @@ FCIMPL2(Object*, RuntimeTypeHandle::CreateInstanceForGenericType, ReflectClassBa
     // Get the type information associated with refThis
     MethodTable* pVMT = instantiatedType.GetMethodTable();
     _ASSERTE (pVMT != 0 &&  !instantiatedType.IsTypeDesc());
-    _ASSERTE(!(pVMT->GetAssembly()->IsDynamic() && !pVMT->GetAssembly()->HasRunAccess()));
     _ASSERTE( !pVMT->IsAbstract() ||! instantiatedType.ContainsGenericVariables());
     _ASSERTE(!pVMT->IsByRefLike() && pVMT->HasDefaultConstructor());
 
@@ -1006,11 +992,6 @@ FCIMPL5(Object*, RuntimeMethodHandle::InvokeMethod,
 
     Assembly *pAssem = pMeth->GetAssembly();
 
-    // We should throw NotSupportedException here. 
-    // But for backward compatibility we are throwing TargetException instead.
-    if (pAssem->IsDynamic() && !pAssem->HasRunAccess())
-        COMPlusThrow(kTargetException);
-
     if (ownerType.IsSharedByGenericInstantiations())
         COMPlusThrow(kNotSupportedException, W("NotSupported_Type"));
  
@@ -1544,11 +1525,6 @@ FCIMPL4(Object*, RuntimeFieldHandle::GetValueDirect, ReflectFieldObject *pFieldU
 
     Assembly *pAssem = pField->GetModule()->GetAssembly();
 
-    // We should throw NotSupportedException here. 
-    // But for backward compatibility we are throwing FieldAccessException instead.
-    if (pAssem->IsDynamic() && !pAssem->HasRunAccess())
-        FCThrow(kFieldAccessException);
-
     OBJECTREF refRet  = NULL;
     CorElementType fieldElType;
 
@@ -1706,11 +1682,6 @@ FCIMPL5(void, RuntimeFieldHandle::SetValueDirect, ReflectFieldObject *pFieldUNSA
 
     Assembly *pAssem = pField->GetModule()->GetAssembly();
 
-    // We should throw NotSupportedException here. 
-    // But for backward compatibility we are throwing FieldAccessException instead.
-    if (pAssem->IsDynamic() && !pAssem->HasRunAccess())
-        FCThrowVoid(kFieldAccessException);
-
     BYTE           *pDst = NULL;
     ARG_SLOT        value = NULL;
     CorElementType  fieldElType;
@@ -1927,11 +1898,6 @@ FCIMPL1(void, ReflectionInvocation::RunClassConstructor, ReflectClassBaseObject
 
     Assembly *pAssem = pMT->GetAssembly();
 
-    if (pAssem->IsDynamic() && !pAssem->HasRunAccess())
-    {
-        FCThrowResVoid(kNotSupportedException, W("NotSupported_DynamicAssemblyNoRunAccess"));
-    }
-
     if (!pMT->IsClassInited()) 
     {
         HELPER_METHOD_FRAME_BEGIN_1(refType);
@@ -1962,9 +1928,6 @@ FCIMPL1(void, ReflectionInvocation::RunModuleConstructor, ReflectModuleBaseObjec
 
     Assembly *pAssem = pModule->GetAssembly();
 
-    if (pAssem->IsDynamic() && !pAssem->HasRunAccess())
-        FCThrowResVoid(kNotSupportedException, W("NotSupported_DynamicAssemblyNoRunAccess"));
-
     DomainFile *pDomainFile = pModule->FindDomainFile(GetAppDomain());
     if (pDomainFile==NULL || !pDomainFile->IsActive())
     {
index f195cd0..63f2edc 100644 (file)
@@ -1283,7 +1283,7 @@ public:
         TSNC_WinRTInitialized           = 0x08000000, // the thread has initialized WinRT
 #endif // FEATURE_COMINTEROP
 
-        TSNC_ForceStackCommit           = 0x10000000, // Commit the whole stack, even if disableCommitThreadStack is set
+        // TSNC_Unused                  = 0x10000000,
 
         TSNC_CallingManagedCodeDisabled = 0x20000000, // Use by multicore JIT feature to asert on calling managed code/loading module in background thread
                                                       // Exception, system module is allowed, security demand is allowed