-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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/arm64: 4 Regressions on 4/8/2024 7:16:22 PM #100922
Comments
Tagging subscribers to this area: @JulieLeeMSFT, @jakobbotsch |
Related regressions: |
@EgorBot -arm64 -perf -commit bc2bd2b vs 8e2655b --disasm using BenchmarkDotNet.Attributes;
using System.Buffers;
using System.Linq;
using System.Text;
BenchmarkDotNet.Running.BenchmarkRunner.Run<Perf_Ascii>(args: args);
public class Perf_Ascii
{
[Params(
128)] // vectorized code path
public int Size;
private byte[] _bytes, _sameBytes, _bytesDifferentCase;
private char[] _characters, _sameCharacters, _charactersDifferentCase;
[GlobalSetup]
public void Setup()
{
_bytes = new byte[Size];
_bytesDifferentCase = new byte[Size];
for (int i = 0; i < Size; i++)
{
// let ToLower and ToUpper perform the same amount of work
_bytes[i] = i % 2 == 0 ? (byte)'a' : (byte)'A';
_bytesDifferentCase[i] = i % 2 == 0 ? (byte)'A' : (byte)'a';
}
_sameBytes = _bytes.ToArray();
_characters = _bytes.Select(b => (char)b).ToArray();
_sameCharacters = _characters.ToArray();
_charactersDifferentCase = _bytesDifferentCase.Select(b => (char)b).ToArray();
}
[Benchmark]
[MemoryRandomization]
public OperationStatus ToUtf16() => Ascii.ToUtf16(_bytes, _characters, out _);
} |
Results on Arm64
See BDN_Artifacts.zip for details. 🔥ProfilerFlame graphs: Main vs PR (interactive!) NotesFor clean |
Will be fixed by #102705 |
Pushing out to .NET10 since it is a minor perf regression. |
Some of these are upwards of 20%, and in the linked issues that appear to be deduped against this, they're measured in us rather than ns. Am I reading this incorrectly or is there other context I'm missing? |
Run Information
Regressions in System.Text.Tests.Perf_Encoding
Test Report
Repro
General Docs link: https://github.com/dotnet/performance/blob/main/docs/benchmarking-workflow-dotnet-runtime.md
System.Text.Tests.Perf_Encoding.GetString(size: 512, encName: "ascii")
ETL Files
Histogram
JIT Disasms
System.Text.Tests.Perf_Encoding.GetChars(size: 512, encName: "ascii")
ETL Files
Histogram
JIT Disasms
System.Text.Tests.Perf_Encoding.GetString(size: 512, encName: "utf-8")
ETL Files
Histogram
JIT Disasms
Docs
Profiling workflow for dotnet/runtime repository
Benchmarking workflow for dotnet/runtime repository
Run Information
Regressions in System.Text.Perf_Ascii
Test Report
Repro
General Docs link: https://github.com/dotnet/performance/blob/main/docs/benchmarking-workflow-dotnet-runtime.md
System.Text.Perf_Ascii.ToUtf16(Size: 128)
ETL Files
Histogram
JIT Disasms
Docs
Profiling workflow for dotnet/runtime repository
Benchmarking workflow for dotnet/runtime repository
The text was updated successfully, but these errors were encountered: