Пример #1
0
        public BenchmarkConfig()
        {
            AddLogger(ConsoleLogger.Default);
            AddExporter(MarkdownExporter.GitHub);
            AddDiagnoser(MemoryDiagnoser.Default);

            AddColumn(new ORMColum());
            AddColumn(TargetMethodColumn.Method);
            AddColumn(StatisticColumn.Mean);
            AddColumn(StatisticColumn.StdDev);
            AddColumn(StatisticColumn.Error);
            AddColumn(BaselineRatioColumn.RatioMean);
            AddColumn(StatisticColumn.Min);
            AddColumn(StatisticColumn.Max);

            AddColumnProvider(DefaultColumnProviders.Metrics);

            var job = Job.ShortRun
                      .WithLaunchCount(DefaultConstants.DefaultLaunchCount)
                      .WithWarmupCount(DefaultConstants.DefaultWarmupCount)
                      .WithUnrollFactor(DefaultConstants.DefaultUnrollFactor)
                      .WithIterationCount(DefaultConstants.DefaultIterationCount);

            AddJob(job);

            Orderer  = new DefaultOrderer(SummaryOrderPolicy.FastestToSlowest);
            Options |= ConfigOptions.JoinSummary | ConfigOptions.StopOnFirstError;
        }
        public Config()
        {
            Add(ConsoleLogger.Default);

            Add(CsvExporter.Default);
            Add(MarkdownExporter.GitHub);
            Add(HtmlExporter.Default);

            var md = MemoryDiagnoser.Default;

            Add(md);
            Add(new ORMColum());
            Add(TargetMethodColumn.Method);
            Add(new ReturnColum());
            Add(StatisticColumn.Mean);
            //Add(StatisticColumn.StdDev);
            //Add(StatisticColumn.Error);
            Add(BaselineRatioColumn.RatioMean);
            //Add(md.GetColumnProvider());

            Add(Job.ShortRun
                .WithLaunchCount(1)
                .WithWarmupCount(2)
                .WithUnrollFactor(Iterations)
                .WithIterationCount(1)
                );
            Orderer  = new DefaultOrderer(SummaryOrderPolicy.FastestToSlowest);
            Options |= ConfigOptions.JoinSummary;
        }
Пример #3
0
        public Config()
        {
            AddLogger(ConsoleLogger.Default);

            AddExporter(CsvExporter.Default);
            AddExporter(MarkdownExporter.GitHub);
            AddExporter(HtmlExporter.Default);

            var md = MemoryDiagnoser.Default;

            AddDiagnoser(md);
            AddColumn(new PipelineColumn());
            AddColumn(TargetMethodColumn.Method);
            AddColumn(StatisticColumn.Mean);
            AddColumn(StatisticColumn.StdDev);
            AddColumn(StatisticColumn.Error);
            AddColumn(BaselineRatioColumn.RatioMean);
            AddColumnProvider(DefaultColumnProviders.Metrics);

            AddJob(Job.ShortRun
                   .WithLaunchCount(1)
                   .WithWarmupCount(2)
                   .WithUnrollFactor(Iterations)
                   .WithIterationCount(10)
                   );
            Orderer  = new DefaultOrderer(SummaryOrderPolicy.FastestToSlowest);
            Options |= ConfigOptions.JoinSummary;
        }
Пример #4
0
 public MyConfig()
 {
     AddJob(Job.ShortRun.WithRuntime(CoreRuntime.Core50));
     AddJob(Job.ShortRun.WithRuntime(CoreRuntime.Core60));
     AddDiagnoser(MemoryDiagnoser.Default);
     Orderer = new DefaultOrderer(SummaryOrderPolicy.Default, MethodOrderPolicy.Alphabetical);
 }
Пример #5
0
        public MyConfig()
        {
            AddJob(Job.Default.WithUnrollFactor(2));

            AddDiagnoser(MemoryDiagnoser.Default);

            Orderer = new DefaultOrderer(SummaryOrderPolicy.Method);
        }
        public CustomIntrinsicConfig() : base()
        {
            AddDiagnoser(MemoryDiagnoser.Default);

            Orderer = new DefaultOrderer(SummaryOrderPolicy.SlowestToFastest);

            AddColumn(SpeedupRatioColumn.SpeedupOfMean);
            AddColumn(WorthinessRatioColumn.WorthinessOfMean);
            AddDiagnoser(new DisassemblyDiagnoser(new DisassemblyDiagnoserConfig(maxDepth: 3)));
        }
Пример #7
0
        public MainConfig()
        {
            Add(Job.Default.With(Platform.X64).With(CsProjCoreToolchain.NetCoreApp30));

            Add(MemoryDiagnoser.Default);
            Add(new MinimalColumnProvider());
            Add(MemoryDiagnoser.Default);
            Orderer = new DefaultOrderer(SummaryOrderPolicy.SlowestToFastest);
            Add(MarkdownExporter.GitHub);
            Add(new ConsoleLogger());
        }
