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

Unified Diff: tools/logreader.js

Issue 6529032: Merge 6168:6800 from bleeding_edge to experimental/gc branch. (Closed) Base URL: http://v8.googlecode.com/svn/branches/experimental/gc/
Patch Set: Created 9 years, 10 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/gyp/v8.gyp ('k') | tools/oprofile/annotate » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/logreader.js
===================================================================
--- tools/logreader.js (revision 6800)
+++ tools/logreader.js (working copy)
@@ -29,11 +29,7 @@
* @fileoverview Log Reader is used to process log file produced by V8.
*/
-// Initlialize namespaces
-var devtools = devtools || {};
-devtools.profiler = devtools.profiler || {};
-
/**
* Base class for processing log files.
*
@@ -41,7 +37,7 @@
* log records.
* @constructor
*/
-devtools.profiler.LogReader = function(dispatchTable) {
+function LogReader(dispatchTable) {
/**
* @type {Array.<Object>}
*/
@@ -55,9 +51,9 @@
/**
* CSV lines parser.
- * @type {devtools.profiler.CsvParser}
+ * @type {CsvParser}
*/
- this.csvParser_ = new devtools.profiler.CsvParser();
+ this.csvParser_ = new CsvParser();
};
@@ -66,7 +62,7 @@
*
* @param {string} str Error message.
*/
-devtools.profiler.LogReader.prototype.printError = function(str) {
+LogReader.prototype.printError = function(str) {
// Do nothing.
};
@@ -76,7 +72,7 @@
*
* @param {string} chunk A portion of log.
*/
-devtools.profiler.LogReader.prototype.processLogChunk = function(chunk) {
+LogReader.prototype.processLogChunk = function(chunk) {
this.processLog_(chunk.split('\n'));
};
@@ -86,7 +82,7 @@
*
* @param {string} line A line of log.
*/
-devtools.profiler.LogReader.prototype.processLogLine = function(line) {
+LogReader.prototype.processLogLine = function(line) {
this.processLog_([line]);
};
@@ -99,7 +95,7 @@
* @param {Array.<string>} stack String representation of a stack.
* @return {Array.<number>} Processed stack.
*/
-devtools.profiler.LogReader.prototype.processStack = function(pc, func, stack) {
+LogReader.prototype.processStack = function(pc, func, stack) {
var fullStack = func ? [pc, func] : [pc];
var prevFrame = pc;
for (var i = 0, n = stack.length; i < n; ++i) {
@@ -124,7 +120,7 @@
* @param {!Object} dispatch Dispatch record.
* @return {boolean} True if dispatch must be skipped.
*/
-devtools.profiler.LogReader.prototype.skipDispatch = function(dispatch) {
+LogReader.prototype.skipDispatch = function(dispatch) {
return false;
};
@@ -135,7 +131,7 @@
* @param {Array.<string>} fields Log record.
* @private
*/
-devtools.profiler.LogReader.prototype.dispatchLogRow_ = function(fields) {
+LogReader.prototype.dispatchLogRow_ = function(fields) {
// Obtain the dispatch.
var command = fields[0];
if (!(command in this.dispatchTable_)) {
@@ -173,7 +169,7 @@
* @param {Array.<string>} lines Log lines.
* @private
*/
-devtools.profiler.LogReader.prototype.processLog_ = function(lines) {
+LogReader.prototype.processLog_ = function(lines) {
for (var i = 0, n = lines.length; i < n; ++i, ++this.lineNum_) {
var line = lines[i];
if (!line) {
« no previous file with comments | « tools/gyp/v8.gyp ('k') | tools/oprofile/annotate » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698