Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v7.7.4 Release Proposal #11941

Merged
merged 48 commits into from
Mar 21, 2017
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
48 commits
Select commit Hold shift + click to select a range
14e3ad0
inspector: proper WS URLs when bound to 0.0.0.0
Mar 1, 2017
5b1d61c
child_process: fix deoptimizing use of arguments
vsemozhetbyt Feb 19, 2017
9a59913
util: avoid using forEach
jasnell Feb 27, 2017
5408301
tls: keep track of stream that is closed
jBarz Mar 9, 2017
646ee55
tls: avoid using forEach
jasnell Feb 26, 2017
5f6025b
test: fail when child dies in fork-net
joyeecheung Mar 4, 2017
c9cf922
test: add regex to assert.throws
matejkrajcovic Mar 12, 2017
d2c9111
test: fix repl-function-redefinition-edge-case
aqrln Mar 8, 2017
2df662c
test: test resolveObject with an empty path
watilde Mar 14, 2017
2649dab
test: added test for indexed properties
AnnaMag Mar 9, 2017
f9c831f
test: fix flaky test-domain-abort-on-uncaught
Trott Mar 12, 2017
560d8ee
test: delay child exit in AIX for pseudo-tty tests
gireeshpunathil Mar 6, 2017
3ae58ac
test: failing behaviour on sandboxed Proxy
AnnaMag Mar 2, 2017
8bda7b8
test: add coverage for child_process bounds check
Trott Mar 11, 2017
2cab00a
test: fix assertion in vm test
AnnaMag Mar 14, 2017
90be5a1
stream: avoid using forEach
jasnell Feb 26, 2017
62e7261
repl: avoid using forEach
jasnell Feb 27, 2017
e19ca8b
readline: remove unneeded eslint-disable comment
Trott Mar 14, 2017
a0b1aa1
readline: avoid using forEach
jasnell Feb 27, 2017
c0a2e02
net: avoid using forEach
jasnell Feb 27, 2017
7e23072
module: avoid using forEach
jasnell Feb 27, 2017
77c69f7
lib, test: add duplicate symbol checking in E()
DavidCai1111 Mar 13, 2017
9cc712c
lib: remove unused msg parameter in debug_agent
mr-spd Mar 13, 2017
fbbcd1a
lib: Fix swallowed events in inspect integration
Mar 15, 2017
cde5d71
doc: var -> let / const in events.md
vsemozhetbyt Mar 12, 2017
e6f113d
doc: console.log() -> console.error() in events.md
vsemozhetbyt Mar 12, 2017
ae52b63
doc: correct comment error in stream.md
Alex-Sokolov Mar 11, 2017
75fcf53
doc: missing argument types for events methods
ameliavoncat Mar 11, 2017
e84e33c
doc: fix a typo in api/process.md
sabakugaara Mar 10, 2017
78ca15d
doc: argument types for dns methods
ameliavoncat Mar 9, 2017
54879ab
doc: fix mistakes in stream doc (object mode)
chdh Mar 12, 2017
9861ec9
doc: increase Buffer.concat() documentation
cjihrig Mar 14, 2017
7c7228e
doc: gcc version is at least 4.8.5 in BUILDING.md
detailyang Mar 14, 2017
6d6a65e
doc: linkable commit message guidelines
sam-github Mar 10, 2017
0c09126
doc: add note that vm module is not a security mechanism
krydos Feb 25, 2017
a5f7393
doc: add vsemozhetbyt to collaborators
vsemozhetbyt Mar 20, 2017
a7e4b02
deps: Add node-inspect 1.10.6
Mar 15, 2017
5244ee3
build: mac OBJ_DIR should point to obj.target
danbev Mar 15, 2017
80949f3
build: add cpp linting to windows build
Mar 15, 2017
d0fb578
fs: avoid using forEach
jasnell Feb 26, 2017
dcac2d8
benchmark: benchmark comparing forEach with for
jasnell Feb 26, 2017
ca31986
deps: cherry-pick ca0f9573 from V8 upstream
ofrobots Mar 20, 2017
f48763c
benchmark: remove benchmarks forced optimizations
bzoz Feb 28, 2017
60ad7af
doc: deprecate debug protocol
Dec 17, 2016
0c00b65
Fix #7065: cli help documentation for --inspect
Mar 16, 2017
c626734
tls: fix segfault on destroy after partial read
bnoordhuis Mar 17, 2017
44b4c0b
2017-03-21, Version 7.7.4 (Current)
cjihrig Mar 21, 2017
bc664cb
Working on v7.7.5
cjihrig Mar 21, 2017
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
benchmark: remove benchmarks forced optimizations
Removes all instances of %OptimizeFunctionOnNextCall from benchmarks