Пример #8
0
        public static IConfig WithLocalSettings(this IConfig config)
        {
            var orderer = new DefaultOrderer(
                SummaryOrderPolicy.FastestToSlowest,
                MethodOrderPolicy.Alphabetical);

            return(config
                   .AddValidator(ExecutionValidator.FailOnError)
                   .AddColumn(RankColumn.Roman)
                   .AddColumn(BaselineRatioColumn.RatioMean)
                   .WithOrderer(orderer));
        }
Пример #9
0
 public BenchmarkConfig()
 {
     AddJob(new Job
     {
         Environment =
         {
             Platform = Platform.X64,
             Jit      = Jit.RyuJit,
             Runtime  = CoreRuntime.Core31,
         }
     });
     AddColumnProvider(DefaultColumnProviders.Instance);
     AddColumn(RankColumn.Arabic);
     AddLogger(ConsoleLogger.Default);
     AddExporter(MarkdownExporter.Default);
     AddDiagnoser(MemoryDiagnoser.Default);
     Orderer   = new DefaultOrderer(SummaryOrderPolicy.FastestToSlowest);
     UnionRule = ConfigUnionRule.AlwaysUseLocal;
 }
Пример #10
0
        public Config()
        {
            AddLogger(ConsoleLogger.Default);
            AddExporter(MarkdownExporter.GitHub);

            var md = MemoryDiagnoser.Default;

            AddDiagnoser(md);

            AddColumn(TargetMethodColumn.Method);
            AddColumn(TargetMethodColumn.Type);
            AddColumn(StatisticColumn.Mean);
            AddColumn(StatisticColumn.StdDev);
            AddColumn(StatisticColumn.Error);
            AddColumn(StatisticColumn.Min);
            AddColumn(StatisticColumn.Max);
            AddColumn(StatisticColumn.OperationsPerSecond);
            AddColumnProvider(DefaultColumnProviders.Metrics);

            if (System.Environment.GetEnvironmentVariable("LOCAL_BENCHMARK") is not null)
            {
                AddJob(Job.ShortRun
                       .WithLaunchCount(5)
                       .WithWarmupCount(5)
                       .WithMinIterationCount(5)
                       .WithMaxIterationCount(10)
                       .WithIterationCount(10));
            }
            else
            {
                AddJob(Job.ShortRun
                       .WithLaunchCount(1)
                       .WithWarmupCount(1)
                       .WithMinIterationCount(1)
                       .WithMaxIterationCount(5)
                       .WithIterationCount(1));
            }

            Orderer  = new DefaultOrderer(SummaryOrderPolicy.FastestToSlowest);
            Options |= ConfigOptions.JoinSummary;
        }
Пример #11
0
        public CerasGlobalBenchmarkConfig(Job baseJob)
        {
            Orderer = new DefaultOrderer(SummaryOrderPolicy.FastestToSlowest);

            baseJob = baseJob
                      .WithOutlierMode(OutlierMode.OnlyUpper)
                      .With(Platform.X64)
                      .WithLaunchCount(1);

            Add(baseJob);

            Add(HtmlExporter.Default);

            Add(BenchmarkLogicalGroupRule.ByCategory);

            Add(CategoriesColumn.Default);
            Add(TargetMethodColumn.Method);
            Add(BaselineRatioColumn.RatioMean);
            Add(StatisticColumn.Mean, StatisticColumn.StdErr);

            Add(DefaultColumnProviders.Params);

            Add(new ConsoleLogger());
        }
Пример #12
0
        public Config()
        {
            Add(ConsoleLogger.Default);
            Add(CsvExporter.Default);
            Add(MarkdownExporter.GitHub);
            Add(HtmlExporter.Default);
            Add(MemoryDiagnoser.Default);
            Add(new ProviderColumn());
            Add(TargetMethodColumn.Method);
            Add(StatisticColumn.Mean);
            Add(BaselineRatioColumn.RatioMean);
            Add(RankColumn.Arabic);
            Add(BenchmarkLogicalGroupRule.ByCategory);
            Add(Job.Dry
                .WithLaunchCount(1)
                .WithWarmupCount(1)
                .WithIterationCount(1)
                .WithGcForce(true)
                .With(InProcessToolchain.Instance)
                );

            Orderer = new DefaultOrderer(SummaryOrderPolicy.FastestToSlowest);
            Options = ConfigOptions.JoinSummary;
        }
Пример #13
0
 public MyConfig()
 {
     Add(Job.Default.WithUnrollFactor(2));
     Add(MemoryDiagnoser.Default);
     Orderer = new DefaultOrderer(SummaryOrderPolicy.Default, MethodOrderPolicy.Alphabetical);
 }