Skip to content

Commit 1ff8566

Browse files
committed
0718603 chore(perf): return perf metrics from AngularProfiler
1 parent 3f25754 commit 1ff8566

758 files changed

Lines changed: 923 additions & 1243 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

BUILD_INFO

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
1-
Fri Apr 15 21:51:03 UTC 2016
2-
9c712595ca398ae3aa3074428f0d0f168a62e96e
1+
Fri Apr 15 21:55:44 UTC 2016
2+
0718603e3e8a88aecda08bc1de48302ce0081ece

animate.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

animate/testing.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

bundles/angular2-all-testing.umd.dev.js

Lines changed: 13 additions & 29 deletions
Large diffs are not rendered by default.

bundles/angular2-all.umd.dev.js

Lines changed: 13 additions & 29 deletions
Large diffs are not rendered by default.

bundles/angular2-all.umd.js

Lines changed: 12 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -19380,7 +19380,7 @@ return /******/ (function(modules) { // webpackBootstrap
1938019380
}
1938119381
Parser.prototype.parseAction = function (input, location) {
1938219382
this._checkNoInterpolation(input, location);
19383-
var tokens = this._lexer.tokenize(this._stripComments(input));
19383+
var tokens = this._lexer.tokenize(input);
1938419384
var ast = new _ParseAST(input, location, tokens, true).parseChain();
1938519385
return new ast_1.ASTWithSource(ast, input, location);
1938619386
};
@@ -19403,7 +19403,7 @@ return /******/ (function(modules) { // webpackBootstrap
1940319403
return quote;
1940419404
}
1940519405
this._checkNoInterpolation(input, location);
19406-
var tokens = this._lexer.tokenize(this._stripComments(input));
19406+
var tokens = this._lexer.tokenize(input);
1940719407
return new _ParseAST(input, location, tokens, false).parseChain();
1940819408
};
1940919409
Parser.prototype._parseQuote = function (input, location) {
@@ -19428,7 +19428,7 @@ return /******/ (function(modules) { // webpackBootstrap
1942819428
return null;
1942919429
var expressions = [];
1943019430
for (var i = 0; i < split.expressions.length; ++i) {
19431-
var tokens = this._lexer.tokenize(this._stripComments(split.expressions[i]));
19431+
var tokens = this._lexer.tokenize(split.expressions[i]);
1943219432
var ast = new _ParseAST(input, location, tokens, false).parseChain();
1943319433
expressions.push(ast);
1943419434
}
@@ -19459,26 +19459,6 @@ return /******/ (function(modules) { // webpackBootstrap
1945919459
Parser.prototype.wrapLiteralPrimitive = function (input, location) {
1946019460
return new ast_1.ASTWithSource(new ast_1.LiteralPrimitive(input), input, location);
1946119461
};
19462-
Parser.prototype._stripComments = function (input) {
19463-
var i = this._commentStart(input);
19464-
return lang_1.isPresent(i) ? input.substring(0, i).trim() : input;
19465-
};
19466-
Parser.prototype._commentStart = function (input) {
19467-
var outerQuote = null;
19468-
for (var i = 0; i < input.length - 1; i++) {
19469-
var char = lang_1.StringWrapper.charCodeAt(input, i);
19470-
var nextChar = lang_1.StringWrapper.charCodeAt(input, i + 1);
19471-
if (char === lexer_1.$SLASH && nextChar == lexer_1.$SLASH && lang_1.isBlank(outerQuote))
19472-
return i;
19473-
if (outerQuote === char) {
19474-
outerQuote = null;
19475-
}
19476-
else if (lang_1.isBlank(outerQuote) && lexer_1.isQuote(char)) {
19477-
outerQuote = char;
19478-
}
19479-
}
19480-
return null;
19481-
};
1948219462
Parser.prototype._checkNoInterpolation = function (input, location) {
1948319463
var parts = lang_1.StringWrapper.split(input, INTERPOLATION_REGEXP);
1948419464
if (parts.length > 1) {
@@ -20157,7 +20137,6 @@ return /******/ (function(modules) { // webpackBootstrap
2015720137
exports.$RBRACKET = 93;
2015820138
var $CARET = 94;
2015920139
var $_ = 95;
20160-
exports.$BT = 96;
2016120140
var $a = 97, $e = 101, $f = 102, $n = 110, $r = 114, $t = 116, $u = 117, $v = 118, $z = 122;
2016220141
exports.$LBRACE = 123;
2016320142
exports.$BAR = 124;
@@ -20416,10 +20395,6 @@ return /******/ (function(modules) { // webpackBootstrap
2041620395
function isExponentSign(code) {
2041720396
return code == exports.$MINUS || code == exports.$PLUS;
2041820397
}
20419-
function isQuote(code) {
20420-
return code === exports.$SQ || code === exports.$DQ || code === exports.$BT;
20421-
}
20422-
exports.isQuote = isQuote;
2042320398
function unescape(code) {
2042420399
switch (code) {
2042520400
case $n:
@@ -33467,6 +33442,14 @@ return /******/ (function(modules) { // webpackBootstrap
3346733442
var lang_1 = __webpack_require__(5);
3346833443
var browser_1 = __webpack_require__(228);
3346933444
var dom_adapter_1 = __webpack_require__(196);
33445+
var ChangeDetectionPerfRecord = (function () {
33446+
function ChangeDetectionPerfRecord(msPerTick, numTicks) {
33447+
this.msPerTick = msPerTick;
33448+
this.numTicks = numTicks;
33449+
}
33450+
return ChangeDetectionPerfRecord;
33451+
}());
33452+
exports.ChangeDetectionPerfRecord = ChangeDetectionPerfRecord;
3347033453
/**
3347133454
* Entry point for all Angular debug tools. This object corresponds to the `ng`
3347233455
* global variable accessible in the dev console.
@@ -33527,6 +33510,7 @@ return /******/ (function(modules) { // webpackBootstrap
3352733510
var msPerTick = (end - start) / numTicks;
3352833511
browser_1.window.console.log("ran " + numTicks + " change detection cycles");
3352933512
browser_1.window.console.log(lang_1.NumberWrapper.toFixed(msPerTick, 2) + " ms per check");
33513+
return new ChangeDetectionPerfRecord(msPerTick, numTicks);
3353033514
};
3353133515
return AngularProfiler;
3353233516
}());

bundles/angular2-all.umd.min.js

Lines changed: 20 additions & 20 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

bundles/angular2.dev.js

Lines changed: 12 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -14178,7 +14178,6 @@ System.register("angular2/src/compiler/expression_parser/lexer", ["angular2/src/
1417814178
exports.$RBRACKET = 93;
1417914179
var $CARET = 94;
1418014180
var $_ = 95;
14181-
exports.$BT = 96;
1418214181
var $a = 97,
1418314182
$e = 101,
1418414183
$f = 102,
@@ -14422,10 +14421,6 @@ System.register("angular2/src/compiler/expression_parser/lexer", ["angular2/src/
1442214421
function isExponentSign(code) {
1442314422
return code == exports.$MINUS || code == exports.$PLUS;
1442414423
}
14425-
function isQuote(code) {
14426-
return code === exports.$SQ || code === exports.$DQ || code === exports.$BT;
14427-
}
14428-
exports.isQuote = isQuote;
1442914424
function unescape(code) {
1443014425
switch (code) {
1443114426
case $n:
@@ -20559,6 +20554,14 @@ System.register("angular2/src/platform/browser/tools/common_tools", ["angular2/s
2055920554
var lang_1 = require("angular2/src/facade/lang");
2056020555
var browser_1 = require("angular2/src/facade/browser");
2056120556
var dom_adapter_1 = require("angular2/src/platform/dom/dom_adapter");
20557+
var ChangeDetectionPerfRecord = (function() {
20558+
function ChangeDetectionPerfRecord(msPerTick, numTicks) {
20559+
this.msPerTick = msPerTick;
20560+
this.numTicks = numTicks;
20561+
}
20562+
return ChangeDetectionPerfRecord;
20563+
}());
20564+
exports.ChangeDetectionPerfRecord = ChangeDetectionPerfRecord;
2056220565
var AngularTools = (function() {
2056320566
function AngularTools(ref) {
2056420567
this.profiler = new AngularProfiler(ref);
@@ -20590,6 +20593,7 @@ System.register("angular2/src/platform/browser/tools/common_tools", ["angular2/s
2059020593
var msPerTick = (end - start) / numTicks;
2059120594
browser_1.window.console.log("ran " + numTicks + " change detection cycles");
2059220595
browser_1.window.console.log(lang_1.NumberWrapper.toFixed(msPerTick, 2) + " ms per check");
20596+
return new ChangeDetectionPerfRecord(msPerTick, numTicks);
2059320597
};
2059420598
return AngularProfiler;
2059520599
}());
@@ -20657,7 +20661,7 @@ System.register("angular2/src/compiler/expression_parser/parser", ["angular2/src
2065720661
}
2065820662
Parser.prototype.parseAction = function(input, location) {
2065920663
this._checkNoInterpolation(input, location);
20660-
var tokens = this._lexer.tokenize(this._stripComments(input));
20664+
var tokens = this._lexer.tokenize(input);
2066120665
var ast = new _ParseAST(input, location, tokens, true).parseChain();
2066220666
return new ast_1.ASTWithSource(ast, input, location);
2066320667
};
@@ -20678,7 +20682,7 @@ System.register("angular2/src/compiler/expression_parser/parser", ["angular2/src
2067820682
return quote;
2067920683
}
2068020684
this._checkNoInterpolation(input, location);
20681-
var tokens = this._lexer.tokenize(this._stripComments(input));
20685+
var tokens = this._lexer.tokenize(input);
2068220686
return new _ParseAST(input, location, tokens, false).parseChain();
2068320687
};
2068420688
Parser.prototype._parseQuote = function(input, location) {
@@ -20703,7 +20707,7 @@ System.register("angular2/src/compiler/expression_parser/parser", ["angular2/src
2070320707
return null;
2070420708
var expressions = [];
2070520709
for (var i = 0; i < split.expressions.length; ++i) {
20706-
var tokens = this._lexer.tokenize(this._stripComments(split.expressions[i]));
20710+
var tokens = this._lexer.tokenize(split.expressions[i]);
2070720711
var ast = new _ParseAST(input, location, tokens, false).parseChain();
2070820712
expressions.push(ast);
2070920713
}
@@ -20731,25 +20735,6 @@ System.register("angular2/src/compiler/expression_parser/parser", ["angular2/src
2073120735
Parser.prototype.wrapLiteralPrimitive = function(input, location) {
2073220736
return new ast_1.ASTWithSource(new ast_1.LiteralPrimitive(input), input, location);
2073320737
};
20734-
Parser.prototype._stripComments = function(input) {
20735-
var i = this._commentStart(input);
20736-
return lang_1.isPresent(i) ? input.substring(0, i).trim() : input;
20737-
};
20738-
Parser.prototype._commentStart = function(input) {
20739-
var outerQuote = null;
20740-
for (var i = 0; i < input.length - 1; i++) {
20741-
var char = lang_1.StringWrapper.charCodeAt(input, i);
20742-
var nextChar = lang_1.StringWrapper.charCodeAt(input, i + 1);
20743-
if (char === lexer_1.$SLASH && nextChar == lexer_1.$SLASH && lang_1.isBlank(outerQuote))
20744-
return i;
20745-
if (outerQuote === char) {
20746-
outerQuote = null;
20747-
} else if (lang_1.isBlank(outerQuote) && lexer_1.isQuote(char)) {
20748-
outerQuote = char;
20749-
}
20750-
}
20751-
return null;
20752-
};
2075320738
Parser.prototype._checkNoInterpolation = function(input, location) {
2075420739
var parts = lang_1.StringWrapper.split(input, INTERPOLATION_REGEXP);
2075520740
if (parts.length > 1) {

bundles/angular2.js

Lines changed: 12 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -14178,7 +14178,6 @@ System.register("angular2/src/compiler/expression_parser/lexer", ["angular2/src/
1417814178
exports.$RBRACKET = 93;
1417914179
var $CARET = 94;
1418014180
var $_ = 95;
14181-
exports.$BT = 96;
1418214181
var $a = 97,
1418314182
$e = 101,
1418414183
$f = 102,
@@ -14422,10 +14421,6 @@ System.register("angular2/src/compiler/expression_parser/lexer", ["angular2/src/
1442214421
function isExponentSign(code) {
1442314422
return code == exports.$MINUS || code == exports.$PLUS;
1442414423
}
14425-
function isQuote(code) {
14426-
return code === exports.$SQ || code === exports.$DQ || code === exports.$BT;
14427-
}
14428-
exports.isQuote = isQuote;
1442914424
function unescape(code) {
1443014425
switch (code) {
1443114426
case $n:
@@ -20559,6 +20554,14 @@ System.register("angular2/src/platform/browser/tools/common_tools", ["angular2/s
2055920554
var lang_1 = require("angular2/src/facade/lang");
2056020555
var browser_1 = require("angular2/src/facade/browser");
2056120556
var dom_adapter_1 = require("angular2/src/platform/dom/dom_adapter");
20557+
var ChangeDetectionPerfRecord = (function() {
20558+
function ChangeDetectionPerfRecord(msPerTick, numTicks) {
20559+
this.msPerTick = msPerTick;
20560+
this.numTicks = numTicks;
20561+
}
20562+
return ChangeDetectionPerfRecord;
20563+
}());
20564+
exports.ChangeDetectionPerfRecord = ChangeDetectionPerfRecord;
2056220565
var AngularTools = (function() {
2056320566
function AngularTools(ref) {
2056420567
this.profiler = new AngularProfiler(ref);
@@ -20590,6 +20593,7 @@ System.register("angular2/src/platform/browser/tools/common_tools", ["angular2/s
2059020593
var msPerTick = (end - start) / numTicks;
2059120594
browser_1.window.console.log("ran " + numTicks + " change detection cycles");
2059220595
browser_1.window.console.log(lang_1.NumberWrapper.toFixed(msPerTick, 2) + " ms per check");
20596+
return new ChangeDetectionPerfRecord(msPerTick, numTicks);
2059320597
};
2059420598
return AngularProfiler;
2059520599
}());
@@ -20657,7 +20661,7 @@ System.register("angular2/src/compiler/expression_parser/parser", ["angular2/src
2065720661
}
2065820662
Parser.prototype.parseAction = function(input, location) {
2065920663
this._checkNoInterpolation(input, location);
20660-
var tokens = this._lexer.tokenize(this._stripComments(input));
20664+
var tokens = this._lexer.tokenize(input);
2066120665
var ast = new _ParseAST(input, location, tokens, true).parseChain();
2066220666
return new ast_1.ASTWithSource(ast, input, location);
2066320667
};
@@ -20678,7 +20682,7 @@ System.register("angular2/src/compiler/expression_parser/parser", ["angular2/src
2067820682
return quote;
2067920683
}
2068020684
this._checkNoInterpolation(input, location);
20681-
var tokens = this._lexer.tokenize(this._stripComments(input));
20685+
var tokens = this._lexer.tokenize(input);
2068220686
return new _ParseAST(input, location, tokens, false).parseChain();
2068320687
};
2068420688
Parser.prototype._parseQuote = function(input, location) {
@@ -20703,7 +20707,7 @@ System.register("angular2/src/compiler/expression_parser/parser", ["angular2/src
2070320707
return null;
2070420708
var expressions = [];
2070520709
for (var i = 0; i < split.expressions.length; ++i) {
20706-
var tokens = this._lexer.tokenize(this._stripComments(split.expressions[i]));
20710+
var tokens = this._lexer.tokenize(split.expressions[i]);
2070720711
var ast = new _ParseAST(input, location, tokens, false).parseChain();
2070820712
expressions.push(ast);
2070920713
}
@@ -20731,25 +20735,6 @@ System.register("angular2/src/compiler/expression_parser/parser", ["angular2/src
2073120735
Parser.prototype.wrapLiteralPrimitive = function(input, location) {
2073220736
return new ast_1.ASTWithSource(new ast_1.LiteralPrimitive(input), input, location);
2073320737
};
20734-
Parser.prototype._stripComments = function(input) {
20735-
var i = this._commentStart(input);
20736-
return lang_1.isPresent(i) ? input.substring(0, i).trim() : input;
20737-
};
20738-
Parser.prototype._commentStart = function(input) {
20739-
var outerQuote = null;
20740-
for (var i = 0; i < input.length - 1; i++) {
20741-
var char = lang_1.StringWrapper.charCodeAt(input, i);
20742-
var nextChar = lang_1.StringWrapper.charCodeAt(input, i + 1);
20743-
if (char === lexer_1.$SLASH && nextChar == lexer_1.$SLASH && lang_1.isBlank(outerQuote))
20744-
return i;
20745-
if (outerQuote === char) {
20746-
outerQuote = null;
20747-
} else if (lang_1.isBlank(outerQuote) && lexer_1.isQuote(char)) {
20748-
outerQuote = char;
20749-
}
20750-
}
20751-
return null;
20752-
};
2075320738
Parser.prototype._checkNoInterpolation = function(input, location) {
2075420739
var parts = lang_1.StringWrapper.split(input, INTERPOLATION_REGEXP);
2075520740
if (parts.length > 1) {

bundles/angular2.min.js

Lines changed: 8 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)