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

Issue 8439061: Support command line parameters to specify a url to file name mapping. This is used during snapsh... (Closed)

Created:
9 years, 1 month ago by siva
Modified:
9 years, 1 month ago
Reviewers:
Anton Muhin
CC:
reviews_dartlang.org, vm-dev_dartlang.org
Visibility:
Public.

Description

Support command line parameters to specify a url to file name mapping. This is used during snapshot generation so that a URL is mapped to a physical file name. Committed: https://code.google.com/p/dart/source/detail?r=1550

Patch Set 1 #

Patch Set 2 : '' #

Patch Set 3 : '' #

Total comments: 1

Patch Set 4 : '' #

Total comments: 15

Patch Set 5 : '' #

Total comments: 7

Patch Set 6 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+237 lines, -99 lines) Patch
M bin/gen_snapshot.cc View 1 2 3 4 5 6 chunks +140 lines, -5 lines 0 comments Download
M bin/main.cc View 1 2 3 4 5 1 chunk +3 lines, -2 lines 0 comments Download
M bin/process_script.h View 1 2 3 4 5 3 chunks +9 lines, -6 lines 0 comments Download
M bin/process_script.cc View 1 2 3 4 5 5 chunks +42 lines, -64 lines 0 comments Download
M bin/run_vm_tests.cc View 1 2 3 4 5 2 chunks +3 lines, -3 lines 0 comments Download
M tools/create_snapshot_file.py View 1 2 3 4 5 3 chunks +34 lines, -14 lines 0 comments Download
M vm/dart.h View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M vm/dart.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M vm/dart_api_impl.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M vm/flags.h View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M vm/flags.cc View 1 2 3 4 5 1 chunk +2 lines, -1 line 0 comments Download

Messages

Total messages: 8 (0 generated)
siva
9 years, 1 month ago (2011-11-03 00:01:39 UTC) #1
siva
PTAL The usage is as follows: sivamach[runtime]>more /workspace/asiva/tmp/junk.dart #import("dart:dom1"); #import("dart:dom2"); main() { func1(); func2(); func3(); ...
9 years, 1 month ago (2011-11-12 02:23:51 UTC) #2
Anton Muhin
http://codereview.chromium.org/8439061/diff/2005/bin/gen_snapshot.cc File bin/gen_snapshot.cc (right): http://codereview.chromium.org/8439061/diff/2005/bin/gen_snapshot.cc#newcode123 bin/gen_snapshot.cc:123: Dart_Handle result = Dart_StringToCString(url, &url_chars); nit: maybe TODO to ...
9 years, 1 month ago (2011-11-14 14:02:13 UTC) #3
Anton Muhin
http://codereview.chromium.org/8439061/diff/8001/bin/gen_snapshot.cc File bin/gen_snapshot.cc (right): http://codereview.chromium.org/8439061/diff/8001/bin/gen_snapshot.cc#newcode193 bin/gen_snapshot.cc:193: url_chars = MapLibraryUrl(url_chars); Sorry, I now think you handle ...
9 years, 1 month ago (2011-11-14 16:44:05 UTC) #4
siva
Addressed comments. http://codereview.chromium.org/8439061/diff/8001/bin/gen_snapshot.cc File bin/gen_snapshot.cc (right): http://codereview.chromium.org/8439061/diff/8001/bin/gen_snapshot.cc#newcode118 bin/gen_snapshot.cc:118: int len = strlen(library_url_chars); On 2011/11/14 14:02:14, ...
9 years, 1 month ago (2011-11-14 22:17:09 UTC) #5
Anton Muhin
Thanks a lot. The only problem I can see is w/ check mapped_url_chars, except for ...
9 years, 1 month ago (2011-11-15 12:34:32 UTC) #6
siva
http://codereview.chromium.org/8439061/diff/14001/bin/gen_snapshot.cc File bin/gen_snapshot.cc (right): http://codereview.chromium.org/8439061/diff/14001/bin/gen_snapshot.cc#newcode135 bin/gen_snapshot.cc:135: // Create the full path based on the including ...
9 years, 1 month ago (2011-11-15 21:00:27 UTC) #7
Anton Muhin
9 years, 1 month ago (2011-11-16 12:45:35 UTC) #8
http://codereview.chromium.org/8439061/diff/14001/bin/gen_snapshot.cc
File bin/gen_snapshot.cc (right):

http://codereview.chromium.org/8439061/diff/14001/bin/gen_snapshot.cc#newcode171
bin/gen_snapshot.cc:171: return Dart_NewString(mapped_url_chars);
Looks like you've submitted it, so let me just experiment.  But I am still
somewhat uneasy that for dart:foo we just return the string doing no
LoadScript/LoadLibrary for kImportTag/kSourceTag.

On 2011/11/15 21:00:27, asiva wrote:
> In this case we found a mapping on the command line for the url so we return
the
> mapping specified on the command line for the URL.
> e.g if url_mapping=dart:dom,/myfile/file.dart
> is specified we would return "/mfile/file.dart" here.
> 
> On 2011/11/15 12:34:32, antonmuhin wrote:
> > is it ok?  you have kImportTag/kSourceTag, but do nothing here.
>

Powered by Google App Engine
This is Rietveld 408576698