platform/upstream/dotnet/runtime.git
3 years agoUpdate license headers (#41783)
Jan Kotas [Thu, 3 Sep 2020 08:43:29 +0000 (01:43 -0700)]
Update license headers (#41783)

3 years ago[master] Update dependencies from mono/linker dotnet/arcade dotnet/runtime-assets...
dotnet-maestro[bot] [Thu, 3 Sep 2020 08:34:10 +0000 (08:34 +0000)]
[master] Update dependencies from mono/linker dotnet/arcade dotnet/runtime-assets dotnet/xharness dotnet/icu (#41591)

[master] Update dependencies from mono/linker dotnet/arcade dotnet/runtime-assets dotnet/xharness dotnet/icu
- Updates:
  - Microsoft.NET.ILLink.Tasks: from 6.0.0-alpha.1.20424.3 to 6.0.0-alpha.1.20451.1

- Updates:
  - Microsoft.DotNet.GenFacades: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.Build.Tasks.Feed: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.Build.Tasks.Packaging: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.Build.Tasks.SharedFramework.Sdk: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.Build.Tasks.TargetFramework.Sdk: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.CodeAnalysis: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.GenAPI: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.XUnitExtensions: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.Helix.Sdk: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.RemoteExecutor: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.VersionTools.Tasks: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.XUnitConsoleRunner: from 2.5.1-beta.20427.5 to 2.5.1-beta.20431.4
  - Microsoft.DotNet.Arcade.Sdk: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4
  - Microsoft.DotNet.ApiCompat: from 5.0.0-beta.20427.5 to 5.0.0-beta.20431.4

- Updates:
  - Microsoft.DotNet.XHarness.CLI: from 1.0.0-prerelease.20424.2 to 1.0.0-prerelease.20431.1
  - Microsoft.DotNet.XHarness.TestRunners.Xunit: from 1.0.0-prerelease.20424.2 to 1.0.0-prerelease.20431.1

- Updates:
  - Microsoft.NETCore.Runtime.ICU.Transport: from 6.0.0-alpha.1.20428.1 to 6.0.0-alpha.1.20451.1

- Updates:
  - System.ComponentModel.TypeConverter.TestData: from 5.0.0-beta.20426.1 to 5.0.0-beta.20451.1
  - System.Drawing.Common.TestData: from 5.0.0-beta.20426.1 to 5.0.0-beta.20451.1
  - System.IO.Compression.TestData: from 5.0.0-beta.20426.1 to 5.0.0-beta.20451.1
  - System.IO.Packaging.TestData: from 5.0.0-beta.20426.1 to 5.0.0-beta.20451.1
  - System.Net.TestData: from 5.0.0-beta.20426.1 to 5.0.0-beta.20451.1
  - System.Private.Runtime.UnicodeData: from 5.0.0-beta.20426.1 to 5.0.0-beta.20451.1
  - System.Security.Cryptography.X509Certificates.TestData: from 5.0.0-beta.20426.1 to 5.0.0-beta.20451.1
  - System.Windows.Extensions.TestData: from 5.0.0-beta.20426.1 to 5.0.0-beta.20451.1

 - fix Browser-related tests

3 years agolook for dhcp lease file in multiple locations (#41016)
Tomas Weinfurt [Thu, 3 Sep 2020 06:55:19 +0000 (23:55 -0700)]
look for dhcp lease file in multiple locations (#41016)

3 years agochar.IsAscii xml doc comments (#41753)
Günther Foidl [Thu, 3 Sep 2020 02:55:24 +0000 (04:55 +0200)]
char.IsAscii xml doc comments (#41753)

* char.IsAscii xml doc comments

* Update src/libraries/System.Private.CoreLib/src/System/Char.cs

Co-authored-by: Dan Moseley <danmose@microsoft.com>
3 years agoAdd LowLevelMonitor (#41736)
Jan Kotas [Thu, 3 Sep 2020 01:35:14 +0000 (18:35 -0700)]
Add LowLevelMonitor (#41736)

* Add LowLevelMonitor

* Fix style and bug

- Prevent CRITICAL_SECTION from moving by allocating it in unmanaged memory
- Refactor to match style used in the rest of System.Native
- Change LowLevelMonitor to struct to avoid unnecessary indirection

Co-authored-by: Koundinya Veluri <kouvel@users.noreply.github.com>
3 years agoWASM: Add SHA* hash functions (#40486)
Alexander Köplinger [Wed, 2 Sep 2020 21:23:26 +0000 (23:23 +0200)]
WASM: Add SHA* hash functions (#40486)

This ports the managed SHA* hash functions from https://github.com/microsoft/referencesource so we can use them on Browser/WASM where we don't have OpenSSL.

Enables the System.Security.Cryptography.Algorithms tests for these classes: `Tests run: 271, Errors: 0, Failures: 0, Skipped: 1. Time: 11.857137s`

Resolves https://github.com/dotnet/runtime/issues/40076

3 years agoFix cross-OS DAC metadata locator interface callback (#41746)
Mike McLaughlin [Wed, 2 Sep 2020 19:11:42 +0000 (12:11 -0700)]
Fix cross-OS DAC metadata locator interface callback (#41746)

3 years agofix version (#41729)
Anirudh Agnihotry [Wed, 2 Sep 2020 15:08:16 +0000 (08:08 -0700)]
fix version (#41729)

3 years agoAdd cache for Socket.LocalEndPoint (#39313)
Natalia Kondratyeva [Wed, 2 Sep 2020 13:51:53 +0000 (14:51 +0100)]
Add cache for Socket.LocalEndPoint (#39313)

Added _localEndPoint field to cache LocalEndPoint value. Cached value
is cleared on error and disconnect. If the value is a wildcard
address, it is also cleared on connect and accept.

Fix #1482

3 years agoCreate productVersion as part of BlobArtifacts; this is used later by the dotnet...
Matt Galbraith [Wed, 2 Sep 2020 13:34:46 +0000 (06:34 -0700)]
Create productVersion as part of BlobArtifacts; this is used later by the dotnet-install.* scripts (#41719)

3 years agoStrip binaries more aggressively (#41039)
Jan Vorlicek [Wed, 2 Sep 2020 09:21:09 +0000 (11:21 +0200)]
Strip binaries more aggressively (#41039)

* Strip binaries more aggressively

We are currently stripping only debug symbols, but there are also other
symbols that can be stripped without affecting debuggability or anything
else. We were stripping the binaries in corefx that way in the past,
but some time ago we have unified the stripping between the former
three repos and started to strip just the debugging symbols.

This change strips all unneeded symbols, which results in significant
reduction of the binaries sizes. For example, libcoreclr.so went down
from 8732272 to 7027024 or libSystem.Security.Cryptography.Native.OpenSsl.so
went down from 163376 to 120952.

* Fix FreeBSD

* Fix FreeBSD and OSX

We use nm command to extract g_dacTable symbol value from libcoreclr
for the DAC purposes. On OSX, there are no dynamic symbols, on
FreeBSD, the stripping strips all regular symbols and leaves
dynamic ones only. So the nm needs to get a -D argument for
non OSX.

3 years agoFix multiple version strings in coreclr shared libraries (#41711)
Jan Vorlicek [Wed, 2 Sep 2020 08:51:44 +0000 (10:51 +0200)]
Fix multiple version strings in coreclr shared libraries (#41711)

We were incorrectly adding the version.c source to all coreclr
libraries and not just the shared ones. That caused multiple
occurences of the version string in coreclr shared libraries
composed of sublibraries.
This change fixes it by adding that source file for shared
libraries only.
I've also discovered that libcoreclrtraceptprovider.so was
missing the version string completely, so I've added it there.

3 years agoDelete multi-byte related functions from PAL (#41611)
Adeel Mujahid [Wed, 2 Sep 2020 03:25:22 +0000 (06:25 +0300)]
Delete multi-byte related functions from PAL (#41611)

* Delete multi-byte related functions from PAL

In PAL, delete:
* `IsDBCSLeadByte`; unimplemented.
* `IsDBCSLeadByteEx`; no-op.
* `GetCPInfo`; has hardcoded length of 4, and the only usage checks for
  `length == 1`.
* `_mbsinc`; has one usage in ilasm, which is simplified for Unix
  (after the removal of above).
* `_mbsninc`; unused.
* `_mbsdec`; usage is inlined as `p--` because `IsDBCSLeadByteEx` is a
  no-op.
* `GetCaseInsensitiveValueA`, handle ANSI cases as Unicode.
* `IsTextUnicode`, single usage in ilasm is inlined.

* Delete _MBCS, _ismbblead and simplifications

* Delete trailing whitespaces from PR file changed

3 years agoRemove System.Net.Connections and related features (#41648)
Geoff Kizer [Wed, 2 Sep 2020 02:31:14 +0000 (19:31 -0700)]
Remove System.Net.Connections and related features (#41648)

* remove System.Net.Connections and related features

* cleanup csproj changes

* Update src/libraries/pkg/baseline/packageIndex.json

Co-authored-by: Cory Nelson <phrosty@gmail.com>
* Update src/libraries/System.Net.Sockets/src/System/Net/Sockets/Socket.Tasks.cs

Co-authored-by: Cory Nelson <phrosty@gmail.com>
Co-authored-by: Geoffrey Kizer <geoffrek@windows.microsoft.com>
Co-authored-by: Cory Nelson <phrosty@gmail.com>
3 years agoFix issue with covariant return method validation (#41703)
Jan Vorlicek [Wed, 2 Sep 2020 01:12:28 +0000 (03:12 +0200)]
Fix issue with covariant return method validation (#41703)

The ClassLoader::ValidateMethodsWithCovariantReturnTypes was being called
from a place where the relevant types were sometimes not fully loaded yet.
That resulted in an attempt to load the type being loaded recursively,
which was detected and the TypeLoadException was thrown.
This change fixes it by moving the call to the
ClassLoader::ValidateMethodsWithCovariantReturnTypes to the PushFinalLevels
when the level is greater than CLASS_LOAD_EXACTPARENTS, which is the
last stage of normal loading.

3 years agofree existingTrust when verifying certificate name on macOS (#41657)
Tomas Weinfurt [Wed, 2 Sep 2020 00:35:25 +0000 (17:35 -0700)]
free existingTrust when verifying certificate name on macOS (#41657)

* free existingTrust when verifying certificate name

* add back NL

* free existingTrust on error path as well

3 years agoUse dynamic port for BrowserDebugHost process (#41688)
Safia Abdalla [Tue, 1 Sep 2020 23:09:51 +0000 (23:09 +0000)]
Use dynamic port for BrowserDebugHost process (#41688)

3 years agoRemove unused USE_REFEMIT define in System.Private.DataContractSerialization (#41664)
Seonyoung Park [Tue, 1 Sep 2020 22:39:37 +0000 (07:39 +0900)]
Remove unused USE_REFEMIT define in System.Private.DataContractSerialization (#41664)

3 years ago[interp] Optimize out conditional branches (#41628)
monojenkins [Tue, 1 Sep 2020 21:01:53 +0000 (17:01 -0400)]
[interp] Optimize out conditional branches (#41628)

If we know the values of the arguments of a conditional branch, replace it with an unconditional branch. Once we have support for basic blocks, we can remove dead basic blocks and merge any adjacent ones.

Co-authored-by: BrzVlad <BrzVlad@users.noreply.github.com>
3 years agoBlock casting to an interface marked ComInterfaceType.InterfaceIsIInspectable (#41633)
Jeremy Koritzinsky [Tue, 1 Sep 2020 20:35:56 +0000 (13:35 -0700)]
Block casting to an interface marked ComInterfaceType.InterfaceIsIInspectable (#41633)

3 years agoAdd methods to manipulate Half in binary (#40882)
Huo Yaoyuan [Tue, 1 Sep 2020 20:17:28 +0000 (04:17 +0800)]
Add methods to manipulate Half in binary (#40882)

* Expose HalfToInt16Bits and Int16BitsToHalf.

* Use HalfToInt16Bits and Int16BitsToHalf in tests.

* Add and expose BinaryPrimitive Half overloads.

* Test BinaryPrimitive Half overloads.

* Add and expose BinaryReader/Writer Half overloads.

* Test BinaryReader/Writer Half overloads.

Co-authored-by: Jan Kotas <jkotas@microsoft.com>
3 years agoInclude CrossOs diagnostic assets for signing (#41655)
Juan Hoyos [Tue, 1 Sep 2020 18:56:58 +0000 (11:56 -0700)]
Include CrossOs diagnostic assets for signing (#41655)

* Include CrossOs diagnostic assets for signing

Co-authored-by: Santiago Fernandez Madero <safern@microsoft.com>
3 years agoAdd SafeBuffer Span<T> methods (#40842)
Huo Yaoyuan [Tue, 1 Sep 2020 16:48:13 +0000 (00:48 +0800)]
Add SafeBuffer Span<T> methods (#40842)

* Implement SafeBuffer.ReadSpan and WriteSpan.

* Add reference source for SafeBuffer.

* Add empty span test for SafeBuffer.

* Add roundtrip tests for SafeBuffer.

Co-authored-by: Jan Kotas <jkotas@microsoft.com>
3 years agoAdd Support to ActivitySource events in DiagnosticSourceEventSource (#41641)
Tarek Mahmoud Sayed [Tue, 1 Sep 2020 16:38:28 +0000 (09:38 -0700)]
Add Support to ActivitySource events in DiagnosticSourceEventSource (#41641)

3 years agoSafeSocketHandle: avoid potential blocking of finalizer thread (#41508)
Tom Deseyn [Tue, 1 Sep 2020 12:42:47 +0000 (14:42 +0200)]
SafeSocketHandle: avoid potential blocking of finalizer thread (#41508)

* SafeSocketHandle: avoid potential blocking of finalizer thread

When the Socket is Disposed, it attempts to make all on-going operations
abort. It does this in a loop, and decides there are no on-going operations
when the reference count becomes zero and the handle gets released.

SafePipeHandle holds a reference to SafeSocketHandle. This prevents the
reference count to drop to zero, and causes the dispose to loop infinitly.

When the Socket is disposed from the finalizer thread, it is no longer used
for operations and we can skip the loop. This avoids blocking the finalizer
thread when the reference count can't drop to zero.

* When disposing from finalizer, fall back to ReleaseHandle

* Add test

* PR feedback

* Fix test

* PR feedback

* Refactor

* Refactor

* Log call to _handle.Dispose

* Handle null handle

3 years agoFix issue 41413 (#41445)
Peter Sollich [Tue, 1 Sep 2020 10:23:21 +0000 (12:23 +0200)]
Fix issue 41413 (#41445)

Fix the AV issue in GCHeap::ApproxTotalBytesInUse:

- The AV is fixed by stopping the iteration when seg1 becomes null
- don't count segments that have been decommited
- stop iterating when seg1 becomes freeable_soh_segment - this takes care of the case where we have put a segment on the list, but the OS call to decommit hasn't come back.

These fixes will still leave a window where the result will be inaccurate. To reduce the chances of an inaccurate result, we try this 3 times.

3 years agoRemove dead files from System.Private.DataContractSerialization (#41646)
Eric Erhardt [Tue, 1 Sep 2020 04:59:44 +0000 (23:59 -0500)]
Remove dead files from System.Private.DataContractSerialization (#41646)

These files have been moved to System.Runtime.Serialization.Primitives and were left over here. They aren't part of any .csproj, so they are not being compiled.

3 years agoAdd assert to verify the correctness of the GCRefMap pulled from an R2R image (#41544)
David Wrighton [Tue, 1 Sep 2020 03:02:37 +0000 (20:02 -0700)]
Add assert to verify the correctness of the GCRefMap pulled from an R2R image (#41544)

3 years agoSearch libgdiplus in /usr/local/lib on macOS (#41503)
Adeel Mujahid [Tue, 1 Sep 2020 02:58:52 +0000 (05:58 +0300)]
Search libgdiplus in /usr/local/lib on macOS (#41503)

With Apple's Hardened Runtime, `/usr/local/lib` is not searched for
`dlopen(3)` calls.

Today, some brew packages, such as `mono-libgdiplus` (used by
System.Drawing) are installed in `/usr/local/lib`. This causes
`DllNotFoundException` and user is supposed to either:

1. manually create a symlink to `/usr/local/lib/libgdiplus.dylib`.
2. export `LD_LIBRARY_PATH`, `DYLD_LIBRARY_PATH` or
  `DYLD_FALLBACK_LIBRARY_PATH` to `/usr/local/lib`.
3. remove signature from dotnet binary:
  `sudo codesign --remove-signature $(command -v dotnet)`

This patch adds a fallback lookup for libgdiplus.dylib, to avoid
workaround on macOS (as it is done for Linux: `libgdiplus.so` falls
back to `libgdiplus.so.0`).

Also removed `LIBSEARCHPATH` which is unused since 8d5e610.

3 years agoObsolete Uri.EscapeUriString (#41501)
Jan Jahoda [Tue, 1 Sep 2020 02:56:29 +0000 (04:56 +0200)]
Obsolete Uri.EscapeUriString (#41501)

* Obsolete Uri.EscapeUriString

* Fix tests

Co-authored-by: Adeel Mujahid <adeelbm@outlook.com>
3 years agoFix infinite recursion in configuration manager (#41638)
Santiago Fernandez Madero [Tue, 1 Sep 2020 02:45:04 +0000 (19:45 -0700)]
Fix infinite recursion in configuration manager (#41638)

* Revert "Remove unused local in System.Configuration.ConfigurationManager (#40583)"

This reverts commit a4eba0a0e1ecb31b7cb3482509bd461c8e9f5ccf.

* Rename unused variable and add regression test

Co-authored-by: Eric Erhardt <eric.erhardt@microsoft.com>
3 years ago[RyuJIT] Avoid emitting cdq/coq for a positive constant in rax for idiv (#41551)
Egor Bogatov [Tue, 1 Sep 2020 02:43:25 +0000 (05:43 +0300)]
[RyuJIT] Avoid emitting cdq/coq for a positive constant in rax for idiv (#41551)

* avoid emitting cdq/coq for dividend if it's a positive constant

3 years agoFix palsuite build (#41622)
Adeel Mujahid [Tue, 1 Sep 2020 01:30:31 +0000 (04:30 +0300)]
Fix palsuite build (#41622)

Error 1
```sh
   CMake Error at src/pal/tests/palsuite/exception_handling/pal_sxs/test1/CMakeLists.txt:22 (set_exports_linker_option):
    set_exports_linker_option Function invoked with incorrect arguments for
    function named: set_exports_linker_option
```
Error 2
```sh
  [ 23%] Building CXX object src/vm/wks/CMakeFiles/cee_wks_core.dir/__/debugdebugger.cpp.o
  In file included from /Users/am11/projects/runtime_base/src/coreclr/src/pal/tests/palsuite/c_runtime/acosf/test1/test1.c:17:
  In file included from /Users/am11/projects/runtime_base/src/coreclr/src/pal/tests/palsuite/common/palsuite.h:24:
  /Users/am11/projects/runtime_base/src/coreclr/src/pal/inc/pal.h:379:28: error: unknown type name 'bool'
      const char *szExePath, bool runningInExe);
                             ^
  1 error generated.
```

3 years agoOptimize out gc polls in basic blocks with regular PInvokes (#41581)
Jan Kotas [Tue, 1 Sep 2020 01:18:23 +0000 (18:18 -0700)]
Optimize out gc polls in basic blocks with regular PInvokes (#41581)

Regular PInvokes poll for GC. It means that the explicit gc polls can be skipped in basic blocks that contain regular PInvoke.

3 years agoAdd nullable annotations for XmlDataDocument (#41541)
Immo Landwerth [Tue, 1 Sep 2020 01:09:41 +0000 (18:09 -0700)]
Add nullable annotations for XmlDataDocument (#41541)

* Add nullable annotations for XmlDataDocument

* Address code review feedback

* More code review feedback

* Address Eric's feedback

* Annotate _dataSet as not null when AttachDataSet is called

* Fix GetElementById return type annotation

In order to match with src

Co-authored-by: Jeff Handley <jeff.handley@microsoft.com>
Co-authored-by: David Cantú <dacantu@microsoft.com>
3 years agoUpdating ref source documentation for full facades (#41629)
Eric Erhardt [Tue, 1 Sep 2020 00:56:28 +0000 (19:56 -0500)]
Updating ref source documentation for full facades (#41629)

3 years agoAdd TypeConverterAttribute to IListSource (#41634)
Eric StJohn [Mon, 31 Aug 2020 23:46:39 +0000 (16:46 -0700)]
Add TypeConverterAttribute to IListSource (#41634)

3 years agoAdd docs link to editing-and-debugging (#41636)
Andy Gocke [Mon, 31 Aug 2020 22:42:51 +0000 (15:42 -0700)]
Add docs link to editing-and-debugging (#41636)

We were missing a link to the Editing and Debugging doc from the main workflow doc.

3 years agoRenable AddMethodBody tests (#41613)
Eric StJohn [Mon, 31 Aug 2020 20:58:16 +0000 (13:58 -0700)]
Renable AddMethodBody tests (#41613)

3 years agomake cns_str indirect loads invariant (#40898)
Egor Bogatov [Mon, 31 Aug 2020 20:47:11 +0000 (23:47 +0300)]
make cns_str indirect loads invariant (#40898)

3 years agoMade char.IsAscii public (#41396)
Günther Foidl [Mon, 31 Aug 2020 20:21:36 +0000 (22:21 +0200)]
Made char.IsAscii public (#41396)

3 years ago[mono] Add mono_image_open_from_data_alc to unstable embedding API (#41334)
Ryan Lucia [Mon, 31 Aug 2020 18:53:38 +0000 (14:53 -0400)]
[mono] Add mono_image_open_from_data_alc to unstable embedding API (#41334)

3 years ago[wasm][debugger] Breakpoint stopping after it's removed (#41479)
Thays Grazia [Mon, 31 Aug 2020 17:30:50 +0000 (14:30 -0300)]
[wasm][debugger] Breakpoint stopping after it's removed (#41479)

* Remove unnecessary WriteLine.
Fix #41447.

* Creating unit test about remove breakpoint.

* Implementing @radical suggestions!

3 years agoAdd Request/Response Headers/Content Start/Stop events (#41590)
Miha Zupan [Mon, 31 Aug 2020 16:45:15 +0000 (18:45 +0200)]
Add Request/Response Headers/Content Start/Stop events (#41590)

3 years agoHTTP 1.1 stress test steps (#41592)
Alexander Nikolaev [Mon, 31 Aug 2020 16:31:08 +0000 (18:31 +0200)]
HTTP 1.1 stress test steps (#41592)

Adds HTTP 1.1 steps to http-stress pipeline.

3 years ago[wasm] Disable an extraneous debug message (#41468)
Ankit Jain [Mon, 31 Aug 2020 14:26:34 +0000 (10:26 -0400)]
[wasm] Disable an extraneous debug message (#41468)

Recent debugger test runs were showing lot of
`CWL: Failed to lookup sequence point` messages.

These are being shown for cases like:

`CWL: list_frames: Failed to lookup sequence point. method: runtime_invoke_direct_void, native_offset: 56`

This is a warning, and doesn't need to be emitted by default.

3 years ago[wasm][debugger] Correctly handle empty, and whitespace-only strings (#41424)
Ankit Jain [Mon, 31 Aug 2020 14:21:04 +0000 (10:21 -0400)]
[wasm][debugger] Correctly handle empty, and whitespace-only strings (#41424)

There are two cases being fixed here:

1. str=='', or str=' '
- We check `str_value == 0`, and for the above cases JS returns
true, due to type coercion.
- So, we show the result as a null string.

2. str==null
- debugger.c adds the value for this with `mono_wasm_add_typed_value ("string", NULL, 0)`
- the second argument is converted to a string with
  `Module.UTF8ToString(..)`, but when it's `0`/NULL, we get an
  empty string. And that becomes a null string, because of (1).

Fixing this by using `===` operator to avoid type coercion.

Fixes https://github.com/dotnet/runtime/issues/41276

3 years agoFix issue 41311 - Assert failure ephemeral_heap_segment->saved_committed == heap_segm...
Peter Sollich [Mon, 31 Aug 2020 13:17:56 +0000 (15:17 +0200)]
Fix issue 41311 - Assert failure ephemeral_heap_segment->saved_committed == heap_segment_committed (#41441)

This is an interaction problem between gradual decommit and entering a no GC region.

Details:
 - When we enter a no GC region, we are manipulating our commit goals outside of GC, we usually are planning to commit more, so it makes sense to stop any gradual decommit in progress.
- Even if we need to do a GC in preparation for a no GC region, any decommit target established by decommit_ephemeral_segment_pages is likely to be invalid, so we do an early out.
- add an assert to grow_heap_segment so we can catch future issues in this area better.

We may want to trigger the gradual decommit logic in set_allocations_for_no_gc if we discover that after accounting for the planned allocation, we still have substantial decommits. I'm leaving this for a later PR though.

3 years agomono: result of regmask should be stored in regmask_t, not int (#41543)
monojenkins [Mon, 31 Aug 2020 13:12:59 +0000 (09:12 -0400)]
mono: result of regmask should be stored in regmask_t, not int (#41543)

While unlikely in practice, architectures with more than 32 registers would be affected by this as `sizeof(regmask_t) ==8` && `sizeof(int) == 4`.

Run into this while debugging something unrelated.

Co-authored-by: skmp <skmp@users.noreply.github.com>
3 years agoMoved HTTP request telemetry to HttpClient.SendAsync (#41022)
Marie Píchová [Mon, 31 Aug 2020 09:28:27 +0000 (11:28 +0200)]
Moved HTTP request telemetry to HttpClient.SendAsync (#41022)

* Moved HTTP request telemetry to HttpClient.SendAsync

* Added ResponseContent and helper methods events.

* Rework helper method activity nesting

* Expand Telemetry tests

* Also log RequestStart/Stop in HttpMessageInvoker

* Update RequestStart signature

* RequestAborted => RequestFailed rename

* ResponseContent Begin => Start/Stop

* Fix HttpMessageInvoker implementation

* Add Synchronous request Telemetry tests

* Check telemetryStarted before ResponseContentStart

Co-authored-by: MihaZupan <mihazupan.zupan1@gmail.com>
3 years agoAdd 32/8 bit values of exit codes (#41566)
eli-fin [Mon, 31 Aug 2020 09:02:16 +0000 (12:02 +0300)]
Add 32/8 bit values of exit codes (#41566)

This will make searching for the exit code a little easier

Co-authored-by: Eli Finkel <Eli.Finkel@checkmarx.com>
3 years agoUpdate perf docs (#41583)
Adam Sitnik [Mon, 31 Aug 2020 08:32:51 +0000 (10:32 +0200)]
Update perf docs (#41583)

* mention benchmarking and profiling in the workflow description

* remove a very general doc about PerfView which was not refferenced by other docs

* update the performance-guidelines.md doc

3 years agoOptimize Half.Equals (#41554)
Huo Yaoyuan [Mon, 31 Aug 2020 07:08:21 +0000 (15:08 +0800)]
Optimize Half.Equals (#41554)

3 years ago[MIPS32] Fix mono_arch_get_cie_program and ELF_MACHINE undefined issue (#41546)
monojenkins [Sun, 30 Aug 2020 16:17:18 +0000 (12:17 -0400)]
[MIPS32] Fix mono_arch_get_cie_program and ELF_MACHINE undefined issue (#41546)

Hi,

Cross compile for MIPS32:

```
CC=mips-linux-gnu-gcc CFLAGS="-I./libatomic_ops/src" ./autogen.sh --host=mips-linux-gnu --prefix=/home/zhaixiang/mono-mips32-git
make
make install
```

And HelloWorld testcase PASSED:

```
$ ./mono-mips32-git/bin/mono HelloWorld/bin/Debug/netcoreapp3.0/HelloWorld.dll
Hello World!
```

Thanks,
Leslie Zhai

Co-authored-by: xiangzhai <xiangzhai@users.noreply.github.com>
3 years agoPass Configuration to cmake. Use -Os on wasm. (#41550)
Zoltan Varga [Sun, 30 Aug 2020 10:25:55 +0000 (06:25 -0400)]
Pass Configuration to cmake. Use -Os on wasm. (#41550)

3 years ago[master] Update dependencies from dotnet/arcade Microsoft/vstest dotnet/runtime-asset...
dotnet-maestro[bot] [Sun, 30 Aug 2020 09:54:11 +0000 (09:54 +0000)]
[master] Update dependencies from dotnet/arcade Microsoft/vstest dotnet/runtime-assets dotnet/xharness dotnet/icu (#41322)

[master] Update dependencies from dotnet/arcade Microsoft/vstest dotnet/runtime-assets dotnet/xharness dotnet/icu
- Updates:
  - System.ComponentModel.TypeConverter.TestData: from 5.0.0-beta.20420.1 to 5.0.0-beta.20426.1
  - System.Drawing.Common.TestData: from 5.0.0-beta.20420.1 to 5.0.0-beta.20426.1
  - System.IO.Compression.TestData: from 5.0.0-beta.20420.1 to 5.0.0-beta.20426.1
  - System.IO.Packaging.TestData: from 5.0.0-beta.20420.1 to 5.0.0-beta.20426.1
  - System.Net.TestData: from 5.0.0-beta.20420.1 to 5.0.0-beta.20426.1
  - System.Private.Runtime.UnicodeData: from 5.0.0-beta.20420.1 to 5.0.0-beta.20426.1
  - System.Security.Cryptography.X509Certificates.TestData: from 5.0.0-beta.20420.1 to 5.0.0-beta.20426.1
  - System.Windows.Extensions.TestData: from 5.0.0-beta.20420.1 to 5.0.0-beta.20426.1

- Updates:
  - Microsoft.DotNet.XHarness.CLI: from 1.0.0-prerelease.20424.1 to 1.0.0-prerelease.20424.2
  - Microsoft.DotNet.XHarness.TestRunners.Xunit: from 1.0.0-prerelease.20424.1 to 1.0.0-prerelease.20424.2

- Updates:
  - Microsoft.NETCore.Runtime.ICU.Transport: from 5.0.0-preview.8.20421.1 to 6.0.0-alpha.1.20428.1

- Updates:
  - Microsoft.DotNet.GenFacades: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.Build.Tasks.Feed: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.Build.Tasks.Packaging: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.Build.Tasks.SharedFramework.Sdk: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.Build.Tasks.TargetFramework.Sdk: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.CodeAnalysis: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.GenAPI: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.XUnitExtensions: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.Helix.Sdk: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.RemoteExecutor: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.VersionTools.Tasks: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.XUnitConsoleRunner: from 2.5.1-beta.20419.21 to 2.5.1-beta.20427.5
  - Microsoft.DotNet.Arcade.Sdk: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5
  - Microsoft.DotNet.ApiCompat: from 5.0.0-beta.20419.21 to 5.0.0-beta.20427.5

- Updates:
  - Microsoft.NET.Test.Sdk: from 16.8.0-release-20200821-04 to 16.8.0-release-20200828-02

 - fix TestFirstYearOfJapaneseEra test on Browser platform

3 years ago[mono] Squelch Mach exception handlers (#41536)
monojenkins [Sat, 29 Aug 2020 18:23:12 +0000 (14:23 -0400)]
[mono] Squelch Mach exception handlers (#41536)

Work around LLDB's unconditionally-installed and inflexible Mach
exception handler by installing a no-op task-wide Mach exception
handler.

See also:
- https://github.com/openjdk/jdk/blob/50cc54c730bb0f130991648d1547d42483edddc1/src/hotspot/os/bsd/os_bsd.cpp#L2810-L2817
- https://github.com/mono/mono/issues/10180#issuecomment-683119507

Co-authored-by: imhameed <imhameed@users.noreply.github.com>
3 years agoFix comments calling surrogate halves low surrogates (#41545)
Serentty [Sat, 29 Aug 2020 18:14:43 +0000 (14:14 -0400)]
Fix comments calling surrogate halves low surrogates (#41545)

I think these comments were copied and pasted and someone forgot to modify them.

3 years agoFix a race condition in GCStress (#41540)
Bruce Forstall [Sat, 29 Aug 2020 17:22:20 +0000 (10:22 -0700)]
Fix a race condition in GCStress (#41540)

Consider the case of a partially interruptible function where we've replaced
each call site with INTERRUPT_INSTR_CALL or INTERRUPT_INSTR_CALL_32. Even
though the call site itself isn't a safe point, we put a GCStress instruction
there so we can capture the call target at GC stress time, then set a specific
GCStress instruction for the next instruction that will indicate how to GC
protect any GC refs that are returned from the call.

Multiple threads can enter `DoGcStress` at the same time. They all get just
past the race check `if (!IsGcCoverageInterruptInstruction(instrPtr)) return;`.
One goes ahead, and reads the instruction code for the address at which we're
doing a GCStress. We set `atCall` to `true` if this matches one of our known
GCStress instructions for partially-interruptible call sites. Later, if
`atCall` is `true`, we write the original call instruction back to the code
stream, write the distinguished next instruction GCStress instruction, and
continue. If the other threads then read at the instruction address, they
might read the actual call opcode, not the distinguished GCStress breakpoint
instruction code. Then, they will set `atCall` to `false`. This will indicate
that we are in a fully-interruptible location, or that no special call-site
behavior is required. We go on, force a GC, and eventually get to the assert
in `EECodeManager::EnumGcRefs` that we are at a GC safe point.

The solution is to simply move the `if (!IsGcCoverageInterruptInstruction(instrPtr))`
check below the read of `*instrPtr` to set `atCall`.

Re-enable the GitHub_27924 test.

Fixes #36681

3 years agoarea-owners.md: Add @radical for debugger-mono (#41425)
Ankit Jain [Sat, 29 Aug 2020 09:59:41 +0000 (05:59 -0400)]
area-owners.md: Add @radical for debugger-mono (#41425)

3 years ago[runtime] Fix signature of mini_cleanup (). (#41510)
Zoltan Varga [Sat, 29 Aug 2020 08:04:54 +0000 (04:04 -0400)]
[runtime] Fix signature of mini_cleanup (). (#41510)

Fixes https://github.com/dotnet/runtime/issues/41470.

3 years agoFix reading cpu cache size for Alpine(musl) (#41532)
Manish Godse [Sat, 29 Aug 2020 05:17:01 +0000 (22:17 -0700)]
Fix reading cpu cache size for Alpine(musl) (#41532)

* Fix reading cpu cache size for Alpine(musl)

* limiting the fallback to Linux only

* exclude ARM

* fixing copy-paste error

3 years agoSystem.Net Telemetry style changes (#41527)
Miha Zupan [Sat, 29 Aug 2020 00:46:03 +0000 (02:46 +0200)]
System.Net Telemetry style changes (#41527)

* Change HandshakeStop SslProtocols parameter to enum

* Parameterize Http11/Http20 events

* Add dummy request to ensure Http2 settings are received

3 years agoNullable annotations for System.Runtime.Serialization.Xml and System.Runtime.Serializ...
Eric Erhardt [Fri, 28 Aug 2020 21:55:24 +0000 (16:55 -0500)]
Nullable annotations for System.Runtime.Serialization.Xml and System.Runtime.Serialization.Json (#41476)

* Initial nullable annotations of System.Private.DataContractSerialization

Contributes to #2339

* Mark DataMember.Name as non-nullable.

* Fix a few simple nullable compile errors.

* Assert attributes is non-null in XmlObjectSerializerReadContext

* Ensure XmlObjectSerializerContext.serializer is never null

* Fix a few simple nullable errors

* Remove any checks that DataMember.MemberInfo can be null.

* Mark EnumDataContract.Members as non-nullable.

Fix nullable errors in SchemaExporter.

* Correctly annotate CollectionDataContract.IsCollectionOrTryCreate.

* Assert DataContractResolver is non-null.

* Suppress https://github.com/dotnet/runtime/issues/41465

* Update System.Runtime.Serialization.Json ref source for nullable annotations.

* Update System.Runtime.Serializaiton.Xml ref source for nullable annotations.

* Update for Xml.ReaderWriter nullable annotations

* Work around compiler issue.

* Fix test failure.

Reference compiler issue in TODO comment.

* Revert nullable suppression now that XmlSchemaAppInfo.Markup is annotated correctly.

* Fix build for latest annotations in master.

* PR feedback round 1

* Address PR feedback round 2

3 years agoModfiy ErrorHandlingTests for Browser (#40659)
Mitchell Hwang [Fri, 28 Aug 2020 21:29:35 +0000 (17:29 -0400)]
Modfiy ErrorHandlingTests for Browser (#40659)

Co-authored-by: Mitchell Hwang <mitchell.hwang@microsoft.com>
3 years agoDo not add bundle deps file to APP_CONTEXT_DEPS_FILES on single-file apps (#41430)
Mateo Torres-Ruiz [Fri, 28 Aug 2020 20:57:39 +0000 (13:57 -0700)]
Do not add bundle deps file to APP_CONTEXT_DEPS_FILES on single-file apps (#41430)

* App Context deps file should be empty for single file apps

3 years agoUpdate IgnoreNullValues obsoletion message (#41141)
Layomi Akinrinade [Fri, 28 Aug 2020 20:39:17 +0000 (13:39 -0700)]
Update IgnoreNullValues obsoletion message (#41141)

* Update IgnoreNullValues obsoletion message

* Add attributes to ref file

3 years agoUpdate excluded tests list for WASM (#41415)
Fan Yang [Fri, 28 Aug 2020 18:40:43 +0000 (14:40 -0400)]
Update excluded tests list for WASM (#41415)

* Check runtime test failures on WASM

* Modify ExcludeList for wasm to exclude only failed tests

* Revert the change to runtime.yml

* Update runtime.yml

3 years agofixed issue 36752 mail address display name (#37874)
jaymin93 [Fri, 28 Aug 2020 18:21:27 +0000 (23:51 +0530)]
fixed issue 36752 mail address display name (#37874)

Co-authored-by: Marie Píchová <11718369+ManickaP@users.noreply.github.com>
Co-authored-by: Karel Zikmund <karelz@microsoft.com>
3 years agoObsolete WebRequest, ServicePoint and WebClient (#41400)
Jan Jahoda [Fri, 28 Aug 2020 17:49:52 +0000 (19:49 +0200)]
Obsolete WebRequest, ServicePoint and WebClient (#41400)

* Obsolete WebRequest, ServicePoint and WebClient

* Update src/libraries/Common/src/System/Obsoletions.cs

Co-authored-by: Cory Nelson <phrosty@gmail.com>
* Remove obsoletion from FileWebRequest

* Add refs assemblies obsoletion

* Add missing attribute

* Add missing attribute

* Suppress warning for System.Media.SoundPlayer

* Change message id

Co-authored-by: Jan Jahoda <jajahoda@.microsoft.com>
Co-authored-by: Cory Nelson <phrosty@gmail.com>
3 years agoMake gc/vxsort/isa_detection.cpp portable (#41517)
Jan Kotas [Fri, 28 Aug 2020 17:13:47 +0000 (10:13 -0700)]
Make gc/vxsort/isa_detection.cpp portable (#41517)

Fixes #41515

3 years agoBump emscripten version to 2.0.1 (#41509)
Alexander Köplinger [Fri, 28 Aug 2020 15:19:12 +0000 (17:19 +0200)]
Bump emscripten version to 2.0.1 (#41509)

Updates the emscripten Docker container we use to build in CI. We no longer need to explicitly set `EMSDK_PATH` since the container already does it.
Also remove `--embedded` flag from `./emsdk activate` since it was deprecated and is now the default.

3 years agoClient side logging for HTTP stress. (#41444)
Marie Píchová [Fri, 28 Aug 2020 13:31:29 +0000 (15:31 +0200)]
Client side logging for HTTP stress. (#41444)

3 years agoFixes Windows docker debug prints. (#41443)
Marie Píchová [Fri, 28 Aug 2020 11:56:31 +0000 (13:56 +0200)]
Fixes Windows docker debug prints. (#41443)

3 years agoBump the local emscripten version to 2.0.1. (#41504)
Zoltan Varga [Fri, 28 Aug 2020 11:53:08 +0000 (07:53 -0400)]
Bump the local emscripten version to 2.0.1. (#41504)

3 years agomono.proj: properly pass -mmacosx-version-min to CFLAGS for OSX (#41433)
Alexander Köplinger [Fri, 28 Aug 2020 11:51:20 +0000 (13:51 +0200)]
mono.proj: properly pass -mmacosx-version-min to CFLAGS for OSX (#41433)

Noticed we were missing this while looking at another PR.

3 years agoPort nullability annotations from System.Private.Xml.Linq to contracts (#41086)
David Cantú [Fri, 28 Aug 2020 10:15:15 +0000 (03:15 -0700)]
Port nullability annotations from System.Private.Xml.Linq to contracts (#41086)

* Enable nullability on System.Xml.XPath.XDocument src

* Port nullability annotations to System.Xml.XPath.XDocument

* Port nullability annotations to System.Xml.XDocument

* Add ? to XmlAttribute argument in int? explicit operator

3 years agoPort nullability annotations to refs XmlDocument and XmlSerializer (#41474)
David Cantú [Fri, 28 Aug 2020 09:58:46 +0000 (02:58 -0700)]
Port nullability annotations to refs XmlDocument and XmlSerializer (#41474)

* Port nullability annotations to refs XmlDocument and XmlSerializer

* Fix new System.Data.Common nullability related errors

* Switch nullability of parameter in SoapElementAttribute ctor

3 years ago[wasm][debugger] Make sure `System.Private.CoreLib.dll` is in sync with (#41469)
Ankit Jain [Fri, 28 Aug 2020 08:08:00 +0000 (04:08 -0400)]
[wasm][debugger] Make sure `System.Private.CoreLib.dll` is in sync with (#41469)

.. it's pdb. Running debugger-tests, I saw lot of messages like:

`CWL: : /Users/radical/dev/runtime/src/mono/mono/metadata/debug-mono-ppdb.c:230 <disabled>`

.. which is trying to print:
`CWL: Symbol file data-0x1c38008 doesn't match image System.Private.CoreLib.dll`

And indeed the dll is out of sync with it's pdb. We need to copy the pdb
too.

3 years agoSwitch Markup property to XmlNode?[]? to reflect it can contain null elements (#41488)
David Cantú [Fri, 28 Aug 2020 06:47:24 +0000 (23:47 -0700)]
Switch Markup property to XmlNode?[]? to reflect it can contain null elements (#41488)

* Switch Markup property to XmlNode?[]? to reflect it can contain null elements

* Update ref

3 years agoRemove if-def from JSON ref file previously used to support linker attributes (#41484)
Layomi Akinrinade [Fri, 28 Aug 2020 01:14:55 +0000 (18:14 -0700)]
Remove if-def from JSON ref file previously used to support linker attributes (#41484)

* Remove if-def from JSON ref file previously used to support linker attributes

* Run GenerateReferenceSource target on ref project

3 years agoimprove InitializeCurrentThread (#41440)
Egor Bogatov [Fri, 28 Aug 2020 00:26:06 +0000 (03:26 +0300)]
improve InitializeCurrentThread (#41440)

3 years agoFix perf token (#41345)
Olivia Chen [Fri, 28 Aug 2020 00:22:43 +0000 (17:22 -0700)]
Fix perf token (#41345)

* remove semicolon from upload token

* will revert - test private commands

* remove condition

* add debug code

* add dump task

* comment out internal param

* rename helixprecommands to sharedhelixprecommands

* update and revert for check-in

3 years agoSwitch text param to nullable in WriteProcessingInstructionAsync (#41481)
David Cantú [Thu, 27 Aug 2020 23:54:03 +0000 (16:54 -0700)]
Switch text param to nullable in WriteProcessingInstructionAsync (#41481)

3 years agoClean up changes in #40914 (#41427)
Layomi Akinrinade [Thu, 27 Aug 2020 22:55:23 +0000 (15:55 -0700)]
Clean up changes in #40914 (#41427)

* Fixup JSON equality checks in polymorphic converter tests

* Limit deserialization value validation to custom _polymorphic_ converters

3 years agoUpdate SYSLIB0012 obsoletion messages to be clear and consistent (#41467)
Jeff Handley [Thu, 27 Aug 2020 22:25:49 +0000 (15:25 -0700)]
Update SYSLIB0012 obsoletion messages to be clear and consistent (#41467)

3 years agoadd tracing to Decryp to complement tracing in Encrypt (#40998)
Tomas Weinfurt [Thu, 27 Aug 2020 20:17:14 +0000 (13:17 -0700)]
add tracing to Decryp to complement tracing in Encrypt (#40998)

* add tracing to Decryp to complement tracing in Encrypt

* feedback from review

* revert encrypt

3 years agoPort nullability annotations to System.Xml.ReaderWriter contract (#41083)
David Cantú [Thu, 27 Aug 2020 20:03:46 +0000 (13:03 -0700)]
Port nullability annotations to System.Xml.ReaderWriter contract (#41083)

* Port nullability annotations to System.Xml.ReaderWriter contract assembly

* Port annotations of recently updated members in Xml/Serialization

* Fix anontations on XmlElement discovered while updating System.Data.Common Xml related annotations

* Fix Xml related annotations on System.Data.Common

* address feedback

Co-authored-by: Krzysztof Wicher <kwicher@microsoft.com>
3 years agoFix SPMI to handle replays of BBINSTR jit method contexts (#41386)
Andy Ayers [Thu, 27 Aug 2020 19:26:33 +0000 (12:26 -0700)]
Fix SPMI to handle replays of BBINSTR jit method contexts (#41386)

Move the handling of allocMethodBlockCounts to the method context.
While this data is both an input and an output, we're more interested
in the input side.

We could also treat it as an output, if we say wanted to verify that
the replay jit wrote the same sequence of IL offsets into the BlockCount
records, but that doesn't seem crucial as changes here would also lead
to code diffs.

Fix the code that checks the AddressMap for reloc hints so it doesn't
fail if the exact lookup fails, but instead falls back to a search.
This is needed because the base of the replay count buffer is recorded
as the map key, but the instrumentation probes in jitted code refer
to offsets from this value.

Fixes #37270.

3 years agoMake minimal OSX version consistent between build-native.sh and configurecompiler...
Alexander Köplinger [Thu, 27 Aug 2020 18:38:25 +0000 (20:38 +0200)]
Make minimal OSX version consistent between build-native.sh and configurecompiler.cmake (#41435)

The latter still specified 10.12 but .NET Core 3+ actually only supports macOS 10.13 or later.

3 years agoFix null check in S.Diagnostics.Contract regressed by nullability annotations (#41382)
Krzysztof Wicher [Thu, 27 Aug 2020 18:00:42 +0000 (20:00 +0200)]
Fix null check in S.Diagnostics.Contract regressed by nullability annotations (#41382)

* Fix null check in S.Diagnostics.Contract regressed by nullability annotations

* fix product per Jan's recommendation

3 years agoConsole.Unix: fix window size not always being invalidated (#41317)
Tom Deseyn [Thu, 27 Aug 2020 17:53:49 +0000 (19:53 +0200)]
Console.Unix: fix window size not always being invalidated (#41317)

Ensure signal handlers are setup to invalidate cached values
for window size.

3 years agoFix ArgumentNullException when using minimum json file (#41428)
Maryam Ariyan [Thu, 27 Aug 2020 17:33:18 +0000 (10:33 -0700)]
Fix ArgumentNullException when using minimum json file (#41428)

3 years agoAllow return null from ConnectionListener.AcceptAsync (#41442)
Natalia Kondratyeva [Thu, 27 Aug 2020 16:20:54 +0000 (19:20 +0300)]
Allow return null from ConnectionListener.AcceptAsync (#41442)

Changed API as it was proposed and approved in #41304

Closes #41304

3 years agoIssue18826 fix (#35137)
monojenkins [Thu, 27 Aug 2020 15:38:44 +0000 (11:38 -0400)]
Issue18826 fix (#35137)

<!--
Thank you for your Pull Request!

If you are new to contributing to Mono, please try to do your best at conforming to our coding guidelines http://www.mono-project.com/community/contributing/coding-guidelines/ but don't worry if you get something wrong. One of the project members will help you to get things landed.

Does your pull request fix any of the existing issues? Please use the following format: Fixes #issue-number
-->

Fixes mono/mono#18826

Co-authored-by: HinTak <HinTak@users.noreply.github.com>
3 years ago[mono] ALC function restructuring for unloadability (#41344)
Ryan Lucia [Thu, 27 Aug 2020 14:56:30 +0000 (10:56 -0400)]
[mono] ALC function restructuring for unloadability (#41344)

We previously had a weird split between the domain and loader headers/files. This makes fewer things public, moves the useful ALC functions to loader-internals.h with the implementation in assembly-load-context.c, and cleans up the flow for some unloading behavior.

3 years agoAdd support for using cmake in the mono runtime build. (#41316)
Zoltan Varga [Thu, 27 Aug 2020 14:13:41 +0000 (10:13 -0400)]
Add support for using cmake in the mono runtime build. (#41316)

* Add support for using cmake in the mono runtime build.

Not enabled by default. Ninja is used for building if available, else we fall
back to make.

* Build and install libmonosgen-2.0.dylib.

* Address review comments.

* Add a few more MONO_EMPTY_SOURCE_FILE defines to silence ranlib warnings on osx.

* Pass -mmacosx-version-min=10.12 on osx.

* Add eventpipe support.

* Quiet the OSX build a bit.

* Address review comments.

3 years agoGlobally enable nullability in XML (#41438)
Krzysztof Wicher [Thu, 27 Aug 2020 12:57:29 +0000 (14:57 +0200)]
Globally enable nullability in XML (#41438)

* Globally enable nullability in XML

* remove double #nullable enable in the file

3 years agoBrowserDebugProxy: bump package versions to latest stable (#41436)
Alexander Köplinger [Thu, 27 Aug 2020 12:51:19 +0000 (14:51 +0200)]
BrowserDebugProxy: bump package versions to latest stable (#41436)

Fixes https://github.com/dotnet/runtime/issues/41356

3 years agoNullable: System.Xml, part 7 (Serialization) (#41261)
Krzysztof Wicher [Thu, 27 Aug 2020 06:29:11 +0000 (08:29 +0200)]
Nullable: System.Xml, part 7 (Serialization) (#41261)

* Nullable: System.Xml, part 7 (Serialization)

* Fix build errors on Release (ifdef-ed code)

* fix incidental product bug

* address PR feedback

* Make XmlSerializer._rootType nullable