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

[Perf] Linux/x64: 2 Regressions on 6/27/2024 6:42:30 AM #104303

Closed
performanceautofiler bot opened this issue Jul 2, 2024 · 6 comments
Closed

[Perf] Linux/x64: 2 Regressions on 6/27/2024 6:42:30 AM #104303

performanceautofiler bot opened this issue Jul 2, 2024 · 6 comments
Assignees
Labels
arch-x64 needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners os-linux Linux OS (any supported distro) runtime-coreclr specific to the CoreCLR runtime tenet-performance Performance related issue tenet-performance-benchmarks Issue from performance benchmark

Comments

@performanceautofiler
Copy link

Run Information

Name Value
Architecture x64
OS ubuntu 22.04
Queue ViperUbuntu
Baseline 58e1a7e6e499da2cd502bebb326497795101783f
Compare 51176f0bf2446f15dbd067b0001bce84b84a42f6
Diff Diff
Configs CompilationMode:tiered, RunKind:micro

Regressions in System.Tests.Perf_Array

Benchmark Baseline Test Test/Base Test Quality Edge Detector Baseline IR Compare IR IR Ratio
431.20 μs 481.58 μs 1.12 0.11 False
385.84 μs 443.34 μs 1.15 0.08 False

graph
graph
Test Report

Repro

General Docs link: https://github.com/dotnet/performance/blob/main/docs/benchmarking-workflow-dotnet-runtime.md

git clone https://github.com/dotnet/performance.git
python3 .\performance\scripts\benchmarks_ci.py -f net8.0 --filter 'System.Tests.Perf_Array*'

System.Tests.Perf_Array.ArrayAssign3D

ETL Files

Histogram

JIT Disasms

System.Tests.Perf_Array.ArrayAssign2D

ETL Files

Histogram

JIT Disasms

Docs

Profiling workflow for dotnet/runtime repository
Benchmarking workflow for dotnet/runtime repository

@performanceautofiler performanceautofiler bot added arch-x64 os-linux Linux OS (any supported distro) runtime-coreclr specific to the CoreCLR runtime untriaged New issue has not been triaged by the area owner labels Jul 2, 2024
@DrewScoggins DrewScoggins transferred this issue from dotnet/perf-autofiling-issues Jul 2, 2024
@dotnet-issue-labeler dotnet-issue-labeler bot added the needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners label Jul 2, 2024
@DrewScoggins DrewScoggins added tenet-performance Performance related issue tenet-performance-benchmarks Issue from performance benchmark labels Jul 2, 2024
@DrewScoggins
Copy link
Member

DrewScoggins commented Jul 2, 2024

Seems related to #102739
Also related:
Linux x64 - dotnet/perf-autofiling-issues#37353

@jkotas
Copy link
Member

jkotas commented Jul 2, 2024

@huoyaoyuan Could you please take a look?

@huoyaoyuan
Copy link
Member

It's about SetValue, which I didn't measure performance for.

There isn't something obviously problematic at first glance. I'm also interested about the context of the improvement at May.

@jkotas
Copy link
Member

jkotas commented Jul 2, 2024

I'm also interested about the context of the improvement at May.

It is possible that the micro-benchmark is bi-modal. It operates on a large array and it does a lot of boxing. Micro-benchmarks like this tend to be bi-modal.

Does the regression reproduce on your machine?

@huoyaoyuan
Copy link
Member

I can't reproduce the regression on array of smaller size:

        private int[,] array2D = new int[100, 100];

        [Benchmark]
        public void ArrayAccess2D()
        {
            for (int i = 0; i < 100; i++)
                for (int j = 0; j < 100; j++)
                    array2D.SetValue(i + j, i, j);
        }
Method Job Toolchain Mean Error StdDev Ratio RatioSD
ArrayAccess2D Job-VQKCWF \AfterMerge\corerun.exe 62.86 us 1.129 us 1.160 us 0.92 0.03
ArrayAccess2D Job-JKQPLR \BeforeMerge\corerun.exe 68.32 us 1.322 us 1.104 us 1.00 0.00

@jkotas
Copy link
Member

jkotas commented Jul 3, 2024

@huoyaoyuan Thank you for checking!

This is bi-modal/unstable benchmark. It operates on large array and it does a lot of allocations (boxing) that are unrelated to the operations being tested. Benchmarks like that tend to be unstable. Closing as by design.

@jkotas jkotas closed this as completed Jul 3, 2024
@dotnet-policy-service dotnet-policy-service bot removed the untriaged New issue has not been triaged by the area owner label Jul 3, 2024
@github-actions github-actions bot locked and limited conversation to collaborators Aug 2, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
arch-x64 needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners os-linux Linux OS (any supported distro) runtime-coreclr specific to the CoreCLR runtime tenet-performance Performance related issue tenet-performance-benchmarks Issue from performance benchmark
Projects
None yet
Development

No branches or pull requests

3 participants