Skip to content
This repository has been archived by the owner on Oct 15, 2020. It is now read-only.

Commit

Permalink
Merge remote-tracking branch 'upstream/v10.x' into v10.x
Browse files Browse the repository at this point in the history
  • Loading branch information
kfarnung committed Apr 23, 2018
2 parents d81f175 + 4c6a47f commit 88689b5
Show file tree
Hide file tree
Showing 75 changed files with 730 additions and 399 deletions.
1 change: 0 additions & 1 deletion .eslintignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ test/addons/??_*
test/es-module/test-esm-dynamic-import.js
test/fixtures
test/message/esm_display_syntax_error.mjs
tools/node_modules
tools/icu
tools/remark-*
node_modules
Expand Down
13 changes: 8 additions & 5 deletions COLLABORATOR_GUIDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -199,11 +199,14 @@ status indicator.

Do not land any Pull Requests without passing (green or yellow) CI runs. If you
believe any failed (red or grey) CI sub-tasks are unrelated to the change in the
Pull Request, you may re-run the sub-task to try to see if it passes. If re-runs
of all failed sub-tasks pass, it is permissible to land the Pull Request but
only if the initial failures are believed in good faith to be unrelated to the
changes in the Pull Request. Otherwise, reasonable steps must be taken to
confirm that the changes are not resulting in an unreliable test.
Pull Request, you may re-run the sub-task to try to see if it passes (just open
the failed sub-task page and press the "Rebuild" button; be sure you are still
logged in for this action). If re-runs of all failed sub-tasks pass (do not
forget to provide the links for successfully rerun sub-tasks), it is permissible
to land the Pull Request but only if the initial failures are believed in good
faith to be unrelated to the changes in the Pull Request. Otherwise, reasonable
steps must be taken to confirm that the changes are not resulting in an
unreliable test.

#### Useful CI Jobs

Expand Down
44 changes: 23 additions & 21 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ PWD = $(CURDIR)

ifdef JOBS
PARALLEL_ARGS = -j $(JOBS)
else
PARALLEL_ARGS = -J
endif

ifdef ENABLE_V8_TAP
Expand Down Expand Up @@ -232,7 +234,7 @@ v8:

.PHONY: jstest
jstest: build-addons build-addons-napi ## Runs addon tests and JS tests
$(PYTHON) tools/test.py --mode=release --flaky-tests=$(FLAKY_TESTS) -J \
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release --flaky-tests=$(FLAKY_TESTS) \
$(CI_JS_SUITES) \
$(CI_NATIVE_SUITES)

Expand Down Expand Up @@ -267,13 +269,13 @@ test-cov: all
$(MAKE) lint

test-parallel: all
$(PYTHON) tools/test.py --mode=release parallel -J
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release parallel

test-valgrind: all
$(PYTHON) tools/test.py --mode=release --valgrind sequential parallel message
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release --valgrind sequential parallel message

test-check-deopts: all
$(PYTHON) tools/test.py --mode=release --check-deopts parallel sequential -J
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release --check-deopts parallel sequential

benchmark/misc/function_call/build/Release/binding.node: all \
benchmark/misc/function_call/binding.cc \
Expand Down Expand Up @@ -396,7 +398,7 @@ clear-stalled:

.PHONY: test-gc
test-gc: all test/gc/build/Release/binding.node
$(PYTHON) tools/test.py --mode=release gc
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release gc

.PHONY: test-gc-clean
test-gc-clean:
Expand All @@ -408,10 +410,10 @@ test-build-addons-napi: all build-addons-napi

.PHONY: test-all
test-all: test-build test/gc/build/Release/binding.node ## Run everything in test/.
$(PYTHON) tools/test.py --mode=debug,release
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=debug,release

test-all-valgrind: test-build
$(PYTHON) tools/test.py --mode=debug,release --valgrind
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=debug,release --valgrind

