We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 886b585 commit b03fb31Copy full SHA for b03fb31
1 file changed
src/benchmarks/micro/libraries/System.Runtime/Perf.String.cs
@@ -20,6 +20,12 @@ public static IEnumerable<object> TestStringSizes()
20
yield return new StringArguments(1000);
21
}
22
23
+ [Benchmark]
24
+ [Arguments(1)]
25
+ [Arguments(10)]
26
+ [Arguments(100)]
27
+ public string CtorCharCount(int size) => new string('a', size);
28
+
29
[Benchmark]
30
[ArgumentsSource(nameof(TestStringSizes))]
31
public char[] GetChars(StringArguments size) // the argument is called "size" to keep the old benchmark ID, do NOT rename it
0 commit comments