Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

System.Linq.Expressions tests failing on some PRs #47374

Closed
GrabYourPitchforks opened this issue Jan 23, 2021 · 16 comments · Fixed by #53782
Closed

System.Linq.Expressions tests failing on some PRs #47374

GrabYourPitchforks opened this issue Jan 23, 2021 · 16 comments · Fixed by #53782
Labels
area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI bug disabled-test The test is disabled in source code against the issue
Milestone

Comments

@GrabYourPitchforks
Copy link
Member

GrabYourPitchforks commented Jan 23, 2021

Blocking clean CI on #45022. See here for the full log.

C:\h\w\A13D08CF\w\B433097F\e>"C:\h\w\A13D08CF\p\dotnet.exe" exec --runtimeconfig System.Linq.Expressions.Tests.runtimeconfig.json --depsfile System.Linq.Expressions.Tests.deps.json xunit.console.dll System.Linq.Expressions.Tests.dll -xml testResults.xml -nologo -nocolor -notrait category=IgnoreForCI -notrait category=OuterLoop -notrait category=failing  
  Discovering: System.Linq.Expressions.Tests (method display = ClassAndMethod, method display options = None)
  Discovered:  System.Linq.Expressions.Tests (found 5646 of 5656 test cases)
  Starting:    System.Linq.Expressions.Tests (parallel test collections = on, max threads = 2)
    System.Linq.Expressions.Tests.ConvertTests.ConvertFloatToUIntTest(useInterpreter: False) [FAIL]
      Assert.Equal() Failure
      Expected: 0
      Actual:   4294967295
      Stack Trace:
        /_/src/libraries/System.Linq.Expressions/tests/Convert/ConvertTests.cs(11424,0): at System.Linq.Expressions.Tests.ConvertTests.VerifyFloatToUInt(Single value, Boolean useInterpreter)
        /_/src/libraries/System.Linq.Expressions/tests/Convert/ConvertTests.cs(3099,0): at System.Linq.Expressions.Tests.ConvertTests.ConvertFloatToUIntTest(Boolean useInterpreter)
    System.Linq.Expressions.Tests.ConvertTests.ConvertFloatToNullableUIntTest(useInterpreter: False) [FAIL]
      Assert.Equal() Failure
      Expected: 0
      Actual:   4294967295
      Stack Trace:
        /_/src/libraries/System.Linq.Expressions/tests/Convert/ConvertTests.cs(11435,0): at System.Linq.Expressions.Tests.ConvertTests.VerifyFloatToNullableUInt(Single value, Boolean useInterpreter)
        /_/src/libraries/System.Linq.Expressions/tests/Convert/ConvertTests.cs(3108,0): at System.Linq.Expressions.Tests.ConvertTests.ConvertFloatToNullableUIntTest(Boolean useInterpreter)
  Finished:    System.Linq.Expressions.Tests
=== TEST EXECUTION SUMMARY ===
   System.Linq.Expressions.Tests  Total: 35233, Errors: 0, Failed: 2, Skipped: 0, Time: 24,631s

Runfo Tracking Issue: system.linq.expressions.tests.converttests.convertfloattonullableuinttest

