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

Issue 225723002: Add support for --raw and --omit to js2c. (Closed)

Created:
6 years, 8 months ago by vogelheim
Modified:
6 years, 8 months ago
CC:
v8-dev
Visibility:
Public.

Description

Add support for --raw and --omit to js2c. --raw writes the raw source data to a separate file --omit allows omitting the source data from the generated files. The intention is (future) support for having the embedder optionally store the source data 'blob' and handling it to V8::Initialize, with the goal of reducing the binary size of V8. The patch also contains numerous unrelated changes/refactorings in the hope of increasing maintainability. Let me know whether you agree. In particular: - Remove some unused code. - Do not overwrite Python built-ins (e.g. the type() function) - Do not use a string as exception object (no longer supported in python 2.7) - Add command line argument handling + help text. - Split logic into: - PrepareSources - which reads + preprocesses the source files - BuildMetadata - which takes the prepared sources and generates the data the code template needs. BUG=355539 LOG=N R=jochen@chromium.org Committed: https://code.google.com/p/v8/source/detail?r=20657

Patch Set 1 : #

Patch Set 2 : style fixes #

Patch Set 3 : use optparse instead of argparse. (Some build bots use python 2.6 which doesn't have argparse.) #

Unified diffs Side-by-side diffs Delta from patch set Stats (+219 lines, -137 lines) Patch
M tools/js2c.py View 1 2 9 chunks +219 lines, -137 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
vogelheim
Not sure whether I'm on the right track; please have a look at this.
6 years, 8 months ago (2014-04-04 10:55:22 UTC) #1
jochen (gone - plz use gerrit)
can you reference the bug (355539) in the cl description? lgtm
6 years, 8 months ago (2014-04-04 11:52:40 UTC) #2
vogelheim
6 years, 8 months ago (2014-04-10 14:53:38 UTC) #3
Message was sent while issue was closed.
Committed patchset #3 manually as r20657 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698