Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-108724: Add PyMutex and _PyParkingLot APIs#109344

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
ericsnowcurrently merged 28 commits intopython:mainfromcolesbury:locks
Sep 19, 2023

Conversation

colesbury
Copy link
Contributor

@colesburycolesbury commentedSep 12, 2023
edited
Loading

PyMutex is a one byte lock with fast, inlineable lock and unlock functions for the common uncontended case. The design is based on WebKit'sWTF::Lock.

PyMutex is built using the_PyParkingLot APIs, which provides a cross-platform futex-like API (based on WebKit'sWTF::ParkingLot). This internal API will be used for building other synchronization primitives used to implement PEP 703, such as one-time initialization and events.

This also includes tests and a mini benchmark inTools/lockbench/lockbench.py to compare with the existingPyThread_type_lock.

Uncontended acquisition + release:
Linux (x86-64): PyMutex: 11 ns, PyThread_type_lock: 44 ns
macOS (arm64): PyMutex: 13 ns, PyThread_type_lock: 18 ns
Windows (x86-64): PyMutex: 13 ns, PyThread_type_lock: 38 ns

PR Overview

The primary purpose of this PR is to implementPyMutex, but there are a number of support pieces (described below).

  • PyMutex: A 1-byte lock that doesn't require memory allocation to initialize and is generally faster than the existingPyThread_type_lock. The API is internal only for now.
  • _PyParking_Lot: A futex-like API based on the API of the same name in WebKit. Used to implementPyMutex.
  • _PyRawMutex: A word sized lock used to implement_PyParking_Lot
  • PyEvent: a one time event. This was used a bunch in the "nogil" fork and is useful for testing thePyMutex implementation, so I've included it as part of the PR.
  • pycore_llist.h: Defines common operations on doubly-linked list. Not strictly necessary (could do the list operations manually), but they come up frequently in the "nogil" fork. (Similar tohttps://man.freebsd.org/cgi/man.cgi?queue)

Linked issue

stonebig and erlend-aasland reacted with heart emoji
`PyMutex` is a one byte lock with fast, inlineable lock and unlockfunctions for the common uncontended case. The design is based onWebKit's `WTF::Lock`.PyMutex is built using the `_PyParkingLot` APIs, which provides across-platform futex-like API (based on WebKit's `WTF::ParkingLot`).This internal API will be used for building other synchronizationprimitives used to implement PEP 703, such as one-time initializationand events.
@colesburycolesbury added the 🔨 test-with-buildbotsTest PR w/ buildbots; report in status section labelSep 12, 2023
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by@colesbury for commit3161e17 🤖

If you want to schedule another build, you need to add the🔨 test-with-buildbots label again.

@bedevere-botbedevere-bot removed the 🔨 test-with-buildbotsTest PR w/ buildbots; report in status section labelSep 12, 2023
@colesbury
Copy link
ContributorAuthor

!buildbot ARM Raspbian
!buildbot wasm

@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by@colesbury for commitf963fd8 🤖

The command will test the builders whose names match following regular expression:ARM Raspbian

The builders matched are:

  • ARM Raspbian PR

@colesbury
Copy link
ContributorAuthor

!buildbot wasm

@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by@colesbury for commitf963fd8 🤖

The command will test the builders whose names match following regular expression:wasm

The builders matched are:

  • wasm32-emscripten node (dynamic linking) PR
  • wasm32-wasi PR
  • wasm32-emscripten node (pthreads) PR
  • wasm32-emscripten browser (dynamic linking, no tests) PR

The lock tests were being picked up twice: once in test_lock.py and oncein Test_testinternalcapi from test_misc.py. The Test_testinternalcapiwas not skipping tests when the platform doesn't have threads. Thismoves the tests to test_misc.py, doesn't include them inTest_testinternalcapi, and skips them if the platform doesn't supportthreads.
@colesbury
Copy link
ContributorAuthor

!buildbot wasm

@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by@colesbury for commit779a401 🤖

The command will test the builders whose names match following regular expression:wasm

The builders matched are:

  • wasm32-emscripten node (dynamic linking) PR
  • wasm32-wasi PR
  • wasm32-emscripten node (pthreads) PR
  • wasm32-emscripten browser (dynamic linking, no tests) PR

Copy link
Member

@ericsnowcurrentlyericsnowcurrently left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Here's the first portion of my review, to get you started. 😄

(FWIW, there should probably be a PEP before making a public API out of this, but that doesn't affect this PR.)

// the mutex is unlocked. If the current thread holds the GIL, then the GIL
// will be released while the thread is parked.
static inline void
PyMutex_Lock(PyMutex *m)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

I was going to recommend using "acquire"/"release" instead of "lock"/"unlock", as the former is quite prevalent in this context (and, to my brain, "lock" evokes the object rather than the action). However, there are definitely examples of "lock"/"unlock".

Ultimately, it would be nice if the names were consistent everywhere, to avoid confusing readers. (It would also be nice if the naming were consistent in the industry and academia.) The closer we can get, the better. I'd rather this PR help us converge than diverge, but I haven't taken the time to decide which way the PR goes.😄 (My initial gut reaction was that it diverges.) Feedback on this from a couple of other core devs would be helpful.

Copy link
ContributorAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Lock/unlock is much more common in libraries and programming languages:

  • pthread_mutex_t (POSIX)
  • std::mutex (C++)
  • std::sync::mutex (Rust)
  • java.util.concurrent.locks.Lock (Java)
  • sync.Mutex (Go)

Windows tends to use "wait"/"release" terminology.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

FWIW, I'm fine with lock/unlock (vs. acquire/release) at this point.

Regardless, I don't see this as a blocker for the PR, since it isn't public API (yet--and the name would get more scrutiny during the PEP process).

Copy link
ContributorAuthor

@colesburycolesbury left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Thanks for your continued review. Here's a summary of the major changes:

  • I removed the thread-local data fromparking_lot.c. It wasn't strictly necessary and didn't actually improve performance.
  • I switched to statically initializing thebuckets linked lists inparking_lot.c, which avoids needing to check if it's initialized inenqueue/dequeue.
  • I moved the_PySemaphore struct definition topycore_semaphore.h because it now includes platform-specific details and I'd like to avoid exposing those inpycore_parking_lot.h (I expect more files to use the parking lot API than the_PySemaphore API.)
  • I switched_PyParkingLot_Unpark to use a function pointer as a callback, like you asked about in the previous review. I think this ends up being a bit nicer, but let me know what you think.

ericsnowcurrently reacted with thumbs up emoji
Copy link
Member

@ericsnowcurrentlyericsnowcurrently left a comment
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Here's the last of my initial review. 😄

Thanks again for doing the work (and for putting up with my many comments)!

Copy link
ContributorAuthor

@colesburycolesbury left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Thanks@ericsnowcurrently. I've updated the PR.

Copy link
Member

@ericsnowcurrentlyericsnowcurrently left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

LGTM

I'll merge this later today, unless@vstinner,@pitrou, or@gpshead have any objections.

erlend-aasland reacted with hooray emojicolesbury reacted with heart emoji
@ericsnowcurrently
Copy link
Member

BTW, thanks for your work on this and for addressing all my concerns.

stonebig and erlend-aasland reacted with hooray emojicolesbury and erlend-aasland reacted with heart emoji

@ericsnowcurrently
Copy link
Member

I'm going to wait until tomorrow, to accommodate timezones. 😄

@ericsnowcurrently
Copy link
Member

Thanks again,@colesbury!

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbotwasm32-emscripten browser (dynamic linking, no tests) 3.x has failed when building commit0c89056.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/1051/builds/3114) and take a look at the build logs.
  4. Check if the failure is related to this commit (0c89056) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/1051/builds/3114

Summary of the results of the build (if available):

Click to see traceback logs
remote:Enumerating objects: 51, done.remote:Counting objects:   2% (1/38)remote:Counting objects:   5% (2/38)remote:Counting objects:   7% (3/38)remote:Counting objects:  10% (4/38)remote:Counting objects:  13% (5/38)remote:Counting objects:  15% (6/38)remote:Counting objects:  18% (7/38)remote:Counting objects:  21% (8/38)remote:Counting objects:  23% (9/38)remote:Counting objects:  26% (10/38)remote:Counting objects:  28% (11/38)remote:Counting objects:  31% (12/38)remote:Counting objects:  34% (13/38)remote:Counting objects:  36% (14/38)remote:Counting objects:  39% (15/38)remote:Counting objects:  42% (16/38)remote:Counting objects:  44% (17/38)remote:Counting objects:  47% (18/38)remote:Counting objects:  50% (19/38)remote:Counting objects:  52% (20/38)remote:Counting objects:  55% (21/38)remote:Counting objects:  57% (22/38)remote:Counting objects:  60% (23/38)remote:Counting objects:  63% (24/38)remote:Counting objects:  65% (25/38)remote:Counting objects:  68% (26/38)remote:Counting objects:  71% (27/38)remote:Counting objects:  73% (28/38)remote:Counting objects:  76% (29/38)remote:Counting objects:  78% (30/38)remote:Counting objects:  81% (31/38)remote:Counting objects:  84% (32/38)remote:Counting objects:  86% (33/38)remote:Counting objects:  89% (34/38)remote:Counting objects:  92% (35/38)remote:Counting objects:  94% (36/38)remote:Counting objects:  97% (37/38)remote:Counting objects: 100% (38/38)remote:Counting objects: 100% (38/38), done.remote:Compressing objects:   4% (1/22)remote:Compressing objects:   9% (2/22)remote:Compressing objects:  13% (3/22)remote:Compressing objects:  18% (4/22)remote:Compressing objects:  22% (5/22)remote:Compressing objects:  27% (6/22)remote:Compressing objects:  31% (7/22)remote:Compressing objects:  36% (8/22)remote:Compressing objects:  40% (9/22)remote:Compressing objects:  45% (10/22)remote:Compressing objects:  50% (11/22)remote:Compressing objects:  54% (12/22)remote:Compressing objects:  59% (13/22)remote:Compressing objects:  63% (14/22)remote:Compressing objects:  68% (15/22)remote:Compressing objects:  72% (16/22)remote:Compressing objects:  77% (17/22)remote:Compressing objects:  81% (18/22)remote:Compressing objects:  86% (19/22)remote:Compressing objects:  90% (20/22)remote:Compressing objects:  95% (21/22)remote:Compressing objects: 100% (22/22)remote:Compressing objects: 100% (22/22), done.remote:Total 51 (delta 17), reused 16 (delta 16), pack-reused 13From https://github.com/python/cpython * branch                  main       -> FETCH_HEADNote:switching to '0c89056fe59ac42f09978582479d40e58a236856'.You are in 'detached HEAD' state. You can look around, make experimentalchanges and commit them, and you can discard any commits you make in thisstate without impacting any branches by switching back to a branch.If you want to create a new branch to retain commits you create, you maydo so (now or later) by using -c with the switch command. Example:  git switch -c <new-branch-name>Or undo this operation with:  git switch -Turn off this advice by setting config variable advice.detachedHead to falseHEAD is now at 0c89056fe5 gh-108724: Add PyMutex and _PyParkingLot APIs (gh-109344)Switched to and reset branch 'main'configure:../../configure --prefix $(PWD)/target/host --with-pydebug --without-pydebug --with-emscripten-target=browser --enable-wasm-dynamic-linking --disable-wasm-pthreads --build=x86_64-pc-linux-gnu --host=wasm32-unknown-emscripten --with-build-python=../build/pythonconfigure:WARNING: using cross tools not prefixed with host tripletmcc:error: no input filesmake:make -j2 all../../Python/initconfig.c:2309:27: warning: format specifies type 'wint_t' (aka 'int') but the argument has type 'wint_t' (aka 'unsigned int') [-Wformat]    printf(usage_envvars, (wint_t)DELIM, (wint_t)DELIM,PYTHONHOMEHELP);~~~~~~~~~~~~~^~~~~~~~~~~~~../../Python/initconfig.c:146:18: note: format string is defined here"PYTHONPATH   : '%lc'-separated list of directories prefixed to the\n"^~~%c../../Python/initconfig.c:2309:42: warning: format specifies type 'wint_t' (aka 'int') but the argument has type 'wint_t' (aka 'unsigned int') [-Wformat]    printf(usage_envvars, (wint_t)DELIM, (wint_t)DELIM,PYTHONHOMEHELP);~~~~~~~~~~~~~^~~~~~~~~~~~~../../Python/initconfig.c:148:58: note: format string is defined here"PYTHONHOME   : alternate <prefix> directory (or <prefix>%lc<exec_prefix>).\n"^~~%c2 warnings generated.../../Python/optimizer.c:408:9: warning: variable 'reserved' set but not used [-Wunused-but-set-variable]int reserved=0;^1 warning generated.In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:83:11: warning: 'htobe16' macro redefined [-Wmacro-redefined]#  define htobe16(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:35:9: note: previous definition is here#define htobe16(x) __bswap16(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:84:11: warning: 'htole16' macro redefined [-Wmacro-redefined]#  define htole16(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:41:9: note: previous definition is here#define htole16(x) (uint16_t)(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:85:11: warning: 'be16toh' macro redefined [-Wmacro-redefined]#  define be16toh(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:36:9: note: previous definition is here#define be16toh(x) __bswap16(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:86:11: warning: 'le16toh' macro redefined [-Wmacro-redefined]#  define le16toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:42:9: note: previous definition is here#define le16toh(x) (uint16_t)(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:88:11: warning: 'htobe32' macro redefined [-Wmacro-redefined]#  define htobe32(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:37:9: note: previous definition is here#define htobe32(x) __bswap32(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:89:11: warning: 'htole32' macro redefined [-Wmacro-redefined]#  define htole32(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:43:9: note: previous definition is here#define htole32(x) (uint32_t)(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:90:11: warning: 'be32toh' macro redefined [-Wmacro-redefined]#  define be32toh(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:38:9: note: previous definition is here#define be32toh(x) __bswap32(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:91:11: warning: 'le32toh' macro redefined [-Wmacro-redefined]#  define le32toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:44:9: note: previous definition is here#define le32toh(x) (uint32_t)(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:93:11: warning: 'htobe64' macro redefined [-Wmacro-redefined]#  define htobe64(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:39:9: note: previous definition is here#define htobe64(x) __bswap64(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:94:11: warning: 'htole64' macro redefined [-Wmacro-redefined]#  define htole64(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:45:9: note: previous definition is here#define htole64(x) (uint64_t)(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:95:11: warning: 'be64toh' macro redefined [-Wmacro-redefined]#  define be64toh(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:40:9: note: previous definition is here#define be64toh(x) __bswap64(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:96:11: warning: 'le64toh' macro redefined [-Wmacro-redefined]#  define le64toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:46:9: note: previous definition is here#define le64toh(x) (uint64_t)(x)^12 warnings generated.In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:83:11: warning: 'htobe16' macro redefined [-Wmacro-redefined]#  define htobe16(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:35:9: note: previous definition is here#define htobe16(x) __bswap16(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:84:11: warning: 'htole16' macro redefined [-Wmacro-redefined]#  define htole16(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:41:9: note: previous definition is here#define htole16(x) (uint16_t)(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:85:11: warning: 'be16toh' macro redefined [-Wmacro-redefined]#  define be16toh(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:36:9: note: previous definition is here#define be16toh(x) __bswap16(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:86:11: warning: 'le16toh' macro redefined [-Wmacro-redefined]#  define le16toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:42:9: note: previous definition is here#define le16toh(x) (uint16_t)(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:88:11: warning: 'htobe32' macro redefined [-Wmacro-redefined]#  define htobe32(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:37:9: note: previous definition is here#define htobe32(x) __bswap32(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:89:11: warning: 'htole32' macro redefined [-Wmacro-redefined]#  define htole32(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:43:9: note: previous definition is here#define htole32(x) (uint32_t)(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:90:11: warning: 'be32toh' macro redefined [-Wmacro-redefined]#  define be32toh(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:38:9: note: previous definition is here#define be32toh(x) __bswap32(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:91:11: warning: 'le32toh' macro redefined [-Wmacro-redefined]#  define le32toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:44:9: note: previous definition is here#define le32toh(x) (uint32_t)(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:93:11: warning: 'htobe64' macro redefined [-Wmacro-redefined]#  define htobe64(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:39:9: note: previous definition is here#define htobe64(x) __bswap64(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:94:11: warning: 'htole64' macro redefined [-Wmacro-redefined]#  define htole64(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:45:9: note: previous definition is here#define htole64(x) (uint64_t)(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:95:11: warning: 'be64toh' macro redefined [-Wmacro-redefined]#  define be64toh(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:40:9: note: previous definition is here#define be64toh(x) __bswap64(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:96:11: warning: 'le64toh' macro redefined [-Wmacro-redefined]#  define le64toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:46:9: note: previous definition is here#define le64toh(x) (uint64_t)(x)^12 warnings generated.In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:83:11: warning: 'htobe16' macro redefined [-Wmacro-redefined]#  define htobe16(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:35:9: note: previous definition is here#define htobe16(x) __bswap16(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:84:11: warning: 'htole16' macro redefined [-Wmacro-redefined]#  define htole16(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:41:9: note: previous definition is here#define htole16(x) (uint16_t)(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:85:11: warning: 'be16toh' macro redefined [-Wmacro-redefined]#  define be16toh(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:36:9: note: previous definition is here#define be16toh(x) __bswap16(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:86:11: warning: 'le16toh' macro redefined [-Wmacro-redefined]#  define le16toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:42:9: note: previous definition is here#define le16toh(x) (uint16_t)(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:88:11: warning: 'htobe32' macro redefined [-Wmacro-redefined]#  define htobe32(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:37:9: note: previous definition is here#define htobe32(x) __bswap32(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:89:11: warning: 'htole32' macro redefined [-Wmacro-redefined]#  define htole32(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:43:9: note: previous definition is here#define htole32(x) (uint32_t)(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:90:11: warning: 'be32toh' macro redefined [-Wmacro-redefined]#  define be32toh(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:38:9: note: previous definition is here#define be32toh(x) __bswap32(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:91:11: warning: 'le32toh' macro redefined [-Wmacro-redefined]#  define le32toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:44:9: note: previous definition is here#define le32toh(x) (uint32_t)(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:93:11: warning: 'htobe64' macro redefined [-Wmacro-redefined]#  define htobe64(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:39:9: note: previous definition is here#define htobe64(x) __bswap64(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:94:11: warning: 'htole64' macro redefined [-Wmacro-redefined]#  define htole64(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:45:9: note: previous definition is here#define htole64(x) (uint64_t)(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:95:11: warning: 'be64toh' macro redefined [-Wmacro-redefined]#  define be64toh(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:40:9: note: previous definition is here#define be64toh(x) __bswap64(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:96:11: warning: 'le64toh' macro redefined [-Wmacro-redefined]#  define le64toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:46:9: note: previous definition is here#define le64toh(x) (uint64_t)(x)^12 warnings generated.../../Modules/expat/xmlparse.c:3116:9: warning: code will never be executed [-Wunreachable-code]        parser->m_characterDataHandler(parser->m_handlerArg, parser->m_dataBuf,^~~~~~../../Modules/expat/xmlparse.c:3115:16: note: silence by adding parentheses to mark code as explicitly deadelseif (0&& parser->m_characterDataHandler)^/*DISABLESCODE*/ ( )../../Modules/expat/xmlparse.c:4059:9: warning: code will never be executed [-Wunreachable-code]        parser->m_characterDataHandler(parser->m_handlerArg, parser->m_dataBuf,^~~~~~../../Modules/expat/xmlparse.c:4058:16: note: silence by adding parentheses to mark code as explicitly deadelseif (0&& parser->m_characterDataHandler)^/*DISABLESCODE*/ ( )../../Modules/expat/xmlparse.c:7703:11: warning: format specifies type 'int' but the argument has type 'ptrdiff_t' (aka 'long') [-Wformat]          bytesMore, (account==XML_ACCOUNT_DIRECT)?"DIR" :"EXP",^~~~~~~~~3 warnings generated.../../Modules/socketmodule.c:4082:33: warning: comparison of integers of different signs: 'unsigned long' and 'long' [-Wsign-compare]         cmsgh!=NULL; cmsgh= CMSG_NXTHDR(&msg, cmsgh)) {^~~~~~~~~~~~~~~~~~~~~~~~/opt/buildbot/.emscripten_cache/sysroot/include/sys/socket.h:356:44: note: expanded from macro 'CMSG_NXTHDR'        __CMSG_LEN(cmsg)+ sizeof(struct cmsghdr)>= __MHDR_END(mhdr)- (unsigned char*)(cmsg) \~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~../../Modules/socketmodule.c:4135:33: warning: comparison of integers of different signs: 'unsigned long' and 'long' [-Wsign-compare]         cmsgh!=NULL; cmsgh= CMSG_NXTHDR(&msg, cmsgh)) {^~~~~~~~~~~~~~~~~~~~~~~~/opt/buildbot/.emscripten_cache/sysroot/include/sys/socket.h:356:44: note: expanded from macro 'CMSG_NXTHDR'        __CMSG_LEN(cmsg)+ sizeof(struct cmsghdr)>= __MHDR_END(mhdr)- (unsigned char*)(cmsg) \~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~../../Modules/socketmodule.c:4759:54: warning: comparison of integers of different signs: 'unsigned long' and 'long' [-Wsign-compare]            cmsgh= (i==0)? CMSG_FIRSTHDR(&msg) : CMSG_NXTHDR(&msg, cmsgh);^~~~~~~~~~~~~~~~~~~~~~~~/opt/buildbot/.emscripten_cache/sysroot/include/sys/socket.h:356:44: note: expanded from macro 'CMSG_NXTHDR'        __CMSG_LEN(cmsg)+ sizeof(struct cmsghdr)>= __MHDR_END(mhdr)- (unsigned char*)(cmsg) \~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~3 warnings generated.../../Modules/_sqlite/connection.c:2260:19: warning: result of comparison of constant 9223372036854775807 with expression of type 'Py_ssize_t' (aka 'long') is always false [-Wtautological-constant-out-of-range-compare]if (data->len>9223372036854775807) {// (1<<63)-1~~~~~~~~~^~~~~~~~~~~~~~~~~~~~1 warning generated.Created /opt/buildbot/bcannon-wasm/3.x.bcannon-wasm.emscripten-browser/build/build_oot/host/opt/buildbot/bcannon-wasm/3.x.bcannon-wasm.emscripten-browser/build/build_oot/host/target/host/lib/python313.zip (2.87 MiB)In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:83:11: warning: 'htobe16' macro redefined [-Wmacro-redefined]#  define htobe16(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:35:9: note: previous definition is here#define htobe16(x) __bswap16(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:84:11: warning: 'htole16' macro redefined [-Wmacro-redefined]#  define htole16(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:41:9: note: previous definition is here#define htole16(x) (uint16_t)(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:85:11: warning: 'be16toh' macro redefined [-Wmacro-redefined]#  define be16toh(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:36:9: note: previous definition is here#define be16toh(x) __bswap16(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:86:11: warning: 'le16toh' macro redefined [-Wmacro-redefined]#  define le16toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:42:9: note: previous definition is here#define le16toh(x) (uint16_t)(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:88:11: warning: 'htobe32' macro redefined [-Wmacro-redefined]#  define htobe32(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:37:9: note: previous definition is here#define htobe32(x) __bswap32(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:89:11: warning: 'htole32' macro redefined [-Wmacro-redefined]#  define htole32(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:43:9: note: previous definition is here#define htole32(x) (uint32_t)(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:90:11: warning: 'be32toh' macro redefined [-Wmacro-redefined]#  define be32toh(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:38:9: note: previous definition is here#define be32toh(x) __bswap32(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:91:11: warning: 'le32toh' macro redefined [-Wmacro-redefined]#  define le32toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:44:9: note: previous definition is here#define le32toh(x) (uint32_t)(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:93:11: warning: 'htobe64' macro redefined [-Wmacro-redefined]#  define htobe64(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:39:9: note: previous definition is here#define htobe64(x) __bswap64(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:94:11: warning: 'htole64' macro redefined [-Wmacro-redefined]#  define htole64(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:45:9: note: previous definition is here#define htole64(x) (uint64_t)(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:95:11: warning: 'be64toh' macro redefined [-Wmacro-redefined]#  define be64toh(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:40:9: note: previous definition is here#define be64toh(x) __bswap64(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:96:11: warning: 'le64toh' macro redefined [-Wmacro-redefined]#  define le64toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:46:9: note: previous definition is here#define le64toh(x) (uint64_t)(x)^12 warnings generated.rror:undefined symbol: sem_timedwait (referenced by top-level compiled C/C++ code)warning:Link with `-sLLD_REPORT_UNDEFINED` to get more information on undefined symbolswarning:To disable errors for undefined symbols use `-sERROR_ON_UNDEFINED_SYMBOLS=0`warning:_sem_timedwait may need to be added to EXPORTED_FUNCTIONS if it arrives from a system libraryError:Aborting compilation due to previous errorsmcc:error: '/opt/emsdk/node/14.18.2_64bit/bin/node /opt/emsdk/upstream/emscripten/src/compiler.js /tmp/tmpbjctbtqx.json' failed (returned 1)make:*** [Makefile:906: python.js] Error 1mmake:error: 'make -j2 all' failed (returned 2)

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbotwasm32-emscripten node (dynamic linking) 3.x has failed when building commit0c89056.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/1056/builds/3121) and take a look at the build logs.
  4. Check if the failure is related to this commit (0c89056) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/1056/builds/3121

