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

[v10.x backport] backport d48bd16 from v8 master #22909

Closed
wants to merge 44 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
1c3f81d
win,msi: install tools for native modules
joaocgreis Aug 29, 2018
05ace78
doc: `node debug` → `node inspect` in CLI docs
addaleax Sep 9, 2018
94e67b6
tools: fix doc tool behavior for version arrays
tniessen Sep 8, 2018
779e072
fs: implement mkdir recursive (mkdirp)
Aug 9, 2018
b1be08f
test: add comment describing test-fs-mkdir
Aug 21, 2018
75c288e
url: provide pathToFileURL and fileURLToPath
guybedford Aug 24, 2018
42e6ce2
test: check parameter type of fs.mkdir()
Aug 30, 2018
cf61a04
test: refactor structure of common/index
jasnell Aug 24, 2018
108a169
assert: align argument names
BridgeAR Sep 8, 2018
09ae073
doc: add history for withFileTypes in fs.readdir[Sync]()
tiendq Sep 10, 2018
8b6a161
crypto: fix public key encryption internals
tniessen Sep 9, 2018
b87ab0f
crypto: rename symbols to match guidelines
tniessen Sep 5, 2018
b9fd99e
doc: add gabrielschulhof to TSC
Trott Sep 12, 2018
8153c10
n-api: add generic finalizer callback
Aug 10, 2018
2b3b205
test: checks on napi factory wrap’s finalization
legendecas Aug 31, 2018
f41911f
lib: remove unnecessary symbols
Aug 22, 2018
01a5c7d
test: minor refactor in common/index.js
jasnell Sep 6, 2018
353cb4e
doc: document http2 timeouts
sagitsofan Sep 10, 2018
a214769
doc: add reference to guide for N-API additions
mhdawson Aug 29, 2018
e85c814
deps: cherry-pick 2363cdf from upstream V8
ofrobots Sep 11, 2018
92b695e
trace_events: avoid flusing uninitialized traces
ofrobots Sep 12, 2018
4159000
fs: ensure readdir() callback is only called once
cjihrig Sep 10, 2018
d853a3f
lib: simplify 'processChunkSync'
Sep 11, 2018
535c30c
module: add createRequireFunction method
devsnek Mar 14, 2018
ec6afb9
worker: correct (de)initialization order
addaleax Sep 9, 2018
c9f2283
tools: implement update-authors in JS
addaleax Sep 9, 2018
c898071
doc: update AUTHORS list
addaleax Sep 9, 2018
878d616
src: move getActiveResources/Handles to node_process.cc
jasnell Sep 7, 2018
27b0cb5
src: move DebugPortGetter/Setter to node_process.cc
jasnell Sep 7, 2018
4ba80b1
doc: fix typo in dns docs
MohammedEssehemy Sep 14, 2018
da86003
doc: add withFileTypes option to fsPromises.readdir
bengl Sep 13, 2018
1e07002
process: generate list of allowed env flags programmatically
addaleax Aug 31, 2018
a793163
lib: generate allowedNodeEnvironmentFlags lazily
addaleax Aug 31, 2018
81fd5d2
doc: add full deprecation history
tniessen Sep 8, 2018
479e1ec
fs: fix promisified fs.readdir withFileTypes
apapirovski Sep 13, 2018
f2ae0cb
src: fix `--prof-process` CLI argument handling
addaleax Sep 10, 2018
9441282
tracing: remove shutdown-on-signal
addaleax Sep 6, 2018
14c491c
path: remove unnecessary if statement
wchargin Aug 11, 2018
7c5e0d8
tools: update ESLint to 5.6.0
Trott Sep 16, 2018
3b763cd
src: move no_async_hooks_checks to env
danbev Sep 10, 2018
182ec37
[v10.x backport] backport d48bd16 from v8 master
Sep 17, 2018
9164ccf
update patch level
Sep 17, 2018
d0166ea
Revert "update patch level"
Sep 17, 2018
ce43fb1
update embedder string
Sep 17, 2018
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
7 changes: 6 additions & 1 deletion .mailmap
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ Gabriel de Perthuis <[email protected]>
Gareth Ellis <[email protected]> <[email protected]>
Garwah Lam <[email protected]>
Geoffrey Bugaisky <[email protected]> gbugaisky <[email protected]>
Gerhard Stoebich <[email protected]>
Gibson Fahnestock <[email protected]> <[email protected]>
Gil Pedersen <[email protected]> <[email protected]>
Graham Fairweather <[email protected]> Xotic750 <xotic750@gmail>
Expand Down Expand Up @@ -204,6 +205,7 @@ Jérémy Lal <[email protected]> <[email protected]>
Juan Sebastian Velez Posada <[email protected]>
Kai Sasaki Lewuathe <[email protected]>
Karl Skomski <[email protected]> <[email protected]>
Kat Marchán <[email protected]> <[email protected]>
Kathy Truong <[email protected]> k3kathy <[email protected]>
Kazuyuki Yamada <[email protected]>
Keith M Wesolowski <[email protected]> <[email protected]>
Expand Down Expand Up @@ -238,6 +240,7 @@ Matheus Marchini <[email protected]> <[email protected]>
Matheus Marchini <[email protected]> <[email protected]>
Matt Lang <[email protected]> matt-in-a-hat <[email protected]>
Matt Reed <[email protected]> matthewreed26 <[email protected]>
Matteo Collina <[email protected]> <[email protected]>
Matthias Bastian <[email protected]> piepmatz <[email protected]>
Mathias Buus <[email protected]> <[email protected]>
Mathias Pettersson <[email protected]>
Expand Down Expand Up @@ -364,6 +367,7 @@ Tadashi SAWADA <[email protected]>
Takahiro ANDO <[email protected]>
Tarun Batra <[email protected]> Tarun <[email protected]>
Ted Young <[email protected]>
Teppei Sato <[email protected]>
Thomas Hunter II <[email protected]> <[email protected]>
Thomas Lee <[email protected]> <[email protected]>
Thomas Reggi <[email protected]>
Expand Down Expand Up @@ -391,7 +395,8 @@ Vladimir de Turckheim <[email protected]>
vsemozhetbyt <[email protected]> Vse Mozhet Byt <[email protected]>
Wang Xinyong <[email protected]> <[email protected]>
Weijia Wang <[email protected]>
Weijia Wang <[email protected]> starkewang <[email protected]>
Weijia Wang <[email protected]> <[email protected]>
Weijia Wang <[email protected]> <[email protected]>
Wei-Wei Wu <[email protected]>
Willi Eggeling <[email protected]>
Will Hayslett <[email protected]>
Expand Down
107 changes: 94 additions & 13 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -650,7 +650,7 @@ Micleusanu Nicu <[email protected]>
Alejandro Oviedo Garcia <[email protected]>
Ben Burns <[email protected]>
Julian Duque <[email protected]>
teppeis <[email protected]>
Teppei Sato <[email protected]>
Rudi Cilibrasi <[email protected]>
Tim Ruffles <[email protected]>
CGavrila <[email protected]>
Expand Down Expand Up @@ -754,14 +754,14 @@ Felipe Batista <[email protected]>
Rebecca Turner <[email protected]>
Tyler Anton <[email protected]>
João Reis <[email protected]>
Kat Marchán <kzm@sykosomatic.org>
Kat Marchán <kzm@zkat.tech>
Ryan Petschek <[email protected]>
Pierre Inglebert <[email protected]>
Ivan Yan <[email protected]>
Sangmin Yoon <[email protected]>
Mark Plomer <[email protected]>
Phillip Johnsen <[email protected]>
Matteo Collina <hello@matteocollina.com>
Matteo Collina <matteo.collina@gmail.com>
jomo <[email protected]>
Gireesh Punathil <[email protected]>
Lucien Greathouse <[email protected]>
Expand Down Expand Up @@ -1432,23 +1432,25 @@ Ahmad Nassri <[email protected]>
Tom Atkinson <[email protected]>
Tobias Nießen <[email protected]>
Joseph Gentle <[email protected]>
Arunesh Chandra <[email protected]>
Gabriel Schulhof <[email protected]>
Ian Halliday <[email protected]>
Sampson Gao <[email protected]>
Taylor Woll <[email protected]>
Zero King <[email protected]>
Raphael Okon <[email protected]>
JR McEntee <[email protected]>
Lovell Fuller <[email protected]>
Jason Marsh <[email protected]>
Vinay Hiremath <[email protected]>
Gabriel Schulhof <[email protected]>
alejandro <[email protected]>
dave-k <[email protected]>
Steven <[email protected]>
Uppinder Chugh <[email protected]>
Karl Cheng <[email protected]>
Taylor Woll <[email protected]>
Tarun Batra <[email protected]>
Nao YONASHIRO <[email protected]>
Christopher Luke <[email protected]>
Sampson Gao <[email protected]>
John Paul Bamberg <[email protected]>
Cody Deckard <[email protected]>
Fabio Campinho <[email protected]>
Expand Down Expand Up @@ -1488,7 +1490,7 @@ Madara Uchiha <[email protected]>
Gil Tayar <[email protected]>
Glenn Schlereth <[email protected]>
Artur G Vieira <[email protected]>
Flarna <[email protected]>
Gerhard Stoebich <[email protected]>
Sreepurna Jasti <[email protected]>
Rafael Fragoso <[email protected]>
Andrei Cioromila <[email protected]>
Expand Down Expand Up @@ -1658,6 +1660,8 @@ Piotr Mionskowski <[email protected]>
Cyril Lakech <[email protected]>
Eduard Bondarenko <[email protected]>
Adina Shanholtz <[email protected]>
Guy Bedford <[email protected]>
Jan Krems <[email protected]>
Miguel Martins <[email protected]>
Yury Popov <[email protected]>
George Bezerra <[email protected]>
Expand All @@ -1670,7 +1674,6 @@ Alex Gresnel <[email protected]>
Will Young <[email protected]>
Martijn Schrage <[email protected]>
Halil İbrahim Şener <[email protected]>
Guy Bedford <[email protected]>
Antoine Amara <[email protected]>
Mani Maghsoudlou <[email protected]>
Bartek Szczepański <[email protected]>
Expand Down Expand Up @@ -1884,7 +1887,6 @@ Ashish Kaila <[email protected]>
c0b <[email protected]>
Damian <[email protected]>
Alec Perkins <[email protected]>
Teppei Sato <[email protected]>
Jinwoo Lee <[email protected]>
Peter Marton <[email protected]>
Erwin W. Ramadhan <[email protected]>
Expand Down Expand Up @@ -2154,9 +2156,7 @@ Nick Filatov <[email protected]>
Jesse Gorzinski <[email protected]>
Pieter Mees <[email protected]>
Malcolm White <[email protected]>
Gerhard Stoebich <[email protected]>
Matei Copot <[email protected]>
ikasumiwt <[email protected]>
Gurin, Sebastian <[email protected]>
Indranil Dasgupta <[email protected]>
Harry Sarson <[email protected]>
Expand Down Expand Up @@ -2187,7 +2187,6 @@ Kyle Martin <[email protected]>
Denis Fäcke <[email protected]>
Daylor Yanes <[email protected]>
Carrie Coxwell <[email protected]>
BeniCheni <[email protected]>
Masashi Hirano <[email protected]>
Brandon Ruggles <[email protected]>
Allen Yonghuang Wang <[email protected]>
Expand Down Expand Up @@ -2218,6 +2217,7 @@ Abhimanyu Vashisht <[email protected]>
Sagir Khan <[email protected]>
Kael Zhang <[email protected]>
Unknown <[email protected]>
Krzysztof Taborski <[email protected]>
Blaine Bublitz <[email protected]>
Shailesh Shekhawat <[email protected]>
Davis Okoth <[email protected]>
Expand All @@ -2236,5 +2236,86 @@ Shelley Vohr <[email protected]>
Deepjyoti Mondal <[email protected]>
Brett Kiefer <[email protected]>
Kevin Thomas <[email protected]>
ZaneHannanAU <[email protected]>
Fernando Doglio <[email protected]>
Renée Kooi <[email protected]>
Jo Colina <[email protected]>
itaysabato <[email protected]>
Victor Belozyorov <[email protected]>
Joonas Rouhiainen <[email protected]>
GauthamBanasandra <[email protected]>
Hugo Josefson <[email protected]>
Sam Ruby <[email protected]>
Haroon Khan <[email protected]>
Developer Davo <[email protected]>
Jacek Pospychała <[email protected]>
MaleDong <[email protected]>
iwko <[email protected]>
Sohail Rajdev <[email protected]>
Niicck <[email protected]>
Denys Otrishko <[email protected]>
Sergey Zelenov <[email protected]>
Travis Fischer <[email protected]>
Dominic Farolino <[email protected]>
Octavian Soldea <[email protected]>
XhmikosR <[email protected]>
AdityaSrivast <[email protected]>
Javier Gonzalez <[email protected]>
RidgeA <[email protected]>
Ryuichi Sakagami <[email protected]>
hectorcoronado <[email protected]>
Petras <[email protected]>
Kevin Lacabane <[email protected]>
Simionescu, Radu <[email protected]>
mariotsi <[email protected]>
prayag21 <[email protected]>
Bruno Pinho <[email protected]>
Anto Aravinth <[email protected]>
Helio Frota <[email protected]>
Tim Ruffles <[email protected]>
Jacob Page <[email protected]>
sagulati <[email protected]>
conectado <[email protected]>
Vitor Bruno de Oliveira Barth <[email protected]>
cclauss <[email protected]>
James Ide <[email protected]>
MaleDong <[email protected]>
bhavayAnand9 <[email protected]>
Brandon Lee <[email protected]>
Oryan Moshe <[email protected]>
Michael Sommer <[email protected]>
Eugene Y. Q. Shen <[email protected]>
Rishabh Singh <[email protected]>
Marco Levrero <[email protected]>
Ouyang Yadong <[email protected]>
yahavfuchs <[email protected]>
Thomas Leah <[email protected]>
Musa Hamwala <[email protected]>
James Bromwell <[email protected]>
Jeremy Apthorp <[email protected]>
Eugen Cazacu <[email protected]>
James Bromwell <[email protected]>
Csaba Palfi <[email protected]>
Ryan Petrich <[email protected]>
Andreas Girgensohn <[email protected]>
Caleb Sander <[email protected]>
Dzmitry_Prudnikau <[email protected]>
Ian McKellar <[email protected]>
Jennifer Bland <[email protected]>
Kyle Fuller <[email protected]>
ZYSzys <[email protected]>
Neeraj Laad <[email protected]>
Scott Van Gilder <[email protected]>
Yaniv Friedensohn <[email protected]>
Lars-Magnus Skog <[email protected]>
Lucas Woo <[email protected]>
Troels Liebe Bentsen <[email protected]>
pranshuchittora <[email protected]>
lakamsani <[email protected]>
Chris White <[email protected]>
Ben Newman <[email protected]>
Szymon Marczak <[email protected]>
Tessei Kameyama <[email protected]>
Chakravarthy S M <[email protected]>

