Skip to content

Commit b8e5b3e

Browse files
committed
chore: add UseLocalJobOnlyAttribute for samples benchmarks
1 parent da946f2 commit b8e5b3e

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+49
-0
lines changed

samples/BenchmarkDotNet.Samples/IntroBasic.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
namespace BenchmarkDotNet.Samples
55
{
66
// It is very easy to use BenchmarkDotNet. You should just create a class
7+
78
public class IntroBasic
89
{
910
// And define a method with the Benchmark attribute

samples/BenchmarkDotNet.Samples/IntroCategories.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
namespace BenchmarkDotNet.Samples
55
{
66
[DryJob]
7+
[UseLocalJobOnly]
78
[CategoriesColumn]
89
[BenchmarkCategory("Awesome")]
910
[AnyCategoriesFilter("A", "1")]

samples/BenchmarkDotNet.Samples/IntroCategoryDiscoverer.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
namespace BenchmarkDotNet.Samples
99
{
1010
[DryJob]
11+
[UseLocalJobOnly]
1112
[CategoriesColumn]
1213
[CustomCategoryDiscoverer]
1314
public class IntroCategoryDiscoverer

samples/BenchmarkDotNet.Samples/IntroColdStart.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
namespace BenchmarkDotNet.Samples
77
{
88
[SimpleJob(RunStrategy.ColdStart, iterationCount: 5)]
9+
[UseLocalJobOnly]
910
[MinColumn, MaxColumn, MeanColumn, MedianColumn]
1011
public class IntroColdStart
1112
{

samples/BenchmarkDotNet.Samples/IntroConfigSource.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
namespace BenchmarkDotNet.Samples
1010
{
1111
[MyConfigSource(Jit.LegacyJit, Jit.RyuJit)]
12+
[UseLocalJobOnly]
1213
public class IntroConfigSource
1314
{
1415
/// <summary>

samples/BenchmarkDotNet.Samples/IntroCultureInfo.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ namespace BenchmarkDotNet.Samples
77
{
88
[Config(typeof(Config))]
99
[ShortRunJob]
10+
[UseLocalJobOnly]
1011
public class IntroCultureInfo
1112
{
1213
private class Config : ManualConfig

samples/BenchmarkDotNet.Samples/IntroCustomMono.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ namespace BenchmarkDotNet.Samples
1010

1111
[MonoJob("Mono x64", @"C:\Program Files\Mono\bin\mono.exe")]
1212
[MonoJob("Mono x86", @"C:\Program Files (x86)\Mono\bin\mono.exe")]
13+
[UseLocalJobOnly]
1314
public class IntroCustomMono
1415
{
1516
[Benchmark]
@@ -22,6 +23,7 @@ public void Foo()
2223
// *** Object Style ***
2324

2425
[Config(typeof(Config))]
26+
[UseLocalJobOnly]
2527
public class IntroCustomMonoObjectStyle
2628
{
2729
private class Config : ManualConfig
@@ -45,6 +47,7 @@ public void Foo()
4547
// ** Object Style, Using AOT **
4648

4749
[Config(typeof(Config))]
50+
[UseLocalJobOnly]
4851
public class IntroCustomMonoObjectStyleAot
4952
{
5053
private class Config : ManualConfig

samples/BenchmarkDotNet.Samples/IntroCustomMonoArguments.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
namespace BenchmarkDotNet.Samples
77
{
88
[Config(typeof(ConfigWithCustomArguments))]
9+
[UseLocalJobOnly]
910
public class IntroCustomMonoArguments
1011
{
1112
public class ConfigWithCustomArguments : ManualConfig

samples/BenchmarkDotNet.Samples/IntroDisassemblyAllJits.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
namespace BenchmarkDotNet.Samples
88
{
99
[Config(typeof(MultipleJits))]
10+
[UseLocalJobOnly]
1011
public class IntroDisassemblyAllJits
1112
{
1213
public class MultipleJits : ManualConfig

samples/BenchmarkDotNet.Samples/IntroDisassemblyDry.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ namespace BenchmarkDotNet.Samples
44
{
55
[DisassemblyDiagnoser(maxDepth: 3)]
66
[DryJob]
7+
[UseLocalJobOnly]
78
public class IntroDisassemblyDry
89
{
910
[Benchmark]

0 commit comments

Comments
 (0)