{"author":"Viktor Szakats","author_email":"commit@vsz.me","author_time":1737056353,"commit_time":1737153118,"committer":"Viktor Szakats","committer_email":"commit@vsz.me","hash":"2c4bfefe917c5f201ba1989de6bf2208b360c3ad","message":"build: stop detecting `sched_yield()` on Windows\n\nOn Windows a successful `sched_yield()` detection requires mingw-w64\nbuilt with POSIX threads (not Win32 threads) and GCC (not llvm/clang).\n(linking to `winpthread` via custom options may also work.)\n\nIn CMake builds, it was pre-cached as unavailable before this patch.\n\nWhen detected (via autotools), it got only used for Windows XP or older\ntargets combined with a non-GCC, non-clang compiler that doesn't support\n`__builtin_ia32_pause()`, or with the Intel C compiler. According to\n`lib/easy_lock.h`.\n\nmingw-w64 only supports GCC and clang, leaving a very narrow chance when\n`shed_yield()` gets called on Windows. Even then, `sched_yield()` is\nimplemented in `winpthread` as `Sleep(0)`, which may or not be a useful.\nIt's also trivial to implement locally if it is, and such rare build\ncombination is also deemed useful.\n\nThus, this patch marks `sched_yields()` permanently unavailable on the\nWindows platform also with autotools, and instead of pre-caching, skip\nthis feature check with CMake.\n\nThis syncs `HAVE_SCHED_YIELDS` between builds methods on Windows.\n\nFollow-up to 9b517c8b69a1f365fdb6f54f7153561182285b6c #11973\nFollow-up to 23af112f5556d6a785c17e09f2422ac931405f61 #8680\n\nCloses #16037\n","parents":["e49797abc24b8e0ac652d7aa0ceec7d252f9a019"],"tree_hash":"be3e677fdc9ee3bbfe86edb4c8016d251d8f4f60"}