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

Unified Diff: dart/utils/compiler/build_helper.dart

Issue 11187028: Generate snapshot for dartj2s; use it in the SDK. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Disable optimizations during gen_snapshot to work around crash Created 8 years, 2 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 | « dart/tools/create_sdk.py ('k') | dart/utils/compiler/compiler.gyp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: dart/utils/compiler/build_helper.dart
diff --git a/dart/utils/compiler/build_helper.dart b/dart/utils/compiler/build_helper.dart
index 9e29f84f158dff6f35bd51dc5b8c3ebb1bc79955..6821599be2391dbd4ca322476179aecac9c1aad4 100644
--- a/dart/utils/compiler/build_helper.dart
+++ b/dart/utils/compiler/build_helper.dart
@@ -116,7 +116,14 @@ if test -t 1; then
COLORS="--enable-diagnostic-colors"
fi
fi
-exec "\$BIN_DIR"/dart$options "\$BIN_DIR/$path" \$COLORS "\$@"
+
+unset SNAPSHOT
+if test -f "\$BIN_DIR/${path}.snapshot"; then
+ # TODO(ahe): Remove the following line when we are relatively sure it works.
+ echo Using snapshot "\$BIN_DIR/${path}.snapshot" 1>&2
+ SNAPSHOT="--use_script_snapshot=\$BIN_DIR/${path}.snapshot"
+fi
+exec "\$BIN_DIR"/dart$options \$SNAPSHOT "\$BIN_DIR/$path" \$COLORS "\$@"
''',
'''
@echo off
« no previous file with comments | « dart/tools/create_sdk.py ('k') | dart/utils/compiler/compiler.gyp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698