From: Christian Heller Date: Thu, 10 Dec 2020 21:56:25 +0000 (+0100) Subject: Raise bar for multiprocessing, after some performance testing. X-Git-Url: https://plomlompom.com/repos/%7B%7Bprefix%7D%7D/process?a=commitdiff_plain;h=0f7053c69a136af83d0517aa1241caa5b9c0268c;p=plomrogue2 Raise bar for multiprocessing, after some performance testing. --- diff --git a/plomrogue/game.py b/plomrogue/game.py index 31cae6f..d390e94 100755 --- a/plomrogue/game.py +++ b/plomrogue/game.py @@ -249,7 +249,7 @@ class Game(GameBase): player_fovs += [player._fov] player_fov_ids += [player.id_] new_fovs = [] - single_core_until = 8 # since multiprocess has its own overhead + single_core_until = 16 # since multiprocess has its own overhead if len(player_fovs) > single_core_until: pool = multiprocessing.Pool() new_fovs = pool.map(FovMap.init_terrain, [fov for fov in player_fovs])