Update hyperthreading rules for task distribution

There is now only one rule: Thread imbalances cannot be tested using workers who have more threads than physical cores
This commit is contained in:
andrew committed 2023-07-30 20:41:05 -04:00
1 parent 51447a5f42
commit baf2fac2bf
1 file changed
+2 -2
+2 -2
View File
@@ -735,8 +735,8 @@ def test_maps_onto_thread_count(test, threads, sockets, hyperthreads):
if max(dev_threads, base_threads) > (threads / sockets):
return False
# Intentional Thread Imbalance, or real cores, or evenly distributed
return dev_threads != base_threads or not hyperthreads or (threads / sockets) % dev_threads == 0
# Refuse to run thread-odds when dipping into hyperthreads
return dev_threads == base_threads or not hyperthreads
def select_workload(machine, tests, variance=0.25):