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

Unified Diff: tools/tickprocessor.js

Issue 1796863002: Remove snapshot log parsing and option from tools. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebase on master. Created 4 years, 8 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 | « tools/tick-processor.html ('k') | tools/tickprocessor-driver.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/tickprocessor.js
diff --git a/tools/tickprocessor.js b/tools/tickprocessor.js
index 600d2eeb7b79dc3bcee56f183e0ec3c2347e83f6..7d07bf6c558a37a63e27e318bebbd9f89efa57d9 100644
--- a/tools/tickprocessor.js
+++ b/tools/tickprocessor.js
@@ -70,88 +70,12 @@ function parseState(s) {
}
-function SnapshotLogProcessor() {
- LogReader.call(this, {
- 'code-creation': {
- parsers: [null, parseInt, parseInt, parseInt, null, 'var-args'],
- processor: this.processCodeCreation },
- 'code-move': { parsers: [parseInt, parseInt],
- processor: this.processCodeMove },
- 'code-delete': { parsers: [parseInt],
- processor: this.processCodeDelete },
- 'function-creation': null,
- 'function-move': null,
- 'function-delete': null,
- 'sfi-move': null,
- 'snapshot-pos': { parsers: [parseInt, parseInt],
- processor: this.processSnapshotPosition }});
-
- V8Profile.prototype.handleUnknownCode = function(operation, addr) {
- var op = Profile.Operation;
- switch (operation) {
- case op.MOVE:
- print('Snapshot: Code move event for unknown code: 0x' +
- addr.toString(16));
- break;
- case op.DELETE:
- print('Snapshot: Code delete event for unknown code: 0x' +
- addr.toString(16));
- break;
- }
- };
-
- this.profile_ = new V8Profile();
- this.serializedEntries_ = [];
-}
-inherits(SnapshotLogProcessor, LogReader);
-
-
-SnapshotLogProcessor.prototype.processCodeCreation = function(
- type, kind, start, size, name, maybe_func) {
- if (maybe_func.length) {
- var funcAddr = parseInt(maybe_func[0]);
- var state = parseState(maybe_func[1]);
- this.profile_.addFuncCode(type, name, start, size, funcAddr, state);
- } else {
- this.profile_.addCode(type, name, start, size);
- }
-};
-
-
-SnapshotLogProcessor.prototype.processCodeMove = function(from, to) {
- this.profile_.moveCode(from, to);
-};
-
-
-SnapshotLogProcessor.prototype.processCodeDelete = function(start) {
- this.profile_.deleteCode(start);
-};
-
-
-SnapshotLogProcessor.prototype.processSnapshotPosition = function(addr, pos) {
- this.serializedEntries_[pos] = this.profile_.findEntry(addr);
-};
-
-
-SnapshotLogProcessor.prototype.processLogFile = function(fileName) {
- var contents = readFile(fileName);
- this.processLogChunk(contents);
-};
-
-
-SnapshotLogProcessor.prototype.getSerializedEntryName = function(pos) {
- var entry = this.serializedEntries_[pos];
- return entry ? entry.getRawName() : null;
-};
-
-
function TickProcessor(
cppEntriesProvider,
separateIc,
callGraphSize,
ignoreUnknown,
stateFilter,
- snapshotLogProcessor,
distortion,
range,
sourceMap,
@@ -170,8 +94,6 @@ function TickProcessor(
processor: this.processCodeDelete },
'sfi-move': { parsers: [parseInt, parseInt],
processor: this.processFunctionMove },
- 'snapshot-pos': { parsers: [parseInt, parseInt],
- processor: this.processSnapshotPosition },
'tick': {
parsers: [parseInt, parseInt, parseInt,
parseInt, parseInt, 'var-args'],
@@ -202,7 +124,6 @@ function TickProcessor(
this.callGraphSize_ = callGraphSize;
this.ignoreUnknown_ = ignoreUnknown;
this.stateFilter_ = stateFilter;
- this.snapshotLogProcessor_ = snapshotLogProcessor;
this.sourceMap = sourceMap;
this.deserializedEntriesNames_ = [];
var ticks = this.ticks_ =
@@ -362,14 +283,6 @@ TickProcessor.prototype.processFunctionMove = function(from, to) {
};
-TickProcessor.prototype.processSnapshotPosition = function(addr, pos) {
- if (this.snapshotLogProcessor_) {
- this.deserializedEntriesNames_[addr] =
- this.snapshotLogProcessor_.getSerializedEntryName(pos);
- }
-};
-
-
TickProcessor.prototype.includeTick = function(vmState) {
return this.stateFilter_ == null || this.stateFilter_ == vmState;
};
@@ -880,8 +793,6 @@ function ArgumentsProcessor(args) {
'Specify the \'nm\' executable to use (e.g. --nm=/my_dir/nm)'],
'--target': ['targetRootFS', '',
'Specify the target root directory for cross environment'],
- '--snapshot-log': ['snapshotLogFileName', 'snapshot.log',
- 'Specify snapshot log file to use (e.g. --snapshot-log=snapshot.log)'],
'--range': ['range', 'auto,auto',
'Specify the range limit as [start],[end]'],
'--distortion': ['distortion', 0,
@@ -906,7 +817,6 @@ function ArgumentsProcessor(args) {
ArgumentsProcessor.DEFAULTS = {
logFileName: 'v8.log',
- snapshotLogFileName: null,
platform: 'unix',
stateFilter: null,
callGraphSize: 5,
« no previous file with comments | « tools/tick-processor.html ('k') | tools/tickprocessor-driver.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698