Skip to content

Commit c61870c

Browse files
committed
deps: upgrade to libuv 1.42.0
Notable changes: - win,tcp: make `uv_close()` work more like unix. - cleanup,win: Remove `_WIN32` guards on threadpool. - more errno mappings and fixes. - higher performance try-writes. - fix string encoding issue of `uv_os_gethostname()` (note: MINGW-W64 upstream is broken on i686 due to https://sourceforge.net/p/mingw-w64/bugs/899/). - zOS support. - Workarounds for a `copy_file_range()` kernel bug. - Better support for TSan. - darwin: use `RLIMIT_STACK` for fsevents pthread. - fix a bug that would cause libuv to hang if the user called `uv_shutdown()`. - darwin: fix `uv_barrier()` race condition. PR-URL: #39525 Fixes: #39502 Reviewed-By: Jiawen Geng <technicalcute@gmail.com> Reviewed-By: Tobias Nießen <tniessen@tnie.de> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
1 parent fe3c5a7 commit c61870c

File tree

145 files changed

+2353
-1172
lines changed

Some content is hidden

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

145 files changed

+2353
-1172
lines changed

deps/uv/.mailmap

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ A. Hauptmann <andreashauptmann@t-online.de>
22
Aaron Bieber <qbit@deftly.net> <deftly@gmail.com>
33
Alan Gutierrez <alan@prettyrobots.com> <alan@blogometer.com>
44
Andrius Bentkus <andrius.bentkus@gmail.com> <toxedvirus@gmail.com>
5+
Andy Fiddaman <andy@omniosce.org> <omnios@citrus-it.co.uk>
56
Bert Belder <bertbelder@gmail.com> <i@bertbelder.com>
67
Bert Belder <bertbelder@gmail.com> <info@2bs.nl>
78
Bert Belder <bertbelder@gmail.com> <user@ChrUbuntu.(none)>
@@ -10,6 +11,8 @@ Brian White <mscdex@mscdex.net>
1011
Brian White <mscdex@mscdex.net> <mscdex@gmail.com>
1112
Caleb James DeLisle <cjd@hyperboria.ca> <cjd@cjdns.fr>
1213
Christoph Iserlohn <christoph.iserlohn@innoq.com>
14+
Darshan Sen <raisinten@gmail.com>
15+
David Carlier <devnexen@gmail.com>
1316
Devchandra Meetei Leishangthem <dlmeetei@gmail.com>
1417
Fedor Indutny <fedor.indutny@gmail.com> <fedor@indutny.com>
1518
Frank Denis <github@pureftpd.org>
@@ -53,4 +56,5 @@ gengjiawen <technicalcute@gmail.com>
5356
jBarz <jBarz@users.noreply.github.com> <jbarboza@ca.ibm.com>
5457
jBarz <jBarz@users.noreply.github.com> <jbarz@users.noreply.github.com>
5558
ptlomholt <pt@lomholt.com>
59+
tjarlama <59913901+tjarlama@users.noreply.github.com> <tjarlama@gmail.com>
5660
zlargon <zlargon1988@gmail.com>

deps/uv/.readthedocs.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
version: 2
2+
3+
sphinx:
4+
builder: html
5+
configuration: null
6+
fail_on_warning: false
7+
8+
python:
9+
version: 3.8
10+
install:
11+
- requirements: docs/requirements.txt

deps/uv/AUTHORS

Lines changed: 22 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,6 @@ Dylan Cali <calid1984@gmail.com>
114114
Austin Foxley <austinf@cetoncorp.com>
115115
Benjamin Saunders <ben.e.saunders@gmail.com>
116116
Geoffry Song <goffrie@gmail.com>
117-
Rasmus Christian Pedersen <ruysch@outlook.com>
118117
William Light <wrl@illest.net>
119118
Oleg Efimov <o.efimov@corp.badoo.com>
120119
Lars Gierth <larsg@systemli.org>
@@ -123,7 +122,6 @@ Justin Venus <justin.venus@gmail.com>
123122
Kristian Evensen <kristian.evensen@gmail.com>
124123
Linus Mårtensson <linus.martensson@sonymobile.com>
125124
Navaneeth Kedaram Nambiathan <navaneethkn@gmail.com>
126-
Yorkie <yorkiefixer@gmail.com>
127125
StarWing <weasley.wx@gmail.com>
128126
thierry-FreeBSD <thierry@FreeBSD.org>
129127
Isaiah Norton <isaiah.norton@gmail.com>
@@ -459,3 +457,25 @@ schamberg97 <50446906+schamberg97@users.noreply.github.com>
459457
Bob Weinand <bobwei9@hotmail.com>
460458
Issam E. Maghni <issam.e.maghni@mailbox.org>
461459
Juan Pablo Canepa <jpcanepa@gmail.com>
460+
Shuowang (Wayne) Zhang <shuowang.zhang@ibm.com>
461+
Ondřej Surý <ondrej@sury.org>
462+
Juan José Arboleda <soyjuanarbol@gmail.com>
463+
Zhao Zhili <zhilizhao@tencent.com>
464+
Brandon Cheng <brandon.cheng@protonmail.com>
465+
Matvii Hodovaniuk <matvii@hodovani.uk>
466+
Hayden <me@diatr.us>
467+
yiyuaner <yguoaz@gmail.com>
468+
bbara <bbara93@gmail.com>
469+
SeverinLeonhardt <Severin.Leonhardt@teamviewer.com>
470+
Andy Fiddaman <andy@omniosce.org>
471+
Romain Roffé <rofferom@gmail.com>
472+
Eagle Liang <eagleliang@gmail.com>
473+
Ricky Zhou <ives199511@gmail.com>
474+
Simon Kissane <skissane@gmail.com>
475+
James M Snell <jasnell@gmail.com>
476+
Ali Mohammad Pur <Ali.mpfard@gmail.com>
477+
Erkhes N <71805796+rexes-ND@users.noreply.github.com>
478+
Joshua M. Clulow <josh@sysmgr.org>
479+
Guilherme Íscaro <cabelitostos@gmail.com>
480+
Martin Storsjö <martin@martin.st>
481+
Claes Nästén <pekdon@gmail.com>

deps/uv/CMakeLists.txt

Lines changed: 52 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,8 @@ option(ASAN "Enable AddressSanitizer (ASan)" OFF)
3434
if(ASAN AND CMAKE_C_COMPILER_ID MATCHES "AppleClang|GNU|Clang")
3535
add_definitions(-D__ASAN__=1)
3636
set (CMAKE_C_FLAGS_DEBUG "${CMAKE_C_FLAGS_DEBUG} -fno-omit-frame-pointer -fsanitize=address")
37-
set (CMAKE_LINKER_FLAGS_DEBUG "${CMAKE_LINKER_FLAGS_DEBUG} -fno-omit-frame-pointer -fsanitize=address")
37+
set (CMAKE_SHARED_LINKER_FLAGS_DEBUG "${CMAKE_SHARED_LINKER_FLAGS_DEBUG} -fno-omit-frame-pointer -fsanitize=address")
38+
set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fno-omit-frame-pointer -fsanitize=address")
3839
endif()
3940

4041
# Compiler check
@@ -209,10 +210,11 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Android")
209210
src/unix/pthread-fixes.c
210211
src/unix/random-getentropy.c
211212
src/unix/random-getrandom.c
212-
src/unix/random-sysctl-linux.c)
213+
src/unix/random-sysctl-linux.c
214+
src/unix/epoll.c)
213215
endif()
214216