Summary of the results of the build (if available):

Click to see traceback logs
remote:Enumerating objects: 51, done.remote:Counting objects:   2% (1/38)remote:Counting objects:   5% (2/38)remote:Counting objects:   7% (3/38)remote:Counting objects:  10% (4/38)remote:Counting objects:  13% (5/38)remote:Counting objects:  15% (6/38)remote:Counting objects:  18% (7/38)remote:Counting objects:  21% (8/38)remote:Counting objects:  23% (9/38)remote:Counting objects:  26% (10/38)remote:Counting objects:  28% (11/38)remote:Counting objects:  31% (12/38)remote:Counting objects:  34% (13/38)remote:Counting objects:  36% (14/38)remote:Counting objects:  39% (15/38)remote:Counting objects:  42% (16/38)remote:Counting objects:  44% (17/38)remote:Counting objects:  47% (18/38)remote:Counting objects:  50% (19/38)remote:Counting objects:  52% (20/38)remote:Counting objects:  55% (21/38)remote:Counting objects:  57% (22/38)remote:Counting objects:  60% (23/38)remote:Counting objects:  63% (24/38)remote:Counting objects:  65% (25/38)remote:Counting objects:  68% (26/38)remote:Counting objects:  71% (27/38)remote:Counting objects:  73% (28/38)remote:Counting objects:  76% (29/38)remote:Counting objects:  78% (30/38)remote:Counting objects:  81% (31/38)remote:Counting objects:  84% (32/38)remote:Counting objects:  86% (33/38)remote:Counting objects:  89% (34/38)remote:Counting objects:  92% (35/38)remote:Counting objects:  94% (36/38)remote:Counting objects:  97% (37/38)remote:Counting objects: 100% (38/38)remote:Counting objects: 100% (38/38), done.remote:Compressing objects:   4% (1/22)remote:Compressing objects:   9% (2/22)remote:Compressing objects:  13% (3/22)remote:Compressing objects:  18% (4/22)remote:Compressing objects:  22% (5/22)remote:Compressing objects:  27% (6/22)remote:Compressing objects:  31% (7/22)remote:Compressing objects:  36% (8/22)remote:Compressing objects:  40% (9/22)remote:Compressing objects:  45% (10/22)remote:Compressing objects:  50% (11/22)remote:Compressing objects:  54% (12/22)remote:Compressing objects:  59% (13/22)remote:Compressing objects:  63% (14/22)remote:Compressing objects:  68% (15/22)remote:Compressing objects:  72% (16/22)remote:Compressing objects:  77% (17/22)remote:Compressing objects:  81% (18/22)remote:Compressing objects:  86% (19/22)remote:Compressing objects:  90% (20/22)remote:Compressing objects:  95% (21/22)remote:Compressing objects: 100% (22/22)remote:Compressing objects: 100% (22/22), done.remote:Total 51 (delta 17), reused 16 (delta 16), pack-reused 13From https://github.com/python/cpython * branch                  main       -> FETCH_HEADNote:switching to '0c89056fe59ac42f09978582479d40e58a236856'.You are in 'detached HEAD' state. You can look around, make experimentalchanges and commit them, and you can discard any commits you make in thisstate without impacting any branches by switching back to a branch.If you want to create a new branch to retain commits you create, you maydo so (now or later) by using -c with the switch command. Example:  git switch -c <new-branch-name>Or undo this operation with:  git switch -Turn off this advice by setting config variable advice.detachedHead to falseHEAD is now at 0c89056fe5 gh-108724: Add PyMutex and _PyParkingLot APIs (gh-109344)Switched to and reset branch 'main'configure:../../configure --prefix $(PWD)/target/host --with-pydebug --without-pydebug --with-emscripten-target=node --enable-wasm-dynamic-linking --disable-wasm-pthreads --build=x86_64-pc-linux-gnu --host=wasm32-unknown-emscripten --with-build-python=../build/pythonconfigure:WARNING: using cross tools not prefixed with host tripletmcc:error: no input filesmake:make -j2 all../../Python/initconfig.c:2309:27: warning: format specifies type 'wint_t' (aka 'int') but the argument has type 'wint_t' (aka 'unsigned int') [-Wformat]    printf(usage_envvars, (wint_t)DELIM, (wint_t)DELIM,PYTHONHOMEHELP);~~~~~~~~~~~~~^~~~~~~~~~~~~../../Python/initconfig.c:146:18: note: format string is defined here"PYTHONPATH   : '%lc'-separated list of directories prefixed to the\n"^~~%c../../Python/initconfig.c:2309:42: warning: format specifies type 'wint_t' (aka 'int') but the argument has type 'wint_t' (aka 'unsigned int') [-Wformat]    printf(usage_envvars, (wint_t)DELIM, (wint_t)DELIM,PYTHONHOMEHELP);~~~~~~~~~~~~~^~~~~~~~~~~~~../../Python/initconfig.c:148:58: note: format string is defined here"PYTHONHOME   : alternate <prefix> directory (or <prefix>%lc<exec_prefix>).\n"^~~%c2 warnings generated.../../Python/optimizer.c:408:9: warning: variable 'reserved' set but not used [-Wunused-but-set-variable]int reserved=0;^1 warning generated.In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:83:11: warning: 'htobe16' macro redefined [-Wmacro-redefined]#  define htobe16(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:35:9: note: previous definition is here#define htobe16(x) __bswap16(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:84:11: warning: 'htole16' macro redefined [-Wmacro-redefined]#  define htole16(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:41:9: note: previous definition is here#define htole16(x) (uint16_t)(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:85:11: warning: 'be16toh' macro redefined [-Wmacro-redefined]#  define be16toh(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:36:9: note: previous definition is here#define be16toh(x) __bswap16(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:86:11: warning: 'le16toh' macro redefined [-Wmacro-redefined]#  define le16toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:42:9: note: previous definition is here#define le16toh(x) (uint16_t)(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:88:11: warning: 'htobe32' macro redefined [-Wmacro-redefined]#  define htobe32(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:37:9: note: previous definition is here#define htobe32(x) __bswap32(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:89:11: warning: 'htole32' macro redefined [-Wmacro-redefined]#  define htole32(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:43:9: note: previous definition is here#define htole32(x) (uint32_t)(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:90:11: warning: 'be32toh' macro redefined [-Wmacro-redefined]#  define be32toh(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:38:9: note: previous definition is here#define be32toh(x) __bswap32(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:91:11: warning: 'le32toh' macro redefined [-Wmacro-redefined]#  define le32toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:44:9: note: previous definition is here#define le32toh(x) (uint32_t)(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:93:11: warning: 'htobe64' macro redefined [-Wmacro-redefined]#  define htobe64(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:39:9: note: previous definition is here#define htobe64(x) __bswap64(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:94:11: warning: 'htole64' macro redefined [-Wmacro-redefined]#  define htole64(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:45:9: note: previous definition is here#define htole64(x) (uint64_t)(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:95:11: warning: 'be64toh' macro redefined [-Wmacro-redefined]#  define be64toh(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:40:9: note: previous definition is here#define be64toh(x) __bswap64(x)^In file included from ../../Modules/md5module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_MD5.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:96:11: warning: 'le64toh' macro redefined [-Wmacro-redefined]#  define le64toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:46:9: note: previous definition is here#define le64toh(x) (uint64_t)(x)^12 warnings generated.In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:83:11: warning: 'htobe16' macro redefined [-Wmacro-redefined]#  define htobe16(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:35:9: note: previous definition is here#define htobe16(x) __bswap16(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:84:11: warning: 'htole16' macro redefined [-Wmacro-redefined]#  define htole16(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:41:9: note: previous definition is here#define htole16(x) (uint16_t)(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:85:11: warning: 'be16toh' macro redefined [-Wmacro-redefined]#  define be16toh(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:36:9: note: previous definition is here#define be16toh(x) __bswap16(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:86:11: warning: 'le16toh' macro redefined [-Wmacro-redefined]#  define le16toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:42:9: note: previous definition is here#define le16toh(x) (uint16_t)(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:88:11: warning: 'htobe32' macro redefined [-Wmacro-redefined]#  define htobe32(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:37:9: note: previous definition is here#define htobe32(x) __bswap32(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:89:11: warning: 'htole32' macro redefined [-Wmacro-redefined]#  define htole32(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:43:9: note: previous definition is here#define htole32(x) (uint32_t)(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:90:11: warning: 'be32toh' macro redefined [-Wmacro-redefined]#  define be32toh(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:38:9: note: previous definition is here#define be32toh(x) __bswap32(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:91:11: warning: 'le32toh' macro redefined [-Wmacro-redefined]#  define le32toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:44:9: note: previous definition is here#define le32toh(x) (uint32_t)(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:93:11: warning: 'htobe64' macro redefined [-Wmacro-redefined]#  define htobe64(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:39:9: note: previous definition is here#define htobe64(x) __bswap64(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:94:11: warning: 'htole64' macro redefined [-Wmacro-redefined]#  define htole64(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:45:9: note: previous definition is here#define htole64(x) (uint64_t)(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:95:11: warning: 'be64toh' macro redefined [-Wmacro-redefined]#  define be64toh(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:40:9: note: previous definition is here#define be64toh(x) __bswap64(x)^In file included from ../../Modules/sha1module.c:47:In file included from ../../Modules/_hacl/Hacl_Hash_SHA1.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:96:11: warning: 'le64toh' macro redefined [-Wmacro-redefined]#  define le64toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:46:9: note: previous definition is here#define le64toh(x) (uint64_t)(x)^12 warnings generated.In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:83:11: warning: 'htobe16' macro redefined [-Wmacro-redefined]#  define htobe16(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:35:9: note: previous definition is here#define htobe16(x) __bswap16(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:84:11: warning: 'htole16' macro redefined [-Wmacro-redefined]#  define htole16(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:41:9: note: previous definition is here#define htole16(x) (uint16_t)(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:85:11: warning: 'be16toh' macro redefined [-Wmacro-redefined]#  define be16toh(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:36:9: note: previous definition is here#define be16toh(x) __bswap16(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:86:11: warning: 'le16toh' macro redefined [-Wmacro-redefined]#  define le16toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:42:9: note: previous definition is here#define le16toh(x) (uint16_t)(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:88:11: warning: 'htobe32' macro redefined [-Wmacro-redefined]#  define htobe32(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:37:9: note: previous definition is here#define htobe32(x) __bswap32(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:89:11: warning: 'htole32' macro redefined [-Wmacro-redefined]#  define htole32(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:43:9: note: previous definition is here#define htole32(x) (uint32_t)(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:90:11: warning: 'be32toh' macro redefined [-Wmacro-redefined]#  define be32toh(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:38:9: note: previous definition is here#define be32toh(x) __bswap32(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:91:11: warning: 'le32toh' macro redefined [-Wmacro-redefined]#  define le32toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:44:9: note: previous definition is here#define le32toh(x) (uint32_t)(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:93:11: warning: 'htobe64' macro redefined [-Wmacro-redefined]#  define htobe64(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:39:9: note: previous definition is here#define htobe64(x) __bswap64(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:94:11: warning: 'htole64' macro redefined [-Wmacro-redefined]#  define htole64(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:45:9: note: previous definition is here#define htole64(x) (uint64_t)(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:95:11: warning: 'be64toh' macro redefined [-Wmacro-redefined]#  define be64toh(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:40:9: note: previous definition is here#define be64toh(x) __bswap64(x)^In file included from ../../Modules/sha3module.c:59:In file included from ../../Modules/_hacl/Hacl_Hash_SHA3.h:34:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:96:11: warning: 'le64toh' macro redefined [-Wmacro-redefined]#  define le64toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:46:9: note: previous definition is here#define le64toh(x) (uint64_t)(x)^12 warnings generated.../../Modules/expat/xmlparse.c:3116:9: warning: code will never be executed [-Wunreachable-code]        parser->m_characterDataHandler(parser->m_handlerArg, parser->m_dataBuf,^~~~~~../../Modules/expat/xmlparse.c:3115:16: note: silence by adding parentheses to mark code as explicitly deadelseif (0&& parser->m_characterDataHandler)^/*DISABLESCODE*/ ( )../../Modules/expat/xmlparse.c:4059:9: warning: code will never be executed [-Wunreachable-code]        parser->m_characterDataHandler(parser->m_handlerArg, parser->m_dataBuf,^~~~~~../../Modules/expat/xmlparse.c:4058:16: note: silence by adding parentheses to mark code as explicitly deadelseif (0&& parser->m_characterDataHandler)^/*DISABLESCODE*/ ( )../../Modules/expat/xmlparse.c:7703:11: warning: format specifies type 'int' but the argument has type 'ptrdiff_t' (aka 'long') [-Wformat]          bytesMore, (account==XML_ACCOUNT_DIRECT)?"DIR" :"EXP",^~~~~~~~~3 warnings generated.../../Modules/socketmodule.c:4082:33: warning: comparison of integers of different signs: 'unsigned long' and 'long' [-Wsign-compare]         cmsgh!=NULL; cmsgh= CMSG_NXTHDR(&msg, cmsgh)) {^~~~~~~~~~~~~~~~~~~~~~~~/opt/buildbot/.emscripten_cache/sysroot/include/sys/socket.h:356:44: note: expanded from macro 'CMSG_NXTHDR'        __CMSG_LEN(cmsg)+ sizeof(struct cmsghdr)>= __MHDR_END(mhdr)- (unsigned char*)(cmsg) \~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~../../Modules/socketmodule.c:4135:33: warning: comparison of integers of different signs: 'unsigned long' and 'long' [-Wsign-compare]         cmsgh!=NULL; cmsgh= CMSG_NXTHDR(&msg, cmsgh)) {^~~~~~~~~~~~~~~~~~~~~~~~/opt/buildbot/.emscripten_cache/sysroot/include/sys/socket.h:356:44: note: expanded from macro 'CMSG_NXTHDR'        __CMSG_LEN(cmsg)+ sizeof(struct cmsghdr)>= __MHDR_END(mhdr)- (unsigned char*)(cmsg) \~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~../../Modules/socketmodule.c:4759:54: warning: comparison of integers of different signs: 'unsigned long' and 'long' [-Wsign-compare]            cmsgh= (i==0)? CMSG_FIRSTHDR(&msg) : CMSG_NXTHDR(&msg, cmsgh);^~~~~~~~~~~~~~~~~~~~~~~~/opt/buildbot/.emscripten_cache/sysroot/include/sys/socket.h:356:44: note: expanded from macro 'CMSG_NXTHDR'        __CMSG_LEN(cmsg)+ sizeof(struct cmsghdr)>= __MHDR_END(mhdr)- (unsigned char*)(cmsg) \~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~3 warnings generated.../../Modules/_sqlite/connection.c:2260:19: warning: result of comparison of constant 9223372036854775807 with expression of type 'Py_ssize_t' (aka 'long') is always false [-Wtautological-constant-out-of-range-compare]if (data->len>9223372036854775807) {// (1<<63)-1~~~~~~~~~^~~~~~~~~~~~~~~~~~~~1 warning generated.In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:83:11: warning: 'htobe16' macro redefined [-Wmacro-redefined]#  define htobe16(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:35:9: note: previous definition is here#define htobe16(x) __bswap16(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:84:11: warning: 'htole16' macro redefined [-Wmacro-redefined]#  define htole16(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:41:9: note: previous definition is here#define htole16(x) (uint16_t)(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:85:11: warning: 'be16toh' macro redefined [-Wmacro-redefined]#  define be16toh(x) __builtin_bswap16(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:36:9: note: previous definition is here#define be16toh(x) __bswap16(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:86:11: warning: 'le16toh' macro redefined [-Wmacro-redefined]#  define le16toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:42:9: note: previous definition is here#define le16toh(x) (uint16_t)(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:88:11: warning: 'htobe32' macro redefined [-Wmacro-redefined]#  define htobe32(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:37:9: note: previous definition is here#define htobe32(x) __bswap32(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:89:11: warning: 'htole32' macro redefined [-Wmacro-redefined]#  define htole32(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:43:9: note: previous definition is here#define htole32(x) (uint32_t)(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:90:11: warning: 'be32toh' macro redefined [-Wmacro-redefined]#  define be32toh(x) __builtin_bswap32(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:38:9: note: previous definition is here#define be32toh(x) __bswap32(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:91:11: warning: 'le32toh' macro redefined [-Wmacro-redefined]#  define le32toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:44:9: note: previous definition is here#define le32toh(x) (uint32_t)(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:93:11: warning: 'htobe64' macro redefined [-Wmacro-redefined]#  define htobe64(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:39:9: note: previous definition is here#define htobe64(x) __bswap64(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:94:11: warning: 'htole64' macro redefined [-Wmacro-redefined]#  define htole64(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:45:9: note: previous definition is here#define htole64(x) (uint64_t)(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:95:11: warning: 'be64toh' macro redefined [-Wmacro-redefined]#  define be64toh(x) __builtin_bswap64(x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:40:9: note: previous definition is here#define be64toh(x) __bswap64(x)^In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:96:11: warning: 'le64toh' macro redefined [-Wmacro-redefined]#  define le64toh(x) (x)^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:46:9: note: previous definition is here#define le64toh(x) (uint64_t)(x)^12 warnings generated.rror:undefined symbol: sem_timedwait (referenced by top-level compiled C/C++ code)warning:Link with `-sLLD_REPORT_UNDEFINED` to get more information on undefined symbolswarning:To disable errors for undefined symbols use `-sERROR_ON_UNDEFINED_SYMBOLS=0`warning:_sem_timedwait may need to be added to EXPORTED_FUNCTIONS if it arrives from a system libraryError:Aborting compilation due to previous errorsmcc:error: '/opt/emsdk/node/14.18.2_64bit/bin/node /opt/emsdk/upstream/emscripten/src/compiler.js /tmp/tmpyjv3jww7.json' failed (returned 1)make:*** [Makefile:906: python.js] Error 1mmake:error: 'make -j2 all' failed (returned 2)