# Generated by tools/update-authors.sh
# Generated by tools/update-authors.js
13 changes: 13 additions & 0 deletions COLLABORATOR_GUIDE.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
- [When Breaking Changes Actually Break Things](#when-breaking-changes-actually-break-things)
- [Reverting commits](#reverting-commits)
- [Introducing New Modules](#introducing-new-modules)
- [Additions to N-API](#additions-to-n-api)
- [Deprecations](#deprecations)
- [Involving the TSC](#involving-the-tsc)
* [Landing Pull Requests](#landing-pull-requests)
Expand Down Expand Up @@ -411,6 +412,18 @@ For new modules that involve significant effort, non-trivial additions to
Node.js or significant new capabilities, an [Enhancement Proposal][] is
recommended but not required.

### Additions to N-API

N-API provides an ABI stable API that we will have to support in future
versions without the usual option to modify or remove existing APIs on
SemVer boundaries. Therefore, additions need to be managed carefully.

This
[guide](https://github.com/nodejs/node/blob/master/doc/guides/adding-new-napi-api.md)
outlines the requirements and principles that we should follow when
approving and landing new N-API APIs (any additions to `node_api.h` and
`node_api_types.h`).

### Deprecations

[_Deprecation_][] is "the discouragement of use of some … feature … or practice,
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -249,6 +249,8 @@ For more information about the governance of the Node.js project, see
**Franziska Hinkelmann** &lt;[email protected]&gt; (she/her)
* [Fishrock123](https://github.com/Fishrock123) -
**Jeremiah Senkpiel** &lt;[email protected]&gt;
* [gabrielschulhof](https://github.com/gabrielschulhof) -
**Gabriel Schulhof** &lt;[email protected]&gt;
* [gibfahn](https://github.com/gibfahn) -
**Gibson Fahnestock** &lt;[email protected]&gt; (he/him)
* [jasnell](https://github.com/jasnell) -
Expand Down
23 changes: 23 additions & 0 deletions benchmark/fs/bench-mkdirp.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
'use strict';

const common = require('../common');
const fs = require('fs');
const tmpdir = require('../../test/common/tmpdir');
tmpdir.refresh();
let dirc = 0;

const bench = common.createBenchmark(main, {
n: [1e4],
});

function main({ n }) {
bench.start();
(function r(cntr) {
if (cntr-- <= 0)
return bench.end(n);
const pathname = `${tmpdir.path}/${++dirc}/${++dirc}/${++dirc}/${++dirc}`;
fs.mkdir(pathname, { createParents: true }, (err) => {
r(cntr);
});
}(n));
}
2 changes: 1 addition & 1 deletion common.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

# Reset this number to 0 on major V8 upgrades.
# Increment by one for each non-official patch applied to deps/v8.
'v8_embedder_string': '-node.25',
'v8_embedder_string': '-node.27',

# Enable disassembler for `--print-code` v8 options
'v8_enable_disassembler': 1,
Expand Down
6 changes: 3 additions & 3 deletions deps/v8/src/base/platform/platform-posix.cc
Original file line number Diff line number Diff line change
Expand Up @@ -246,11 +246,11 @@ void* OS::GetRandomMmapAddr() {
// Use extra address space to isolate the mmap regions.
raw_addr += uint64_t{0x400000000000};
#elif V8_TARGET_BIG_ENDIAN
// Big-endian Linux: 44 bits of virtual addressing.
// Big-endian Linux: 42 bits of virtual addressing.
raw_addr &= uint64_t{0x03FFFFFFF000};
#else
// Little-endian Linux: 48 bits of virtual addressing.
raw_addr &= uint64_t{0x3FFFFFFFF000};
// Little-endian Linux: 46 bits of virtual addressing.
raw_addr &= uint64_t{0x3FFFFFFF0000};
#endif
#elif V8_TARGET_ARCH_MIPS64
// We allocate code in 256 MB aligned segments because of optimizations using
Expand Down
32 changes: 18 additions & 14 deletions deps/v8/src/libplatform/tracing/tracing-controller.cc
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,15 @@ uint64_t TracingController::AddTraceEvent(
const uint64_t* arg_values,
std::unique_ptr<v8::ConvertableToTraceFormat>* arg_convertables,
unsigned int flags) {
uint64_t handle;
TraceObject* trace_object = trace_buffer_->AddTraceEvent(&handle);
if (trace_object) {
trace_object->Initialize(
phase, category_enabled_flag, name, scope, id, bind_id, num_args,
arg_names, arg_types, arg_values, arg_convertables, flags,
CurrentTimestampMicroseconds(), CurrentCpuTimestampMicroseconds());
uint64_t handle = 0;
if (mode_ != DISABLED) {
TraceObject* trace_object = trace_buffer_->AddTraceEvent(&handle);
if (trace_object) {
trace_object->Initialize(
phase, category_enabled_flag, name, scope, id, bind_id, num_args,
arg_names, arg_types, arg_values, arg_convertables, flags,
CurrentTimestampMicroseconds(), CurrentCpuTimestampMicroseconds());
}
}
return handle;
}
Expand All @@ -81,13 +83,15 @@ uint64_t TracingController::AddTraceEventWithTimestamp(
const uint64_t* arg_values,
std::unique_ptr<v8::ConvertableToTraceFormat>* arg_convertables,
unsigned int flags, int64_t timestamp) {
uint64_t handle;
TraceObject* trace_object = trace_buffer_->AddTraceEvent(&handle);
if (trace_object) {
trace_object->Initialize(phase, category_enabled_flag, name, scope, id,
bind_id, num_args, arg_names, arg_types,
arg_values, arg_convertables, flags, timestamp,
CurrentCpuTimestampMicroseconds());
uint64_t handle = 0;
if (mode_ != DISABLED) {
TraceObject* trace_object = trace_buffer_->AddTraceEvent(&handle);
if (trace_object) {
trace_object->Initialize(phase, category_enabled_flag, name, scope, id,
bind_id, num_args, arg_names, arg_types,
arg_values, arg_convertables, flags, timestamp,
CurrentCpuTimestampMicroseconds());
}
}
return handle;
}
Expand Down
4 changes: 2 additions & 2 deletions doc/api/cli.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ To view this documentation as a manual page in a terminal, run `man node`.

`node [options] [V8 options] [script.js | -e "script" | -] [--] [arguments]`

`node debug [script.js | -e "script" | <host>:<port>] …`
`node inspect [script.js | -e "script" | <host>:<port>] …`

`node --v8-options`

Execute without arguments to start the [REPL][].

_For more info about `node debug`, please see the [debugger][] documentation._
_For more info about `node inspect`, please see the [debugger][] documentation._

## Options

Expand Down
Loading