Code cleanup: moving compiler perf tests to compiler/tool
Task as described in https://docs.google.com/spreadsheets/d/1zebkSp_VjVFC_vd2JufrOkrT5O1XVu6iyoCmusE_UEk/edit#gid=0&vpid=A1
R=sigmund@google.com
Review URL: https://codereview.chromium.org/2473553005 .
diff --git a/pkg/compiler/lib/src/dart2js_profile_many.dart b/pkg/compiler/tool/dart2js_profile_many.dart
similarity index 94%
rename from pkg/compiler/lib/src/dart2js_profile_many.dart
rename to pkg/compiler/tool/dart2js_profile_many.dart
index 8288a9a..ba344e0 100644
--- a/pkg/compiler/lib/src/dart2js_profile_many.dart
+++ b/pkg/compiler/tool/dart2js_profile_many.dart
@@ -6,7 +6,7 @@
import 'dart:async';
-import 'dart2js.dart' as cmdline;
+import 'package:compiler/src/dart2js.dart' as cmdline
const String USAGE = """
Usage: dart2js_profile_many.dart [OPTIONS] [FILES]
diff --git a/pkg/compiler/lib/src/dart2js_stress.dart b/pkg/compiler/tool/dart2js_stress.dart
similarity index 80%
rename from pkg/compiler/lib/src/dart2js_stress.dart
rename to pkg/compiler/tool/dart2js_stress.dart
index 804c577..d699e2b 100644
--- a/pkg/compiler/lib/src/dart2js_stress.dart
+++ b/pkg/compiler/tool/dart2js_stress.dart
@@ -4,7 +4,8 @@
library dart2js.stress;
-import "dart2js.dart" as dart2js;
+import 'package:compiler/src/dart2js.dart' as dart2js;
+import 'dart:io' show Platform;
const ITERATIONS_FLAG_PREFIX = "--iterations=";
void main(List<String> args) {
@@ -20,7 +21,9 @@
"Use '$ITERATIONS_FLAG_PREFIX<count>' to set a repetition count"
" (as first flag).");
}
- args = ["--suppress-warnings", "--suppress-hints"]..addAll(args);
+ args = ["--suppress-warnings", "--suppress-hints", "--library-root="
+ "${Platform.script.resolve('../../../sdk').toFilePath()}"]
+ ..addAll(args);
void iterate() {
count++;
sw.reset();