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

github.com/mono/corert.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-10-27dd IsDotNetFrameworkProductAssembly for Framework Assemblylouluqun
With Project file cotains Property <IsDotNetFrameworkProductAssembly>true</IsDotNetFrameworkProductAssembly>, the final assembly will contain assembly attribute [assembly: AssemblyMetadata(".NETFrameworkAssembly", "")]
2017-10-26Merge pull request #4805 from dotnet/nmirrorJan Kotas
Merge nmirror to master
2017-10-25DefineConstants fix for System.Private.InteropLuqun Lou
Previous My last minute change introduces two problems: 1. in System.Private.Interop.CoreCLR.csproj file, if you use "<DefineConstants>$(DefineConstants);*</DefineConstants>" , when building it, it will define CoreRT which isn't expected. 2. in System.Private.Interop.Mono.csproj file, move "import System.Private.Interop.CoreCLR.csproj" above the PropertyGroup, so that the Properties in System.Private.Interop.Mono.csproj can overwrite Properties in System.Private.Interop.CoreCLR.csproj [tfs-changeset: 1679184]
2017-10-25Use WinRT Types from CoreRTLuqun Lou
As pointed by Jan, there are duplicate copy of these types in S.R.WR/S.P.Interop and CoreRT. The change is to remove duplicate copy of WinRT Type in ProjectN and use types from CoreRT instead. The next step is to remove the duplicate copy in S.R.WR. [tfs-changeset: 1679183]
2017-10-25Merge pull request #4790 from dotnet/nmirrorMichal Strehovský
Merge nmirror to master
2017-10-24Add some WellKnown WinRT Types for MiniWinRTLuqun Lou
The change is to add some "wellknown" winrt types and these winrt types( are treated specially by MCG/Interop due to projection. The reason to add them type into System.Private.Interop is that dynamic interop need these "wellknown" winrt type to compare with given type. such as if(type is typeof(IReference)) {//do something special} Details: 1. System.Private.Interop.CoreCLR.csproj: add $(DefineConstants) to avoid override other Constants 2. System.Private.Interop.Mono.csproj: add all of these well known winrt types 3. DebugAnnotations.cs: this attribute is consumed only by debugger 4. DependencyReductionRootAttribute: add other attribute Usage 5. InteropExtensions.cs/PInvokeMarshal.cs: default implementation for methods referenced in McgMarshal 6. McgIntrinsics.cs: make necessary #ifdef change to compile new added winrt Types 7. System\Runtime\InteropServices\WindowsRuntime: Wellknown WinRT Type 8. Windows\Foundation\: Wellknown WinRT Type [tfs-changeset: 1678923]
2017-10-23Search/replace Debug.Assert(false, => Debug.Fail( (#4782)Jan Kotas
2017-10-21Enable GetRuntimeClassName for MiniWinRTLuqun Lou
simple #ifdef change [tfs-changeset: 1678784]
2017-10-21Enable LibraryInitializer for Mcg on miniwinrtLuqun Lou
Mcg on MiniWinRT scenario need to use LibraryInitializer to run specific static class constructors. By the way, Mcg on miniWinRT doesn't need pinvoke data support and Mcg on Coreclr do need pinvoke support TODO: enable RuntimeAugments.InitializeInteropLookups for mcg on coreclr scenario [tfs-changeset: 1678783]
2017-10-21Add a project file for Mcg On MiniWinRTLuqun Lou
This project file will generate a System.Private.Interop.dll for mono with MiniWinRT enable [tfs-changeset: 1678779]
2017-10-18Merge pull request #4747 from dotnet/nmirrorJan Kotas
Merge nmirror to master
2017-10-18Delegate shouldn't treat as ComClassLuqun Lou
From interop point, Delegate isn't ComClass. In WinRT, we treat delegate as interface instead of Class. [tfs-changeset: 1678339]
2017-10-18Enable string marshalling for minwinrt modeLuqun Lou
ENABLE_MIN_WINRT is defined when it runs on ProjectN or mcg on minwinrt mode. [tfs-changeset: 1678338]
2017-10-18Fix build break with latest VS preview (#4748)Jan Kotas
2017-10-18MiniWinRT need IMarshal/IStream supportLuqun Lou
the reason to change Clone signature from "out IntPtr" to "IntPtr" is that "our IntPtr" needs marshal support and "Intptr" doesn't need marshal support. For NativeCallable method, it shouldn't need marshal support. [tfs-changeset: 1678334]
2017-10-17Replace generic StdCall intristics with non-generic StdCallLuqun Lou
the reason for replacing StdCall<T> with StdCall__int is that 1. CoreCLR doesn't support generic Calli, see voidSigPointer::ConvertToInternalExactlyOne(Module* pSigModule, SigTypeContext *pTypeContext, SigBuilder * pSigBuilder, BOOL bSkipCustomModifier) for more info 2. StdCall<T> doesn't buy us much, since we always use StdCall<int> [tfs-changeset: 1678326]
2017-10-17Mirror changes from coreclr exception serialization (#4744)Viktor Hofer
2017-10-17Fix For Bug#507240 Marshal.IsComObject fails for __ComObject in x-plat MCGLuqun Lou
Yi/Alan/Tyler found out this bug and the root cause--- IsComObject(Type t) only check whether t is subclass of __ComObject or not --- IsSubclassOf fails if type is exactly __ComObject: https://msdn.microsoft.com/en-us/library/system.type.issubclassof%28v=vs.110%29.aspx the fix is to add a check to see whether type itself is __ComObject or not. Changes: 1. Unify IsCOMObject and IsComObject into IsComObject. don't confuse ourselves 2. Move McgComHelpers.IsComObject into McgMarshal.IsComObject TODO: 1. Consider to split McgMarshal.cs into McgMarshal.Pinvoke.cs/McgMarshal.Com.cs/McgMarshal.WinRT.cs/McgMarshal.Common.cs [tfs-changeset: 1678276]
2017-10-14Delete contract annotations (#4722)Jan Kotas
2017-10-06Remove Thunk created during DynamicCCWLuqun Lou
The change is to free these thunks created by DynamicCCW through CallInterceptor. Changes: 1. ComCallableObject.cs: a. Use m_dynamicMethodStart and m_dynamicMethodEnd to record methods [dynamicMethodStart , dynamicMethodEnd) are dynamically created. b. Free these thunks during interface CCW destroy 2. CallInterceptor.cs a. Add a static FreeThunk method to free thunks created by CCW. The use pattern for CCW dynamic thunk is that it only save thunk address instead of CallInterceptor instance. it is hard to call CallInterceptor instance's FreeThunk() 3. InteropCallInterceptors: Remove TODO, since it isn't okay to clear these two field after native call this delegate once. In native side, it may call this WinRT delegate couple times. if we clear these two fields after one call, the next call will fail. [tfs-changeset: 1677503]
2017-10-03Fix filename casingJan Kotas
2017-10-03Fix Unix build breakFaizur Rahman
2017-10-03Move CoreCLR version of System.Private.Interop to CoreRTFaizur Rahman
This is the first step towards open sourcing MCG - moving CoreCLR version of System.Private.Interop to CoreRT. This change also merges System.Private.Interop with System.Private.CoreLib.InteropServices.CoreCLR. I have verified that it builds on CoreRT, but haven't tried run any test with it yet. [tfs-changeset: 1677117]
2017-09-21Trivial update for dynamic interopLuqun Lou
__ComObject.cs: during dynamic interop, We can generate dynamic adapter on fly for generic type InteropCallInterceptors.cs: align with Mcg generated source code, always call McgMarshal.GetExceptionForHR instead [tfs-changeset: 1674995]
2017-09-14Enable Dynamic Support for GenericArgumentsLuqun Lou
For Generic Argument type, we should able to dynamic create them even its mcg data doesn't exist. In future, we should remove these generic argument mcg data, since type system will help us to create them as demand. [tfs-changeset: 1674129]
2017-09-10Move PInvoke interop related attributes to shared CoreLib partitionJan Kotas
[tfs-changeset: 1673253]
2017-09-08Disable DebuggerBrowsable for __ComObject fields and properties . We wereTijoy Tom Kalathiparambil
showing implementation details in the debugger which is of no use for the end user . Also this improved func eval perf since we avoid unnecessary evaluations. [tfs-changeset: 1673187]
2017-08-30Fix issue where attemping to get Type equality on McgFakeMetadataTypes ↵David Wrighton
causes an exception - Fix it to behave as it did before NS2.0 and be a reference equality operation - NS 2.0 work brought along a new Equals method that needs to be overriden for correct behavior [tfs-changeset: 1672183]
2017-08-15Remove Unnecessary Debug Assert in ObjectToComInterfaceLuqun Lou
The Debug.Assert(obj == null || obj is __ComObject) is Unnecessary and incorrect: Unnecessary: There is another Debug.Assert(!typeHnd.IsNull()) later, which will do similar(or better) check. since Debug.Assert(!typeHnd.IsNull()) also handle managed winmdobject case. Incorrect: it miss a case such as obj itself is a managed winmd object case. so it should be Debug.Assert(obj == null || obj is __ComObject || obj is managed winmd object); [tfs-changeset: 1670398]
2017-08-05typo (#4274)github-john-doe
2017-08-04Fix async call performance regressionAnton Lapounov
Bugs: • https://devdiv.visualstudio.com/DevDiv/_workitems/edit/470211 • https://devdiv.visualstudio.com/DevDiv/_workitems/edit/205405 CR: AdityaM To schedule an asynchronous call, we perform several WinRT calls to check whether the current thread has either a CoreDispatcher or a DispatcherQueue associated with it. These calls, especially the recently added ones related to DispatcherQueue support, are expensive and make async calls around 3 times slower than on desktop CLR on a microbenchmark. This change implements a number of optimizations based on a discussion with Windows developers: • Skip checking for CoreDispatcher/DispatcherQueue on non-[A]STA threads. • Skip checking for CoreDispatcher for desktop apps. (CoreDispatcher is not supported for desktop apps.) • Cache the IDispatcherQueueStatics interface pointer instead of calling RoGetActivationFactory on each async call. • Avoid an unnecessary closure object allocation in FactoryCache.GetActivationFactory. I had to change WinRTCallbacks.s_resourceContextQualifierMap initialization, because it would crash for desktop apps. (The class constructor would never be called for desktop apps before I added extra static fields.) I also deleted the orphaned Interop.WinRT.cs file. [tfs-changeset: 1669116]
2017-07-07WindowsRuntimeMarshal.RemoveEventHandler was doing the wrong thing for ↵Tijoy Tom Kalathiparambil
static remove method. For static method delegate.Target is null and it takes the ManagedEventRegistrationImpl code path which asserts target!=null .CoreCLR does the right thing https://github.com/Microsoft/referencesource/blob/master/mscorlib/system/runtime/interopservices/windowsruntime/windowsruntimemarshal.cs#L98 [tfs-changeset: 1665004]
2017-06-30Cleanup MightBeBlittable implementationJan Kotas
- Cleaned up comments around MightBeBlittable and simplified the implementation - Moved a few more Marshal methods to PInvokeMarshal from InteropExtensions and removed redundant wrappers - Fixed potential integer truncation in UnsafeAddrOfPinnedArrayElement on 64-bit platforms [tfs-changeset: 1663953]
2017-06-30Cleanup ConditionalWeakTable use by interopJan Kotas
Interop (and a few other parts) have been using internal enumerators on ConditionalWeakTable. Replace them with the public tested efficient/non-allocating enumerator introduced for .NET Core 2.0. [tfs-changeset: 1663943]
2017-06-27Merge pull request #3991 from dotnet/nmirrorJan Kotas
Merge nmirror to master
2017-06-27Throw right exception if generic argument to EventRegistrationTokenTable is ↵Tijoy Tom Kalathiparambil
not delegate type [tfs-changeset: 1663402]
2017-06-27Merge pull request #3986 from dotnet/nmirrorMichal Strehovský
Merge nmirror to master
2017-06-27Roll back CS1662871Luqun Lou
Yi want to get more info about this change [tfs-changeset: 1663381]
2017-06-25Merge pull request #3980 from dotnet/nmirrorJan Kotas
Merge nmirror to master
2017-06-24Remove unnecessary ProjectN build dependency on AotPackageReference projectJan Kotas
[tfs-changeset: 1663213]
2017-06-24Update CoreRT build to use latest .NET CLI and build tools (#3916)Jan Kotas
- Pick up latest .NET Core 2.0 CLI and buildtools - Remove all project.json references and convert everything to msbuild projects - Stick to vanilla .NET CLI project shape as much as possible. Minimize dependencies on buildtools special behaviors
2017-06-24 Add Marshal.PtrToStringUni internal implementation in S.P.CoreLibFaizur Rahman
This change adds and internal Marshal.PtrToStringUni in S.P.CoreLib to unblock the benchmark Sergiy has been working on. [tfs-changeset: 1662877]
2017-06-24 Enable DynamicRCW by defaultLuqun Lou
Enable dynamic rcw by default, which enable generic interface casting for incremental build and non-incremental build For non-generic type, this shouldn't affect its behavior For generic type, support the cast will always work if QI return succeeded Generic Type Dynamic RCW dependency: 1. These DynamicRCWAdapter for generic interface need to be UniversalCanon Note: This change may have negative perf impact for non-incremental build Before(Disable DynamicRCW): • It will only call ICastable.IsInstanceOfInterface • ICastable.IsInstanceOfInterface will return true iff whether ComObject support(QI) this interface After(Enable DyanamicRCW): • It will call ICastable.IsInstanceOfInterface first, if ICastable.IsInstanceOfInterface return false, then call CastableObject.CastToInterface • ICastable.IsInstanceOfInterface will return true iff interface has DispatchClass and ComObject support(QI) this interface [tfs-changeset: 1662871]
2017-06-24Remove the bounds check from UnsafeAddrOfPinnedArrayElement.The bounds check ↵Tijoy Tom Kalathiparambil
disallowed pinning a zero length array and corefx networking libraries use it.Also desktop do not do bounds check. [tfs-changeset: 1662861]
2017-06-24Change NotImplementedException to ↵Yi Zhang
NotSupportedException/NotImplemented.ByDesign according to guidelines. [tfs-changeset: 1662850]
2017-06-20Undo ToolsVersion cleanup on full framework projectsJan Kotas
VS is trying to "upgrate" the full framework projects without ToolsVersion [tfs-changeset: 1662259]
2017-06-19Fix For Bug296322Luqun Lou
Bug 296322 # [AppCompat] System.Reflection.AmbiguousMatchException:Ambiguous match found.. The issue is related to Jupiter data binding for hiding property with different return type, see following sample code. public class A { public int P {get;set;} } public class B : A { public new string P {get;set;} } <TextBlock name="myTextBlock" Text="{Binding P}" /> myTextBlock.DataContext = new B{ P = "B"}; Behavior: Desktop: it will throw AmbiguousMatchException first, and then swallow it, return null and S_OK NS2.0-: it will return B.P NS2.0+: it will throw AmbiguousMatchException due to Reflection Change The change is to align Desktop behavior--swallow the exception and return null property and S_OK [tfs-changeset: 1662099]
2017-06-17Delete ToolsVersion attribute from msbuild filesJan Kotas
The latest project templates do not have it, and it is only good for generating warnings like the following in the detailed build log: Project file contains ToolsVersion="4.0". This toolset may be unknown or missing, in which case you may be able to resolve this by installing the appropriate version of MSBuild, or the build may have been forced to a particular ToolsVersion for policy reasons. Treating the project as if it had ToolsVersion="14.0". For more information, please see http://go.microsoft.com/fwlink/?LinkId=293424. [tfs-changeset: 1662024]
2017-06-10Fix ProjectN build breaks (#3859)Jan Kotas
2017-06-10Merge pull request #3849 from dotnet/nmirrorJan Kotas
Merge nmirror to master