Build Definition Kind Run Name
1025261 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.7.Amd64.Open
1025261 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
1025261 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
986006 runtime PR 47488 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
986006 runtime PR 47488 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
986006 runtime PR 47488 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
976701 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.7.Amd64.Open
976701 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
976701 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
974259 runtime PR 47488 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
974259 runtime PR 47488 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
974259 runtime PR 47488 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
974259 runtime PR 47488 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
974259 runtime PR 47488 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
974259 runtime PR 47488 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
974259 runtime PR 47488 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
974259 runtime PR 47488 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
973882 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.7.Amd64.Open
973882 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
973882 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
972275 runtime PR 47488 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
972275 runtime PR 47488 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
972275 runtime PR 47488 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
971888 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.7.Amd64.Open
971888 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
971888 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966797 runtime PR 47489 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
966797 runtime PR 47489 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966797 runtime PR 47489 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
966790 runtime PR 47488 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
966790 runtime PR 47488 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
966790 runtime PR 47488 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966776 runtime PR 47349 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
966776 runtime PR 47349 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966776 runtime PR 47349 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
966764 runtime PR 47483 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
966764 runtime PR 47483 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
966764 runtime PR 47483 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966691 runtime PR 47443 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
966691 runtime PR 47443 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966691 runtime PR 47443 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
966691 runtime PR 47443 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
966691 runtime PR 47443 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966691 runtime PR 47443 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
966583 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.7.Amd64.Open
966583 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
966583 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966494 runtime PR 47479 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
966494 runtime PR 47479 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966494 runtime PR 47479 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
966364 runtime PR 47040 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
966364 runtime PR 47040 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966364 runtime PR 47040 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
966360 runtime PR 47349 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
966360 runtime PR 47349 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
966360 runtime PR 47349 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966305 runtime PR 47229 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
966305 runtime PR 47229 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
966305 runtime PR 47229 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
966218 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.7.Amd64.Open
966218 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.ServerRS5.Open
966218 runtime Rolling net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965963 runtime PR 47150 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965963 runtime PR 47150 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965963 runtime PR 47150 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
965963 runtime PR 47150 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
965963 runtime PR 47150 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965963 runtime PR 47150 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965733 runtime PR 45827 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965733 runtime PR 45827 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965733 runtime PR 45827 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965733 runtime PR 45827 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965733 runtime PR 45827 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
965733 runtime PR 45827 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965733 runtime PR 45827 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965337 runtime PR 47439 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965337 runtime PR 47439 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
965337 runtime PR 47439 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
965238 runtime PR 47301 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
965238 runtime PR 47301 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
965238 runtime PR 47301 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
964801 runtime PR 46823 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
964801 runtime PR 46823 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
964801 runtime PR 46823 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open
964801 runtime PR 46823 net6.0-windows-Release-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.ES.Open
964801 runtime PR 46823 net6.0-windows-Debug-x86-CoreCLR_release-Windows.7.Amd64.Open
964801 runtime PR 46823 net6.0-windows-Debug-x86-CoreCLR_release-Windows.10.Amd64.Server19H1.Open

Displaying 100 of 103 results

Build Result Summary

Day Hit Count Week Hit Count Month Hit Count
0 0 0
@GrabYourPitchforks GrabYourPitchforks added area-System.Linq.Expressions blocking-clean-ci Blocking PR or rolling runs of 'runtime' or 'runtime-extra-platforms' labels Jan 23, 2021
@ghost
Copy link

ghost commented Jan 23, 2021

Tagging subscribers to this area: @cston
See info in area-owners.md if you want to be subscribed.

Issue Details

Blocking clean CI on #45022. See here for the full log.

C:\h\w\A13D08CF\w\B433097F\e>"C:\h\w\A13D08CF\p\dotnet.exe" exec --runtimeconfig System.Linq.Expressions.Tests.runtimeconfig.json --depsfile System.Linq.Expressions.Tests.deps.json xunit.console.dll System.Linq.Expressions.Tests.dll -xml testResults.xml -nologo -nocolor -notrait category=IgnoreForCI -notrait category=OuterLoop -notrait category=failing  
  Discovering: System.Linq.Expressions.Tests (method display = ClassAndMethod, method display options = None)
  Discovered:  System.Linq.Expressions.Tests (found 5646 of 5656 test cases)
  Starting:    System.Linq.Expressions.Tests (parallel test collections = on, max threads = 2)
    System.Linq.Expressions.Tests.ConvertTests.ConvertFloatToUIntTest(useInterpreter: False) [FAIL]
      Assert.Equal() Failure
      Expected: 0
      Actual:   4294967295
      Stack Trace:
        /_/src/libraries/System.Linq.Expressions/tests/Convert/ConvertTests.cs(11424,0): at System.Linq.Expressions.Tests.ConvertTests.VerifyFloatToUInt(Single value, Boolean useInterpreter)
        /_/src/libraries/System.Linq.Expressions/tests/Convert/ConvertTests.cs(3099,0): at System.Linq.Expressions.Tests.ConvertTests.ConvertFloatToUIntTest(Boolean useInterpreter)
    System.Linq.Expressions.Tests.ConvertTests.ConvertFloatToNullableUIntTest(useInterpreter: False) [FAIL]
      Assert.Equal() Failure
      Expected: 0
      Actual:   4294967295
      Stack Trace:
        /_/src/libraries/System.Linq.Expressions/tests/Convert/ConvertTests.cs(11435,0): at System.Linq.Expressions.Tests.ConvertTests.VerifyFloatToNullableUInt(Single value, Boolean useInterpreter)
        /_/src/libraries/System.Linq.Expressions/tests/Convert/ConvertTests.cs(3108,0): at System.Linq.Expressions.Tests.ConvertTests.ConvertFloatToNullableUIntTest(Boolean useInterpreter)
  Finished:    System.Linq.Expressions.Tests
