1. 23 1月, 2020 14 次提交
    • M
      Add asynchronous overload of WindowsIdentity.RunImpersonated (#1152) · beff8ab2
      Marco Rossignoli 提交于
      * add RunImpersonateAsync overloads
      
      * skip on full framework
      
      * run test netcoreapp only
      
      * skip tests on nanoserver
      
      * address PR feedback
      
      * address PR feedback
      
      * address PR feedback
      
      * address PR feedback
      
      * Update WindowsIdentity.cs
      
      update comment
      
      * Update WindowsIdentity.cs
      
      update comment
      
      * Update WindowsIdentity.cs
      
      Fix comment
      
      * Update WindowsIdentity.cs
      
      fix comment
      
      * Fix comment
      beff8ab2
    • M
      configure.ac: remove AC_SEARCH_LIBS for libintl (#2027) · 62c00342
      Marek Safar 提交于
      configure.ac: remove AC_SEARCH_LIBS for libintl
      62c00342
    • A
      Enable NetworkAddressChange on FreeBSD (#1602) · a4129114
      Adeel Mujahid 提交于
      a4129114
    • J
      Protect multi-threaded access to Module.m_GenericParamToDescMap. (#1907) · 7a02a535
      Jan Kotas 提交于
      Same type can be loaded by multiple threads in parallel in rare situations
      
      Fixes #1847
      7a02a535
    • D
      [master] Update dependencies from dotnet/arcade mono/linker Microsoft/vstest (#1804) · 6cfbbef6
      dotnet-maestro[bot] 提交于
      * Update dependencies from https://github.com/dotnet/arcade build 20200115.5
      
      - Microsoft.DotNet.XUnitExtensions - 5.0.0-beta.20065.5
      - Microsoft.DotNet.VersionTools.Tasks - 5.0.0-beta.20065.5
      - Microsoft.DotNet.ApiCompat - 5.0.0-beta.20065.5
      - Microsoft.DotNet.Arcade.Sdk - 5.0.0-beta.20065.5
      - Microsoft.DotNet.Build.Tasks.Configuration - 5.0.0-beta.20065.5
      - Microsoft.DotNet.Build.Tasks.Feed - 5.0.0-beta.20065.5
      - Microsoft.DotNet.Build.Tasks.Packaging - 5.0.0-beta.20065.5
      - Microsoft.DotNet.Build.Tasks.SharedFramework.Sdk - 5.0.0-beta.20065.5
      - Microsoft.DotNet.CodeAnalysis - 5.0.0-beta.20065.5
      - Microsoft.DotNet.GenAPI - 5.0.0-beta.20065.5
      - Microsoft.DotNet.GenFacades - 5.0.0-beta.20065.5
      - Microsoft.DotNet.Helix.Sdk - 5.0.0-beta.20065.5
      - Microsoft.DotNet.RemoteExecutor - 5.0.0-beta.20065.5
      - Microsoft.DotNet.XUnitConsoleRunner - 2.5.1-beta.20065.5
      
      * Update dependencies from https://github.com/dotnet/arcade build 20200116.1
      
      - Microsoft.DotNet.XUnitExtensions - 5.0.0-beta.20066.1
      - Microsoft.DotNet.VersionTools.Tasks - 5.0.0-beta.20066.1
      - Microsoft.DotNet.ApiCompat - 5.0.0-beta.20066.1
      - Microsoft.DotNet.Arcade.Sdk - 5.0.0-beta.20066.1
      - Microsoft.DotNet.Build.Tasks.Configuration - 5.0.0-beta.20066.1
      - Microsoft.DotNet.Build.Tasks.Feed - 5.0.0-beta.20066.1
      - Microsoft.DotNet.Build.Tasks.Packaging - 5.0.0-beta.20066.1
      - Microsoft.DotNet.Build.Tasks.SharedFramework.Sdk - 5.0.0-beta.20066.1
      - Microsoft.DotNet.CodeAnalysis - 5.0.0-beta.20066.1
      - Microsoft.DotNet.GenAPI - 5.0.0-beta.20066.1
      - Microsoft.DotNet.GenFacades - 5.0.0-beta.20066.1
      - Microsoft.DotNet.Helix.Sdk - 5.0.0-beta.20066.1
      - Microsoft.DotNet.RemoteExecutor - 5.0.0-beta.20066.1
      - Microsoft.DotNet.XUnitConsoleRunner - 2.5.1-beta.20066.1
      
      * Update dependencies from https://github.com/microsoft/vstest build 20200116-01
      
      - Microsoft.NET.Test.Sdk - 16.5.0-preview-20200116-01
      
      * Update dependencies from https://github.com/dotnet/arcade build 20200117.2
      
      - Microsoft.DotNet.XUnitExtensions - 5.0.0-beta.20067.2
      - Microsoft.DotNet.VersionTools.Tasks - 5.0.0-beta.20067.2
      - Microsoft.DotNet.ApiCompat - 5.0.0-beta.20067.2
      - Microsoft.DotNet.Arcade.Sdk - 5.0.0-beta.20067.2
      - Microsoft.DotNet.Build.Tasks.Configuration - 5.0.0-beta.20067.2
      - Microsoft.DotNet.Build.Tasks.Feed - 5.0.0-beta.20067.2
      - Microsoft.DotNet.Build.Tasks.Packaging - 5.0.0-beta.20067.2
      - Microsoft.DotNet.Build.Tasks.SharedFramework.Sdk - 5.0.0-beta.20067.2
      - Microsoft.DotNet.CodeAnalysis - 5.0.0-beta.20067.2
      - Microsoft.DotNet.GenAPI - 5.0.0-beta.20067.2
      - Microsoft.DotNet.XUnitConsoleRunner - 2.5.1-beta.20067.2
      - Microsoft.DotNet.GenFacades - 5.0.0-beta.20067.2
      - Microsoft.DotNet.Helix.Sdk - 5.0.0-beta.20067.2
      - Microsoft.DotNet.RemoteExecutor - 5.0.0-beta.20067.2
      
      * Update dependencies from https://github.com/dotnet/arcade build 20200118.1
      
      - Microsoft.DotNet.XUnitExtensions - 5.0.0-beta.20068.1
      - Microsoft.DotNet.VersionTools.Tasks - 5.0.0-beta.20068.1
      - Microsoft.DotNet.ApiCompat - 5.0.0-beta.20068.1
      - Microsoft.DotNet.Arcade.Sdk - 5.0.0-beta.20068.1
      - Microsoft.DotNet.Build.Tasks.Configuration - 5.0.0-beta.20068.1
      - Microsoft.DotNet.Build.Tasks.Feed - 5.0.0-beta.20068.1
      - Microsoft.DotNet.Build.Tasks.Packaging - 5.0.0-beta.20068.1
      - Microsoft.DotNet.Build.Tasks.SharedFramework.Sdk - 5.0.0-beta.20068.1
      - Microsoft.DotNet.CodeAnalysis - 5.0.0-beta.20068.1
      - Microsoft.DotNet.GenAPI - 5.0.0-beta.20068.1
      - Microsoft.DotNet.XUnitConsoleRunner - 2.5.1-beta.20068.1
      - Microsoft.DotNet.GenFacades - 5.0.0-beta.20068.1
      - Microsoft.DotNet.Helix.Sdk - 5.0.0-beta.20068.1
      - Microsoft.DotNet.RemoteExecutor - 5.0.0-beta.20068.1
      
      * Update dependencies from https://github.com/microsoft/vstest build 20200120-01
      
      - Microsoft.NET.Test.Sdk - 16.5.0-preview-20200120-01
      
      * Update dependencies from https://github.com/dotnet/arcade build 20200121.3
      
      - Microsoft.DotNet.XUnitExtensions - 5.0.0-beta.20071.3
      - Microsoft.DotNet.VersionTools.Tasks - 5.0.0-beta.20071.3
      - Microsoft.DotNet.ApiCompat - 5.0.0-beta.20071.3
      - Microsoft.DotNet.Arcade.Sdk - 5.0.0-beta.20071.3
      - Microsoft.DotNet.Build.Tasks.Configuration - 5.0.0-beta.20071.3
      - Microsoft.DotNet.Build.Tasks.Feed - 5.0.0-beta.20071.3
      - Microsoft.DotNet.Build.Tasks.Packaging - 5.0.0-beta.20071.3
      - Microsoft.DotNet.Build.Tasks.SharedFramework.Sdk - 5.0.0-beta.20071.3
      - Microsoft.DotNet.CodeAnalysis - 5.0.0-beta.20071.3
      - Microsoft.DotNet.GenAPI - 5.0.0-beta.20071.3
      - Microsoft.DotNet.XUnitConsoleRunner - 2.5.1-beta.20071.3
      - Microsoft.DotNet.GenFacades - 5.0.0-beta.20071.3
      - Microsoft.DotNet.Helix.Sdk - 5.0.0-beta.20071.3
      - Microsoft.DotNet.RemoteExecutor - 5.0.0-beta.20071.3
      6cfbbef6
    • S
      Add a Sockets test to validate undesired blocking of continuations (#1973) · 28646107
      Stephen Toub 提交于
      We go out of our way (e.g. on Unix queueing work off of the epoll threads) to ensure that arbitrary user code running as part of socket continuations doesn't block those threads and potentially deadlock.  Add a test to help validate this.
      28646107
    • B
      Don't do STRESS_PROFILER_CALLBACKS when pre-JITing (#2016) · 8861275a
      Bruce Forstall 提交于
      This leads us to generate an illegal relocation fixup.
      
      Fixes #1789
      8861275a
    • S
      Tweak codegen for Regex's FindFirstChar (#1996) · 5a948f14
      Stephen Toub 提交于
      * Avoid extra field loads / comparisons in FindFirstChar
      
      If we've already compared the current pos to the end pos as part of a minimum length check, we don't need to repeat it again later.  We can also read from locals rather than fields more than we are to save redundant field reads.
      
      * Reduce branches in Boyer-Moore negative switch table
      
      It's often the case that lots of negative branches have the same value.  We can coalesce them.
      
      * Address PR feedback
      5a948f14
    • K
      Prohibit null key on HMAC. (#2018) · 0f51290d
      Kevin Jones 提交于
      * Validate key on HMAC classes.
      
      A refactoring in HMACCommon caused null keys to be implicitly converted
      in to empty spans. This lead to a null key being used as an empty key.
      
      * Use assertion helper to test parameter name.
      0f51290d
    • M
      configure.ac: remove AC_SEARCH_LIBS for libintl · 80d161f7
      monojenkins 提交于
      This causes an additional dependency of mono on libintl which we didn't have before.
      Reported by a user on gitter, it's problematic on macOS since it makes the mono binary depend on the libintl we ship in the Mono .pkg.
      
      It was introduced in Mono 6.6 by https://github.com/mono/mono/commit/18e0ebfe89be0a175d2f904b9bb1ec6816daa318
      80d161f7
    • A
      Enable Mono build in CI (#1934) · 6eb3edf8
      Alexander Köplinger 提交于
      * Enable Mono in default build
      
      * Integrate Mono into the build system
      
      * Fix System.Private.CoreLib build in Mono
      
      Broken by https://github.com/dotnet/runtime/commit/9c82a36c23235c4d50954cb33a4d5d89b787a1aa
      
      * Disable Windows test runs
      
      Fails due to https://github.com/dotnet/runtime/issues/1933Co-authored-by: NViktor Hofer <viktor.hofer@microsoft.com>
      6eb3edf8
    • V
      Moving fast parts of cast FCALLs to managed code. (#1068) · c3dc1fdf
      Vladimir Sadov 提交于
      * Exposed casting cache to managed code
      * Implemented a managed version of cache lookup
      * Moved `JIT_IsInstanceOfAny` and `JIT_ChkCastAny`  to managed code as the first ones to move.
      * Skip managed JIT helpers in exception stack traces and debugger
      * Managed `JIT_IsInstanceOfInterface`
      * All other cast helpers are managed.
      
      Fixes:https://github.com/dotnet/coreclr/issues/27931
      c3dc1fdf
    • S
      Improve error messages for invalid WebSocket headers (#1962) · 375a15ba
      Stephen Toub 提交于
      And add tests.
      375a15ba
    • J
      Split AsnReader into a class and a ref struct (AsnValueReader) · 47ab0dc0
      Jeremy Barton 提交于
      Largely, the intent of this change was to reduce the number of temporary readers required for deeply structured payloads (`ReadSequence` returns a new reader), while still maintaining the better usability of the class; and, frankly, to understand what the impact of splitting functionality into "bare metal" and "more usable" pieces was.
      
      ```
      foreach (file in AsnReader.*)
      {
          Copy/paste the entirety of the `partial class AsnReader`;
          Change the top version to say ref partial struct AsnValueReader;
          Replace all AsnReader calls in the top version to say AsnValueReader.
          Replace all ReadOnlyMemory in the top portion with ReadOnlySpan;
          Remove ArraySegment overloads from the top portion (when present);
          Rewrite the bottom portion to open a ref reader at the state the memory is tracking and defer work into the ref reader;
          Run all the existing tests to ensure that nothing broke in that piece;
      }
      ```
      
      Once that was done, I changed the asn.xslt to generate all of the decoding in terms of AsnValueReader.  This didn't change field generation from ReadOnlyMemory to ReadOnlySpan (and the types from struct to ref struct)--a change that could be done later--but instead added a new ReadOnlyMemory input parameter so it can use Overlaps to slice the memory as appropriate (with a fallback of ToArray()).
      
      While I was editing asn.xslt I fixed probably all of the whitespace errors it generated.  I still left the "stylecop, have no opinion about whitespace" pragma since the generator isn't run as part of most people's (or the official) builds.  This also turns on the nullability checks in all of the generated structs.
      47ab0dc0
  2. 22 1月, 2020 26 次提交
    • B
      Fix script errors in mainv1, mainv2 tests (#1997) · 0dcdbac7
      Bruce Forstall 提交于
      * Add additional error checking for mainv1, mainv2 tests
      
      These have been silently failing due to mainv1.exe and mainv2.exe
      changing to be built at mainv1.dll and mainv2.dll without
      corresponding changes in the project files, due to insufficient
      testing in the script.
      
      Add this additional testing.
      
      * Add more error checking
      
      * Fix script errors in mainv1, mainv2 tests
      
      A while back, tests were changed from building .exe to building .dll files
      but these were not updated. Fix that.
      0dcdbac7
    • C
      Reconcile handling of EH vars (#1884) · e686c07f
      Carol Eidt 提交于
      * Reconcile handling of EH vars
      
      Modify `BasicBlock::hasEHBoundaryIn()` and `BasicBlock::hasEHBoundaryOut()` to reflect what liveness is doing, and adjust the register allocator code appropriately.
      
      It might make sense to extract the code that's basically the same, except that the register allocator doesn't need the `finallyVars` except as validation in the `DEBUG` case.
      
      Fix #1786
      e686c07f
    • S
      Use a consistent rootfs location (#2005) · 2dd815d5
      Swift Kim 提交于
      2dd815d5
    • R
      Fix some links to coreclr repo (#1991) · 4cb104ee
      Roman Marusyk 提交于
      4cb104ee
    • M
      Add readme for Mono specific version of SPC (#1963) · b1b407a9
      Marek Safar 提交于
      * Add readme for Mono specific version of SPC
      
      * Update src/mono/netcore/System.Private.CoreLib/README.md
      Co-Authored-By: NStephen Toub <stoub@microsoft.com>
      b1b407a9
    • M
      Do not run validation on runtime determined types (#1357) · 8c1512cf
      Michal Strehovský 提交于
      It doesn't seem like we validate anything for those and `IsRuntimeDeterminedSubtype` check is rather expensive.
      8c1512cf
    • L
      Unify char.IsControl and Rune.IsControl (#1988) · 9b4eece6
      Levi Broderick 提交于
      Not perf-critical, just some cleanup of low hanging fruit.
      9b4eece6
    • J
      Unify CoreLib interop files (#1914) · 9c82a36c
      Jan Kotas 提交于
      - Unify more of CoreLib interop files
      - Replace manual interop with regular managed APIs where possible
      - Delete unused code
      
      Contributes to #1232
      9c82a36c
    • E
      Rebased version of CoreFX renames (#1941) · caa2ed96
      Erhan Atesoglu 提交于
      * FinalCoreFXRenames
      
      The last of the CoreFX renames.
      
      * Update DirectorySearcher.cs
      
      Fixed typo in DirectorySearcher.cs
      
      * Update TestClasses.SimpleTestClassWithObjectArrays.cs
      
      This fixes the expected value of the tests to runtime, instead of corefx.
      
      * Update PersistedFiles.Names.Unix.cs
      
      Adds a note to not update the corefx reference.
      caa2ed96
    • A
    • D
      **BYPASS_SECRET_SCANNING** · 4dbc6f16
      Davis Goodin 提交于
      4dbc6f16
    • M
      Fix long name cross arch DAC (#1948) · 0cab4ab7
      Mike McLaughlin 提交于
      0cab4ab7
    • S
      Workaround AzDo issue when evaluating Build.SourcesDirectory variable in a... · 50efd229
      Santiago Fernandez Madero 提交于
      Workaround AzDo issue when evaluating Build.SourcesDirectory variable  in a docker container (#1982)
      
      * Workaround AzDo issue when evaluating Build.SourcesDirectory variable in a docker container
      
      * Only use env var when in a docker container
      50efd229
    • A
      Make EHInfo parsing lazy (#1899) · e3b370f3
      Andrew Au 提交于
      e3b370f3
    • T
      Eliminate X509Extension allocations during ssl handshake with OpenSSL · 4e72737a
      Tomas Weinfurt 提交于
      Moves policydata to a PAL struct so it can be passed without creating and discarding the X509Extension objects.
      4e72737a
    • A
      Remove unwanted instrumentation code (#1820) · 4c5edb6f
      Andrew Au 提交于
      4c5edb6f
    • A
      Making the Microsoft.NET.IL.Sdk cross target. (#1972) · f991fe7d
      Anirudh Agnihotry 提交于
      * making ilsdk crosstarget
      
      * editing the comment
      f991fe7d
    • S
      Rename CLR_CMAKE_PLATFORM* CLR_CMAKE_HOST* (#1974) · 696e72b1
      Steve MacLean 提交于
      The term platform was ambiguous. Migrate to using common terminology for
      cross compilation.
      
      Host is the platfrom which will execute the code
      Target is the platform which will be debugged or for which code will be generated.
      
      In most cases HOST == TARGET.  The exceptions are the cross component crossgen
      tools and the future cross DAC.
      696e72b1
    • T
      enable unicode tests on OSX (#1728) · 644bdd98
      Tomas Weinfurt 提交于
      644bdd98
    • S
      Streamline Regex path to matching, and improve Replace/Split (#1950) · c469f2da
      Stephen Toub 提交于
      * Add ThrowHelper, and clean up some style
      
      Trying to streamline main path to the engine, ensuring helpers can be inlined, reducing boilerplate, etc.  And as long as ThrowHelper was being used in some places, used it in others where it didn't require adding additional methods.
      
      Also cleaned style along the way.
      
      * Streamline the Scan loop
      
      The main costs remaining are the virtual calls to FindFirstChar/Go.
      
      * Enumerate matches with a reusable match object in Regex.Replace/Split
      
      The cost of re-entering the scan implementation and creating a new Match object for each NextMatch is measurable, but in these cases, we can use an iterator to quickly get back to where we were and reuse the match object.  It adds a couple interface calls per iteration, as well as an allocation for the enumerator, but it saves more than that in the common case.
      
      * Use SegmentStringBuilder instead of ValueStringBuilder in Replace
      
      A previous .NET Core release saw StringBuilder in Regex.Replace replaced by ValueStringBuilder.  This was done to avoid the allocations from the StringBuilder.  However, in some ways, for large input strings, it made things worse.  StringBuilder is implemented as a linked list of builders, whereas ValueStringBuilder is contiguous memory taken from the ArrayPool.  For large input strings, we start requesting buffers too large for the ArrayPool, and thus when we grow we generate large array allocations that become garbage.
      
      We're better off using a simple arraypool-backed struct to store the segments that need to be concatenated, and then just creating the final string from those segments.  For the common case where there are many fewer replacements than the length of the string, this saves a lot of memory as well as avoiding a layer of copying.
      
      * Replace previously added enumerator with a callback mechanism
      
      The delegate invocation per match is faster than the two interface calls per match, plus we can avoid allocating the enumerator and just pass the relevant state through by ref.
      
      * Remove unnecessary fields from MatchCollection
      
      * More exception streamlining and style cleanup
      
      * Address PR feedback, and fix merge with latest changes
      c469f2da
    • T
      Optimize DateTime decomposition in CoreLib (#1944) · e5444a18
      ts2do 提交于
      * Optimize DateTime decomposition in CoreLib
      Add uses of DateTime.GetDate (renamed from GetDatePart) where appropriate
      Add DateTime.GetTime method to eliminate duplicate computations
      
      * Remove unused arithmetic from DateTime.GetTime
      e5444a18
    • M
      WinHttpHandler tests are back (#1676) · 26298bc6
      Marie Píchová 提交于
      The tests used by PlatformHandlerTest moved to Common/tests in order to share them between System.Net.Http and System.Net.Http.WinHttpHandler.
      The added conditions correspond to the state before WinHttpHandler removal. They're just based on IsWinHttpHandler instead of UseSocketHandler.
      Some of the code must be conditionally compiled since there is no usable common base class for HttpClientHandler and WinHttpHandler. Other issues solved by introducing WinHttpClientHandler for testing purposes. It corresponds to HttpClientHandler.Windows.cs code from before its removal.
      26298bc6
    • G
      Fix typo (#1970) · a6738ed4
      Gérald Barré 提交于
      a6738ed4
    • T
    • S
      Specialize Regex codegen for ? (#1898) · dc173458
      Stephen Toub 提交于
      We're currently generating the code for a one / not one / set ? quantifier (zero-or-one) as a loop, when it can actually just be a conditional check.  This adds a special path for that case.
      
      (I've also added another reduction test for alternation, and tweaked the codegen for a successful match to touch fields less.)
      dc173458
    • A
      JIT: check that constant handles are not OK2_CONST_LONGs (#1831) · c26a6534
      Andy Ayers 提交于
      Follow-up from #1788.
      
      Add padding to `AssertionDsc` so that the `iconFlags` no longer overlap with `lconVal`. Assert that `iconFlags` is never set for an O2K_CONST_LONG assertion.
      
      Also remove an arm-only handle block that should now be redundant.
      c26a6534