CI_NATIVE_SUITES ?= addons addons-napi
CI_JS_SUITES ?= default
Expand Down Expand Up @@ -473,29 +475,29 @@ run-ci: build-ci
$(MAKE) test-ci

test-release: test-build
$(PYTHON) tools/test.py --mode=release
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release

test-debug: test-build
$(PYTHON) tools/test.py --mode=debug
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=debug

test-message: test-build
$(PYTHON) tools/test.py message
$(PYTHON) tools/test.py $(PARALLEL_ARGS) message

test-simple: | cctest # Depends on 'all'.
$(PYTHON) tools/test.py parallel sequential
$(PYTHON) tools/test.py $(PARALLEL_ARGS) parallel sequential

test-pummel: all
$(PYTHON) tools/test.py pummel
$(PYTHON) tools/test.py $(PARALLEL_ARGS) pummel

test-internet: all
$(PYTHON) tools/test.py internet
$(PYTHON) tools/test.py $(PARALLEL_ARGS) internet

test-node-inspect: $(NODE_EXE)
USE_EMBEDDED_NODE_INSPECT=1 $(NODE) tools/test-npm-package \
--install deps/node-inspect test

test-tick-processor: all
$(PYTHON) tools/test.py tick-processor
$(PYTHON) tools/test.py $(PARALLEL_ARGS) tick-processor

.PHONY: test-hash-seed
# Verifies the hash seed used by V8 for hashing is random.
Expand All @@ -505,10 +507,10 @@ test-hash-seed: all
.PHONY: test-doc
test-doc: doc-only ## Builds, lints, and verifies the docs.
$(MAKE) lint
$(PYTHON) tools/test.py $(CI_DOC)
$(PYTHON) tools/test.py $(PARALLEL_ARGS) $(CI_DOC)

test-known-issues: all
$(PYTHON) tools/test.py known_issues
$(PYTHON) tools/test.py $(PARALLEL_ARGS) known_issues

# Related CI job: node-test-npm
test-npm: $(NODE_EXE) ## Run the npm test suite on deps/npm.
Expand All @@ -519,7 +521,7 @@ test-npm-publish: $(NODE_EXE)

.PHONY: test-addons-napi
test-addons-napi: test-build-addons-napi
$(PYTHON) tools/test.py --mode=release addons-napi
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release addons-napi

.PHONY: test-addons-napi-clean
test-addons-napi-clean:
Expand All @@ -528,7 +530,7 @@ test-addons-napi-clean:

.PHONY: test-addons
test-addons: test-build test-addons-napi
$(PYTHON) tools/test.py --mode=release addons
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release addons

.PHONY: test-addons-clean
test-addons-clean:
Expand All @@ -539,19 +541,19 @@ test-addons-clean:

test-timers:
$(MAKE) --directory=tools faketime
$(PYTHON) tools/test.py --mode=release timers
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release timers

test-timers-clean:
$(MAKE) --directory=tools clean

test-async-hooks:
$(PYTHON) tools/test.py --mode=release async-hooks
$(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release async-hooks

test-with-async-hooks:
$(MAKE) build-addons
$(MAKE) build-addons-napi
$(MAKE) cctest
NODE_TEST_WITH_ASYNC_HOOKS=1 $(PYTHON) tools/test.py --mode=release -J \
NODE_TEST_WITH_ASYNC_HOOKS=1 $(PYTHON) tools/test.py $(PARALLEL_ARGS) --mode=release \
$(CI_JS_SUITES) \
$(CI_NATIVE_SUITES)

Expand Down
4 changes: 2 additions & 2 deletions benchmark/arrays/var-int.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ const bench = common.createBenchmark(main, {
'Float32Array',
'Float64Array'
],
n: [25]
n: [25e6]
});

function main({ type, n }) {
const clazz = global[type];

bench.start();
const arr = new clazz(n * 1e6);
const arr = new clazz(n);
for (var i = 0; i < 10; ++i) {
run();
}
Expand Down
4 changes: 2 additions & 2 deletions benchmark/arrays/zero-float.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ const bench = common.createBenchmark(main, {
'Float32Array',
'Float64Array'
],
n: [25]
n: [25e6]
});

function main({ type, n }) {
const clazz = global[type];

bench.start();
const arr = new clazz(n * 1e6);
const arr = new clazz(n);
for (var i = 0; i < 10; ++i) {
run();
}
Expand Down
4 changes: 2 additions & 2 deletions benchmark/arrays/zero-int.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ const bench = common.createBenchmark(main, {
'Float32Array',
'Float64Array'
],
n: [25]
n: [25e6]
});

function main({ type, n }) {
const clazz = global[type];

bench.start();
const arr = new clazz(n * 1e6);
const arr = new clazz(n);
for (var i = 0; i < 10; ++i) {
run();
}
Expand Down
6 changes: 3 additions & 3 deletions benchmark/buffers/buffer-base64-decode-wrapped.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@
const common = require('../common.js');

const bench = common.createBenchmark(main, {
charsPerLine: [76],
linesCount: [8 << 16],
n: [32],
});

function main({ n }) {
const charsPerLine = 76;
const linesCount = 8 << 16;
function main({ charsPerLine, linesCount, n }) {
const bytesCount = charsPerLine * linesCount / 4 * 3;

const line = `${'abcd'.repeat(charsPerLine / 4)}\n`;
Expand Down
5 changes: 3 additions & 2 deletions benchmark/buffers/buffer-base64-decode.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,11 @@ const common = require('../common.js');

const bench = common.createBenchmark(main, {
n: [32],
size: [8 << 20]
});

function main({ n }) {
const s = 'abcd'.repeat(8 << 20);
function main({ n, size }) {
const s = 'abcd'.repeat(size);
// eslint-disable-next-line node-core/no-unescaped-regexp-dot
s.match(/./); // Flatten string.
assert.strictEqual(s.length % 4, 0);
Expand Down
8 changes: 4 additions & 4 deletions benchmark/buffers/buffer-indexof.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,10 @@ const bench = common.createBenchmark(main, {
search: searchStrings,
encoding: ['undefined', 'utf8', 'ucs2', 'binary'],
type: ['buffer', 'string'],
iter: [100000]
n: [100000]
});

function main({ iter, search, encoding, type }) {
function main({ n, search, encoding, type }) {
var aliceBuffer = fs.readFileSync(
path.resolve(__dirname, '../fixtures/alice.html')
);
Expand All @@ -46,8 +46,8 @@ function main({ iter, search, encoding, type }) {
}

bench.start();
for (var i = 0; i < iter; i++) {
for (var i = 0; i < n; i++) {
aliceBuffer.indexOf(search, 0, encoding);
}
bench.end(iter);
bench.end(n);
}
4 changes: 2 additions & 2 deletions benchmark/http/cluster.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ function main({ type, len, c }) {
if (workers < 2)
return;

setTimeout(function() {
setImmediate(function() {
const path = `/${type}/${len}`;

bench.http({
Expand All @@ -36,6 +36,6 @@ function main({ type, len, c }) {
w1.destroy();
w2.destroy();
});
}, 100);
});
});
}
5 changes: 5 additions & 0 deletions deps/uv/AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -332,3 +332,8 @@ Ryuichi KAWAMATA <ryuichi.kawamata@dena.jp>
Joyee Cheung <joyeec9h3@gmail.com>
Michael Kilburn <crusader.mike@gmail.com>
Ruslan Bekenev <furyinbox@gmail.com>
Bob Burger <rgburger@beckman.com>
Thomas Versteeg <thomasversteeg@gmx.com>
zzzjim <zzzjim@users.noreply.github.com>
Alex Arslan <ararslan@comcast.net>
Kyle Farnung <kfarnung@microsoft.com>
36 changes: 36 additions & 0 deletions deps/uv/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,39 @@
2018.04.23, Version 1.20.2 (Stable), c51fd3f66bbb386a1efdeba6812789f35a372d1e

Changes since version 1.20.1:

* zos: use custom semaphore (jBarz)

* win: fix registry API error handling (Kyle Farnung)

* build: add support for 64-bit AIX (Richard Lau)

* aix: guard STATIC_ASSERT for glibc work around (Richard Lau)


2018.04.19, Version 1.20.1 (Stable), 36ac2fc8edfd5ff3e9be529be1d4a3f0d5364e94

Changes since version 1.20.0:

* doc,fs: improve documentation (Bob Burger)

* win: return a floored double from uv_uptime() (Refael Ackermann)

* doc: clarify platform specific pipe naming (Thomas Versteeg)

* unix: fix uv_pipe_chmod() on macOS (zzzjim)

* unix: work around glibc semaphore race condition (Anna Henningsen)

* tcp,openbsd: disable Unix TCP check for IPV6_ONLY (Alex Arslan)

* test,openbsd: use RETURN_SKIP in UDP IPv6 tests (Alex Arslan)

* test,openbsd: fix multicast test (Alex Arslan)

* Revert "win, fs: use FILE_WRITE_ATTRIBUTES when opening files" (cjihrig)


2018.04.03, Version 1.20.0 (Stable), 0012178ee2b04d9e4a2c66c27cf8891ad8325ceb

Changes since version 1.19.2:
Expand Down
6 changes: 5 additions & 1 deletion deps/uv/common.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@
}]
]
}],
['OS in "freebsd dragonflybsd linux openbsd solaris android"', {
['OS in "freebsd dragonflybsd linux openbsd solaris android aix"', {
'cflags': [ '-Wall' ],
'cflags_cc': [ '-fno-rtti', '-fno-exceptions' ],
'target_conditions': [
Expand Down Expand Up @@ -162,6 +162,10 @@
'cflags': [ '-pthread' ],
'ldflags': [ '-pthread' ],
}],
[ 'OS=="aix" and target_arch=="ppc64"', {
'cflags': [ '-maix64' ],
'ldflags': [ '-maix64' ],
}],
],
}],
['OS=="mac"', {
Expand Down
2 changes: 1 addition & 1 deletion deps/uv/configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

AC_PREREQ(2.57)
AC_INIT([libuv], [1.20.0], [https://github.com/libuv/libuv/issues])
AC_INIT([libuv], [1.20.2], [https://github.com/libuv/libuv/issues])
AC_CONFIG_MACRO_DIR([m4])
m4_include([m4/libuv-extra-automake-flags.m4])
m4_include([m4/as_case.m4])
Expand Down
6 changes: 4 additions & 2 deletions deps/uv/docs/src/fs.rst
Original file line number Diff line number Diff line change
Expand Up @@ -148,8 +148,8 @@ Public members

.. c:member:: void* uv_fs_t.ptr
Stores the result of :c:func:`uv_fs_readlink` and serves as an alias to
`statbuf`.
Stores the result of :c:func:`uv_fs_readlink` and
:c:func:`uv_fs_realpath` and serves as an alias to `statbuf`.

.. seealso:: The :c:type:`uv_req_t` members also apply.

Expand Down Expand Up @@ -311,10 +311,12 @@ API
.. c:function:: int uv_fs_readlink(uv_loop_t* loop, uv_fs_t* req, const char* path, uv_fs_cb cb)
Equivalent to :man:`readlink(2)`.
The resulting string is stored in `req->ptr`.
.. c:function:: int uv_fs_realpath(uv_loop_t* loop, uv_fs_t* req, const char* path, uv_fs_cb cb)
Equivalent to :man:`realpath(3)` on Unix. Windows uses `GetFinalPathNameByHandle <https://msdn.microsoft.com/en-us/library/windows/desktop/aa364962(v=vs.85).aspx>`_.
The resulting string is stored in `req->ptr`.
.. warning::
This function has certain platform-specific caveats that were discovered when used in Node.
Expand Down
Loading

0 comments on commit 88689b5

Please sign in to comment.