Refs: #9615
Refs: #11720
  • Loading branch information
bzoz authored and italoacasas committed Mar 21, 2017
commit f48763c5b9d56da253296519dfe9ab664b1bee6e
9 changes: 0 additions & 9 deletions benchmark/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -235,12 +235,3 @@ it returns to accomplish what they need. This function reports timing
data to the parent process (usually created by running `compare.js`, `run.js` or
`scatter.js`).

### v8ForceOptimization(method[, ...args])

Force V8 to mark the `method` for optimization with the native function
`%OptimizeFunctionOnNextCall()` and return the optimization status
after that.

It can be used to prevent the benchmark from getting disrupted by the optimizer
kicking in halfway through. However, this could result in a less effective
optimization. In general, only use it if you know what it actually does.
4 changes: 0 additions & 4 deletions benchmark/buffers/buffer-compare-instance-method.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
'use strict';
const common = require('../common.js');
const v8 = require('v8');

const bench = common.createBenchmark(main, {
size: [16, 512, 1024, 4096, 16386],
Expand All @@ -20,7 +19,6 @@ function main(conf) {

b1[size - 1] = 'b'.charCodeAt(0);

// Force optimization before starting the benchmark
switch (args) {
case 2:
b0.compare(b1, 0);
Expand All @@ -37,8 +35,6 @@ function main(conf) {
default:
b0.compare(b1);
}
v8.setFlagsFromString('--allow_natives_syntax');
eval('%OptimizeFunctionOnNextCall(b0.compare)');
switch (args) {
case 2:
b0.compare(b1, 0);
Expand Down
23 changes: 0 additions & 23 deletions benchmark/buffers/buffer-compare-offset.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
'use strict';
const common = require('../common.js');
const v8 = require('v8');

const bench = common.createBenchmark(main, {
method: ['offset', 'slice'],
Expand All @@ -9,18 +8,6 @@ const bench = common.createBenchmark(main, {
});

function compareUsingSlice(b0, b1, len, iter) {

// Force optimization before starting the benchmark
Buffer.compare(b0.slice(1, len), b1.slice(1, len));
v8.setFlagsFromString('--allow_natives_syntax');
eval('%OptimizeFunctionOnNextCall(Buffer.compare)');
eval('%OptimizeFunctionOnNextCall(b0.slice)');
eval('%OptimizeFunctionOnNextCall(b1.slice)');
Buffer.compare(b0.slice(1, len), b1.slice(1, len));
doCompareUsingSlice(b0, b1, len, iter);
}

function doCompareUsingSlice(b0, b1, len, iter) {
var i;
bench.start();
for (i = 0; i < iter; i++)
Expand All @@ -29,16 +16,6 @@ function doCompareUsingSlice(b0, b1, len, iter) {
}

function compareUsingOffset(b0, b1, len, iter) {
len = len + 1;
// Force optimization before starting the benchmark
b0.compare(b1, 1, len, 1, len);
v8.setFlagsFromString('--allow_natives_syntax');
eval('%OptimizeFunctionOnNextCall(b0.compare)');
b0.compare(b1, 1, len, 1, len);
doCompareUsingOffset(b0, b1, len, iter);
}

function doCompareUsingOffset(b0, b1, len, iter) {
var i;
bench.start();
for (i = 0; i < iter; i++)
Expand Down
5 changes: 1 addition & 4 deletions benchmark/buffers/buffer-swap.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
'use strict';

const common = require('../common.js');
const v8 = require('v8');

const bench = common.createBenchmark(main, {
aligned: ['true', 'false'],
Expand Down Expand Up @@ -81,9 +80,7 @@ function main(conf) {
const buf = createBuffer(len, aligned === 'true');
const bufferSwap = genMethod(method);

v8.setFlagsFromString('--allow_natives_syntax');
eval('%OptimizeFunctionOnNextCall(bufferSwap)');

bufferSwap(n, buf);
bench.start();
bufferSwap(n, buf);
bench.end(n);
Expand Down
14 changes: 0 additions & 14 deletions benchmark/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -229,17 +229,3 @@ Benchmark.prototype.report = function(rate, elapsed) {
type: 'report'
});
};

exports.v8ForceOptimization = function(method) {
if (typeof method !== 'function')
return;

const v8 = require('v8');
v8.setFlagsFromString('--allow_natives_syntax');

const args = Array.prototype.slice.call(arguments, 1);
method.apply(null, args);
eval('%OptimizeFunctionOnNextCall(method)');
method.apply(null, args);
return eval('%GetOptimizationStatus(method)');
};
9 changes: 6 additions & 3 deletions benchmark/crypto/get-ciphers.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,12 @@ function main(conf) {
const v = conf.v;
const method = require(v).getCiphers;
var i = 0;

common.v8ForceOptimization(method);
// first call to getChipers will dominate the results
if (n > 1) {
for (; i < n; i++)
method();
}
bench.start();
for (; i < n; i++) method();
for (i = 0; i < n; i++) method();
bench.end(n);
}
4 changes: 0 additions & 4 deletions benchmark/es/defaultparams-bench.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@ function defaultParams(x = 1, y = 2) {

function runOldStyleDefaults(n) {

common.v8ForceOptimization(oldStyleDefaults);

var i = 0;
bench.start();
for (; i < n; i++)
Expand All @@ -33,8 +31,6 @@ function runOldStyleDefaults(n) {

function runDefaultParams(n) {

common.v8ForceOptimization(defaultParams);

var i = 0;
bench.start();
for (; i < n; i++)
Expand Down
6 changes: 0 additions & 6 deletions benchmark/es/restparams-bench.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@ function useArguments() {

function runCopyArguments(n) {

common.v8ForceOptimization(copyArguments, 1, 2, 'a', 'b');

var i = 0;
bench.start();
for (; i < n; i++)
Expand All @@ -46,8 +44,6 @@ function runCopyArguments(n) {

function runRestArguments(n) {

common.v8ForceOptimization(restArguments, 1, 2, 'a', 'b');

var i = 0;
bench.start();
for (; i < n; i++)
Expand All @@ -57,8 +53,6 @@ function runRestArguments(n) {

function runUseArguments(n) {

common.v8ForceOptimization(useArguments, 1, 2, 'a', 'b');

var i = 0;
bench.start();
for (; i < n; i++)
Expand Down
13 changes: 0 additions & 13 deletions benchmark/misc/console.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,6 @@ const common = require('../common.js');
const assert = require('assert');
const Writable = require('stream').Writable;
const util = require('util');
const v8 = require('v8');

v8.setFlagsFromString('--allow_natives_syntax');

const methods = [
'restAndSpread',
Expand Down Expand Up @@ -51,14 +48,7 @@ function usingArgumentsAndApplyC() {
nullStream.write(util.format.apply(null, arguments) + '\n');
}

function optimize(method, ...args) {
method(...args);
eval(`%OptimizeFunctionOnNextCall(${method.name})`);
method(...args);
}

function runUsingRestAndConcat(n) {
optimize(usingRestAndConcat, 'a', 1);

var i = 0;
bench.start();
Expand All @@ -70,7 +60,6 @@ function runUsingRestAndConcat(n) {
function runUsingRestAndSpread(n, concat) {

const method = concat ? usingRestAndSpreadC : usingRestAndSpreadTS;
optimize(method, 'this is %s of %d', 'a', 1);

var i = 0;
bench.start();
Expand All @@ -82,7 +71,6 @@ function runUsingRestAndSpread(n, concat) {
function runUsingRestAndApply(n, concat) {

const method = concat ? usingRestAndApplyC : usingRestAndApplyTS;
optimize(method, 'this is %s of %d', 'a', 1);

var i = 0;
bench.start();
Expand All @@ -94,7 +82,6 @@ function runUsingRestAndApply(n, concat) {
function runUsingArgumentsAndApply(n, concat) {

const method = concat ? usingArgumentsAndApplyC : usingArgumentsAndApplyTS;
optimize(method, 'this is %s of %d', 'a', 1);

var i = 0;
bench.start();
Expand Down
6 changes: 3 additions & 3 deletions benchmark/misc/punycode.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,16 +42,16 @@ function usingICU(val) {
}

function runPunycode(n, val) {
common.v8ForceOptimization(usingPunycode, val);
var i = 0;
bench.start();
for (; i < n; i++)
usingPunycode(val);
bench.start();
for (i = 0; i < n; i++)
usingPunycode(val);
bench.end(n);
}

function runICU(n, val) {
common.v8ForceOptimization(usingICU, val);
var i = 0;
bench.start();
for (; i < n; i++)
Expand Down
8 changes: 0 additions & 8 deletions benchmark/misc/util-extend-vs-object-assign.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

const common = require('../common.js');
const util = require('util');
const v8 = require('v8');

const bench = common.createBenchmark(main, {
type: ['extend', 'assign'],
Expand All @@ -12,25 +11,18 @@ const bench = common.createBenchmark(main, {
function main(conf) {
let fn;
const n = conf.n | 0;
let v8command;

if (conf.type === 'extend') {
fn = util._extend;
v8command = '%OptimizeFunctionOnNextCall(util._extend)';
} else if (conf.type === 'assign') {
fn = Object.assign;
// Object.assign is built-in, cannot be optimized
v8command = '';
}

// Force-optimize the method to test so that the benchmark doesn't
// get disrupted by the optimizer kicking in halfway through.
for (var i = 0; i < conf.type.length * 10; i += 1)
fn({}, process.env);

v8.setFlagsFromString('--allow_natives_syntax');
eval(v8command);

var obj = new Proxy({}, { set: function(a, b, c) { return true; } });

bench.start();
Expand Down
7 changes: 0 additions & 7 deletions benchmark/path/basename-posix.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
'use strict';
var common = require('../common.js');
var path = require('path');
var v8 = require('v8');

var bench = common.createBenchmark(main, {
pathext: [
Expand Down Expand Up @@ -30,12 +29,6 @@ function main(conf) {
input = input.slice(0, extIdx);
}

// Force optimization before starting the benchmark
p.basename(input, ext);
v8.setFlagsFromString('--allow_natives_syntax');
eval('%OptimizeFunctionOnNextCall(p.basename)');
p.basename(input, ext);

bench.start();
for (var i = 0; i < n; i++) {
p.basename(input, ext);
Expand Down
7 changes: 0 additions & 7 deletions benchmark/path/basename-win32.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
'use strict';
var common = require('../common.js');
var path = require('path');
var v8 = require('v8');

var bench = common.createBenchmark(main, {
pathext: [
Expand Down Expand Up @@ -30,12 +29,6 @@ function main(conf) {
input = input.slice(0, extIdx);
}

// Force optimization before starting the benchmark
p.basename(input, ext);
v8.setFlagsFromString('--allow_natives_syntax');
eval('%OptimizeFunctionOnNextCall(p.basename)');
p.basename(input, ext);

bench.start();
for (var i = 0; i < n; i++) {
p.basename(input, ext);
Expand Down
7 changes: 0 additions & 7 deletions benchmark/path/dirname-posix.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
'use strict';
var common = require('../common.js');
var path = require('path');
var v8 = require('v8');

var bench = common.createBenchmark(main, {
path: [
Expand All @@ -21,12 +20,6 @@ function main(conf) {
var p = path.posix;
var input = '' + conf.path;

// Force optimization before starting the benchmark
p.dirname(input);
v8.setFlagsFromString('--allow_natives_syntax');
eval('%OptimizeFunctionOnNextCall(p.dirname)');
p.dirname(input);

bench.start();
for (var i = 0; i < n; i++) {
p.dirname(input);
Expand Down
7 changes: 0 additions & 7 deletions benchmark/path/dirname-win32.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
'use strict';
var common = require('../common.js');
var path = require('path');
var v8 = require('v8');

var bench = common.createBenchmark(main, {
path: [
Expand All @@ -21,12 +20,6 @@ function main(conf) {
var p = path.win32;
var input = '' + conf.path;

// Force optimization before starting the benchmark
p.dirname(input);
v8.setFlagsFromString('--allow_natives_syntax');
eval('%OptimizeFunctionOnNextCall(p.dirname)');
p.dirname(input);

bench.start();
for (var i = 0; i < n; i++) {
p.dirname(input);
Expand Down
7 changes: 0 additions & 7 deletions benchmark/path/extname-posix.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
'use strict';
var common = require('../common.js');
var path = require('path');
var v8 = require('v8');

var bench = common.createBenchmark(main, {
path: [
Expand All @@ -24,12 +23,6 @@ function main(conf) {
var p = path.posix;
var input = '' + conf.path;

// Force optimization before starting the benchmark
p.extname(input);
v8.setFlagsFromString('--allow_natives_syntax');
eval('%OptimizeFunctionOnNextCall(p.extname)');
p.extname(input);

bench.start();
for (var i = 0; i < n; i++) {
p.extname(input);
Expand Down
Loading