@ericsnowcurrently
Copy link
Member

@colesbury ^^^

colesbury reacted with thumbs up emoji

@ericsnowcurrently
Copy link
Member

In file included from ../../Modules/sha2module.c:48:In file included from ../../Modules/_hacl/Hacl_Hash_SHA2.h:35:In file included from ../../Modules/_hacl/include/krml/types.h:12:../../Modules/_hacl/include/krml/lowstar_endianness.h:83:11: warning: 'htobe16' macro redefined [-Wmacro-redefined]#  define htobe16(x) __builtin_bswap16(x)          ^/opt/buildbot/.emscripten_cache/sysroot/include/endian.h:35:9: note: previous definition is here#define htobe16(x) __bswap16(x)        ^

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbotAMD64 Ubuntu Shared 3.x has failed when building commit0c89056.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/506/builds/5900) and take a look at the build logs.
  4. Check if the failure is related to this commit (0c89056) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/506/builds/5900

Failed tests:

  • test.test_concurrent_futures.test_wait

Failed subtests:

  • test_timeout - test.test_concurrent_futures.test_wait.ProcessPoolForkserverWaitTest.test_timeout

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/srv/buildbot/buildarea/3.x.bolen-ubuntu/build/Lib/test/test_concurrent_futures/test_wait.py", line128, intest_timeoutself.assertEqual(set([CANCELLED_AND_NOTIFIED_FUTURE,AssertionError:Items in the first set but not the second:<Future at 0x7f25adaf3bc0 state=running>

