Skip to content

Vector128 and Vector256 General purpose DotProduct tests fail #75791

Description

@davidwrighton

Description

These tests fail when upgraded to the new xunit based test system. This issue will be visible once #74886 is merged.

Reproduction Steps

Run the hardwareintrinsics_ro merged test project located in src/tests/JIT/HardwareIntrinsics/HardwareIntrinsics_ro.csproj

Expected behavior

Test should reliably pass.

Actual behavior

It fails where the difference in behavior is a floating point accuracy issue. (The algorithm is ... close in result) The expected result is within a small fraction of the actual result.

Console output looks like

21:26:27.767 Running test: global::JIT.HardwareIntrinsics.General._Vector128.Program.DotSingle()
Beginning scenario: RunBasicScenario_UnsafeRead
Vector128.Dot<Single>(Vector128<Single>, Vector128<Single>): RunBasicScenario_UnsafeRead failed:
    left: (0.3433865, 0.9667737, 0.12783496, 0.37054372)
   right: (0.98444676, 0.49922475, 0.64575523, 0.07723055)
  result: 0.93185043

Beginning scenario: RunReflectionScenario_UnsafeRead
Beginning scenario: RunClsVarScenario
Beginning scenario: RunLclVarScenario_UnsafeRead
Vector128.Dot<Single>(Vector128<Single>, Vector128<Single>): RunLclVarScenario_UnsafeRead failed:
    left: (0.3433865, 0.9667737, 0.12783496, 0.37054372)
   right: (0.98444676, 0.49922475, 0.64575523, 0.07723055)
  result: 0.93185043

Beginning scenario: RunClassLclFldScenario
Beginning scenario: RunClassFldScenario
Vector128.Dot<Single>(Vector128<Single>, Vector128<Single>): RunClassFldScenario failed:
    left: (0.74744684, 0.2090859, 0.9512482, 0.5400413)
   right: (0.558003, 0.40041316, 0.7649265, 0.91902465)
  result: 1.7247446

Beginning scenario: RunStructLclFldScenario
Beginning scenario: RunStructFldScenario
21:26:28.001 Failed test: global::JIT.HardwareIntrinsics.General._Vector128.Program.DotSingle()

Regression?

Unlikely.

Known Workarounds

No response

Configuration

No response

Other information

No response

category:correctness
theme:vector-codegen
skill-level:beginner
cost:small
impact:small

Activity

  1. ghost added
    untriagedNew issue has not been triaged by the area owner
    on Sep 17, 2022
  2. ghost added
    area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI
    on Sep 17, 2022
  3. removed
    untriagedNew issue has not been triaged by the area owner
    on Sep 19, 2022
  4. added this to the 8.0.0 milestone on Sep 19, 2022
  5. JulieLeeMSFT commented on Sep 19, 2022

    @JulieLeeMSFT
    Member

    @kunalspathak PTAL. cc @dotnet/jit-contrib.
    @davidwrighton, setting it to .net 8.0. Please get back to me if it needs to be 7.0.

  6. tannergooding commented on Sep 19, 2022

    @tannergooding
    Member

    I'd guess there is some subtle difference in addition ordering for the pre SSE4.1 codegen and that is causing it to be slightly off as compared to dpps.

  7. BruceForstall commented on Oct 14, 2022

    @BruceForstall
    Contributor

    Why do they only fail when converted to the new test system? Are we not properly running them in the current test system?

  8. markples commented on Oct 14, 2022

    @markples
    Contributor

    Is this #76280? It looks like there are numerous failure symptoms there (all zeroes, all ones, inverted max, etc.), but #76280 (comment) shows a small value change.

  9. ghost added
    in-prThere is an active PR which will close this issue when it is merged
    on Nov 13, 2022
  10. ghost removed
    in-prThere is an active PR which will close this issue when it is merged
    on Jan 12, 2023
  11. ghost locked as resolved and limited conversation to collaborators on Feb 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMI

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions