Tarek Mahmoud Sayed [Mon, 29 Mar 2021 00:24:24 +0000 (17:24 -0700)]
Use random file names in the TZ tests (#50339)
Eric Erhardt [Sun, 28 Mar 2021 21:52:37 +0000 (16:52 -0500)]
Add documentation on ILLink files (#50302)
* Add documentation on ILLink files
* Add link to ILLink-files from project-guidelines
dotnet-maestro[bot] [Sun, 28 Mar 2021 20:34:59 +0000 (20:34 +0000)]
[main] Update dependencies from dotnet/arcade dotnet/xharness (#50278)
[main] Update dependencies from dotnet/arcade dotnet/xharness
- reintroduce publishing branch workarounds.
Required while https://github.com/dotnet/arcade/issues/6987 is fixed
- fix whitespace in publish-using-darc script
- re-introduce publishing branch workaround
https://github.com/dotnet/arcade/issues/698
Sychev Vadim [Sun, 28 Mar 2021 12:46:02 +0000 (15:46 +0300)]
Add check for JsonConverterFactory (#50219) (#50329)
Zoltan Varga [Sat, 27 Mar 2021 18:06:39 +0000 (14:06 -0400)]
[mono] Reduce usage of the domain lock (#50313)
* [mono] Add a separate lock for the method_to_dyn_method hashtable.
* Use the jit memory manager lock instead of the domain lock in the arm64 patch code.
* Remove usage of the domain lock from the interpreter code.
* Use a separate lock to protect the jit info table.
* Fix the build.
Bruce Forstall [Sat, 27 Mar 2021 16:30:11 +0000 (09:30 -0700)]
Harden SuperPMI replay against missing data (#50307)
When generating disasm for an SPMI replay, we can call
`eeGetMethodFullName` for callees for which we are missing data.
Fix `MethodContext::repGetArgNext` to raise an appropriate exception,
and not crash, when it encounters missing data.
Jose Perez Rodriguez [Sat, 27 Mar 2021 15:59:20 +0000 (08:59 -0700)]
Resolve remaining Xslt-related warnings (round 2) (#50211)
* Resolve remaining Xslt-related warnings
* Addressing final linker warning and adding annotations to ref assembly
* Update src/libraries/System.Private.Xml/src/System/Xml/Xsl/IlGen/GenerateHelper.cs
Co-authored-by: Eric Erhardt <eric.erhardt@microsoft.com>
* Update src/libraries/System.Private.Xml/src/System/Xml/Xsl/Runtime/XmlExtensionFunction.cs
Co-authored-by: Eric Erhardt <eric.erhardt@microsoft.com>
* Addressing PR feedback
* kept -> preserved
* Address remaining feedback
Co-authored-by: Eric Erhardt <eric.erhardt@microsoft.com>
Jeremy Koritzinsky [Sat, 27 Mar 2021 07:11:34 +0000 (00:11 -0700)]
Fix PKCS Crypto tests on Android (#50252)
* Handle the fact that on Android, more validation failures are treated as PartialChain when doing CMS signing.
* Fix copy-paste error for RSA SHA-512 PKCS1 padding
* Change condition so we have it in netstandard builds.
Levi Broderick [Sat, 27 Mar 2021 04:52:19 +0000 (21:52 -0700)]
Improve performance of DateTime.UtcNow on Windows (#50263)
Optimizes leap-second handling by avoiding calls to FileTimeToSystemTime when possible
Jan Kotas [Sat, 27 Mar 2021 03:02:35 +0000 (20:02 -0700)]
Delete unreachable code for emitting PE fixups and obj files (#50259)
* Delete unrechable code for emitting PE fixups and obj files
* Fold ICeeGen into ICeeGenInternal and change IID
Jeremy Koritzinsky [Sat, 27 Mar 2021 01:53:10 +0000 (18:53 -0700)]
Add CoreCLR implementation of CallConvMemberFunction. (#47828)
* Add CoreCLR implementation of CallConvMemberFunction.
* Add tests and make a few fixes to get them passing.
* Fix Clang build
* Fix argument ordering for calling a cdecl or stdcall instance method from managed.
* Update src/coreclr/dlls/mscorrc/mscorrc.rc
Co-authored-by: Jan Kotas <jkotas@microsoft.com>
* Fix UnmanagedCallersOnly instance method calls for stdcall and cdecl.
* Update issues.targets.
* Fix formatting.
* Add dummy param to validate param order. Rewrite traversal to second-to-last argument.
* Merge implementations of call conv modopt name comparison.
Use a macro-based implementation initially since it allows us to add new calling conventions by adding one line and the macro-ized code is relatively small.
* Fix assignment alignment.
* SAL and contracts.
* Add assert
* Fix UnmanagedCallersOnly parsing in the refactored parser.
Co-authored-by: Jan Kotas <jkotas@microsoft.com>
Tarek Mahmoud Sayed [Sat, 27 Mar 2021 01:51:55 +0000 (18:51 -0700)]
Add more support for Julian time zones POSIX rules (#50131)
Eirik Tsarpalis [Sat, 27 Mar 2021 00:31:05 +0000 (00:31 +0000)]
Use IGenericSharedAPI test harness in PriorityQueue (#50291)
* Use IGenericSharedAPI test harness in PriorityQueue
* remove dead code
* remove index check from IEnumerator.Current
* Update src/libraries/System.Collections/tests/Generic/PriorityQueue/PriorityQueue.Generic.cs
Co-authored-by: Stephen Toub <stoub@microsoft.com>
* Update src/libraries/System.Collections/tests/Generic/PriorityQueue/PriorityQueue.Generic.cs
Co-authored-by: Stephen Toub <stoub@microsoft.com>
Co-authored-by: Stephen Toub <stoub@microsoft.com>
Andy Gocke [Sat, 27 Mar 2021 00:07:49 +0000 (17:07 -0700)]
Add PGD files to runtime package (#50296)
Bruce Forstall [Fri, 26 Mar 2021 23:13:26 +0000 (16:13 -0700)]
Fix superpmi.py setting of environment (#50304)
Especially, fix the setting of environment when generating asm diffs
artifacts.
Before, we were setting the global environment before generating textual
dasm or dump files, and not resetting it. Because we currently loop over
all the MCH files doing (1) `superpmi -a` to determine binary diffs,
then (2) generating textual dasm; after the the environment was set in
(2), if there were further MCH files to process, then the variables would
get picked up in (1). This seemed to work ok, except made the diff process
extremely slow because the baseline and diff JIT were generating textual
dasm for every single MC, which was ignored, then we would re-generate it
for any binary diffs.
Thus, for multiple MCH files, and diffs, things are MUCH faster now.
Kunal Pathak [Fri, 26 Mar 2021 21:34:13 +0000 (14:34 -0700)]
Use SPMI_CACHE_DIRECTORY for sharing mch files across repos (#50298)
* Use SPMI_LOCATION
* Rename to SUPERPMI_CACHE_DIRECTORY
Eric StJohn [Fri, 26 Mar 2021 21:21:16 +0000 (14:21 -0700)]
Ensure System.Resources.Extensions targets are applied transitively (#50288)
Copy targets to buildTransitive so that they will be applied from
transitive package/project references. We maintain build folder so that
old nuget clients can still get the build targets.
Kevin Jones [Fri, 26 Mar 2021 21:15:58 +0000 (17:15 -0400)]
Wrap ArgumentException with CryptographicException for incorrect key in EnvelopedCms
If an incorrect asymmetric key is used to decrypt a symmetric key
in enveloped data, and the decryption is successful but produces
an invalid symmetric key, wrap that as a CryptographicException.
Eric Erhardt [Fri, 26 Mar 2021 20:22:38 +0000 (15:22 -0500)]
Rename ILLinkTrim files to ILLink.Descriptors (#50216)
* Rename ILLinkTrim files to ILLink.Descriptors.
Fix #37651
Jo Shields [Fri, 26 Mar 2021 19:56:11 +0000 (15:56 -0400)]
Add missing Windows Android cross compilers (#50118)
Previously, only android-x64 cross compilers have been produced for running on windows-x64.
This PR introduces the three missing android RID targets.
Egor Bogatov [Fri, 26 Mar 2021 19:21:29 +0000 (22:21 +0300)]
JIT: Don't allocate string literals inside potential BBJ_THROW candidates (#50112)
Adam Sitnik [Fri, 26 Mar 2021 18:57:14 +0000 (19:57 +0100)]
Fix buffering bug (#50277)
Co-authored-by: Stephen Toub <stoub@microsoft.com>
Eric StJohn [Fri, 26 Mar 2021 18:32:19 +0000 (11:32 -0700)]
Remove some assemblies from ASP.NETCore transport package (#50284)
Marie Píchová [Fri, 26 Mar 2021 17:21:28 +0000 (18:21 +0100)]
[QUIC] API Update (#49823)
* Cherry picked change from scalablecory/msquic-update.
* Enum rename _FLAG --> _FLAGS to follow msquic naming.
* Enums updated
* Updated interop, compilable project.
* Somewhat working update of msquic API
* Post-merge compilation fixes.
* Fixed most of the tests, one turned into ActiveIssue
* Comments.
* Regenerated ref sources.
* Addressed some feedback.
* Added readme.
* QUIC_ADDRESS_FAMILY
Stephen Toub [Fri, 26 Mar 2021 16:29:28 +0000 (12:29 -0400)]
Implement ISpanFormattable on Rune and Char (#50272)
* Implement ISpanFormattable on Rune and Char
For now, this helps reduce allocation if a rune or char is used as an argument to string.Format. Once ISpanFormattable (or whatever we decide to do as part of API review) is public as part of the improved support for interpolated strings, it'll help there as well.
* Address PR feedback
Anton Firszov [Fri, 26 Mar 2021 16:28:24 +0000 (17:28 +0100)]
move NonDisposedSocket_SafeHandlesCollected to a non-parallel test collection (#50279)
Johan Lorensson [Fri, 26 Mar 2021 15:45:16 +0000 (16:45 +0100)]
Add SIMD instructions not emitted in simd-intrinsics.c for decompose. (#50168)
Mono codegen emits a couple of SIMD instructions in regular codegen.
Add them to list of instructions to check for vtype decompose.
With this fix all tests under System.Numerics.Vectors pass on Windows.
Ryan Lucia [Fri, 26 Mar 2021 15:34:16 +0000 (11:34 -0400)]
[mono] Runtime cleanup functions removal (#49639)
* Remove DISABLE_CLEANUP define
* Remove the rest of the cleanup functions
* Readd profiler APIs
Stephen Toub [Fri, 26 Mar 2021 10:54:17 +0000 (06:54 -0400)]
Add tests validating collections drop references (#50258)
Peter Sollich [Fri, 26 Mar 2021 09:11:05 +0000 (10:11 +0100)]
Lock region allocator (#49990)
Make region_allocator multi-thread safe by wrapping a dedicated lock around region_allocator::allocate and region_allocator:delete_region. Added a few ASSERT_HOLDING_SPIN_LOCK to guard against future bitrot.
Jan Kotas [Fri, 26 Mar 2021 09:06:22 +0000 (02:06 -0700)]
Fix pointer tearing in JIT_MemSet helper on ARM64 (#50273)
Kunal Pathak [Fri, 26 Mar 2021 07:26:55 +0000 (00:26 -0700)]
Print reason why EH Var was not enregistered (#50215)
* zero init
* add indicator why EH-var did not get enregistered
* jit format
* review comments
Sergey Andreenko [Fri, 26 Mar 2021 06:46:57 +0000 (23:46 -0700)]
Delete a test method that produces an error during compilation. (#50208)
* Delete a method that produces an error.
The error was:
```
[ 4%] Building CXX object Interop/PInvoke/Miscellaneous/ThisCall/CMakeFiles/ThisCallNative.dir/ThisCallNative.cpp.o
/Users/seandree/git/runtime/src/tests/Common/Platform/platformdefines.cpp:356:12: error: cast to smaller integer type 'unsigned int' from '_opaque_pthread_t *' [-Werror,-Wpointer-to-int-cast]
return (DWORD)*tThread;
^~~~~~~~~~~~~~~
1 error generated.
```
* Delete TP_JoinThread
Zoltan Varga [Fri, 26 Mar 2021 05:31:09 +0000 (01:31 -0400)]
[mono] Fix HOST_WASM -> TARGET_WASM in llvm code. (#50269)
Jan Jahoda [Fri, 26 Mar 2021 04:18:38 +0000 (05:18 +0100)]
Credentials fix (#50230)
* Port of https://github.com/dotnet/corefx/pull/43051
* Shrink suppression file
* Fix another bugs
* Bump System.Net.TestData version
* Fix typo
* Revert casing in connection string
* Fix connection string case
* more fixes
* Change suppression messages
* Fix typo
* Remove false positive
* Fix usersecrets
Co-authored-by: Dan Moseley <danmose@microsoft.com>
Mike McLaughlin [Fri, 26 Mar 2021 01:39:14 +0000 (18:39 -0700)]
Block debugger attach after any ApplyUpdate changes (#50200)
* Block debugger attach after any ApplyUpdate changes
* Add better error message for ApplyUpdate while debugging
* Code review feedback
* Fix arm32/arm64 builds
* Code review feedback
* Code review feedback
Hugh Bellamy [Fri, 26 Mar 2021 01:05:47 +0000 (01:05 +0000)]
Add PropertyItem tests (#46794)
* Refactor PropertyItem image code
* Refactor PropertyItemInternal
* Use Windows implementation of PropertyItem in Unix
* PR feedback
* Use ArrayPool
kronic [Fri, 26 Mar 2021 00:59:08 +0000 (03:59 +0300)]
remove repetitions ';' (#50236)
Co-authored-by: kronic <kronic@softland.ru>
Stephen Toub [Fri, 26 Mar 2021 00:50:33 +0000 (20:50 -0400)]
Seal internal types in libraries (#50225)
Elinor Fung [Fri, 26 Mar 2021 00:22:53 +0000 (17:22 -0700)]
Make tests target overwrite any existing xunit-excludes.txt file when building test app (#50183)
Aleksey Kliger (λgeek) [Fri, 26 Mar 2021 00:21:14 +0000 (20:21 -0400)]
[mbr] Fix encmap boundary and method RVA lookup. (#50248)
Two separate issues:
1. When we process the EnC map, any tables after the last one that has an
update gets an "enc_recs" pointer that's one past the last row of the
table. (the enc_recs pointer is used to speed up relative address lookup). So
at lookup time if enc_recs says to look past the end of the EnC map table, we
know there won't be any updates - return -1.
2. When looking for the updated RVA of a method, we need to go through every
delta and find the latest one that has an update for the given method. The
problem is that if a later generation doesn't have an update, we would take the
NULL return value at face value and it would look like the method had no
updates to its body - we would go back to using the original version from
before any updates were applied. Instead now ignore lookup table misses and
remember the last successful lookup. Fixes
https://github.com/dotnet/runtime/issues/50190
Vladimir Sadov [Thu, 25 Mar 2021 23:45:58 +0000 (16:45 -0700)]
Removing suspension prioritization scheme for GC threads vs. non-GC (#49378)
* remove nonfunctional suspension prioritization scheme for GC threads
* remove cntCollideRetry statistics counter
Kunal Pathak [Thu, 25 Mar 2021 23:38:43 +0000 (16:38 -0700)]
Do not set predecessor for throw block (#50115)
* Do not set predecessor for throw block
* jit format
* added comments
* delete BBF_SHARED_THROW
Elinor Fung [Thu, 25 Mar 2021 22:43:44 +0000 (15:43 -0700)]
Remove unused JNI objects (#50224)
dotnet-maestro[bot] [Thu, 25 Mar 2021 22:41:48 +0000 (22:41 +0000)]
[main] Update dependencies from dotnet/arcade dotnet/xharness dotnet/runtime-assets (#50231)
[main] Update dependencies from dotnet/arcade dotnet/xharness dotnet/runtime-assets
- Re-introduce publishing workaround
Required while https://github.com/dotnet/arcade/issues/6987 is resolved
Drew Scoggins [Thu, 25 Mar 2021 21:37:18 +0000 (14:37 -0700)]
Add arch specifier for AOT unpack path (#50194)
Vladimir Sadov [Thu, 25 Mar 2021 21:26:44 +0000 (14:26 -0700)]
Remove GETTHREAD_ALLOWED tracking (#50080)
* Remove GETTHREAD_ALLOWED tracking
* removed EE_THREAD_NOT_REQUIRED
* removed EE_THREAD_REQUIRED
* step1
* more changes
* fix Unix build
* more changes
* GetThread in pinvokestubs.S
* build fix for dac
* PInvokeGetThreadHelper
* more changes (dac)
* more (cordbe)
* more (nearly all?)
* Couple places that were mistakengly set to use `GetThreaNotOk` (should use `GetThreadNULLOk`)
* Renamed GetThread() -> GetThreadDoNotUse()
* Missed a few uses of GetThread()
* One more case of GetThread
* Bring GetThread() back - now with an assert in it.
* Renamed PInvokeGetThreadHelper -> JitGetThreadHelper
* One place that should use GetThreadNULLOk (otherwise there are asserts)
* Apply suggestions from code review
Jan's 74 suggestions.
Co-authored-by: Jan Kotas <jkotas@microsoft.com>
* remove SetFiberMode - it is dead code
* Make `EE_THREAD_NOT_REQUIRED` a noop and revert its removal.
* `GetThreadNULLOk()` should be used here.
* PR review suggestion
Co-authored-by: Jan Kotas <jkotas@microsoft.com>
* renamed JitGetThreadHelper -> GetThreadHelper
* One more place that should use `GetThreadNULLOk()`.
Co-authored-by: Jan Kotas <jkotas@microsoft.com>
Thays Grazia [Thu, 25 Mar 2021 19:40:00 +0000 (16:40 -0300)]
[debugger] Removing call to jit_done to help debug multithread (#50240)
It was causing a side effect on Unity, I will study it again while implement multithread on icordebug.
Reverting part of this PR #19103
Mirror of this PR https://github.com/mono/mono/pull/20970
David Fowler [Thu, 25 Mar 2021 19:09:20 +0000 (12:09 -0700)]
Dispose the ContentFileProvider when the host is disposed (#50181)
* Dispose the ContentFileProvider when the host is disposed
- Today we don't and it results in a leak when hosts are created and destroyed.
* Added test
Tomas Weinfurt [Thu, 25 Mar 2021 16:08:57 +0000 (09:08 -0700)]
Improve Linux root certificate store change detection involving symlinks
Jan Kotas [Thu, 25 Mar 2021 14:45:51 +0000 (07:45 -0700)]
Port misc changes from feature/NativeAOT (#50212)
Michal Strehovský [Thu, 25 Mar 2021 14:39:41 +0000 (15:39 +0100)]
Fix incorrect optimization of Activator.CreateInstance (#50228)
We should not return "default" if there's a private parameterless constructor. GetDefaultConstructor only calls the default constructor in the C# sense (public parameterless ctor on a non-abstract class).
Radek Doulik [Thu, 25 Mar 2021 14:13:57 +0000 (15:13 +0100)]
[wasm] Build AOT cross-compiler on windows (#50113)
Enable `BuildMonoAOTCrossCompiler ` on windows/wasm.
Update `offsets-tool` to add few emscripten include locations.
Use emscripten's `python` to run the `offsets-tool`.
* Add few debug prints
* Show libclang file on windows
* Use c:/dev/LLVM/bin/libclang.dll in CI builds
* Use emsdk's python
* Revert "Add few debug prints"
This reverts commit
b3133cfa04a45d64cb07defb8841e8643bf5f0cc.
* Build wasm/windows as Release configuration
The debug has problems of mixing debug/release like:
LLVMDemangle.lib(ItaniumDemangle.cpp.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in monosgen-2.0.lib(mini-llvm-cpp.cpp.obj)
LLVMDemangle.lib(ItaniumDemangle.cpp.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MT_StaticRelease' doesn't match value 'MTd_StaticDebug' in monosgen-2.0.lib(mini-llvm-cpp.cpp.obj)
Need to further look into this
* Add `-c $(_BuildConfig)`
David Cantú [Thu, 25 Mar 2021 08:45:24 +0000 (01:45 -0700)]
Use Length property instead of GetFileInformationByHandleEx for Seek(SeekOrigin.End) (#50218)
Michal Strehovský [Thu, 25 Mar 2021 08:41:38 +0000 (09:41 +0100)]
Move PGO support to Common (#50083)
This part is shareable with other CorInfo implementers.
Zoltan Varga [Thu, 25 Mar 2021 04:29:33 +0000 (00:29 -0400)]
[mono] Fix an assert. (#50220)
Radek Doulik [Thu, 25 Mar 2021 04:09:05 +0000 (05:09 +0100)]
[wasm] Copy native ICU libraries to native bin dir (#50184)
We were missing these in built artifacts on windows, resulting in this
error, when building wasm projects:
Compiling native assets with emcc. This may take a while ...
emcc: error: C:\...\artifacts\bin\microsoft.netcore.app.runtime.browser-wasm\Release\runtimes\browser-wasm\native\libicuuc.a: No such file or directory ("C:\Users\rodo\git\winwasm2\artifacts\bin\microsoft.netcore.app.runtime.browser-wasm\Release\runtimes\browser-wasm\native\libicuuc.a" was expected to be an input file, based on the commandline arguments provided)
Omair Majid [Thu, 25 Mar 2021 02:14:29 +0000 (22:14 -0400)]
Fix more copy-paste errors in host_context_test.cpp (#50147)
I missed a whole bunch of duplicate code when fixing
https://github.com/dotnet/runtime/pull/47430, this fixes that.
Tanner Gooding [Thu, 25 Mar 2021 02:12:07 +0000 (19:12 -0700)]
Ensure Vector<T>.op_Multiply is handled as an intrinsic in appropriate cases (#49503)
* Ensure Vector<T>.op_Multiply is handled as an intrinsic in appropriate cases
* Applying formatting patch
* Ensure TYP_BYTE and TYP_UBYTE are handled for Vector<T>.op_Multiply on ARM64
* Ensure broadcast nodes are inserted for all `operator *(Vector<T>, T)`
* Ensure ARM64 uses MultiplyByScalar when its available
* Applying formatting patch
* Ensure the scalar for op_Multiply is op2 on ARM64
* Ensure we do a full multiply for `Vector<T> * Vector<T>` on ARM64
* Applying formatting patch
Omair Majid [Thu, 25 Mar 2021 02:04:22 +0000 (22:04 -0400)]
Fix leak of app variable on assert in hostpolicy (#50199)
This was caught by a static anlyzer that pointed out that if the assert
is hit and the method returns, app is never deallocated.
Elinor Fung [Thu, 25 Mar 2021 01:58:53 +0000 (18:58 -0700)]
Propagate extra string data passed to Android instrumentation app as managed args (#50203)
Jeremy Koritzinsky [Wed, 24 Mar 2021 23:42:59 +0000 (16:42 -0700)]
When marshalling a layout class, fall-back to dynamically marshalling the type if it doesn't match the static type in the signature. (#50137)
Elinor Fung [Wed, 24 Mar 2021 23:25:26 +0000 (16:25 -0700)]
Make DSACryptoServiceProvider set legal key sizes to most restrictive for platform (#50192)
Bruce Forstall [Wed, 24 Mar 2021 23:23:42 +0000 (16:23 -0700)]
Loop inversion throughput improvements (#50154)
A few minor changes that should improve throughput:
1. Move the `fgForwardBranch` check lower, after all the
cheaper checks, since it does a linear walk of the basic
block list.
2. Don't do a tree walk to count shared static helpers if we
already know it's cheap enough to do the optimization.
Also, removed the not-too-useful `optFindLoopTermTest`,
and added more use of FMT_WT.
Layomi Akinrinade [Wed, 24 Mar 2021 22:54:44 +0000 (15:54 -0700)]
Align dictionary key converter/metadata retrieval with pattern for collection elements (#50074)
* Align dictionary key converter/metadata retrieval with pattern for collection elements
* Address review feedback
Tomáš Rylek [Wed, 24 Mar 2021 22:50:08 +0000 (15:50 -0700)]
Fix CoreCLR runtime in the presence of 1-file composite images (#50188)
I hit this while creating a regression test for the issue #49982.
In the initial composite R2R design I proposed slightly different
organization of the header tables when the composite image
only comprises a single file; later on I removed this special
casing as it was confusing and making the format more complicated
but apparently I forgot to fix this runtime bit. When there's a
composite image with only one component in it, we weren't properly
initializing the component header table and so we were unable to
resolve any R2R methods for the composite image.
Thanks
Tomas
Jeff Handley [Wed, 24 Mar 2021 22:16:38 +0000 (15:16 -0700)]
Include the iOS, Android, and macCatalyst supported platforms (#50143)
Stephen Toub [Wed, 24 Mar 2021 21:24:43 +0000 (17:24 -0400)]
Avoid multiple exceptions at startup from MsQuic support tests (#49973)
Aleksey Kliger (λgeek) [Wed, 24 Mar 2021 21:23:24 +0000 (17:23 -0400)]
[mbr] Fix null ptr use (#50173)
g_getenv can return NULL if the env var is unset
Ankit Jain [Wed, 24 Mar 2021 21:15:34 +0000 (17:15 -0400)]
[wasm] Add support for using emscripten from packages (#50077)
* [wasm] Add support for using emscripten from packages
When using a workload that has the emscripten packages, certain
properties get set. If that isn't set then we fallback to using
`$(EMSDK_PATH)`.
This should allow being able to use emscripten from workloads, but for
other cases where we depend on an installed emscripten, that should work
too.
* Fix setting PATH on windows
* Using msbuild NormalizeDirectory to construct dir path
* fix setting PATH on windows, when paths have trailing slash
* [wasm] Improve checking emscripten from workload, and EMSDK_PATH
- If a workload pack is being used, then ignore `EMSDK_PATH`
- And error in that order too
- Emit better error messages
Example messages:
- Missing python dir when relinking:
`warning : Specified Emscripten sdk at $(EMSDK_PATH)=. is missing some paths: $(EmscriptenPythonToolsPath)=/Users/radical/dev/r3/artifacts/bin/Wasm.Build.Tests/net6.0-Release/browser-wasm/e10djxv0.wdr/python/3.7.4-2_64bit/ . Emscripten SDK is required for building native files.`
- Missing node directory, or the wrong version dir:
`warning : Specified Emscripten sdk at $(EMSDK_PATH)=/Users/radical/dev/r3/src/mono/wasm/emsdk is missing some paths: $(EmscriptenNodeToolsPath)=/Users/radical/dev/r3/src/mono/wasm/emsdk/node/12.18.1_64bit/ . Emscripten SDK is required for building native files.`
- Empty `EMSDK_PATH`
`Error : Could not find Emscripten sdk at $(EMSDK_PATH)=/Users/radical/dev/r3/src/mono/wasm/emsdk/. Emscripten SDK is required for AOT'ing assemblies.`
- Bad `EMSDK_PATH`
`error : Specified Emscripten sdk at $(EMSDK_PATH)=. is missing some paths: $(EmscriptenPythonToolsPath)=/Users/radical/dev/r3/artifacts/bin/Wasm.Build.Tests/net6.0-Release/browser-wasm/l2mcsipf.isn/python/3.7.4-2_64bit/ . Emscripten SDK is required for AOT'ing assemblies.`
* [wasm] Don't hardcode versions for python/node bundled in emsdk
.. and listen to @lewing's suggestions!
* [wasm] GetDirectories doesn't like non-existant paths
* Fix the earlier fix
* improve errors when some paths are missing
* cleanup
* debugging on ci
* [wasm] emscripten uses system python on linux, so don't try to find it in emscripten sdk
Eirik Tsarpalis [Wed, 24 Mar 2021 21:13:15 +0000 (21:13 +0000)]
Fix PriorityQueue not deleting references to dequeued elements (#50182)
* Fix #50114
* add debug assertions to MoveUp/Down methods
Sergey Andreenko [Wed, 24 Mar 2021 18:20:11 +0000 (11:20 -0700)]
Disable a failing test. (#50160)
Eric Erhardt [Wed, 24 Mar 2021 17:57:08 +0000 (12:57 -0500)]
Fix string.Remove exception message (#50176)
Follow up from #50096
Jeremy Barton [Wed, 24 Mar 2021 17:52:14 +0000 (10:52 -0700)]
Fix cross compilation of XmlSerializer.Generator tests (#50180)
Jeremy Barton [Wed, 24 Mar 2021 17:27:42 +0000 (10:27 -0700)]
Use EVP_PKEY for RSA Decrypt
Zoltan Varga [Wed, 24 Mar 2021 15:49:01 +0000 (11:49 -0400)]
[llvm] Mark stores for reference variables volatile on wasm to avoid llvm moving them. (#50159)
Fixes some GC crashes on WASM+aot.
Sergey Andreenko [Wed, 24 Mar 2021 15:48:08 +0000 (08:48 -0700)]
improve 'optRemoveRedundantZeroInits' (#50155)
It covers cases like:
```
N006 ( 13, 12) [000019] -A-XG---R--- * ASG struct (copy)
N005 ( 9, 9) [000018] n----------- +--* OBJ struct<System.Threading.Tasks.ValueTask, 16>
N004 ( 3, 5) [000017] ------------ | \--* ADDR byref
N003 ( 3, 4) [000014] D------N---- | \--* LCL_FLD struct V03 tmp1 [+0] Fseq[_value]
N002 ( 3, 2) [000015] ---XG------- \--* IND struct
N001 ( 1, 1) [000000] ------------ \--* LCL_VAR byref V00 this
```
Nikola Milosavljevic [Wed, 24 Mar 2021 15:31:18 +0000 (08:31 -0700)]
Pick new version of Microsoft.DotNet.Build.Tasks.Installers (#50153)
Jan Vorlicek [Wed, 24 Mar 2021 14:31:24 +0000 (15:31 +0100)]
Fix Alpine 3.13 ARM build (#50105)
* Fix Alpine 3.13 ARM build
Alpine 3.13 is the first version of Alpine Linux that uses 64 bit time_t
on both 64 and 32 bit platforms. That breaks the build as we assumed
that 32 bit platforms use always 32 bit time_t.
This change fixes it by making the PAL time_t type always 64 bit.
Everything still works fine on non-Alpine ARM / x86 Linuxes, since
it only changes the time_t type size outside of PAL.
* Fix case when time function gets NULL argument
Eric Erhardt [Wed, 24 Mar 2021 13:33:38 +0000 (08:33 -0500)]
Resolve ILLink warnings in System.ComponentModel.Annotations (#49901)
* Resolve ILLink warnings in System.ComponentModel.Annotations
Contributes to #45623
* PR feedback
kronic [Wed, 24 Mar 2021 13:32:28 +0000 (16:32 +0300)]
System.Xml.NameTable optimizations (#49988)
* Slight simplification and acceleration
* use SequenceEqual
* fix nullability
* innline TextEquals
* Inline ComputeHash32
* remove using
* fix nullability
Co-authored-by: kronic <kronic@softland.ru>
Michal Strehovský [Wed, 24 Mar 2021 13:20:04 +0000 (14:20 +0100)]
Make it possible to condition tests on line number support (#50165)
* Update PlatformDetection.cs
* Update ExceptionTests.cs
* Update PlatformDetection.cs
Anton Firszov [Wed, 24 Mar 2021 11:46:32 +0000 (12:46 +0100)]
Improve NonDisposedSocket_SafeHandlesCollected test (#50104)
Apply timeouts in NonDisposedSocket_SafeHandlesCollected
wfurt [Wed, 24 Mar 2021 01:01:36 +0000 (18:01 -0700)]
fix BasicTest_AccessInstanceProperties_NoExceptions_Bsd
jaymin suthar [Mon, 22 Feb 2021 16:03:32 +0000 (21:33 +0530)]
fixes the https://github.com/dotnet/runtime/issues/48062
Egor Bogatov [Wed, 24 Mar 2021 09:55:13 +0000 (12:55 +0300)]
JIT: Add rootTreeOp to DumpFg (#50119)
Ulrich Weigand [Wed, 24 Mar 2021 09:29:35 +0000 (10:29 +0100)]
Big-endian fixes: networking stack (#48398)
* Fix various places that assumed host byte order was little-endian,
use appropriate host <-> network byte order conversion instead.
* This in particular affects handling of IPv4 addresses, which
are stored internally in network order.
* Fix endian assumptions in socket option code (GetSockOpt).
* Update test cases and provide /proc test files from a
big-endian system.
Johan Lorensson [Wed, 24 Mar 2021 08:34:12 +0000 (09:34 +0100)]
Fix mono_simd_decompose_intrinsic to only decompose SIMD instructions. (#50109)
Current implemention of mono_simd_decompose_intrinsic was a little too
imprecise when decomposing SIMD instructions. If we add one SIMD
instruction in emit_simd_intrinsics, we flagged complete cfg to be
investigate for SIMD instructions that needs decomposition on Windows.
In mono/mono that worked well enough, but in dotnet/runtime there are
more scenarios where this can cause issues and very hard to debug
issue together with additional set of SIMD intrinsics.
If we for example emit SN_get_Count and SN_get_IsHardwareAccelerated
that won't add any specific SIMD instructions, we still flag cfg that
it includes SIMD instructions that needs to be evaluated for decomposition.
If we then for example had a call using SIMD type directly reusing argument
from method, it would be incorrectly decomposed causing codegen error.
An example where this was observed was in SpanHelpers.Char LocateFirstFoundChar
that triggered an error returning incorrect value from method, causing
IndexOf to report incorrect index in some specific cases. Since it uses
count on Vector type, the cfg will be flagged to use SIMD instructions
that may need decomposition and when function is not inlined (debug build)
call to AsVectorUInt64 will directly take match from argument list, so
code thinks it needs to decompose that value type before passing it to
AsVectorUInt64, that is just a regular method taking value type as argument
so it already handles the case (unlike the SIMD intrinsics).
Fix makes the check if we should decompose source/dest regs more precise
and will only apply to registers that are xregs, meaning that they are
part of a SIMD instruction.
Maxim Lipnin [Wed, 24 Mar 2021 08:06:24 +0000 (11:06 +0300)]
Set default features flags to match to iOS SDK defaults (#49635)
Contributes to #43865.
Based on https://github.com/xamarin/xamarin-macios/blob/
834b0888853210ca01d5e8f5ce2c65fe9c55fc10/dotnet/targets/Xamarin.Shared.Sdk.targets#L138-L146
The changes:
- added a property group with iOS/iOSSimulator default feature flags;
- aligned the conditions to check the properties activating the defaults for true in order to follow better msbuild practice.
Eric Rafalovsky [Wed, 24 Mar 2021 07:58:52 +0000 (03:58 -0400)]
Add test coverage for Module.GetMethod/s (#50076)
Fix dotnet/runtime#49926
Anton Lapounov [Wed, 24 Mar 2021 07:23:29 +0000 (00:23 -0700)]
Put back DiaSymReader library for cross-arch crossgen to package (#50149)
yowl [Wed, 24 Mar 2021 07:13:53 +0000 (02:13 -0500)]
move gen[]s to compiler.cpp as they are declared in compiler.h/hpp (#50141)
Larry Ewing [Wed, 24 Mar 2021 02:56:04 +0000 (21:56 -0500)]
Don't bundle the LLVM optimizer on wasm we use the emscripten version (#50132)
Matt Johnson-Pint [Wed, 24 Mar 2021 01:34:09 +0000 (18:34 -0700)]
Improve time zone display names on Unix (#48931)
Larry Ewing [Wed, 24 Mar 2021 01:05:08 +0000 (20:05 -0500)]
Skip ninja and cmake errors in aotcrossonly mode (#50140)
dotnet-maestro[bot] [Tue, 23 Mar 2021 22:11:00 +0000 (23:11 +0100)]
Update dependencies from https://github.com/mono/linker build
20210322.2 (#50090)
Microsoft.NET.ILLink.Tasks
From Version 6.0.100-preview.2.21169.4 -> To Version 6.0.100-preview.2.21172.2
Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Egor Bogatov [Tue, 23 Mar 2021 22:01:51 +0000 (01:01 +0300)]
JIT: Fold null checks against initialized static readonly fields (#50000)
Co-authored-by: Andy Ayers <andya@microsoft.com>
Co-authored-by: Sergey Andreenko <seandree@microsoft.com>
Jo Shields [Tue, 23 Mar 2021 21:38:46 +0000 (17:38 -0400)]
We shouldn't provision emsdk on cross-compiler builds, which don't need it (#50098)
Bruce Forstall [Tue, 23 Mar 2021 21:01:40 +0000 (14:01 -0700)]
Comments and cleanup for loop cloning (#49768)
* Comments and cleanup for loop cloning
This is a no-diff change
Added various comments to document loop cloning.
Standardized and improved some logging.
Consolidated more loop cloning condition checking into
`optIsLoopClonable` that was previously in `optIdentifyLoopOptInfo`.
Replaced some `0` weights with `BB_ZERO_WEIGHT`.
Made FMT_BB use pervasive.
* Review feedback
Added FMT_LP formatting string.
Cached often-used `optLoopTable[loopInd]` expression.
Added `const` to many loop query member functions.
Added static `GenTree::OperIs(compareOper, oper, oper, oper...)`
functions for simplifying oper check expressions where the
compareOper isn't from a GenTree node `OperGet()`. (This doesn't
need to be part of GenTree, but it doesn't hurt, either.)
Added a few more comments.
* Fix static OperIs
Rename to StaticOperIs. It appears the compiler uses the wrong
template in some cases, but doesn't complain about duplicate
options, leading to run-time failures.
Viktor Hofer [Tue, 23 Mar 2021 20:36:19 +0000 (21:36 +0100)]
Remove ProjectGuids from libs projects and update slngen (#48551)
* Remove ProjectGuids from libs projects
Based on this comment: https://github.com/dotnet/project-system/issues/6830#issuecomment-
782591566
* Update slngen
* Add required NuGet.config