=== TEST EXECUTION SUMMARY ===
   System.Linq.Expressions.Tests  Total: 35233, Errors: 0, Failed: 2, Skipped: 0, Time: 24,631s
Author: GrabYourPitchforks
Assignees: -
Labels:

area-System.Linq.Expressions, blocking-clean-ci

Milestone: -

@SingleAccretion
Copy link
Contributor

Leaving a note that this is likely to have been caused by my #47133. I have confirmed locally that it does hit the new path on x64. Investigating...

@EgorBo
Copy link
Member

EgorBo commented Jan 23, 2021

@SingleAccretion the problem it seems in this transformation in gtFoldExprConst:

before:

               [000001] ------------              *  CAST      int <- uint <- float
               [000000] ------------              \--*  CNS_DBL   float  3.4028234663852886e+38    (float.MaxValue)

after:

               [000001] ------------              *  CNS_INT   int    -1

@EgorBo
Copy link
Member

EgorBo commented Jan 23, 2021

Honestly, looks more like a Roslyn bug(or undefined behavior) to me, run the following:

using System;
using System.Runtime.CompilerServices;

class Program
{
    [MethodImpl(MethodImplOptions.NoInlining)]
    static float Foo(float x) => x;

    static void Main()
    {
        // convert float.MaxValue to int
        Console.WriteLine(unchecked((int)float.MaxValue)); // Roslyn emits `ldc.i4.0` here

        // convert float.MaxValue to int via a call:
        Console.WriteLine((int)Foo(float.MaxValue)); // vcvttss2si returns -1

        Console.ReadKey();
    }
}

/cc @tannergooding

PS: clang and MSVC also fold it to 0 (unlike GCC): https://godbolt.org/z/1hP5rT

@EgorBo
Copy link
Member

EgorBo commented Jan 23, 2021

We can temporarily remove float.MaxValue from both tests to unblock CI I guess. @SingleAccretion Do you want to create a PR?

@SingleAccretion
Copy link
Contributor

I am afraid that I won't be able to do it today (it being 1:20 AM and all).

Thank you Egor for your analysis! I am yet to realize what would the proper fix here be.

@john-h-k
Copy link
Contributor

Honestly, looks more like a Roslyn bug(or undefined behavior) to me, run the following:

It's UB according to the C# spec. So either the spec needs to change or these tests need to ignore non-finite values (NaN, +-inf)

@EgorBo
Copy link
Member

EgorBo commented Jan 23, 2021

Honestly, looks more like a Roslyn bug(or undefined behavior) to me, run the following:

It's UB according to the C# spec. So either the spec needs to change or these tests need to ignore non-finite values (NaN, +-inf)

Yep, 11.3.2
image

@john-h-k
Copy link
Contributor

john-h-k commented Jan 23, 2021

I guess appropriate test would be that non-finite cast doesn't throw in unchecked, ignoring the result

@AraHaan
Copy link
Member

AraHaan commented Jan 23, 2021

I think the issue with the tests is that they use unchecked and so then the value is no 0? Looks to me either the value must increase, or something else like removing unchecked on them right?

Or could just change the expected values to the actual values that it shows on the failure for now, unless the actual value is random and changes all the time.

@tannergooding
Copy link
Member

This was likely fixed in Roslyn as part of the general determinism fixes around: dotnet/roslyn#37527
This was necessary to avoid compiling on ARM and compiling on x86 from producing different assemblies and breaking determinism.

You are then only left with the existing UB of values that are computed at runtime by either the JIT or underlying architecture.

@tannergooding
Copy link
Member

I believe there was some special handling added for NaN in CSE (valuenum.cpp) due to similar reasons a while back. This might fall into the same general categorization and might also need special handling.

@ghost ghost added the in-pr There is an active PR which will close this issue when it is merged label Jan 24, 2021
@SingleAccretion
Copy link
Contributor

