platform/upstream/dotnet/runtime.git
3 years agoFix ActivitySource.StartActivity when start time is provided (#39884)
Alan West [Fri, 24 Jul 2020 16:25:05 +0000 (09:25 -0700)]
Fix ActivitySource.StartActivity when start time is provided (#39884)

3 years agoPost #35606 cleanup (#39891)
Viktor Hofer [Fri, 24 Jul 2020 16:02:32 +0000 (18:02 +0200)]
Post #35606 cleanup (#39891)

* Post #35606 cleanup

3 years agoConvert math intrinsics to named intrinsics (#39730)
Adeel Mujahid [Fri, 24 Jul 2020 15:35:17 +0000 (18:35 +0300)]
Convert math intrinsics to named intrinsics (#39730)

* Convert math intrinsics to named intrinsics

* Annotate Floor and Ceiling with [Intrinsic]

3 years ago[debugger] Removing unhandled_exception which was used for android. (#39377)
monojenkins [Fri, 24 Jul 2020 14:42:10 +0000 (10:42 -0400)]
[debugger] Removing unhandled_exception which was used for android. (#39377)

Trying to remove the usage of unhandled_exception function to make debugger handle with an exception when running on android.
We should ignore the try catch that is in an WRAPPER_SUBTYPE_ICALL_WRAPPER, then we can walk through all the callstack and find any try catch in managed code if it exists.

Co-authored-by: thaystg <thaystg@users.noreply.github.com>
3 years agoAdd CBOR property-based tests (#39828)
Eirik Tsarpalis [Fri, 24 Jul 2020 13:56:12 +0000 (14:56 +0100)]
Add CBOR property-based tests (#39828)

* Add CBOR property-based tests

* address feedback

3 years ago[browser][tests] Activate System.Private.Uri.Functional.Tests (#39817)
Kenneth Pouncey [Fri, 24 Jul 2020 09:50:41 +0000 (11:50 +0200)]
[browser][tests] Activate System.Private.Uri.Functional.Tests (#39817)

Local:

```
info: test[0]
        Tests run: 883, Errors: 0, Failures: 0, Skipped: 1. Time: 188.7140968s
```

3 years ago[runtime] Fix some more gc tracking problems in create_cattr_named/typed_arg. (#39856)
Zoltan Varga [Fri, 24 Jul 2020 09:23:38 +0000 (05:23 -0400)]
[runtime] Fix some more gc tracking problems in create_cattr_named/typed_arg. (#39856)

3 years agoRemove leading dot check for cookie domain (#39781)
Natalia Kondratyeva [Fri, 24 Jul 2020 07:18:00 +0000 (10:18 +0300)]
Remove leading dot check for cookie domain (#39781)

Minimal fix for domain-related cookie issues of #26141

To fully comply with RFC 6265, one should remove deprecated cookie
properties, such as Version, from public API. So only the stated
issues with leading dot were addressed now.

Also note that the leading dot was not stripped from the domain even
though RFC 6265 proposed it. This behavior was chosen because
browsers like Chrome and Edge also don't strip the leading dot.

3 years agoAdd ReferenceConverter entry to intrinsic type converters table (#39854)
Santiago Fernandez Madero [Fri, 24 Jul 2020 06:13:07 +0000 (23:13 -0700)]
Add ReferenceConverter entry to intrinsic type converters table (#39854)

* Add ReferenceConverter entry to intrinsic type converters table

* Add tests

3 years agoRemove unused pinvokes for WinRT scenarios (#39846)
Aaron Robinson [Fri, 24 Jul 2020 01:03:29 +0000 (18:03 -0700)]
Remove unused pinvokes for WinRT scenarios (#39846)

* Remove GetRestructedErrorInfo P/Invoke

* Remove win32 core memory P/Invokes

* Remove RoGetBufferMarshaler P/Invoke

* Remove RoGetActivationFactory P/Invoke

* Remove CoreComm P/Invokes

* Remove IRestrictedErrorInfo definition.

3 years ago[aot] Avoid a crash in generic sharing for invalid generic instances. Fixes https...
monojenkins [Fri, 24 Jul 2020 00:58:24 +0000 (20:58 -0400)]
[aot] Avoid a crash in generic sharing for invalid generic instances. Fixes https://github.com/mono/mono/issues/20138. (#39869)

Co-authored-by: vargaz <vargaz@users.noreply.github.com>
3 years agoAnnotate TypeConverterAttribute so that the ILLinker preserves the ctor on the conver...
Layomi Akinrinade [Fri, 24 Jul 2020 00:54:19 +0000 (17:54 -0700)]
Annotate TypeConverterAttribute so that the ILLinker preserves the ctor on the converter (#39144)

* Annotate TypeConverterAttribute so that the ILLinker preserves the ctor on the converter

* Address review feedback & add attributes to ref

* Use custom enum converter type

* Split tests

3 years agoImplementation of CSE for GT_CNS_INT benefits ARM64 (#39096)
Brian Sullivan [Fri, 24 Jul 2020 00:20:46 +0000 (17:20 -0700)]
Implementation of CSE for GT_CNS_INT benefits ARM64 (#39096)

* Change the type of csdHashKey to size_t

* Update gtCostSz and gtCostEx for constant nodes

* Implementation of code size optimization, CSE of constant values for ARM64
Implementation of code size optimization, CSE of constant values for ARM64
We will share a single CSE for constants that differ only in their low 12 bits on ARM64

Number of shared constant low bits set in target.h  CSE_CONST_SHARED_LOW_BITS
we use 12 bits on Arm platforms and 16 bits on XArch platforms

Disable the CSE of the REG_R2R_INDIRECT_PARAM on Arm32
as it hits  Assertion failed 'candidates != candidateBit' in lsra.cpp Line: 3723

Config variable: COMPlus_JitConstCSE
// Default 0: enable the CSE of Constants, including nearby offsets. (only for ARM64)
// If 1, disable all the CSE of Constants
// If 2, enable the CSE of Constants but don't combine with nearby offsets. (only for ARM64)
// If 3, enable the CSE of Constants including nearby offsets. (all platforms)
// If 4, enable the CSE of Constants but don't combine with nearby offsets. (all platforms)
//

* Added additional Priority 0 test coverage for Floating Point optimizations

* Fix for COMPLUS_JitConstCSE=4

* Renamed config variable from COMPlus_JitDisableConstCSE to COMPlus_JitConstCSE

* Updated with Codereview feedback, removed sort from Const CSE phase

* Fix for assertionProp issue in the refTypesdynamic test

3 years agoWASM: Enable Invariant.Tests (#39814)
Santiago Fernandez Madero [Thu, 23 Jul 2020 23:21:06 +0000 (16:21 -0700)]
WASM: Enable Invariant.Tests (#39814)

* WASM: Enable Invariant.Tests

* Fix build and PR Feedback

3 years agoWASM: enable System.ObjectModel.Tests (#39849)
Santiago Fernandez Madero [Thu, 23 Jul 2020 22:05:43 +0000 (15:05 -0700)]
WASM: enable System.ObjectModel.Tests (#39849)

3 years agoRemove obsolete ActiveIssue attributes for #23972 (#39842)
Viktor Hofer [Thu, 23 Jul 2020 21:18:40 +0000 (23:18 +0200)]
Remove obsolete ActiveIssue attributes for #23972 (#39842)

3 years agoExtend Linker test job timeout to 2 hours (#39847)
Jose Perez Rodriguez [Thu, 23 Jul 2020 21:06:09 +0000 (14:06 -0700)]
Extend Linker test job timeout to 2 hours (#39847)

3 years agoRemove a new assert that can fire with unsafe code and type casts (#38912)
Brian Sullivan [Thu, 23 Jul 2020 21:05:35 +0000 (14:05 -0700)]
Remove a new assert that can fire with unsafe code and type casts (#38912)

3 years agoAdd @dotnet/jit-contrib to CODEOWNERS (#39862)
Jan Kotas [Thu, 23 Jul 2020 21:01:07 +0000 (14:01 -0700)]
Add @dotnet/jit-contrib to CODEOWNERS (#39862)

3 years agoWrite error events for service errors (#39766)
Next Turn [Thu, 23 Jul 2020 19:10:43 +0000 (03:10 +0800)]
Write error events for service errors (#39766)

* Write error events for service errors

* Explicitly specify EventLogEntryType.Error

3 years agoEnsure the size of Vector<T> takes COMPlus_EnableHWIntrinsic into account (#39368)
Tanner Gooding [Thu, 23 Jul 2020 18:41:38 +0000 (11:41 -0700)]
Ensure the size of Vector<T> takes COMPlus_EnableHWIntrinsic into account (#39368)

* Ensure the size of Vector<T> takes COMPlus_EnableHWIntrinsic into account

* Add basic logging to Runtime_34587

* Exclude InstructionSet_POPCNT and InstructionSet_POPCNT_X64 if featureSIMD is disabled

3 years agoturn pauseonstart test off for Windows (#39789)
John Salem [Thu, 23 Jul 2020 17:46:36 +0000 (10:46 -0700)]
turn pauseonstart test off for Windows (#39789)

3 years agoRemove outdated comment in System.CM.Composition.Tests (#39839)
Viktor Hofer [Thu, 23 Jul 2020 16:20:02 +0000 (18:20 +0200)]
Remove outdated comment in System.CM.Composition.Tests (#39839)

We don't plan to add a .NETFramework test configuration for this library anymore.

3 years agoRemove depprojs in favor of PackageReferences (#35606)
Viktor Hofer [Thu, 23 Jul 2020 15:20:26 +0000 (17:20 +0200)]
Remove depprojs in favor of PackageReferences  (#35606)

- Remove depprojs which currently binplace external references into the RefPath folders in favor of PackageReference and PackageDownload items.
- Build all configurations by default when building an individual project (either on the CLI or inside VS) same as with the official SDK. This enables .NETFramework Test Explorer support.
- Centrally define libraries that compose the shared framework instead of in each Directory.Build.props file to be able to build the targeting pack first and consume it in the OOB libraries.
- Use ProjectReferences to reference OOB projects. Compile against the reference assembly but use the implementation assembly app-local during runtime.
- Remove OOBs from the testhost and remove the testhost folder for .NETFramework as it isn't required anymore.
- Only binplace for $(NetCoreAppCurrent) to compose a) the targeting pack, b) the runtime pack, c) the testhost, d) a full closure for the shims.
- Use Targeting Packs for OOB projects (with their implicit assembly references) but still explicitly define granular references for .NETCoreApp configurations (DisableImplicitAssemblyReferences switch). Use the implicit targeting pack references in some Microsoft.Extensions.* cases.
- Remove placeholder configurations as they aren't needed anymore with explicit P2Ps vs Targeting Pack references.
- Remove implicit assembly references (ie for .NETFramework, mscorlib)
- Remove AssemblySearchPath hacks that were introduced with b7c4cb7 as the targeting pack is now used by default.
- Reduce unnecessary .NETFramework configurations that were added to run tests in favor of the already existing ref&src configurations.
- Stop hardcoding the paths for wasm assemblies and use the returned TargetPath of the ProjectReferences.
- Addressed formatting (ItemGroups, References at the bottom of the project file, ordering of references, use LibrariesProjectRoot instead of a relative path, unnecessary AssemblyName and RootNamespace properties which are identical to the project name, ordering of tfms)
- Revert "fix clean (#33758)"

3 years agoFix CNG persisted symmetric key operations
Jeremy Barton [Thu, 23 Jul 2020 15:19:04 +0000 (08:19 -0700)]
Fix CNG persisted symmetric key operations

During a code cleanup the encoding changed from UTF-16LE
to UTF-8, which is not valid for the P/Invoke.

3 years agoWASM: Fix System.Net.Primitives and tests (#39748)
Alexander Köplinger [Thu, 23 Jul 2020 14:43:07 +0000 (16:43 +0200)]
WASM: Fix System.Net.Primitives and tests (#39748)

Add HostInformationPal and InterfaceInfoPal implementations for Browser.

In CookiePortTest.cs use example.com instead of localhost for the tests since Browser uses `localhost` as the `Environment.MachineName` and that changes the test values.

Allows the tests to run on WebAssembly:
```
System.Net.Primitives.Pal.Tests: Tests run: 60, Errors: 0, Failures: 0, Skipped: 0. Time: 0.15872s
System.Net.Primitives.Functional.Tests: Tests run: 2620, Errors: 0, Failures: 0, Skipped: 1. Time: 3.145804s
```

3 years ago[wasm] Enable System.Threading.Thread.Tests test suite (#39826)
Maxim Lipnin [Thu, 23 Jul 2020 13:21:59 +0000 (16:21 +0300)]
[wasm] Enable System.Threading.Thread.Tests test suite (#39826)

3 years agoHardcode path to ICU on macOS (#39833)
Alexander Köplinger [Thu, 23 Jul 2020 12:14:44 +0000 (14:14 +0200)]
Hardcode path to ICU on macOS (#39833)

3 years agoSuppress credscan false positives (#38026)
Jan Jahoda [Thu, 23 Jul 2020 09:59:00 +0000 (11:59 +0200)]
Suppress credscan false positives (#38026)

* Suppress initial cred issues

* Another bunch of supresses

* Clean up

* Another bunch of supresses

* Revert to suppression messages

* Clean up

* Apply suggestions from code review

Co-authored-by: Jeremy Barton <jbarton@microsoft.com>
* Revert passwords literals

* Fix suppression justification comment

Co-authored-by: Jan Jahoda <jajahoda@.microsoft.com>
Co-authored-by: Jeremy Barton <jbarton@microsoft.com>
3 years agoSwitch Windows arm64 testing to use Windows.10.Arm64v8.Open queue. (#39802)
Eugene Rozenfeld [Thu, 23 Jul 2020 07:17:29 +0000 (00:17 -0700)]
Switch Windows arm64 testing to use Windows.10.Arm64v8.Open queue. (#39802)

Windows arm testing has been scaled back in #39655 so now we can start
using better machines for Windows arm64 testing. These machines were
previously used for Windows arm testing.

3 years agoFix FCall implementation collision on ARM64 (#39810)
Anton Lapounov [Thu, 23 Jul 2020 04:17:42 +0000 (21:17 -0700)]
Fix FCall implementation collision on ARM64 (#39810)

Two FCalls, DependentHandle::nSetPrimary and MarshalNative::GCHandleInternalSet, had identical implementations, which led to a failure in ECall::GetFCallImpl ("Duplicate pImplementation entries found in reverse fcall table"). Add FCUnique() to make them different.

3 years agoDisabled tests with the PlatformDetection.IsPreciseGcSupported (#39796)
Maryam Ariyan [Thu, 23 Jul 2020 01:20:55 +0000 (18:20 -0700)]
Disabled tests with the PlatformDetection.IsPreciseGcSupported (#39796)

3 years agoTry re-enabling IBC on macOS. (#39801)
Jeremy Koritzinsky [Thu, 23 Jul 2020 01:09:46 +0000 (18:09 -0700)]
Try re-enabling IBC on macOS. (#39801)

3 years ago[browser][file system] GetLogicalDrives implementation (#39763)
Kenneth Pouncey [Wed, 22 Jul 2020 23:30:50 +0000 (01:30 +0200)]
[browser][file system] GetLogicalDrives implementation (#39763)

- Directory.GetLogicalDrives threw PNSE.  Follows existing code paths.
- Add common DriveInfoInternal.Browser that is common code path for other implementations
   - Environment.GetLogicalDrives
   - DriveInfo.Drives

Fix for FileSystemTest https://github.com/dotnet/runtime/blob/master/src/libraries/System.IO.FileSystem/tests/Directory/GetLogicalDrives.cs

3 years agoFix Failing Casing Tests with Invariant Culture (#39747)
Tarek Mahmoud Sayed [Wed, 22 Jul 2020 21:58:36 +0000 (14:58 -0700)]
Fix Failing Casing Tests with Invariant Culture (#39747)

3 years agoLimit arm32 Windows testing. (#39655)
Eugene Rozenfeld [Wed, 22 Jul 2020 21:55:42 +0000 (14:55 -0700)]
Limit arm32 Windows testing. (#39655)

Remove Windows arm32 testing from PRs. Builds are not removed.
Remove Windows arm32 jitstress testing.
Remove Windows arm32 builds from official builds.

Outerloop still has Windows arm32 builds and testing.

3 years ago[runtime] Make sure newly created objects are pinned during a runtime invoke in creat...
Zoltan Varga [Wed, 22 Jul 2020 21:05:27 +0000 (17:05 -0400)]
[runtime] Make sure newly created objects are pinned during a runtime invoke in create_cattr_typed/named_arg (). (#39774)

Hopefully helps with https://github.com/dotnet/runtime/issues/39473.

3 years agoUpdate the JITEEVersionIdentifier (#39779)
Tanner Gooding [Wed, 22 Jul 2020 20:44:19 +0000 (13:44 -0700)]
Update the JITEEVersionIdentifier (#39779)

3 years agofix CborWriter bug when writing tagged empty collections (#39786)
Eirik Tsarpalis [Wed, 22 Jul 2020 19:58:21 +0000 (20:58 +0100)]
fix CborWriter bug when writing tagged empty collections (#39786)

3 years agoAdd events around type load and r2r usage (#39656)
David Wrighton [Wed, 22 Jul 2020 19:54:37 +0000 (12:54 -0700)]
Add events around type load and r2r usage (#39656)

- Allows for investigation of type loader performance
  - Uses a new keyword, as this event will generate many strings which is itself fairly slow
- Changes R2R events from Verbose events to Informational events
  - These events are already controlled by a separate keyword, and don't need to also be only emitted when Verbose eventing is on

3 years ago[wasm] add zone.tab to dotnet.timezones.blat (#39731)
Tammy Qiu [Wed, 22 Jul 2020 19:41:40 +0000 (15:41 -0400)]
[wasm] add zone.tab to dotnet.timezones.blat  (#39731)

* [wasm] add zone.tab to dotnet.timezones.blat to allow system time zones to load
* renable GetSystemTimeZones()
* reduce size of data file by removing unnecessary timezones

3 years agoRemove BundleDir/PublishDir at the end of ArchiveTests to save disk space (#39714)
Alexander Köplinger [Wed, 22 Jul 2020 19:13:38 +0000 (21:13 +0200)]
Remove BundleDir/PublishDir at the end of ArchiveTests to save disk space (#39714)

Hosted build agents have not a lot of free disk space and since we don't need these dirs anymore after we created the test archive we can delete it.

3 years ago[Infra] collect dumps of all corerun in tree on timeout (#38647)
John Salem [Wed, 22 Jul 2020 19:03:00 +0000 (12:03 -0700)]
[Infra] collect dumps of all corerun in tree on timeout (#38647)

3 years agoAdd missing space padding before exception message in log (#39534) (#39719)
Maryam Ariyan [Wed, 22 Jul 2020 18:39:02 +0000 (11:39 -0700)]
Add missing space padding before exception message in log (#39534) (#39719)

3 years agoMEH test failure on mono (#39784)
Maryam Ariyan [Wed, 22 Jul 2020 18:25:38 +0000 (11:25 -0700)]
MEH test failure on mono (#39784)

Factory_CleanupCycle_DisposesEligibleHandler

3 years agoFix double-writes in test projects (#39778)
Viktor Hofer [Wed, 22 Jul 2020 18:15:17 +0000 (20:15 +0200)]
Fix double-writes in test projects (#39778)

* Fix double-writes in test projects

3 years agoAdd rules for changing InstructionSetDesc.txt (#39777)
Jan Kotas [Wed, 22 Jul 2020 18:10:44 +0000 (11:10 -0700)]
Add rules for changing InstructionSetDesc.txt (#39777)

3 years agoAdd runtimelab.yml for dotnet/runtimelab experiments CI and build infrastructure...
Jose Perez Rodriguez [Wed, 22 Jul 2020 17:49:22 +0000 (10:49 -0700)]
Add runtimelab.yml for dotnet/runtimelab experiments CI and build infrastructure (#39749)

* Add runtimelab.yml for dotnet/runtimelab experiments CI and build infrastructure

* rename one of the ymls based on feedback

4 years agoAllow higher iteration counts for PBES2
Kevin Jones [Wed, 22 Jul 2020 16:18:14 +0000 (12:18 -0400)]
Allow higher iteration counts for PBES2

4 years agoFix some scenarios for DynamicRevocationTests on macOS.
Kevin Jones [Wed, 22 Jul 2020 16:16:51 +0000 (12:16 -0400)]
Fix some scenarios for DynamicRevocationTests on macOS.

4 years ago[wasm] Enable System.Linq.Expressions.Tests test suite (#39772)
Maxim Lipnin [Wed, 22 Jul 2020 14:45:43 +0000 (17:45 +0300)]
[wasm] Enable System.Linq.Expressions.Tests test suite (#39772)

4 years agoUse function pointers in more places (#39752)
Jan Kotas [Wed, 22 Jul 2020 14:27:01 +0000 (07:27 -0700)]
Use function pointers in more places (#39752)

4 years ago[wasm] WasmAppBuilder write the json as json (#39660)
Larry Ewing [Wed, 22 Jul 2020 14:15:42 +0000 (09:15 -0500)]
[wasm] WasmAppBuilder write the json as json (#39660)

* Write the json as json

Co-authored-by: Alexander Köplinger <alex.koeplinger@outlook.com>
4 years ago[wasm] Enable System.Xml.XmlSerializer.ReflectionOnly.Tests, System.Xml.XmlSerializer...
Maxim Lipnin [Wed, 22 Jul 2020 11:40:18 +0000 (14:40 +0300)]
[wasm] Enable System.Xml.XmlSerializer.ReflectionOnly.Tests, System.Xml.XmlSerializer.Tests, and System.Security.Permissions.Tests test suites (#39767)

4 years agoCI Integration for Cross OS DAC (#39574)
Juan Hoyos [Wed, 22 Jul 2020 10:15:11 +0000 (03:15 -0700)]
CI Integration for Cross OS DAC (#39574)

* Transfer assets from Cross OS DAC builds into a pipeline container
* Preserve additional properties in subsets' projects
* Add packaging projects for Cross OS Dac assets
* Pipeline change to package, sign, and publish the cross OS DAC

4 years agoMove `GetLclOffs` method to `GenTreeLclVarCommon`. (#39623)
Sergey Andreenko [Wed, 22 Jul 2020 09:02:32 +0000 (02:02 -0700)]
Move `GetLclOffs` method to `GenTreeLclVarCommon`. (#39623)

* Move `GetLclOffs` to `Common`.

* Start using it.

* Review response.

4 years agoUse lib prefix for native library names for consistency (#39717)
Jan Kotas [Wed, 22 Jul 2020 03:15:13 +0000 (20:15 -0700)]
Use lib prefix for native library names for consistency (#39717)

4 years agoAdd note about the tagging bot to area-owners.md (#39750)
Alexander Köplinger [Wed, 22 Jul 2020 03:05:43 +0000 (05:05 +0200)]
Add note about the tagging bot to area-owners.md (#39750)

Follow-up to https://github.com/dotnet/runtime/pull/39659

Co-authored-by: Dan Moseley <danmose@microsoft.com>
4 years agoAdd Overloads for Add(Json/Systemd/Simple)Console (#39725)
Maryam Ariyan [Tue, 21 Jul 2020 23:14:07 +0000 (16:14 -0700)]
Add Overloads for Add(Json/Systemd/Simple)Console (#39725)

4 years agoFix libraries outerloop builds (#39735)
Santiago Fernandez Madero [Tue, 21 Jul 2020 22:41:58 +0000 (15:41 -0700)]
Fix libraries outerloop builds (#39735)

* Fix libraries outerloop builds

* Remove liveRuntimeBuildConfig from all configurations build to not make it wait for coreclr to run

4 years ago[runtime] Initialize the class if needed in type_is_blittable (). (#39700)
Zoltan Varga [Tue, 21 Jul 2020 22:08:40 +0000 (18:08 -0400)]
[runtime] Initialize the class if needed in type_is_blittable (). (#39700)

* [runtime] Initialize the class if needed in type_is_blittable ().

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

* Delete workarounds.

4 years agoModify build-test scripts to use response files for Crossgen compilation (#39705)
Tomáš Rylek [Tue, 21 Jul 2020 19:35:50 +0000 (21:35 +0200)]
Modify build-test scripts to use response files for Crossgen compilation (#39705)

This makes it much easier to rerun Crossgen(2) for a particular
framework assembly or for the framework composite build as opposed
to having to copy over the lengthy command line.

Thanks

Tomas

4 years ago[wasm] Enable System.ComponentModel.TypeConverter test suite (#39710)
Maxim Lipnin [Tue, 21 Jul 2020 19:30:28 +0000 (22:30 +0300)]
[wasm] Enable System.ComponentModel.TypeConverter test suite (#39710)

4 years agoWASM: Enable System.Reflection tests (#39696)
Alexander Köplinger [Tue, 21 Jul 2020 19:25:24 +0000 (21:25 +0200)]
WASM: Enable System.Reflection tests (#39696)

Disable tests that won't work on browser.

4 years agoClean up code following JSON number handling and field support PRs (#39716)
Layomi Akinrinade [Tue, 21 Jul 2020 19:23:03 +0000 (12:23 -0700)]
Clean up code following JSON number handling and field support PRs (#39716)

* Clean up code following JSON number handling and field support PRs

* Move IsValidNumberHandlingValue to better location

4 years agoDisable crossgen2smoke test for GCStress (#39680)
Bruce Forstall [Tue, 21 Jul 2020 18:49:36 +0000 (11:49 -0700)]
Disable crossgen2smoke test for GCStress (#39680)

It times out in some modes, especially HeapVerify modes.

Issue: https://github.com/dotnet/runtime/issues/33949

4 years agoEnable builds of internal branches (#39437)
Matt Mitchell [Tue, 21 Jul 2020 16:22:40 +0000 (09:22 -0700)]
Enable builds of internal branches (#39437)

4 years agoFix hosted crossgen2 build on arm64 (#39537)
Omair Majid [Tue, 21 Jul 2020 16:15:15 +0000 (12:15 -0400)]
Fix hosted crossgen2 build on arm64 (#39537)

4 years agoUpdate license header in NameResolutionTelemetry (#39711)
Miha Zupan [Tue, 21 Jul 2020 15:52:18 +0000 (17:52 +0200)]
Update license header in NameResolutionTelemetry (#39711)

4 years agoTrim more Http DiagnosticsHandler code (#39525)
Eric Erhardt [Tue, 21 Jul 2020 13:59:52 +0000 (08:59 -0500)]
Trim more Http DiagnosticsHandler code (#39525)

Since the DiagnosticsHandler still gets instantiated in the HttpClientHandler, none of its overriden methods are getting trimmed. This leads to System.Diagnostics.DiagnosticListener still being preserved in a linked application.

The fix is to split DiagnosticsHandler.IsEnabled() into two methods:

* IsGloballyEnabled() - checks the AppContext switch, and is replaced by the linker by a feature swtich.
* IsEnabled() - which checks IsGloballyEnabled() and if there is an Activity or listener available.

This allows all but the IsEnabled and IsGloballyEnabled methods to get trimmed on DiagnosticsHandler.

Contributes to #38765

4 years agoAdd CryptoStream.FlushFinalBlockAsync
Kevin Jones [Tue, 21 Jul 2020 13:58:36 +0000 (09:58 -0400)]
Add CryptoStream.FlushFinalBlockAsync

4 years ago[browser][tests] Activate System.Runtime.Extensions UserName tests (#39692)
Kenneth Pouncey [Tue, 21 Jul 2020 11:30:44 +0000 (13:30 +0200)]
[browser][tests] Activate System.Runtime.Extensions UserName tests (#39692)

- Added specific tests for Browser

4 years agoFix TableOutOfRangeException in Crossgen2 (#39653)
Tomáš Rylek [Tue, 21 Jul 2020 10:03:17 +0000 (12:03 +0200)]
Fix TableOutOfRangeException in Crossgen2 (#39653)

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

Turns out the compilation failure here wasn't caused by Managed C++,
it was due to a simple bug in the field RVA copy loop - reading
compressed 16-bit field indices as signed, not unsigned, from the
FieldRVA ECMA metadata table.

Thanks

Tomas

4 years agoWASM: Enable System.Reflection.MetadataLoadContext tests (#39651)
Alexander Köplinger [Tue, 21 Jul 2020 08:44:44 +0000 (10:44 +0200)]
WASM: Enable System.Reflection.MetadataLoadContext tests (#39651)

`Tests run: 559, Errors: 0, Failures: 0, Skipped: 0. Time: 5.4221639s`

4 years agoDo not touch crossgen if crossgen is not requested (#39628)
Gleb Balykov [Tue, 21 Jul 2020 05:45:28 +0000 (08:45 +0300)]
Do not touch crossgen if crossgen is not requested (#39628)

4 years agoDisable getappdomainstaticaddress for JIT stress modes (#39667)
Bruce Forstall [Tue, 21 Jul 2020 04:57:21 +0000 (21:57 -0700)]
Disable getappdomainstaticaddress for JIT stress modes (#39667)

Issue: https://github.com/dotnet/runtime/issues/37117

4 years agoAdd JsonNumberHandling(Attribute) & support for (de)serializing numbers from/to strin...
Layomi Akinrinade [Tue, 21 Jul 2020 04:13:29 +0000 (21:13 -0700)]
Add JsonNumberHandling(Attribute) & support for (de)serializing numbers from/to string (#39363)

* Add JsonNumberHandling & support for (de)serializing numbers from/to string

* Add JsonNumberHandlingAttribute

* Address review feedback + fixups

* Address review feedback ii

4 years agofix missing command case (#39686)
John Salem [Tue, 21 Jul 2020 03:58:56 +0000 (20:58 -0700)]
fix missing command case (#39686)

4 years agoStart using UnmanagedCallersOnly in CoreLib (#39082)
Jan Kotas [Tue, 21 Jul 2020 02:32:22 +0000 (19:32 -0700)]
Start using UnmanagedCallersOnly in CoreLib (#39082)

- Fix CoreCLR assert on x86
- Use workaround for Mono

4 years agoFixing a memory ordering issue in AsymmetricLock and enabling MemoryBarrierProcessWid...
Vladimir Sadov [Tue, 21 Jul 2020 02:29:13 +0000 (19:29 -0700)]
Fixing a memory ordering issue in AsymmetricLock and enabling MemoryBarrierProcessWide test on ARM64 (#39668)

4 years agoFix tailCall check for CallI. (#39621)
Sergey Andreenko [Tue, 21 Jul 2020 01:35:31 +0000 (18:35 -0700)]
Fix tailCall check for CallI. (#39621)

4 years agoAdd CoffeeFlux to area-VM-meta-mono (#39659)
Ryan Lucia [Tue, 21 Jul 2020 00:41:30 +0000 (20:41 -0400)]
Add CoffeeFlux to area-VM-meta-mono (#39659)

This ensures I see notifications about new issues

4 years ago[master] Update dependencies from mono/linker Microsoft/vstest dotnet/runtime-assets...
dotnet-maestro[bot] [Mon, 20 Jul 2020 23:51:08 +0000 (01:51 +0200)]
[master] Update dependencies from mono/linker Microsoft/vstest dotnet/runtime-assets dotnet/llvm-project dotnet/icu (#39516)

* Update dependencies from https://github.com/mono/linker build 20200716.2

Microsoft.NET.ILLink.Tasks
 From Version 5.0.0-preview.3.20363.5 -> To Version 5.0.0-preview.3.20366.2

* Update dependencies from https://github.com/microsoft/vstest build 20200716-03

Microsoft.NET.Test.Sdk
 From Version 16.8.0-preview-20200708-01 -> To Version 16.8.0-preview-20200716-03

* Update dependencies from https://github.com/dotnet/runtime-assets build 20200714.1

System.ComponentModel.TypeConverter.TestData , System.Drawing.Common.TestData , System.IO.Compression.TestData , System.IO.Packaging.TestData , System.Net.TestData , System.Private.Runtime.UnicodeData , System.Security.Cryptography.X509Certificates.TestData , System.Windows.Extensions.TestData
 From Version 5.0.0-beta.20360.1 -> To Version 5.0.0-beta.20364.1

* Update dependencies from https://github.com/dotnet/llvm-project build 20200715.1

runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools , runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools , runtime.win-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk , runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools , runtime.osx.10.12-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk , runtime.linux-x64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk , runtime.linux-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Tools , runtime.linux-arm64.Microsoft.NETCore.Runtime.Mono.LLVM.Sdk
 From Version 9.0.1-alpha.1.20356.1 -> To Version 9.0.1-alpha.1.20365.1

* Update dependencies from https://github.com/dotnet/icu build 20200716.2

Microsoft.NETCore.Runtime.ICU.Transport
 From Version 5.0.0-preview.8.20365.1 -> To Version 5.0.0-preview.8.20366.2

* Update dependencies from https://github.com/dotnet/icu build 20200717.1

Microsoft.NETCore.Runtime.ICU.Transport
 From Version 5.0.0-preview.8.20365.1 -> To Version 5.0.0-preview.8.20367.1

Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Alexander Köplinger <alex.koeplinger@outlook.com>
4 years agoFix build failure in net472 debug AdvSimd Utf16Utility (#39652)
Carlos Sanchez Lopez [Mon, 20 Jul 2020 22:35:59 +0000 (15:35 -0700)]
Fix build failure in net472 debug AdvSimd Utf16Utility (#39652)

4 years agoAdvSimd support for System.Text.Unicode.Utf8Utility.GetPointerToFirstInvalidByte...
Carlos Sanchez Lopez [Mon, 20 Jul 2020 22:26:22 +0000 (15:26 -0700)]
AdvSimd support for System.Text.Unicode.Utf8Utility.GetPointerToFirstInvalidByte (#38653)

* AdvSimd support for System.Text.Unicode.Utf8Utility.GetPointerToFirstInvalidByte

* Move comment to the top, add shims.

* Little endian checks

* Use custom MoveMask method for AdvSimd

* Address suggestions to improve the AdvSimdMoveMask method

* Define initialMask outside MoveMask method

* UInt64 in Arm64MoveMask

* Add unit test case to verify intrinsics improvement

* Avoid casting to smaller integer type

* Typo and comment

* Use ShiftRightArithmetic instead of CompareEqual + And.
Remove test case causing other unit tests to fail.

* Use AddPairwise version of GetNotAsciiBytes

* Add missing shims causing Linux build to fail

* Simplify GetNonAsciiBytes to only one AddPairwise call, shorter bitmask

* Respect data type returned by masking method

* Address suggestions - assert trailingzerocount and bring back uint mask

* Trailing zeroes in AdvSimd need to be divided by 4, and total number should not be larger than 16

* Avoid declaring static field which causes PNSE in Utf8String.Experimental (S.P.Corelib code is used for being NetStandard)

* Prefer using nuint for BitConverter.TrailingZeroCount

4 years agoAdvSimd support for System.Text.Unicode.Utf8Utility.TranscodeToUtf8 (#39041)
Carlos Sanchez Lopez [Mon, 20 Jul 2020 22:04:40 +0000 (15:04 -0700)]
AdvSimd support for System.Text.Unicode.Utf8Utility.TranscodeToUtf8 (#39041)

* AdvSimd support for System.Text.Unicode.Utf8Utility.TranscodeToUtf8

* Readd using to prevent build failure.
Add AdvSimd equivalent operation to TestZ.

* Inverted condition

* Address IsSupported order, improve use ExtractNarrowingSaturated usage

* Rename source to result, second argument utf16Data

* Improve CompareTest

* Add shims causing failures in Linux

* Use unsigned version of ExtractNarrowingSaturate, avoid using MinAcross and use MaxPairwise instead

* Missing support check for Sse2.X64

* Add missing case for AdvSimd

* Use MinPairwise for short

4 years agoRevert "Fix resx test name mangling logic" (#39644)
Levi Broderick [Mon, 20 Jul 2020 22:02:34 +0000 (15:02 -0700)]
Revert "Fix resx test name mangling logic" (#39644)

* Revert "Fix resx test name mangling logic"

This reverts commit 6af0d0e09a3b00a3a79033f7d26670b2563405fa.

* Add comment warning not to change this code

4 years agoFix tiering assertion failures from concurrent or reentering JIT of the same native...
Koundinya Veluri [Mon, 20 Jul 2020 22:00:19 +0000 (18:00 -0400)]
Fix tiering assertion failures from concurrent or reentering JIT of the same native code version (#39643)

Fix tiering assertion failures from concurrent or reentering JIT of the same native code version

Allowed disabling call counting multiple times.

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

4 years agoDeclare AllowReversePInvokeCallsAttribute as Obsolete. (#39636)
Aaron Robinson [Mon, 20 Jul 2020 21:24:50 +0000 (14:24 -0700)]
Declare AllowReversePInvokeCallsAttribute as Obsolete. (#39636)

4 years agoAllow Debugger attributes to be trimmed in Mono (#39479)
Eric Erhardt [Mon, 20 Jul 2020 20:42:22 +0000 (15:42 -0500)]
Allow Debugger attributes to be trimmed in Mono (#39479)

* Allow Debugger attributes to be trimmed in Mono.

Changed debugger-agent to allow for the Debugger Attributes to not exist.
Removed the Debugger Attributes entries from the Descriptors.xml file.

Fix https://github.com/mono/linker/issues/1355

* Use GENERATE_TRY_GET_CLASS_WITH_CACHE to initialize Debugger attribute pointers.

4 years agoApply missing obsolete attributes in src; fix attribute ordering (#39607)
Jeff Handley [Mon, 20 Jul 2020 20:34:18 +0000 (13:34 -0700)]
Apply missing obsolete attributes in src; fix attribute ordering (#39607)

* Apply missing obsolete attributes in src; fix attribute ordering

* Only obsolete the constructors of PolicyStatement

4 years agoAdd ProcessInfo command to Diagnostics Server (#38967)
John Salem [Mon, 20 Jul 2020 20:31:42 +0000 (13:31 -0700)]
Add ProcessInfo command to Diagnostics Server (#38967)

4 years agoFix fd leak in Diagnostics Server and add better error handling (#39129)
John Salem [Mon, 20 Jul 2020 20:25:26 +0000 (13:25 -0700)]
Fix fd leak in Diagnostics Server and add better error handling (#39129)

4 years ago[wasm] Address System.Text.RegularExpressions.Tests Failures (#39470)
Mitchell Hwang [Mon, 20 Jul 2020 19:59:59 +0000 (15:59 -0400)]
[wasm] Address System.Text.RegularExpressions.Tests Failures (#39470)

Co-authored-by: Mitchell Hwang <mitchell.hwang@microsoft.com>
4 years agoUnify resource strings used for Browser PNSE (#39637)
Alexander Köplinger [Mon, 20 Jul 2020 19:22:55 +0000 (21:22 +0200)]
Unify resource strings used for Browser PNSE (#39637)

We sometimes used `... is not supported on Browser.` and elsewhere `... is not supported on this platform.`

Standardize on the latter one as it can potentially be reused for other targets.

4 years ago[wasm] Enable System.CodeDom.Tests test suite (#39626)
Maxim Lipnin [Mon, 20 Jul 2020 19:11:37 +0000 (22:11 +0300)]
[wasm] Enable System.CodeDom.Tests test suite (#39626)

Part of https://github.com/dotnet/runtime/issues/38422.

4 years agoAdd PNSE on non-Browser for S.R.I.JavaScript and clean up references (#39629)
Alexander Köplinger [Mon, 20 Jul 2020 18:53:20 +0000 (20:53 +0200)]
Add PNSE on non-Browser for S.R.I.JavaScript and clean up references (#39629)

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

4 years agoCreate and add instance reference inside ResolveMetadata* (#39330)
David Cantu [Mon, 20 Jul 2020 18:39:32 +0000 (11:39 -0700)]
Create and add instance reference inside ResolveMetadata* (#39330)

* Create and add instance reference on ResolveMetadata

* Address suggestions

4 years ago[mono] Update ICU version, disable some tests for Browser (#39596)
Egor Bogatov [Mon, 20 Jul 2020 18:38:01 +0000 (21:38 +0300)]
[mono] Update ICU version, disable some tests for Browser (#39596)

4 years ago[wasm] Sort Assembly List in WASM Apps (#39374)
Mitchell Hwang [Mon, 20 Jul 2020 16:52:02 +0000 (12:52 -0400)]
[wasm] Sort Assembly List in WASM Apps (#39374)

Co-authored-by: Mitchell Hwang <mitchell.hwang@microsoft.com>