Skip to content

Commit ed0c00b

Browse files
authored
Merge branch 'master' into read-error-destroy
2 parents 99ee5ed + de85b1e commit ed0c00b

Some content is hidden

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

54 files changed

+897
-526
lines changed

.github/CODEOWNERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
# tls/crypto
5555

5656
/lib/internal/crypto/* @nodejs/crypto
57-
/lib/internal/tls.js @nodejs/crypto @nodejs/net
57+
/lib/internal/tls/* @nodejs/crypto @nodejs/net
5858
/lib/crypto.js @nodejs/crypto
5959
/lib/tls.js @nodejs/crypto @nodejs/net
6060
/src/node_crypto* @nodejs/crypto
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Find inactive collaborators
2+
3+
on:
4+
schedule:
5+
# Run on the 15th day of the month at 4:05 AM UTC.
6+
- cron: '5 4 15 * *'
7+
8+
workflow_dispatch:
9+
10+
jobs:
11+
find:
12+
13+
runs-on: ubuntu-latest
14+
15+
steps:
16+
- uses: actions/checkout@v2
17+
- run: tools/find-inactive-collaborators.mjs '1 year ago'

Makefile

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ check: test
204204
# in place
205205
coverage-clean:
206206
$(RM) -r node_modules
207-
$(RM) -r gcovr build
207+
$(RM) -r gcovr
208208
$(RM) -r coverage/tmp
209209
$(FIND) out/$(BUILDTYPE)/obj.target \( -name "*.gcda" -o -name "*.gcno" \) \
210210
-type f -exec $(RM) {} \;
@@ -220,13 +220,7 @@ coverage: coverage-test ## Run the tests and generate a coverage report.
220220
.PHONY: coverage-build
221221
coverage-build: all
222222
-$(MAKE) coverage-build-js
223-
if [ ! -d gcovr ]; then git clone -b 3.4 --depth=1 \
224-
--single-branch https://github.com/gcovr/gcovr.git; fi
225-
if [ ! -d build ]; then git clone --depth=1 \
226-
--single-branch https://github.com/nodejs/build.git; fi
227-
if [ ! -f gcovr/scripts/gcovr.orig ]; then \
228-
(cd gcovr && patch -N -p1 < \
229-
"$(CURDIR)/build/jenkins/scripts/coverage/gcovr-patches-3.4.diff"); fi
223+
if [ ! -d gcovr ]; then $(PYTHON) -m pip install -t gcovr gcovr==4.2; fi
230224
$(MAKE)
231225

232226
.PHONY: coverage-build-js
@@ -238,16 +232,14 @@ coverage-build-js:
238232

239233
.PHONY: coverage-test
240234
coverage-test: coverage-build
241-
$(RM) out/$(BUILDTYPE)/obj.target/node/src/*.gcda
242-
$(RM) out/$(BUILDTYPE)/obj.target/node/src/*/*.gcda
243-
$(RM) out/$(BUILDTYPE)/obj.target/node_lib/src/*.gcda
244-
$(RM) out/$(BUILDTYPE)/obj.target/node_lib/src/*/*.gcda
235+
$(FIND) out/$(BUILDTYPE)/obj.target -name "*.gcda" -type f -exec $(RM) {} \;
245236
-NODE_V8_COVERAGE=coverage/tmp \
246237
TEST_CI_ARGS="$(TEST_CI_ARGS) --type=coverage" $(MAKE) $(COVTESTS)
247238
$(MAKE) coverage-report-js
248-
-(cd out && "../gcovr/scripts/gcovr" \
239+
-(cd out && PYTHONPATH=../gcovr $(PYTHON) -m gcovr \
249240
--gcov-exclude='.*\b(deps|usr|out|cctest|embedding)\b' -v \
250-
-r Release/obj.target --html --html-detail -o ../coverage/cxxcoverage.html \
241+
-r ../src/ --object-directory Release/obj.target \
242+
--html --html-details -o ../coverage/cxxcoverage.html \
251243
--gcov-executable="$(GCOV)")
252244
@printf "Javascript coverage %%: "
253245
@grep -B1 Lines coverage/index.html | head -n1 \
@@ -847,6 +839,9 @@ else
847839
ifeq ($(findstring powerpc,$(shell uname -p)),powerpc)
848840
DESTCPU ?= ppc64
849841
else
842+
ifeq ($(findstring riscv64,$(UNAME_M)),riscv64)
843+
DESTCPU ?= riscv64
844+
else
850845
DESTCPU ?= x86
851846
endif
852847
endif
@@ -857,6 +852,7 @@ endif
857852
endif
858853
endif
859854
endif
855+
endif
860856
ifeq ($(DESTCPU),x64)
861857
ARCH=x64
862858
else
@@ -878,6 +874,9 @@ else
878874
ifeq ($(DESTCPU),s390x)
879875
ARCH=s390x
880876
else
877+
ifeq ($(DESTCPU),riscv64)
878+
ARCH=riscv64
879+
else
881880
ARCH=x86
882881
endif
883882
endif
@@ -886,6 +885,7 @@ endif
886885
endif
887886
endif
888887
endif
888+
endif
889889

890890
# node and v8 use different arch names (e.g. node 'x86' vs v8 'ia32').
891891
# pass the proper v8 arch name to $V8_ARCH based on user-specified $DESTCPU.
@@ -1093,7 +1093,7 @@ $(TARBALL): release-only doc-only
10931093
find $(TARNAME)/deps/v8/test -type f ! -regex '.*/test/torque/.*' | xargs $(RM)
10941094
find $(TARNAME)/deps/zlib/contrib/* -type d ! -regex '.*/contrib/optimizations$$' | xargs $(RM) -r
10951095
find $(TARNAME)/ -name ".eslint*" -maxdepth 2 | xargs $(RM)
1096-
find $(TARNAME)/ -type l | xargs $(RM) # annoying on windows
1096+
find $(TARNAME)/ -type l | xargs $(RM)
10971097
tar -cf $(TARNAME).tar $(TARNAME)
10981098
$(RM) -r $(TARNAME)
10991099
gzip -c -f -9 $(TARNAME).tar > $(TARNAME).tar.gz

README.md

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,10 @@ For information about the governance of the Node.js project, see
200200
* [Trott](https://github.com/Trott) -
201201
**Rich Trott** &lt;[email protected]&gt; (he/him)
202202

203+
<details>
204+
205+
<summary>Emeriti</summary>
206+
203207
### TSC emeriti
204208

205209
* [addaleax](https://github.com/addaleax) -
@@ -243,6 +247,8 @@ For information about the governance of the Node.js project, see
243247
* [trevnorris](https://github.com/trevnorris) -
244248
**Trevor Norris** &lt;[email protected]&gt;
245249

250+
</details>
251+
246252
### Collaborators
247253

248254
* [addaleax](https://github.com/addaleax) -
@@ -458,6 +464,10 @@ For information about the governance of the Node.js project, see
458464
* [ZYSzys](https://github.com/ZYSzys) -
459465
**Yongsheng Zhang** &lt;[email protected]&gt; (he/him)
460466

467+
<details>
468+
469+
<summary>Emeriti</summary>
470+
461471
### Collaborator emeriti
462472

463473
* [andrasq](https://github.com/andrasq) -
@@ -592,6 +602,8 @@ For information about the governance of the Node.js project, see
592602
**Vse Mozhet Byt** &lt;[email protected]&gt; (he/him)
593603
* [whitlockjc](https://github.com/whitlockjc) -
594604
**Jeremy Whitlock** &lt;[email protected]&gt;
605+
606+
</details>
595607
<!--lint enable prohibited-strings-->
596608

597609
Collaborators follow the [Collaborator Guide](./doc/guides/collaborator-guide.md) in
@@ -655,7 +667,9 @@ gpg --keyserver pool.sks-keyservers.net --recv-keys B9E2F5981AA6E0CD28160D9FF139
655667
See the section above on [Verifying Binaries](#verifying-binaries) for how to
656668
use these keys to verify a downloaded file.
657669

658-
Other keys used to sign some previous releases:
670+
<details>
671+
672+
<summary>Other keys used to sign some previous releases</summary>
659673

660674
* **Chris Dickinson** &lt;[email protected]&gt;
661675
`9554F04D7259F04124DE6B476D5A82AC7E37093B`
@@ -676,6 +690,8 @@ Other keys used to sign some previous releases:
676690
* **Timothy J Fontaine** &lt;[email protected]&gt;
677691
`7937DFD2AB06298B2293C3187D33FF9D0246406D`
678692

693+
</details>
694+
679695
## License
680696

681697
Node.js is available under the

common.gypi

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@
3636

3737
# Reset this number to 0 on major V8 upgrades.
3838
# Increment by one for each non-official patch applied to deps/v8.
39-
'v8_embedder_string': '-node.13',
39+
'v8_embedder_string': '-node.20',
4040

4141
##### V8 defaults for Node.js #####
4242

configure.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1066,6 +1066,7 @@ def host_arch_cc():
10661066
'__PPC__' : 'ppc64',
10671067
'__x86_64__' : 'x64',
10681068
'__s390x__' : 's390x',
1069+
'__riscv' : 'riscv',
10691070
}
10701071

10711072
rtn = 'ia32' # default
@@ -1078,6 +1079,12 @@ def host_arch_cc():
10781079
if rtn == 'mipsel' and '_LP64' in k:
10791080
rtn = 'mips64el'
10801081

1082+
if rtn == 'riscv':
1083+
if k['__riscv_xlen'] == '64':
1084+
rtn = 'riscv64'
1085+
else:
1086+
rtn = 'riscv32'
1087+
10811088
return rtn
10821089

10831090

deps/v8/include/v8-version.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
#define V8_MAJOR_VERSION 9
1212
#define V8_MINOR_VERSION 1
1313
#define V8_BUILD_NUMBER 269
14-
#define V8_PATCH_LEVEL 36
14+
#define V8_PATCH_LEVEL 38
1515

1616
// Use 1 for candidates and 0 otherwise.
1717
// (Boolean macro values are not supported by all preprocessors.)

deps/v8/src/heap/heap.cc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2129,6 +2129,10 @@ void Heap::CompleteSweepingYoung(GarbageCollector collector) {
21292129
array_buffer_sweeper()->EnsureFinished();
21302130
}
21312131

2132+
void Heap::EnsureSweepingCompleted() {
2133+
mark_compact_collector()->EnsureSweepingCompleted();
2134+
}
2135+
21322136
void Heap::UpdateCurrentEpoch(GarbageCollector collector) {
21332137
if (IsYoungGenerationCollector(collector)) {
21342138
epoch_young_ = next_epoch();

deps/v8/src/heap/heap.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1074,6 +1074,8 @@ class Heap {
10741074
void CompleteSweepingFull();
10751075
void CompleteSweepingYoung(GarbageCollector collector);
10761076

1077+
void EnsureSweepingCompleted();
1078+
10771079
IncrementalMarking* incremental_marking() {
10781080
return incremental_marking_.get();
10791081
}

deps/v8/src/json/json-parser.cc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -620,6 +620,11 @@ Handle<Object> JsonParser<Char>::BuildJsonObject(
620620
DCHECK_EQ(mutable_double_address, end);
621621
}
622622
#endif
623+
// Before setting the length of mutable_double_buffer back to zero, we
624+
// must ensure that the sweeper is not running or has already swept the
625+
// object's page. Otherwise the GC can add the contents of
626+
// mutable_double_buffer to the free list.
627+
isolate()->heap()->EnsureSweepingCompleted();
623628
mutable_double_buffer->set_length(0);
624629
}
625630
}

0 commit comments

Comments
 (0)