1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-11 23:54:18 +00:00
JUCE/modules/juce_core/native
reuk 48c6087faf Thread: Update macOS thread priority calculation
The Apple threading documentation [^1] says the following:

> The second argument to pthread_setschedparam is the desired policy,
  which can currently be one of SCHED_FIFO (first in, first out),
  SCHED_RR (round-robin), or SCHED_OTHER. The SCHED_OTHER policy is
  generally used for extra policies that are specific to a given
  operating system, and should thus be avoided when writing portable
  code.

This appears to differ from the policy semantics on Linux and BSD, where
FIFO and RR are both explicitly real-time policies.

Therefore, on Linux/BSD we only enable the RR policy if the requested
priority is 8 or higher. Meanwhile, on macOS, we map all thread
priorities (0 - 10) onto the RR policy with an appropriate priority.

[^1]: https://developer.apple.com/library/archive/documentation/Darwin/Conceptual/KernelProgramming/scheduler/scheduler.html
2021-12-14 22:50:09 +00:00
..
java Replaced all references to ROLI with Raw Material Software and regenerated all bytecode 2020-04-23 17:30:40 +01:00
javacore Replaced all references to ROLI with Raw Material Software and regenerated all bytecode 2020-04-23 17:30:40 +01:00
juce_android_Files.cpp Updated all license headers 2020-04-23 17:30:39 +01:00
juce_android_JNIHelpers.cpp Normalised all whitespace before args in std::function 2020-06-05 09:37:49 +01:00
juce_android_JNIHelpers.h Desktop: Deprecate isOSXDarkModeActive() and add isDarkModeActive() for other platforms 2021-09-29 17:40:58 +01:00
juce_android_Misc.cpp Updated all license headers 2020-04-23 17:30:39 +01:00
juce_android_Network.cpp URL: Allow specifying shared container for downloads on iOS 2021-09-28 11:31:47 +01:00
juce_android_RuntimePermissions.cpp Android: Request ACCESS_FINE_LOCATION permission when using Bluetooth 2020-11-25 17:39:57 +00:00
juce_android_SystemStats.cpp Android: Fix numeric conversion warnings 2021-02-03 16:09:54 +00:00
juce_android_Threads.cpp Replaced all references to ROLI with Raw Material Software and regenerated all bytecode 2020-04-23 17:30:40 +01:00
juce_BasicNativeHeaders.h macOS/iOS: Replace compile-time deployment target checks with runtime checks using the available keyword 2021-10-13 15:06:18 +01:00
juce_curl_Network.cpp URL: Allow specifying shared container for downloads on iOS 2021-09-28 11:31:47 +01:00
juce_intel_SharedCode.h Added preliminary support for FreeBSD 2021-03-29 14:16:46 +01:00
juce_linux_CommonFile.cpp Added preliminary support for FreeBSD 2021-03-29 14:16:46 +01:00
juce_linux_Files.cpp Text: Fix some build issues when JUCE_STRING_UTF_TYPE != 8 2021-10-14 16:52:31 +01:00
juce_linux_Network.cpp URL: Allow specifying shared container for downloads on iOS 2021-09-28 11:31:47 +01:00
juce_linux_SystemStats.cpp Added preliminary support for FreeBSD 2021-03-29 14:16:46 +01:00
juce_linux_Threads.cpp Updated all license headers 2020-04-23 17:30:39 +01:00
juce_mac_CFHelpers.h macOS: Fix compile error when using C++20 language standard 2021-09-29 11:45:43 +01:00
juce_mac_Files.mm macOS: Silence deprecation warnings on Monterey 2021-11-01 10:04:35 +00:00
juce_mac_Network.mm ObjC Helpers: Automatically derive appropriate signature for function 2021-11-24 11:51:11 +00:00
juce_mac_ObjCHelpers.h ObjC Helpers: Ensure that all methods accept mandatory "self" and "selector" arguments 2021-12-07 19:08:11 +00:00
juce_mac_Strings.mm Updated all license headers 2020-04-23 17:30:39 +01:00
juce_mac_SystemStats.mm SystemStats: Set hasNeon flag correctly on M1 machines 2021-11-24 16:20:35 +00:00
juce_mac_Threads.mm Updated all license headers 2020-04-23 17:30:39 +01:00
juce_posix_IPAddress.h Tweaks for emscripten support 2021-02-08 09:59:46 +00:00
juce_posix_NamedPipe.cpp NamedPipe: Avoid early exits from writes on unavailable pipes 2021-10-14 12:40:25 +01:00
juce_posix_SharedCode.h Thread: Update macOS thread priority calculation 2021-12-14 22:50:09 +00:00
juce_wasm_SystemStats.cpp Tweaks for emscripten support 2021-02-08 09:59:46 +00:00
juce_win32_ComSmartPtr.h ComSmartPtr: Fixed behaviour of ComBaseClassHelper::QueryInterface() in release builds 2021-06-29 16:15:01 +01:00
juce_win32_Files.cpp Update code to use C++14 [[deprecated]] attribute 2021-09-29 16:14:00 +01:00
juce_win32_Network.cpp URL: Allow specifying shared container for downloads on iOS 2021-09-28 11:31:47 +01:00
juce_win32_Registry.cpp MinGW: Fix windows/gcc warnings 2020-05-11 11:28:28 +01:00
juce_win32_SystemStats.cpp MacOS: Fix API deprecations in macOS 12.0 and iOS 15.0 2021-06-10 15:20:39 +01:00
juce_win32_Threads.cpp Windows: Fix clang/gnu compiler warnings 2021-06-03 17:30:44 +01:00