platform/upstream/dotnet/runtime.git
2 years agoDon't hardcode /tmp in named pipe tests, it's not for us on Android (#73067)
Jo Shields [Mon, 1 Aug 2022 14:27:35 +0000 (10:27 -0400)]
Don't hardcode /tmp in named pipe tests, it's not for us on Android (#73067)

Closes: #49873

2 years agoRemove 1024 character limit on ODBC connection strings (#73149)
Shay Rojansky [Mon, 1 Aug 2022 14:17:44 +0000 (17:17 +0300)]
Remove 1024 character limit on ODBC connection strings (#73149)

Fixes #63630

2 years agoRemove cctor from X500NameEncoder (#73115)
Kevin Jones [Mon, 1 Aug 2022 13:46:14 +0000 (09:46 -0400)]
Remove cctor from X500NameEncoder (#73115)

2 years ago[Unix] Console.ReadKey rewrite (#72193)
Adam Sitnik [Mon, 1 Aug 2022 12:48:33 +0000 (14:48 +0200)]
[Unix] Console.ReadKey rewrite (#72193)

* split TermInfo related logic into separate files, so they can be referenced from test project

* move the key mapping logic to a separate class, do NOT change it

* simple tests for ASCII characters

* test cases for xterm and xterm-256color

* add PuTTY

* add Windows Terminal data

* add more PuTTY test cases

* add mappings for single characters

* add mappings for 3 characters

* fix test cases where pressing Ctrl/Alt/Shift + other key produces two bytes which represent single UTF8 character by design

* handle more complex sequences (with modifiers)

* handle edge cases properly

* add tmux test data

* add rxvt-unicode test data and implementation for rxvt modifiers

* switch to the new implementation and allow the users to differentiate between Enter (\r) and Ctrl+Enter (\n) like we do on Windows

* add way more test cases and fix identified issues

* add more SCO mappings

* Numeric Keypad

* add Tmux 256 color test cases (TERM=screen-256color)

* fix issue discovered by adding more tmux test cases: ^[OM should be mapped to Enter

* address code review feedback

* add .NET 6 compat switch

* Apply suggestions from code review

Co-authored-by: David Cantú <dacantu@microsoft.com>
* address code review feedback

Co-authored-by: David Cantú <dacantu@microsoft.com>
2 years agoAdd more DataFlow tests from linker to NativeAOT (#72777)
Vitek Karas [Mon, 1 Aug 2022 08:26:50 +0000 (01:26 -0700)]
Add more DataFlow tests from linker to NativeAOT (#72777)

This adds several dataflow tests from linker - only those which are passing with the fixes in this change. More will be added later.

Fixes:
- Correctly handle Requires attributes in generic types
- Recognize `ref Type` as interesting for data flow
- Fix generic parameter propagation for compiler generated types
- Treat multi-dimensional arrays as "Unknown" values (to match linker behavior)
- Improve origin of warnings generated from attributes

2 years ago[mono][interp] Improve tiering performance (#70649)
Vlad Brezae [Mon, 1 Aug 2022 08:18:14 +0000 (11:18 +0300)]
[mono][interp] Improve tiering performance (#70649)

* [mono][interp] Don't allocate some vars as execution stack

It is not really true and it serves no purpose here.

* [mono][interp] Print code before any optimizations take place

Fix bitrotten mono_interp_print_td_code. Don't print IL_SEQ_POINT opcodes since they are too noisy.

* [mono][interp] Use td->optimized directly in more places

* [mono][interp] Add dummy MINT_LDNULL instruction

We were pushing local that wasn't defined by any instruction, potentially confusing the var offset allocator.

* [mono][interp] Add fast offset allocator, to be used by unoptimized code

This is the old offset allocation scheme that we were using originally, before the var offset allocator was added. Vars have the same offset as they would have in IL code, based on their position on the execution stack at the moment when they are pushed. Whenever we push/pop on the execution stack we keep track of the used stack size. Every var pushed on the execution stack will therefore have this stack_offset remembered. Once the entire IL code is traversed and we have all the global locals allocated, the real offset of the execution stack locals can be determined. It is computed as the originally determined stack_offset added with the offset of the execution stack start (size of the global locals space).

With this offset allocator, calls no longer need to store all the call args sregs and the return_offset is always the same as call_args_offset. This is because all vars are directly placed in the right position and no optimizations can move them around. The offset of the return value will therefore be also the offset where all the args are placed.

The limitation with this way of allocating offsets is that we run into the same problems with opcodes that don't have typical stack usage (use values, pop them, store result). This happens with newobj opcodes. The opcode receives the params, and then it needs to call a ctor with these same params and a newly allocated this object. Since we can't use a var offset allocation pass to compute the offset ideally, the newobj opcodes in the case of unoptimized code must move these params around on the stack, in order to make room for `this`.

* [mono][interp] Add dreg to all calls in unoptimized code

All calls need to have a dreg (a dummy one if it is void call), in order for unoptimized offset allocator to determine the offset of the call. In unoptimized code, the offset of the first argument is always the same as the offset of the return, if any.

* [mono][interp] Fix issue with passing of exvars

Unoptimized code can't use a global local directly (like the exvar), it must first be pushed to a new var on the execution stack. Add a mov instruction when we start executing the basic block for a handler.

2 years agoAdd localloc empty stack verification (#73109)
Denis Proshutinskii [Mon, 1 Aug 2022 08:12:24 +0000 (15:12 +0700)]
Add localloc empty stack verification (#73109)

* Add localloc empty stack verification
* Update error message
* Add more tests
* Fix tests

Co-authored-by: Jan Kotas <jkotas@microsoft.com>
Co-authored-by: Dan Moseley <danmose@microsoft.com>
2 years agoAdd some QuicListener tests (#73072)
Radek Zikmund [Mon, 1 Aug 2022 07:13:37 +0000 (09:13 +0200)]
Add some QuicListener tests (#73072)

2 years agoLink issue to the RDC attribute on DispatchProxy (#73137)
Michal Strehovský [Mon, 1 Aug 2022 05:36:38 +0000 (14:36 +0900)]
Link issue to the RDC attribute on DispatchProxy (#73137)

2 years agoFix assert in NativeAOT when handling data flow on compiler generated code. (#73085)
Vitek Karas [Mon, 1 Aug 2022 05:35:14 +0000 (22:35 -0700)]
Fix assert in NativeAOT when handling data flow on compiler generated code. (#73085)

The problem occurs when an entire type/assembly is preserved through explicit rooting (command line, rd.xml, ...). If such type contains a local function (for example) which is only called from a branch which is going to be removed by constant-prop/branch removal the internal tracking of compiler generated methods will see this local function as orphaned (not belonging to any user method). This leads to a case where we will try to run data flow on the local function - but that should never happen for compiler generated methods directly -> assert.

The fix is (just like in the linker), to never run data flow on compiler generated methods directly - they should only run data flow as part of their respective user method.

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

2 years agoEnable more libraries tests (#73104)
Michal Strehovský [Mon, 1 Aug 2022 04:08:19 +0000 (13:08 +0900)]
Enable more libraries tests (#73104)

2 years agoUpdate CLRConfig knob description (#73133)
Aaron Robinson [Mon, 1 Aug 2022 00:35:11 +0000 (17:35 -0700)]
Update CLRConfig knob description (#73133)

2 years agoAdd TPN entry for Date/Time processing algorithm (#73128)
Dan Moseley [Sun, 31 Jul 2022 20:38:01 +0000 (21:38 +0100)]
Add TPN entry for Date/Time processing algorithm (#73128)

2 years agoAdd documentation for hot/cold splitting (#73029)
Aman Khalid [Sun, 31 Jul 2022 15:26:46 +0000 (08:26 -0700)]
Add documentation for hot/cold splitting (#73029)

* Add documentation for hot/cold splitting

* Address feedback

* Improve phrasing

2 years ago30% optimization of `DateTime.GetDate()`/`.Year/.Month/.Day/.DayOfYear` by 'Euclidean...
Sergei Pavlov [Sun, 31 Jul 2022 15:07:22 +0000 (08:07 -0700)]
30% optimization of `DateTime.GetDate()`/`.Year/.Month/.Day/.DayOfYear` by 'Euclidean affine functions' (#72712)

* Optimize DateTime.GetDate()/.GetDatePart() by 'Euclidean affine functions'

* Code style

* Refactoring: avoid switch and 'var' keyword; add March1BasedDayOfNewYear constant

* Fix build

* Add [MethodImpl(MethodImplOptions.AggressiveInlining)] to GetDatePart()

* revert relevant comments from original code

* Inline calculations into properties: Year, Month, Day, DayOfYear instead of Common GetDatePart() function

* Fix indentation

* align comment

2 years agoJIT: have jit tail call stress avoid creating loops in some cases (#73114)
Andy Ayers [Sun, 31 Jul 2022 15:04:13 +0000 (08:04 -0700)]
JIT: have jit tail call stress avoid creating loops in some cases (#73114)

Don't create a loop via tail call stress if the method didn't already have a loop and could have patchpoints.

Fixes #73090.

2 years ago[Android] Don't exclude .gz files from assets.zip (#73077)
Jo Shields [Sun, 31 Jul 2022 12:39:41 +0000 (08:39 -0400)]
[Android] Don't exclude .gz files from assets.zip (#73077)

Closes: #36845

2 years ago[GC] Handle objects from frozen segments in GCHeap::IsEphemeral (#73110)
Egor Bogatov [Sun, 31 Jul 2022 05:42:25 +0000 (07:42 +0200)]
[GC] Handle objects from frozen segments in GCHeap::IsEphemeral (#73110)

2 years agoRemove undefined behavior for address of null reference (#73113)
Aaron Robinson [Sun, 31 Jul 2022 03:34:07 +0000 (20:34 -0700)]
Remove undefined behavior for address of null reference (#73113)

2 years agoImplement test checking whether CET is active (#71509)
Tomáš Rylek [Sat, 30 Jul 2022 15:39:54 +0000 (17:39 +0200)]
Implement test checking whether CET is active (#71509)

As part of Control Flow Enforcement Technology (CET) testing we need
to make sure that CET is actually active on the execution machines;
otherwise subtle infra changes could easily regress the testing by
inadvertently deactivating CET without anyone noticing. This change
introduces an initial CET availability test for this purpose.

Thanks

Tomas

2 years agoAdd retry to symlink test (#73042)
Dan Moseley [Sat, 30 Jul 2022 07:04:11 +0000 (01:04 -0600)]
Add retry to symlink test (#73042)

2 years agoMove System.ValueType.s_seed into System.Runtime.CompilerServices.RuntimeHelpers...
Gregg Miskelly [Sat, 30 Jul 2022 02:52:48 +0000 (19:52 -0700)]
Move System.ValueType.s_seed into System.Runtime.CompilerServices.RuntimeHelpers (#73080)

PR https://github.com/dotnet/runtime/pull/69723 added a 's_seed' field to
System.ValueType. This causes the debugger to show all structs as having
static members. This PR moves the field and the function that used it into RuntimeHelpers.

2 years agoAnnotate System.Linq.Queryable with RDC (#72899)
Andy Gocke [Sat, 30 Jul 2022 00:40:35 +0000 (17:40 -0700)]
Annotate System.Linq.Queryable with RDC (#72899)

Annotates for RequiresDynamicCode, which represents AOT safety.

2 years agoAppropriately free temporary values on EC import
Jeremy Barton [Fri, 29 Jul 2022 21:55:54 +0000 (14:55 -0700)]
Appropriately free temporary values on EC import

EC import from parameters calls into a series of set-routines that neither
self-describe their ownership of the reference counted inputs (`set0` vs `set1`)
nor document them.

Looking at code usage examples, and underlying code, they are all logically
`set1`-style routines, in that they do not take ownership of the inputs, which
means we need to free the BN values on both success and failure.  This assertion
was verified by an intermediate change that reset all numbers to 1
(e.g. `BN_one(qxBn)`) and watched for test failures.  When none of our tests
failed with that change, it moved to the freeing form.

Verified with importing the cross-product of:
{ secp256r1, sect163k1 }
x
{ named curve, explicit parameters }
x
{ q + d, q only, d only }

2 years agoDisable NJulianRuleTest on Android (#73030)
Tarek Mahmoud Sayed [Fri, 29 Jul 2022 21:36:15 +0000 (21:36 +0000)]
Disable NJulianRuleTest on Android (#73030)

Co-authored-by: Ilona Tomkowicz <32700855+ilonatommy@users.noreply.github.com>
2 years agoAdd EH filters for generic catch(T) blocks (#72721)
Egor Bogatov [Fri, 29 Jul 2022 21:29:50 +0000 (23:29 +0200)]
Add EH filters for generic catch(T) blocks (#72721)

Co-authored-by: Jan Kotas <jkotas@microsoft.com>
2 years agoAdd stateful marshaller support to the CustomMarshallerAttributeAnalyzer (#72888)
Jeremy Koritzinsky [Fri, 29 Jul 2022 21:21:34 +0000 (14:21 -0700)]
Add stateful marshaller support to the CustomMarshallerAttributeAnalyzer (#72888)

2 years agoUpdate ConvertToLibraryImport analyzer and fixer to limit false-positives/code breaks...
Jeremy Koritzinsky [Fri, 29 Jul 2022 21:18:59 +0000 (14:18 -0700)]
Update ConvertToLibraryImport analyzer and fixer to limit false-positives/code breaks (#72965)

2 years agoFix incremental XxHash32/XxHash64 (#69185)
froce [Fri, 29 Jul 2022 20:32:53 +0000 (22:32 +0200)]
Fix incremental XxHash32/XxHash64 (#69185)

2 years agoFix crc32 issues found in #62692 (#73005)
Egor Bogatov [Fri, 29 Jul 2022 20:20:04 +0000 (22:20 +0200)]
Fix crc32 issues found in #62692 (#73005)

2 years agoRefactor root-level serialization logic and polymorphic value handling. (#72789)
Eirik Tsarpalis [Fri, 29 Jul 2022 19:32:35 +0000 (20:32 +0100)]
Refactor root-level serialization logic and polymorphic value handling. (#72789)

* Refactor root-level serialization logic and polymorphic value handling.

* Address feedback

* Do not consult metadata LRU cache in JsonResumableConverter bridging logic.

* Use secondary LRU cache when resolving root-level polymorphic types.

* Add test coverage for root-level polymorphic values in JsonTypeInfo<T> JsonSerializer methods.

* Change caching strategy for root-level polymorphic values.

* Update src/libraries/System.Text.Json/src/System/Text/Json/Serialization/JsonSerializer.Helpers.cs

* Remove commented out code

2 years agorecursive generic fix (#73071)
Vladimir Sadov [Fri, 29 Jul 2022 18:17:05 +0000 (11:17 -0700)]
recursive generic fix (#73071)

2 years ago[wasm] `JSImport` generator `AllowUnsafeBlocks` diagnostic (#72996)
Pavel Savara [Fri, 29 Jul 2022 17:48:06 +0000 (19:48 +0200)]
[wasm] `JSImport` generator `AllowUnsafeBlocks` diagnostic (#72996)

- added `JSImportAttribute requires unsafe code` + unit test
- fixed Diagnostic IDs + reservation
- moved System.Runtime.InteropServices.JavaScript.UnitTests to subfolder

2 years agoDefine __cpuid{ex} only when there's no builtin one (#73065)
Adeel Mujahid [Fri, 29 Jul 2022 16:34:00 +0000 (19:34 +0300)]
Define __cpuid{ex} only when there's no builtin one (#73065)

* Define __cpuid{ex} only when there's no builtin one

Fix clang 15 RC1 build: `error: definition of builtin function '__cpuid'`

* Add clang-15 autodetection

2 years agoLocalized file check-in by OneLocBuild Task: Build definition ID 679: Build ID 191026...
dotnet bot [Fri, 29 Jul 2022 14:10:10 +0000 (07:10 -0700)]
Localized file check-in by OneLocBuild Task: Build definition ID 679: Build ID 1910260 (#73028)

2 years agore-enable tests for 66421 (#73052)
Krzysztof Wicher [Fri, 29 Jul 2022 13:23:45 +0000 (15:23 +0200)]
re-enable tests for 66421 (#73052)

2 years ago[wasm-ep] diagnostic server IPC fixups (#72859)
Aleksey Kliger (λgeek) [Fri, 29 Jul 2022 13:06:14 +0000 (09:06 -0400)]
[wasm-ep] diagnostic server IPC fixups (#72859)

* [wasm-ep] Trim trailing nul when parsing IPC command strings

The protocol spec says there's a length and a nul terminator, but sending that literal UTF-16 nul to ep_enable_2 means we use an incorrect name when looking for the provider.

* [wasm-ep] Fix formating of event pipe provider strings

   convert the 64-bit "keywords" mask into a hex string properly by padding both halves with zeroes after calling the JS Number.toString() method

* use Array splice instead of String substring

* Address review feedback

2 years agoFix UnsupportedOSPlatformAttribute usage in System.Net.NetworkInformation.cs (#72792)
Radek Zikmund [Fri, 29 Jul 2022 10:56:02 +0000 (12:56 +0200)]
Fix UnsupportedOSPlatformAttribute usage in System.Net.NetworkInformation.cs (#72792)

* Test attribute on IsDnsEligible

* Add more attributes

* Icmp statistics

* IPGlobalProperties

* IPInterfaceProperties

* IPInterfaceStatistics

* Replace unsupportedOS attribute by SupportedOS attribute

* IPv4/6InterfaceProperties

2 years ago[NativeAOT] Fix assert in Thread.SpinWait(0) (#73033)
Vladimir Sadov [Fri, 29 Jul 2022 09:57:56 +0000 (02:57 -0700)]
[NativeAOT] Fix assert in Thread.SpinWait(0) (#73033)

* do not inline long wait

2 years agoMake JSON support required properties (#72937)
Krzysztof Wicher [Fri, 29 Jul 2022 08:06:08 +0000 (10:06 +0200)]
Make JSON support required properties (#72937)

* Throw exception when 'required' keyword used but ctor does not have 'SetsRequiredMembers'

* Support required keyword (and internal IsRequired)

* remove local variable (forgot to press Save All)

* revert added namespaces in two files

* Apply feedback

* apply second round of feedback (minus HashSet optimization)

* Use BitArray rather than HashSet

* simplify validation code

* Truncate the message if too long, flip meaning of bit array bits

* remove default value, add description for BitArray

* for compiler attributes check for full type name rather than using typeof on net7.0

2 years agoUnblock tests blocked on 70012 (#73044)
Michal Strehovský [Fri, 29 Jul 2022 06:00:55 +0000 (15:00 +0900)]
Unblock tests blocked on 70012 (#73044)

2 years agoFixing the per object hard limit support for regions (#72229)
Andrew Au [Fri, 29 Jul 2022 05:36:01 +0000 (22:36 -0700)]
Fixing the per object hard limit support for regions (#72229)

2 years agoImplementation of opcode OP_GC_SAFE_POINT for ppc64le (#72997)
Alhad Deshpande [Fri, 29 Jul 2022 04:55:15 +0000 (10:25 +0530)]
Implementation of opcode OP_GC_SAFE_POINT for ppc64le (#72997)

* Avoid transformation from multiplication to left shift in case of 64 bit value

* Fixed System.Collections.Concurrent.Tests timeout issue

2 years agoRun more test on NativeAOT Linux (#72832)
Michal Strehovský [Fri, 29 Jul 2022 04:16:32 +0000 (13:16 +0900)]
Run more test on NativeAOT Linux (#72832)

2 years agoGet more libraries tests running with NativeAOT (#72917)
Michal Strehovský [Fri, 29 Jul 2022 04:11:34 +0000 (13:11 +0900)]
Get more libraries tests running with NativeAOT (#72917)

* MetadataLoadContext tests need more work for single file testing in general. Filed a separate issue.
* S.R.Intrinsics is now clean. Running it on NativeAOT found good JIT bugs (#72081, #72158). Promoting to a smoke test.
* S.Drawing.Primitives was testing DataContractSerializer for whatever reason. Marked that as aggresive trimming incompatible. This wouldn't be covered by #72910.
* Made S.R.InteropServices.ComDisabled fully pass by fixing exceptions we throw.
* A couple tests won't ever make sense to run on NativeAOT so removed them from triage area.

2 years agoJIT: Disqualify methods with modifiable `this` from OSR. (#72877)
Andy Ayers [Fri, 29 Jul 2022 00:14:05 +0000 (17:14 -0700)]
JIT: Disqualify methods with modifiable `this` from OSR. (#72877)

Closes #72845.

2 years agoRemove some debug code (#72985)
Aaron Robinson [Thu, 28 Jul 2022 23:46:43 +0000 (16:46 -0700)]
Remove some debug code (#72985)

* Remove stale debug code

Remove the FreeBuildDebugBreak() and DebBreak() API.
Remove BreakOnRetailAssert config knob.
Remove DBGIGNORE logic.
Remove LaunchJITDebugger() API from utilcode.
Remove x86 StackOverflow break config
Remove INTERNAL_DebugBreakOnAssert config knob
Remove unused debug macros and constants
Remove TerminateOnAssert() and DebugBreakOnAssert() logic.
Remove unused NGen bind config knobs
Remove ValidateObject() from rspriv.

2 years agoAdd support for specifying Kerberos package on Linux/macOS (in addition to NTLM and...
Filip Navara [Thu, 28 Jul 2022 23:42:22 +0000 (01:42 +0200)]
Add support for specifying Kerberos package on Linux/macOS (in addition to NTLM and Negotiate) (#72024)

2 years ago[wasm] reduce legacy interop usage (#72021)
Pavel Savara [Thu, 28 Jul 2022 20:33:04 +0000 (22:33 +0200)]
[wasm] reduce legacy interop usage (#72021)

2 years ago[wasm][debugger] Fix assert when passing an invalid array to runtime. (#73006)
Thays Grazia [Thu, 28 Jul 2022 20:32:14 +0000 (17:32 -0300)]
[wasm][debugger] Fix assert when passing an invalid array to runtime. (#73006)

Check if it's an array before calling the array functions.

Fix #65742

2 years agoDo not embed result type in VN for scalar hw intrinsics (#72895)
Kunal Pathak [Thu, 28 Jul 2022 20:21:20 +0000 (13:21 -0700)]
Do not embed result type in VN for scalar hw intrinsics (#72895)

* do not embed result type for scalar hw intrinsics

* Check the simdSize

* oversight fix

2 years agoAvoid promoting in sweep_in_plan when we already decided not to promote (#72998)
Andrew Au [Thu, 28 Jul 2022 19:52:19 +0000 (12:52 -0700)]
Avoid promoting in sweep_in_plan when we already decided not to promote (#72998)

2 years agoUpdate the CustomMarshallerAttributeFixer to support adding missing methods for state...
Jeremy Koritzinsky [Thu, 28 Jul 2022 18:37:35 +0000 (11:37 -0700)]
Update the CustomMarshallerAttributeFixer to support adding missing methods for stateless marshaller shapes (#72869)

2 years agoAdded remaining APIs to complete NativeMemory set (#72960)
SRV [Thu, 28 Jul 2022 18:13:44 +0000 (21:13 +0300)]
Added remaining APIs to complete NativeMemory set (#72960)

* Implemented Copy method

* Added Fill implementation

* Review feedback

* Fixed tests naming convention

* Added tests for Fill method

* More test cases for overlapped memory copy

* Removed unused MemSet native function

2 years agoUse the common path for lowering single-reg SIMD returns (#72944)
SingleAccretion [Thu, 28 Jul 2022 17:23:29 +0000 (20:23 +0300)]
Use the common path for lowering single-reg SIMD returns (#72944)

* Use the common path for lowering single-reg SIMD returns

This handles type mismatches that morph can create.

* Avoid regressions from RA copies

Lowering will now retype non-reg-candidate LCL_VAR nodes to LCL_FLD
ones in more circumstances, and this pessimizes LSRA a bit.

Apply the same fix as used by the LCL_VAR case. This turns out to
be a good CQ improvement on its own as well.

* Add a test

* Add more tests

* Fix CNS_INT handling

* Fix another similar issue

And remove the duplicative special handling of HWI/SIMD nodes.

2 years agoAnnoating Net.Quic & Net.Security libraries to be AOT safe (#72791)
Lakshan Fernando [Thu, 28 Jul 2022 17:16:37 +0000 (10:16 -0700)]
Annoating Net.Quic & Net.Security libraries to be AOT safe (#72791)

* Annoating Net.Quic & Net.Security libraries to be AOT safe

* changing the justification msg as per FB

* workaround for issue 72833

2 years agoHTTP/3 Made alt-used show only on alt-svc redirect (#72669)
Corcodel Iulia [Thu, 28 Jul 2022 17:02:57 +0000 (20:02 +0300)]
HTTP/3 Made alt-used show only on alt-svc redirect (#72669)

* #56876 issue test

* Implemented Alt-Used compliance

* resolved code review

* changed variable name

* removed white spaces

* Update src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Http3.cs

Co-authored-by: Natalia Kondratyeva <knatalia@microsoft.com>
* Update src/libraries/System.Net.Http/tests/FunctionalTests/HttpClientHandlerTest.Http3.cs

Co-authored-by: Natalia Kondratyeva <knatalia@microsoft.com>
Co-authored-by: iuliaco <t-icorcodel@microsoft.com>
Co-authored-by: Natalia Kondratyeva <knatalia@microsoft.com>
2 years agoFix `ldelem[a]/stelem/cpobj/ldobj/stobj <pointer type>` import (#71679)
SingleAccretion [Thu, 28 Jul 2022 16:56:15 +0000 (19:56 +0300)]
Fix `ldelem[a]/stelem/cpobj/ldobj/stobj <pointer type>` import (#71679)

2 years ago[mono][jit] Use MONO_CLASS_IS_SIMD () in more places to fix running with -O=-simd...
Zoltan Varga [Thu, 28 Jul 2022 16:17:13 +0000 (12:17 -0400)]
[mono][jit] Use MONO_CLASS_IS_SIMD () in more places to fix running with -O=-simd. (#72982)

2 years agoFix race when receiving HEADERS and RST_STREAM in rapid succession. (#72932)
Radek Zikmund [Thu, 28 Jul 2022 15:29:01 +0000 (17:29 +0200)]
Fix race when receiving HEADERS and RST_STREAM in rapid succession. (#72932)

* Fix race when receiving HEADERS and RST_STREAM in rapid succession.

* Improve test

2 years agoEnable tests disabled by issue 36882 (#72931)
Johan Lorensson [Thu, 28 Jul 2022 15:05:07 +0000 (17:05 +0200)]
Enable tests disabled by issue 36882 (#72931)

2 years agoJIT: Skip Min/Max optimization when SSE2 is not enabled (#72991)
Jakob Botsch Nielsen [Thu, 28 Jul 2022 14:42:53 +0000 (16:42 +0200)]
JIT: Skip Min/Max optimization when SSE2 is not enabled (#72991)

Fix #71928

2 years ago[libs][mono] Enable diagnostics_tracing runtime component in Android build and reenab...
Mitchell Hwang [Thu, 28 Jul 2022 14:34:09 +0000 (10:34 -0400)]
[libs][mono] Enable diagnostics_tracing runtime component in Android build and reenable System.Diagnostics.Tracing (#72955)

2 years ago[wasm][debugger] Added support for getting members of static structures. (#69542)
Ilona Tomkowicz [Thu, 28 Jul 2022 14:24:31 +0000 (16:24 +0200)]
[wasm][debugger] Added support for getting members of static structures. (#69542)

* Added info flow about being static + including static.

* Added static testcases to Browsable, changed names to more suitable.

* Fixed tests affected by adding static members to GetProperties reply.

* Removed whitespaces I did not intend to correct.

* Test require full name after merge with main.

* Added @radical's sugestions.

* Fixed tests: Private attr is detected even when it's not set.

* Better way of checking attr flags.

2 years agoFix SslStress docker build (#72940)
Anton Firszov [Thu, 28 Jul 2022 13:46:49 +0000 (15:46 +0200)]
Fix SslStress docker build (#72940)

2 years agoFix evaluate expression of mutidimensional array. (#72964)
Thays Grazia [Thu, 28 Jul 2022 13:17:22 +0000 (10:17 -0300)]
Fix evaluate expression of mutidimensional array. (#72964)

2 years agoLocalized file check-in by OneLocBuild Task: Build definition ID 679: Build ID 190818...
dotnet bot [Thu, 28 Jul 2022 13:00:22 +0000 (06:00 -0700)]
Localized file check-in by OneLocBuild Task: Build definition ID 679: Build ID 1908187 (#72980)

2 years ago[wasm] Wasm.Build.Tests: Use Chrome on windows, instead of V8 (#72983)
Ankit Jain [Thu, 28 Jul 2022 11:30:40 +0000 (07:30 -0400)]
[wasm] Wasm.Build.Tests: Use Chrome on windows, instead of V8 (#72983)

* [wasm] Wasm.Build.Tests: Use Chrome on windows, instead of V8
* Wasm.Build.Tests: Completely disable running tests with V8 on windows

2 years ago#53624 enable test suites in maccatalyst (#72445)
Meri Khamoyan [Thu, 28 Jul 2022 09:13:34 +0000 (13:13 +0400)]
#53624 enable test suites in maccatalyst (#72445)

* #53624 enable test suites in maccatalyst and update ntrampolines

2 years ago[wasm] remove support for CommonJS (#72865)
Pavel Savara [Thu, 28 Jul 2022 08:20:58 +0000 (10:20 +0200)]
[wasm] remove support for CommonJS (#72865)

2 years agoImplement ControlledExecution API (#71661)
Anton Lapounov [Thu, 28 Jul 2022 06:38:38 +0000 (23:38 -0700)]
Implement ControlledExecution API (#71661)

2 years agoAdd extra Module.ModuleHandle test (#72875)
Marek Safar [Thu, 28 Jul 2022 06:13:35 +0000 (08:13 +0200)]
Add extra Module.ModuleHandle test (#72875)

* Add extra Module.ModuleHandle test

* Update src/libraries/System.Runtime/tests/System/Reflection/ModuleTests.cs

Co-authored-by: Jan Kotas <jkotas@microsoft.com>
* Fix mono implementation

Co-authored-by: Jan Kotas <jkotas@microsoft.com>
2 years agoMinor cleanup in MethodDesc::GetPrecompiledCode (#72963)
Juan Hoyos [Thu, 28 Jul 2022 05:22:35 +0000 (22:22 -0700)]
Minor cleanup in MethodDesc::GetPrecompiledCode (#72963)

2 years agoBump timeout on ARM64 NativeAOT legs (#72974)
Michal Strehovský [Thu, 28 Jul 2022 04:34:13 +0000 (13:34 +0900)]
Bump timeout on ARM64 NativeAOT legs (#72974)

2 years ago[wasm][wbt] Test that `dotnet.js` could be run from any current directory (#69441)
Yusuke Yamada [Thu, 28 Jul 2022 03:42:13 +0000 (12:42 +0900)]
[wasm][wbt] Test that `dotnet.js` could be run from any current directory (#69441)

In #72275 we fixed locateFile to deal with relative file path or URL. We could also handle absolute path/URL. This PR is adding tests to prove it works.

2 years agoAdd memory fences to ByRefAssignRef on Unix ARM64 (#72919)
Michal Strehovský [Thu, 28 Jul 2022 00:19:57 +0000 (09:19 +0900)]
Add memory fences to ByRefAssignRef on Unix ARM64 (#72919)

2 years agoDisable tests that wait for compaction (#72954)
Dan Moseley [Thu, 28 Jul 2022 00:17:24 +0000 (18:17 -0600)]
Disable tests that wait for compaction (#72954)

2 years agoRename [RegexGenerator] to [GeneratedRegex] (#72434)
Adeel Mujahid [Thu, 28 Jul 2022 00:14:53 +0000 (03:14 +0300)]
Rename [RegexGenerator] to [GeneratedRegex] (#72434)

Co-authored-by: Jose Perez Rodriguez <joperezr@microsoft.com>
2 years agoFixed HWIntrinsic reflection bug with `NextCallReturnAddress` intrinsic (#72505)
Will Smith [Thu, 28 Jul 2022 00:02:51 +0000 (17:02 -0700)]
Fixed HWIntrinsic reflection bug with `NextCallReturnAddress` intrinsic (#72505)

* Adding more asserts

* Another assert

* Force add a label

* Extra check

* Remove cookie set

* Added check for compHasNextCallRetAddr for hw intrinsics

* Added additional checks

* Conslidate compHasNextCallRetAddr

* Remove extra assert

* Fixing some logic

* Remove opt check

* Reverting back to original nextcallretaddr logic

* Fix formatting

* Fix formatting

2 years agoRemove a few hardcoded instances of "net7.0" (#72950)
Alexander Köplinger [Wed, 27 Jul 2022 22:30:28 +0000 (00:30 +0200)]
Remove a few hardcoded instances of "net7.0" (#72950)

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

The xunit runner package defines a property `XunitConsoleNetCore21AppPath` which (despite the name) points to the xunit.console.dll, we can use that instead.

The properties for the workloads/installer tasks aren't needed either since the packages already define them.

2 years agoAdd SqlTypes apis for SqlClient (#72724)
Wraith [Wed, 27 Jul 2022 22:03:11 +0000 (23:03 +0100)]
Add SqlTypes apis for SqlClient (#72724)

* SqlMoney changes

* SqlDecimal changes

* SqlBinary changes

* add CLS compliance attributes

2 years agoMake revocation tests use CRLBuilder when it can instead of its own copy
Jeremy Barton [Wed, 27 Jul 2022 21:41:39 +0000 (14:41 -0700)]
Make revocation tests use CRLBuilder when it can instead of its own copy

2 years agoDisable CrlBuilderTests.BuildEmptyRsaPss on Android
Jeremy Barton [Wed, 27 Jul 2022 21:39:51 +0000 (14:39 -0700)]
Disable CrlBuilderTests.BuildEmptyRsaPss on Android

2 years agoCMake support in VS open folder for coreclr (#70285)
Huo Yaoyuan [Wed, 27 Jul 2022 21:39:30 +0000 (05:39 +0800)]
CMake support in VS open folder for coreclr (#70285)

* Basic building support

* Add windows platform matrix

* Add open folder debug instructions

2 years ago[Mono][Arm64] Instrinsify methods for Vector4 on Arm64 (#72124)
Fan Yang [Wed, 27 Jul 2022 17:17:06 +0000 (13:17 -0400)]
[Mono][Arm64] Instrinsify methods for Vector4 on Arm64 (#72124)

* Initial change to enable intrinsics for Vector4 on arm64

* Fix return

* Add test app

* Also the makefile change

* Fix return type handling from vector to struct

* Fix wasm build failure

* Handle volatile argument

* Promote SIMD return to value

* Address review feedback and add intrinsify more methods

* Assign a NULL pointer to retval

* Remove unused local var

* Fix build warning

2 years agoAdd support for int keyed dictionaries to configuration binder (#71609)
Giuseppe Marazzi [Wed, 27 Jul 2022 17:03:19 +0000 (19:03 +0200)]
Add support for int keyed dictionaries to configuration binder (#71609)

* Add support for int keyed dictionaries to configuration binder

* PR feedback

Co-authored-by: Eric Erhardt <eric.erhardt@microsoft.com>
2 years agoAdd BuildCrlDistributionPointExtension
Jeremy Barton [Wed, 27 Jul 2022 16:56:05 +0000 (09:56 -0700)]
Add BuildCrlDistributionPointExtension

2 years ago[wasm] Modify workload to pick threading runtime packs (#72412)
Steve Pfister [Wed, 27 Jul 2022 16:08:59 +0000 (09:08 -0700)]
[wasm] Modify workload to pick threading runtime packs (#72412)

* [wasm] Modify workload to pick threading runtime packs

This change adds the 2 wasm threading runtime packs to the wasm workload. In order for a threading runtime pack to be chosen, WorkloadManifest.targets is also modified to override the runtime pack name when the following props are set:

WasmEnableThreads - full threading support and will load Microsoft.NETCore.App.Runtime.multithread.Mono.browser-wasm

WasmEnablePerfTrace - runtime only threading support and will load Microsoft.NETCore.App.Runtime.perftrace.Mono.browser-wasm

* Add error condition when both WasmEnableThreading and WasmEnablePerfTrace are true

* [wasm] Set default value for MonoWasmBuildVariant, for runtime pack nuget

* [wasm] Wasm.Build.Tests: build runtime pack nugets with different names

- The earlier approach of simply making copies of the existing runtime
pack nuget with different names doesn't work, and `dotnet workload
install` rejects it.

```
  Installing pack Microsoft.NETCore.App.Runtime.Mono.multithread.browser-wasm version 7.0.0-ci...
  Workload installation failed. Rolling back installed packs...
```

Instead, now we build the missing nugets from the project with different
values for `$(MonoWasmBuildVariant)`.

- this handles local builds, and incremental builds also
- To skip building the missing nugets, for example, when you have all of
them available, then set `WasmSkipMissingRuntimePackBuild=true`.

* fix comment

Co-authored-by: Steve Pfister <steve.pfister@microsoft.com>
Co-authored-by: Ankit Jain <radical@gmail.com>
2 years agoDisable ReadAsync_CancelPendingValueTask_ThrowsCancellationException for Http1 (...
Radek Zikmund [Wed, 27 Jul 2022 16:00:59 +0000 (18:00 +0200)]
Disable ReadAsync_CancelPendingValueTask_ThrowsCancellationException for Http1 (#72854)

2 years agoFix the NJulianRuleTest when running with libc check builds (#72893)
Tarek Mahmoud Sayed [Wed, 27 Jul 2022 15:58:54 +0000 (15:58 +0000)]
Fix the NJulianRuleTest when running with libc check builds (#72893)

Co-authored-by: Tarek Ghonaim <tarek@Tarek-Family.localdomain>
2 years agoRemove InvalidOperationException when reading system properties from EventLogRecords...
Eric StJohn [Wed, 27 Jul 2022 15:30:43 +0000 (08:30 -0700)]
Remove InvalidOperationException when reading system properties from EventLogRecords (#72913)

2 years agoBump timeout for "CoreCLR Tools Unit Tests Linux x64 checked" (#72928)
Alexander Köplinger [Wed, 27 Jul 2022 15:13:27 +0000 (17:13 +0200)]
Bump timeout for "CoreCLR Tools Unit Tests Linux x64 checked" (#72928)

We recently saw more instances of this job running into the default 60mins timeout, bump it to 120mins

2 years agoRe-enable throwinnestedtrycatch_il_r test (#72901)
Kunal Pathak [Wed, 27 Jul 2022 14:51:28 +0000 (07:51 -0700)]
Re-enable throwinnestedtrycatch_il_r test (#72901)

2 years agoFix a couple of issues when using textual PGO input (#72773)
Jakob Botsch Nielsen [Wed, 27 Jul 2022 14:50:11 +0000 (16:50 +0200)]
Fix a couple of issues when using textual PGO input (#72773)

* Ensure non generic method defs when using textual PGO

* Allow static profiles to contain static methods for non-delegate calls

The textual PGO format currently just describes methods by name and does
not include signature information/generic instantiations. This means we
may see various edge cases here. These particular cases would hit asserts.

2 years agoJIT: Avoid removing multi-use boxes (#72842)
Jakob Botsch Nielsen [Wed, 27 Jul 2022 14:48:31 +0000 (16:48 +0200)]
JIT: Avoid removing multi-use boxes (#72842)

There was an assumption that the local operand to a GT_BOX node is
single-use which was being violated when GDV clones these as arguments.
We now allow multi-uses of these locals by setting a flag when cloning
and then handle it in gtTryRemoveBoxUpstreamEffects.

There is also GTF_VAR_CLONED that would be set on the local itself, but
given that transformations can affect the operand local node arbitrarily
I went with another of these type of flags on GT_BOX instead.

Fix #72775

2 years agoEnable GitHub_35821 (#72900)
Kunal Pathak [Wed, 27 Jul 2022 14:14:42 +0000 (07:14 -0700)]
Enable GitHub_35821 (#72900)

2 years agoenable https://github.com/dotnet/runtime/issues/53957 and https://github.com/dotnet...
Pavel Savara [Wed, 27 Jul 2022 13:50:37 +0000 (15:50 +0200)]
enable https://github.com/dotnet/runtime/issues/53957 and https://github.com/dotnet/runtime/issues/57519 (#72843)

2 years agoAdd missing System.Net docs (#72459)
Stephen Toub [Wed, 27 Jul 2022 13:05:59 +0000 (09:05 -0400)]
Add missing System.Net docs (#72459)

* Add missing System.Net docs

* Address PR feedback

* Update src/libraries/System.Net.Http/src/System/Net/Http/Headers/MediaTypeHeaderValue.cs

Co-authored-by: Radek Zikmund <32671551+rzikm@users.noreply.github.com>
Co-authored-by: Radek Zikmund <32671551+rzikm@users.noreply.github.com>
2 years ago[mini] Emit a null check using MONO_EMIT_NEW_CHECK_THIS for GetArrayDataReference...
Aleksey Kliger (λgeek) [Wed, 27 Jul 2022 12:09:41 +0000 (08:09 -0400)]
[mini] Emit a null check using MONO_EMIT_NEW_CHECK_THIS for GetArrayDataReference (#72897)

using MONO_EMIT_NULL_CHECK does not emit a null check in the backend
if the pointer is otherwise unused

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

2 years agoLocalized file check-in by OneLocBuild Task: Build definition ID 679: Build ID 190619...
dotnet bot [Wed, 27 Jul 2022 11:16:12 +0000 (04:16 -0700)]
Localized file check-in by OneLocBuild Task: Build definition ID 679: Build ID 1906193 (#72884)

* Localized file check-in by OneLocBuild Task: Build definition ID 679: Build ID 1905001

* Localized file check-in by OneLocBuild Task: Build definition ID 679: Build ID 1905340