215-
if(APPLE OR CMAKE_SYSTEM_NAME MATCHES "Android|Linux|OS390")
217+
if(APPLE OR CMAKE_SYSTEM_NAME MATCHES "Android|Linux")
216218
list(APPEND uv_sources src/unix/proctitle.c)
217219
endif()
218220

@@ -253,7 +255,8 @@ if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
253255
src/unix/linux-syscalls.c
254256
src/unix/procfs-exepath.c
255257
src/unix/random-getrandom.c
256-
src/unix/random-sysctl-linux.c)
258+
src/unix/random-sysctl-linux.c
259+
src/unix/epoll.c)
257260
endif()
258261

259262
if(CMAKE_SYSTEM_NAME STREQUAL "NetBSD")
@@ -266,9 +269,11 @@ if(CMAKE_SYSTEM_NAME STREQUAL "OpenBSD")
266269
endif()
267270

268271
if(CMAKE_SYSTEM_NAME STREQUAL "OS390")
269-
list(APPEND uv_defines PATH_MAX=255)
272+
enable_language(CXX)
273+
list(APPEND uv_defines PATH_MAX=1024)
270274
list(APPEND uv_defines _AE_BIMODAL)
271275
list(APPEND uv_defines _ALL_SOURCE)
276+
list(APPEND uv_defines _ENHANCED_ASCII_EXT=0xFFFFFFFF)
272277
list(APPEND uv_defines _ISOC99_SOURCE)
273278
list(APPEND uv_defines _LARGE_TIME_API)
274279
list(APPEND uv_defines _OPEN_MSGQ_EXT)
@@ -279,14 +284,31 @@ if(CMAKE_SYSTEM_NAME STREQUAL "OS390")
279284
list(APPEND uv_defines _UNIX03_SOURCE)
280285
list(APPEND uv_defines _UNIX03_THREADS)
281286
list(APPEND uv_defines _UNIX03_WITHDRAWN)
287+
list(APPEND uv_defines _XOPEN_SOURCE=600)
282288
list(APPEND uv_defines _XOPEN_SOURCE_EXTENDED)
283289
list(APPEND uv_sources
284290
src/unix/pthread-fixes.c
285291
src/unix/os390.c
286-
src/unix/os390-syscalls.c)
287-
list(APPEND uv_cflags -Wc,DLL -Wc,exportall -Wc,xplink)
288-
list(APPEND uv_libraries -Wl,xplink)
289-
list(APPEND uv_test_libraries -Wl,xplink)
292+
src/unix/os390-syscalls.c
293+
src/unix/os390-proctitle.c)
294+
list(APPEND uv_cflags
295+
-q64
296+
-qascii
297+
-qexportall
298+
-qgonumber
299+
-qlongname
300+
-qlibansi
301+
-qfloat=IEEE
302+
-qtune=10
303+
-qarch=10
304+
-qasm
305+
-qasmlib=sys1.maclib:sys1.modgen)
306+
find_library(ZOSLIB
307+
NAMES zoslib
308+
PATHS ${ZOSLIB_DIR}
309+
PATH_SUFFIXES lib
310+
)
311+
list(APPEND uv_libraries ${ZOSLIB})
290312
endif()
291313

