Reflection performance tweaks & cleanup (#21737)
authorJan Kotas <jkotas@microsoft.com>
Fri, 4 Jan 2019 09:05:49 +0000 (23:05 -1000)
committerGitHub <noreply@github.com>
Fri, 4 Jan 2019 09:05:49 +0000 (23:05 -1000)
commita6269391cf04c656e9d472e1101e1ec670ecd605
treed54e0b5a520b88413adb0d95f338ee4d42bc55a6
parent7d67f73b7223620b709b2c7e33e0f6e3cef5a7e8
Reflection performance tweaks & cleanup (#21737)

- Delete internal "Unsafe" field getters/setters. They performance was very close (within 10%) of the regular getters/setters.
- Made a few performance tweaks in reflection to make reflection faster overall. The regular field getters/setters are faster than what the unsafe ones used to be with this change.
src/System.Private.CoreLib/System.Private.CoreLib.csproj
src/System.Private.CoreLib/src/System/Attribute.CoreCLR.cs [moved from src/System.Private.CoreLib/src/System/Attribute.cs with 100% similarity]
src/System.Private.CoreLib/src/System/Reflection/CustomAttribute.cs
src/System.Private.CoreLib/src/System/Reflection/RtFieldInfo.cs
src/System.Private.CoreLib/src/System/RtType.cs
src/System.Private.CoreLib/src/System/Runtime/InteropServices/GcHandle.cs
src/System.Private.CoreLib/src/System/ValueType.cs