After thinking about this for a bit, I suspect there are a couple of issues at play here.

The tests that fail assert that the result of the expression Convert(ConstantFloat) is always the same as the value Roslyn produces during its constant folding phase. This assertion seems suspect at best. System.Linq.Expressions implements a C#-like interface, but it doesn't actually implement the language. There are no requirements (as far as I am aware) for it to differentiate between "constant folding" and "runtime", like there are for Roslyn. While it would be good to converge the behavior here, it seems like a very significant investment would be required for that to happen, and it is not clear what the actual benefits would be.

The tests have only very recently started failing. This seems fairly mysterious, as the logic for folding in the Jit has been there for a very long time, and it always folded things like (uint)float.MaxValue, apparently to zero (and still does fold it to zero on my machine). At the same time, (int)float.MaxValue was being folded to -1, which is exactly the value that now shows up in the logs for the unsigned cast:

System.Linq.Expressions.Tests.ConvertTests.ConvertFloatToUIntTest(useInterpreter: False) [FAIL]
   Assert.Equal() Failure
   Expected: 0
   Actual:   4294967295 <- (uint)-1

This is either a subtle change in the C++ compiler's behavior (very unlikely), or a latent bug in the folding logic. I am yet to reproduce this locally.

More broadly, it seems like the time that this comment talks about has come, with Crossgen2 now entering wide use with its excellent support for cross-compilation. You can construct some very "interesting" scenarios if you mix R2R, inlining, tiered compilation and PGO with constant folding that's different between the AOT compiler and the Jit.

Stepping back, the immediate action here would be, in my opinion, to get rid of testing in System.Linq.Expression something that may not actually be what the implementation promises (or decide that the implementation actually does promise the same behavior that Roslyn has, and implement it, which seems like exceedingly unlikely - #27790), and at the same time investigate what caused the float -> uint casts to start behaving like float -> int on Release CoreCLR Windows x86.

How to proceed requires a decision from the maintainers.

@EgorBo
Copy link
Member

EgorBo commented Jan 24, 2021

@SingleAccretion I suspect it's MSVC x86 specific actually, a small repro:

#include <iostream>

__declspec(noinline) float FloatMaxValue() {
    return 3.40282346638528859e+38;
}

int main() {
    std::cout << (unsigned)FloatMaxValue();
}
MSVC x64: 0
MSVC x86: 4294967295
MSVC x86 + /d2noftol3 flag: 0  (uses FPU)

Fix #47380

@danmoseley
Copy link
Member

Is there a volunteer to disable the affected tests meantime?

@hoyosjs hoyosjs added disabled-test The test is disabled in source code against the issue bug area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI and removed blocking-clean-ci Blocking PR or rolling runs of 'runtime' or 'runtime-extra-platforms' untriaged New issue has not been triaged by the area owner area-System.Linq.Expressions labels Jan 26, 2021
@JulieLeeMSFT JulieLeeMSFT added this to the 6.0.0 milestone Mar 10, 2021
SingleAccretion added a commit to SingleAccretion/runtime that referenced this issue Jun 6, 2021
@ghost ghost added the in-pr There is an active PR which will close this issue when it is merged label Jun 7, 2021
kunalspathak pushed a commit that referenced this issue Jul 7, 2021
* Enhance the FloatOvfToInt2 test to exercise VN paths

It is not very effective right now because the "bad" combinations of
types are morphed into helpers too early, but it will be helpful when
we enable folding outside of the importer for those cases too.

* Enhance the FloatOvfToInt2 test to cover importer

It now fails on Windows x86, where many of the
previous similar failures were observed.

* Disable the test on Mono

* Re-enable tests disabled against #13651

* Re-enable tests disabled against #51346

* Re-enable tests disabled against #47374

* Disable folding in gtFoldExprConst

* Disable folding in VN

* Temporarily promote the test to Pri0

* Reword the comment

* Move the tests back to Pri1

Where they originally were.
@ghost ghost removed the in-pr There is an active PR which will close this issue when it is merged label Jul 7, 2021
@ghost ghost locked as resolved and limited conversation to collaborators Aug 6, 2021
@SingleAccretion SingleAccretion removed their assignment Nov 20, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-CodeGen-coreclr CLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI bug disabled-test The test is disabled in source code against the issue
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

10 participants