292314
if(CMAKE_SYSTEM_NAME STREQUAL "OS400")
@@ -303,9 +325,11 @@ if(CMAKE_SYSTEM_NAME STREQUAL "OS400")
303325
endif()
304326

305327
if(CMAKE_SYSTEM_NAME STREQUAL "SunOS")
306-
list(APPEND uv_defines __EXTENSIONS__ _XOPEN_SOURCE=500)
328+
list(APPEND uv_defines __EXTENSIONS__ _XOPEN_SOURCE=500 _REENTRANT)
307329
list(APPEND uv_libraries kstat nsl sendfile socket)
308-
list(APPEND uv_sources src/unix/no-proctitle.c src/unix/sunos.c)
330+
list(APPEND uv_sources
331+
src/unix/no-proctitle.c
332+
src/unix/sunos.c)
309333
endif()
310334

311335
if(CMAKE_SYSTEM_NAME STREQUAL "Haiku")
@@ -349,6 +373,10 @@ target_include_directories(uv
349373
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
350374
PRIVATE
351375
$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/src>)
376+
if(CMAKE_SYSTEM_NAME STREQUAL "OS390")
377+
target_include_directories(uv PUBLIC $<BUILD_INTERFACE:${ZOSLIB_DIR}/include>)
378+
set_target_properties(uv PROPERTIES LINKER_LANGUAGE CXX)
379+
endif()
352380
target_link_libraries(uv ${uv_libraries})
353381

