runtime: [x86] SequenceEqual returns false for equal spans
Run: runtime-libraries-coreclr outerloop 20220213.4
Failed test:
net7.0-windows-Release-x86-CoreCLR_release-Windows.Amd64.Server2022.Open
- System.IO.Tests.UnseekableDeviceFileStreamConnectedConformanceTests.ReadWrite_Success_Large(mode: AsyncMemory, writeSize: 10485760, startWithFlush: True)
- System.IO.Tests.AnonymousPipeFileStreamConnectedConformanceTests.ReadWrite_Success_Large(mode: SyncArray, writeSize: 10485760, startWithFlush: False)
Error message:
Showing first 10 differences
Total number of differences: 0 out of 10485760
Stack trace
at System.AssertExtensions.SequenceEqual[T](ReadOnlySpan`1 expected, ReadOnlySpan`1 actual) in /_/src/libraries/Common/tests/TestUtilities/System/AssertExtensions.cs:line 473
at System.IO.Tests.ConnectedStreamConformanceTests.ReadWrite_Success(ReadWriteMode mode, Int32 writeSize, Boolean startWithFlush) in /_/src/libraries/Common/tests/StreamConformanceTests/System/IO/StreamConformanceTests.cs:line 1765
at System.IO.Tests.ConnectedStreamConformanceTests.ReadWrite_Success_Large(ReadWriteMode mode, Int32 writeSize, Boolean startWithFlush) in /_/src/libraries/Common/tests/StreamConformanceTests/System/IO/StreamConformanceTests.cs:line 1719
--- End of stack trace from previous location ---
| Build | Kind | Start Time |
|---|---|---|
| 1612202 | Rolling | 2022-14-02 |
| 1613425 | Rolling | 2022-15-02 |
| 1616198 | Rolling | 2022-16-02 |
| 1616876 | Rolling | 2022-16-02 |
| 1617545 | Rolling | 2022-17-02 |
| 1618267 | Rolling | 2022-17-02 |
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 66 (66 by maintainers)
Yep!!. I got a repro on my mail machine that is Intel (CoffeLake), but runs Win11.
the last tracked piece - porting to 3.1 has been completed. Closing.
Should this be reopened to track the need for servicing backport?
CPU-Z is not very detailed but the
CoreInfo -f(from SysInternals) should be detailed enough. For reference, this is the output on AMD Ryzen 7 5700G where ERMSB is listed as supported:Once we have a full fix, we will likely be taking the fix down level to all supported versions.
Actually, it reproduces even on 6.0.100 SDK, so the range may be much bigger than I anticipated, or there is some external trigger factor.
Update: Also 5.0.403 SDK when I converted the code to
Marshal.Alloc/FreeHGlobal.Where should I ship the machine to? 😂 More realistically, happy to give access to it or test anything that comes along.
I will take a look. I have AMD machines.
@jkotas appologies for that, I’ve applied the following change
re-run the tests and uploaded all the files here
I’ve pushed my exact repro to https://github.com/adamsitnik/runtime/tree/issue65292repro
And uploaded full dump to OneDrive
I am on:
Thanks for the minimal repro, looking at it now
It seems to be a bug in
System.Memoryor codegen, asSequenceEqualsreturns true, but the helper fails to find any differences:https://github.com/dotnet/runtime/blob/e23382c32bf03d3fea5a2f1157a99148a51ca3f4/src/libraries/Common/tests/TestUtilities/System/AssertExtensions.cs#L445-L471
I was able to reproduce it using the following test:
@EgorBo is there any chance you could take a look?