| Index: runtime/vm/benchmark_test.cc
|
| diff --git a/runtime/vm/benchmark_test.cc b/runtime/vm/benchmark_test.cc
|
| index 488a2d918da432540c506dca731fc8566e60e38e..1c59f8dbea52baec1fe3415f98e60df98d225161 100644
|
| --- a/runtime/vm/benchmark_test.cc
|
| +++ b/runtime/vm/benchmark_test.cc
|
| @@ -20,8 +20,6 @@ using dart::bin::File;
|
|
|
| namespace dart {
|
|
|
| -DECLARE_FLAG(bool, background_compilation);
|
| -
|
| Benchmark* Benchmark::first_ = NULL;
|
| Benchmark* Benchmark::tail_ = NULL;
|
| const char* Benchmark::executable_ = NULL;
|
| @@ -181,10 +179,15 @@ BENCHMARK(Dart2JSCompilerStats) {
|
| stats->EnableBenchmark();
|
| Timer timer(true, "Compile all of dart2js benchmark");
|
| timer.Start();
|
| +#if !defined(PRODUCT)
|
| + // Constant in product mode.
|
| const bool old_flag = FLAG_background_compilation;
|
| FLAG_background_compilation = false;
|
| +#endif
|
| Dart_Handle result = Dart_CompileAll();
|
| +#if !defined(PRODUCT)
|
| FLAG_background_compilation = old_flag;
|
| +#endif
|
| EXPECT_VALID(result);
|
| timer.Stop();
|
| int64_t elapsed_time = timer.TotalElapsedTime();
|
| @@ -387,10 +390,14 @@ BENCHMARK(Dart2JSCompileAll) {
|
| }
|
| Timer timer(true, "Compile all of dart2js benchmark");
|
| timer.Start();
|
| +#if !defined(PRODUCT)
|
| const bool old_flag = FLAG_background_compilation;
|
| FLAG_background_compilation = false;
|
| +#endif
|
| Dart_Handle result = Dart_CompileAll();
|
| +#if !defined(PRODUCT)
|
| FLAG_background_compilation = old_flag;
|
| +#endif
|
| EXPECT_VALID(result);
|
| timer.Stop();
|
| int64_t elapsed_time = timer.TotalElapsedTime();
|
|
|