@ericsnowcurrently
Copy link
Member

The AMD64 Ubuntu Shared 3.x failure is due to an unrelated flaky test.

colesbury reacted with thumbs up emoji

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbotAMD64 Fedora Stable 3.x has failed when building commit0c89056.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/543/builds/4495) and take a look at the build logs.
  4. Check if the failure is related to this commit (0c89056) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/543/builds/4495

Failed tests:

  • test.test_concurrent_futures.test_shutdown

Summary of the results of the build (if available):

==

Click to see traceback logs
remote:Enumerating objects: 51, done.remote:Counting objects:   2% (1/38)remote:Counting objects:   5% (2/38)remote:Counting objects:   7% (3/38)remote:Counting objects:  10% (4/38)remote:Counting objects:  13% (5/38)remote:Counting objects:  15% (6/38)remote:Counting objects:  18% (7/38)remote:Counting objects:  21% (8/38)remote:Counting objects:  23% (9/38)remote:Counting objects:  26% (10/38)remote:Counting objects:  28% (11/38)remote:Counting objects:  31% (12/38)remote:Counting objects:  34% (13/38)remote:Counting objects:  36% (14/38)remote:Counting objects:  39% (15/38)remote:Counting objects:  42% (16/38)remote:Counting objects:  44% (17/38)remote:Counting objects:  47% (18/38)remote:Counting objects:  50% (19/38)remote:Counting objects:  52% (20/38)remote:Counting objects:  55% (21/38)remote:Counting objects:  57% (22/38)remote:Counting objects:  60% (23/38)remote:Counting objects:  63% (24/38)remote:Counting objects:  65% (25/38)remote:Counting objects:  68% (26/38)remote:Counting objects:  71% (27/38)remote:Counting objects:  73% (28/38)remote:Counting objects:  76% (29/38)remote:Counting objects:  78% (30/38)remote:Counting objects:  81% (31/38)remote:Counting objects:  84% (32/38)remote:Counting objects:  86% (33/38)remote:Counting objects:  89% (34/38)remote:Counting objects:  92% (35/38)remote:Counting objects:  94% (36/38)remote:Counting objects:  97% (37/38)remote:Counting objects: 100% (38/38)remote:Counting objects: 100% (38/38), done.remote:Compressing objects:   4% (1/22)remote:Compressing objects:   9% (2/22)remote:Compressing objects:  13% (3/22)remote:Compressing objects:  18% (4/22)remote:Compressing objects:  22% (5/22)remote:Compressing objects:  27% (6/22)remote:Compressing objects:  31% (7/22)remote:Compressing objects:  36% (8/22)remote:Compressing objects:  40% (9/22)remote:Compressing objects:  45% (10/22)remote:Compressing objects:  50% (11/22)remote:Compressing objects:  54% (12/22)remote:Compressing objects:  59% (13/22)remote:Compressing objects:  63% (14/22)remote:Compressing objects:  68% (15/22)remote:Compressing objects:  72% (16/22)remote:Compressing objects:  77% (17/22)remote:Compressing objects:  81% (18/22)remote:Compressing objects:  86% (19/22)remote:Compressing objects:  90% (20/22)remote:Compressing objects:  95% (21/22)remote:Compressing objects: 100% (22/22)remote:Compressing objects: 100% (22/22), done.remote:Total 51 (delta 17), reused 16 (delta 16), pack-reused 13From https://github.com/python/cpython * branch                  main       -> FETCH_HEADNote:switching to '0c89056fe59ac42f09978582479d40e58a236856'.You are in 'detached HEAD' state. You can look around, make experimentalchanges and commit them, and you can discard any commits you make in thisstate without impacting any branches by switching back to a branch.If you want to create a new branch to retain commits you create, you maydo so (now or later) by using -c with the switch command. Example:  git switch -c <new-branch-name>Or undo this operation with:  git switch -Turn off this advice by setting config variable advice.detachedHead to falseHEAD is now at 0c89056fe5 gh-108724: Add PyMutex and _PyParkingLot APIs (gh-109344)Switched to and reset branch 'main'../Objects/longobject.c:In function ‘long_format_binary’:../Objects/longobject.c:2120:13: warning: ‘kind’ may be used uninitialized [-Wmaybe-uninitialized] 2120 |     else if (kind == PyUnicode_1BYTE_KIND) {|^../Objects/longobject.c:1996:9: note: ‘kind’ was declared here 1996 |     int kind;|^~~~../Objects/longobject.c:In function ‘long_to_decimal_string_internal’:../Objects/longobject.c:1943:13: warning: ‘kind’ may be used uninitialized [-Wmaybe-uninitialized] 1943 |     else if (kind == PyUnicode_1BYTE_KIND) {|^../Objects/longobject.c:1767:9: note: ‘kind’ was declared here 1767 |     int kind;|^~~~make:*** [Makefile:2040: buildbottest] Error 5

