On Darwin, we want to limit the parallelism during test execution for
sanitizer tests that use shadow memory. The reason is explained by this
existing comment:
Only run up to 3 processes that require shadow memory simultaneously
on 64-bit Darwin. Using more scales badly and hogs the system due to
inefficient handling of large mmap'd regions (terabytes) by the
kernel.
Previously we detected 3 cases:
- on-device: limit to 1 process
- 64-bit: macOS & simulators, limit to 3 processes
- others (32-bit): no limitation
We checked for the 64-bit case like this: `if arch in ['x86_64',
'x86_64h']` which misses macOS running on AS. Additionally, we don't
care about 32-bit anymore, so I've simplified this to 2 cases: on-device
and everything else.
How do we ensure this change doesn't effect non-Darwin hosts?
Previously we would only assign a parallelism group on Darwin hosts, now we don't have that check anymore.
Is it okay to do this because assigning a parallelism group on its own won't change anything. Presumably it also requires the lit_config.parallelism_groups['shadow-memory'] = 3 setting which is guarded by platform.system() == 'Darwin'?