354382
add_library(uv_a STATIC ${uv_sources})
@@ -360,6 +388,10 @@ target_include_directories(uv_a
360388
$<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>
361389
PRIVATE
362390
$<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/src>)
391+
if(CMAKE_SYSTEM_NAME STREQUAL "OS390")
392+
target_include_directories(uv_a PUBLIC $<BUILD_INTERFACE:${ZOSLIB_DIR}/include>)
393+
set_target_properties(uv_a PROPERTIES LINKER_LANGUAGE CXX)
394+
endif()
363395
target_link_libraries(uv_a ${uv_libraries})
364396

365397
if(LIBUV_BUILD_TESTS)
@@ -457,6 +489,9 @@ if(LIBUV_BUILD_TESTS)
457489
test/test-metrics.c
458490
test/test-multiple-listen.c
459491
test/test-mutexes.c
492+
test/test-not-readable-nor-writable-on-read-error.c
493+
test/test-not-readable-on-eof.c
494+
test/test-not-writable-after-shutdown.c
460495
test/test-osx-select.c
461496
test/test-pass-always.c
462497
test/test-ping-pong.c
@@ -489,6 +524,7 @@ if(LIBUV_BUILD_TESTS)
489524
test/test-semaphore.c
490525
test/test-shutdown-close.c
491526
test/test-shutdown-eof.c
527+
test/test-shutdown-simultaneous.c
492528
test/test-shutdown-twice.c
493529
test/test-signal-multiple-loops.c
494530
test/test-signal-pending-on-close.c
@@ -582,6 +618,11 @@ if(LIBUV_BUILD_TESTS)
582618
add_test(NAME uv_test_a
583619
COMMAND uv_run_tests_a
584620
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR})
621+
if(CMAKE_SYSTEM_NAME STREQUAL "OS390")
622+
set_target_properties(uv_run_benchmarks_a PROPERTIES LINKER_LANGUAGE CXX)
623+
set_target_properties(uv_run_tests PROPERTIES LINKER_LANGUAGE CXX)
624+
set_target_properties(uv_run_tests_a PROPERTIES LINKER_LANGUAGE CXX)
625+
endif()
585626
endif()
586627

587628
if(UNIX OR MINGW)

deps/uv/CONTRIBUTING.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ The stable branch is effectively frozen; patches that change the libuv
2323
API/ABI or affect the run-time behavior of applications get rejected.
2424

2525
In case of doubt, open an issue in the [issue tracker][], post your question
26-
to the [libuv mailing list], or contact one of [project maintainers][] on [IRC][].
26+
to the [libuv discussions forum], or message the [libuv mailing list].
2727

28-
Especially do so if you plan to work on something big. Nothing is more
29-
frustrating than seeing your hard work go to waste because your vision
30-
does not align with that of a project maintainers.
28+
Especially do so if you plan to work on something big. Nothing is more
29+
frustrating than seeing your hard work go to waste because your vision does not
30+
align with that of the [project maintainers].
3131

3232

3333
### BRANCH
@@ -166,6 +166,6 @@ not send out notifications when you add commits.
166166

167167
[issue tracker]: https://github.com/libuv/libuv/issues
168168
[libuv mailing list]: http://groups.google.com/group/libuv
169-
[IRC]: http://webchat.freenode.net/?channels=libuv
169+
[libuv discussions forum]: https://github.com/libuv/libuv/discussions
170170
[Google C/C++ style guide]: https://google.github.io/styleguide/cppguide.html
171171
[project maintainers]: https://github.com/libuv/libuv/blob/master/MAINTAINERS.md

0 commit comments

Comments
 (0)