Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(393)

Unified Diff: vm/benchmark_test.cc

Issue 10697055: Represent tokens as a compressed stream instead of an array. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: Created 8 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | vm/datastream.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: vm/benchmark_test.cc
===================================================================
--- vm/benchmark_test.cc (revision 9536)
+++ vm/benchmark_test.cc (working copy)
@@ -173,14 +173,21 @@
1);
EXPECT(!Dart_IsError(result));
- Timer timer(true, "UseDartApi benchmark");
- timer.Start();
Dart_Handle args[1];
args[0] = Dart_NewInteger(kNumIterations);
+
+ // Warmup first to avoid compilation jitters.
Dart_Invoke(lib,
Dart_NewString("benchmark"),
1,
args);
+
+ Timer timer(true, "UseDartApi benchmark");
+ timer.Start();
+ Dart_Invoke(lib,
+ Dart_NewString("benchmark"),
+ 1,
+ args);
timer.Stop();
int64_t elapsed_time = timer.TotalElapsedTime();
benchmark->set_score(elapsed_time);
« no previous file with comments | « no previous file | vm/datastream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698