@bedevere-bot
Copy link

⚠️⚠️⚠️ Buildbot failure⚠️⚠️⚠️

Hi! The buildbots390x RHEL8 LTO 3.x has failed when building commit0c89056.

What do you need to do:

  1. Don't panic.
  2. Checkthe buildbot page in the devguide if you don't know what the buildbots are or how they work.
  3. Go to the page of the buildbot that failed (https://buildbot.python.org/all/#builders/567/builds/4922) and take a look at the build logs.
  4. Check if the failure is related to this commit (0c89056) or if it is a false positive.
  5. If the failure is related to this commit, please, reflect that on the issue and make a new Pull Request with a fix.

You can take a look at the buildbot page here:

https://buildbot.python.org/all/#builders/567/builds/4922

Failed tests:

  • test.test_asyncio.test_subprocess
  • test_tools

Failed subtests:

  • test_subprocess_consistent_callbacks - test.test_asyncio.test_subprocess.SubprocessThreadedWatcherTests.test_subprocess_consistent_callbacks
  • test_subprocess_consistent_callbacks - test.test_asyncio.test_subprocess.SubprocessSafeWatcherTests.test_subprocess_consistent_callbacks
  • test_freeze_simple_script - test.test_tools.test_freeze.TestFreeze.test_freeze_simple_script

Summary of the results of the build (if available):

==

Click to see traceback logs
Traceback (most recent call last):  File"/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/test/test_tools/test_freeze.py", line28, intest_freeze_simple_script    outdir, scriptfile, python= helper.prepare(script, outdir)^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^  File"/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Tools/freeze/test/freeze.py", line146, inprepare    copy_source_tree(srcdir,SRCDIR)  File"/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Tools/freeze/test/freeze.py", line95, incopy_source_tree    shutil.copytree(oldroot, newroot,ignore=ignore_non_src)  File"/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/shutil.py", line588, incopytreereturn _copytree(entries=entries,src=src,dst=dst,symlinks=symlinks,^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^  File"/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/shutil.py", line542, in_copytreeraise Error(errors)shutil.Error:[('/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/build/test_python_2810433æ/test_python_6n2okkfj.sock', '/tmp/test_python_2ysh974y/tmp0i2d4jz3/cpython/build/test_python_2810433æ/test_python_6n2okkfj.sock', "[Errno 6] No such device or address: '/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/build/test_python_2810433æ/test_python_6n2okkfj.sock'")]Traceback (most recent call last):  File"/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/test/test_asyncio/test_subprocess.py", line788, intest_subprocess_consistent_callbacksself.loop.run_until_complete(main())  File"/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/asyncio/base_events.py", line664, inrun_until_completereturn future.result()^^^^^^^^^^^^^^^  File"/home/dje/cpython-buildarea/3.x.edelsohn-rhel8-z.lto/build/Lib/test/test_asyncio/test_subprocess.py", line780, inmainself.assertEqual(events, [AssertionError:Lists differ: ['process_exited', ('pipe_data_received', 1, b'stdout')] != [('pipe_data_received', 1, b'stdout'), ('p[95 chars]ted']

@ericsnowcurrently
Copy link
Member

The WASM buildbot failures are fixed bygh-109583.

@colesburycolesbury deleted the locks branchSeptember 19, 2023 21:00
csm10495 pushed a commit to csm10495/cpython that referenced this pull requestSep 28, 2023
PyMutex is a one byte lock with fast, inlineable lock and unlock functions for the common uncontended case.  The design is based on WebKit's WTF::Lock.PyMutex is built using the _PyParkingLot APIs, which provides a cross-platform futex-like API (based on WebKit's WTF::ParkingLot).  This internal API will be used for building other synchronization primitives used to implement PEP 703, such as one-time initialization and events.This also includes tests and a mini benchmark in Tools/lockbench/lockbench.py to compare with the existing PyThread_type_lock.Uncontended acquisition + release:* Linux (x86-64): PyMutex: 11 ns, PyThread_type_lock: 44 ns* macOS (arm64): PyMutex: 13 ns, PyThread_type_lock: 18 ns* Windows (x86-64): PyMutex: 13 ns, PyThread_type_lock: 38 nsPR Overview:The primary purpose of this PR is to implement PyMutex, but there are a number of support pieces (described below).* PyMutex:  A 1-byte lock that doesn't require memory allocation to initialize and is generally faster than the existing PyThread_type_lock.  The API is internal only for now.* _PyParking_Lot:  A futex-like API based on the API of the same name in WebKit.  Used to implement PyMutex.* _PyRawMutex:  A word sized lock used to implement _PyParking_Lot.* PyEvent:  A one time event.  This was used a bunch in the "nogil" fork and is useful for testing the PyMutex implementation, so I've included it as part of the PR.* pycore_llist.h:  Defines common operations on doubly-linked list.  Not strictly necessary (could do the list operations manually), but they come up frequently in the "nogil" fork. ( Similar tohttps://man.freebsd.org/cgi/man.cgi?queue)---------Co-authored-by: Eric Snow <ericsnowcurrently@gmail.com>
@vstinner
Copy link
Member

This change introduced new compiler warnings: see issuegh-110014.

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@ericsnowcurrentlyericsnowcurrentlyericsnowcurrently approved these changes

@vstinnervstinnerAwaiting requested review from vstinner

@erlend-aaslanderlend-aaslandAwaiting requested review from erlend-aaslanderlend-aasland is a code owner

@corona10corona10Awaiting requested review from corona10corona10 is a code owner

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

4 participants
@colesbury@bedevere-bot@ericsnowcurrently@vstinner

[8]ページ先頭

©2009-2025 Movatter.jp