From Switcher and MultiFinder, with Process Manager and Thread Manager in Classic Mac OS, to Pthreads, NSThreads, and Grand Central Dispatch.
GCD
How Swift supports cooperative multitasking using async/await. How to call asynchronous code from within synchronous code, and does it also multithread code in parallel?
The general rule for allocating threads to P and E cores according to their QoS, with fine controls such as Game Mode, and frequency control.
Understanding terms, including process, thread and task. How the assigned Quality of Service, or QoS, is used to determine how threads are allocated to cores.
Virtual CPU cores are of one type, and QoS has no effect in virtualised macOS. This has consequences for both the host and guest macOS.
Many apps could benefit users of Apple silicon Macs by giving them controls over core use by their threads. Here’s how that can be done simply and effectively.
How you can use the taskpolicy command to confine all the threads of a process to the E cores, as a brake, but there’s no accelerator in macOS.
How can the two E cores in an M1 Pro or Max equal performance of the four in the original M1? Why does running two threads complete in half the time taken to run one?
Threads, GCD and core allocation in Apple silicon explained. How thread priority is baked into code, and how important it is to performance.
It’s a strange coincidence that Intel and Microsoft came up with similar hardware of P and E core types in a SoC, and identical terminology for thread allocation using QoS.
