square function and some sanity checks
.NET Test / .NET tests (push) Successful in 1m35s

This commit is contained in:
2026-09-18 16:59:28 +04:00
parent 5797bf4884
commit 620faca7eb
10 changed files with 455 additions and 28 deletions
@@ -87,6 +87,18 @@ public class ArithmeticBenchmarks
return _doubleDoubleLeft * _doubleDoubleRight;
}
[Benchmark(Baseline = true), BenchmarkCategory("Squaring")]
public DoubleDouble DoubleDoubleSquareViaMultiply()
{
return _doubleDoubleLeft * _doubleDoubleLeft;
}
[Benchmark, BenchmarkCategory("Squaring")]
public DoubleDouble DoubleDoubleSquare()
{
return DoubleDouble.Square(_doubleDoubleLeft);
}
[Benchmark(Baseline = true), BenchmarkCategory("Division")]
public double DoubleDivide()
{