We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent dd16185 commit b392ae5Copy full SHA for b392ae5
wpiformat/wpiformat/__init__.py
@@ -226,11 +226,16 @@ def main():
226
help=
227
"verbosity level 2 (prints names of processed files and tasks run on them)"
228
)
229
+ # mp.Pool() uses WaitForMultipleObjects() to wait for subprocess completion
230
+ # on Windows. WaitForMultipleObjects() cannot wait on more then 64 events at
231
+ # once, and mp uses a few internal events. Therefore, the maximum number of
232
+ # parallel jobs is 60.
233
+ cpu_count = min(60, mp.cpu_count())
234
parser.add_argument(
235
"-j",
236
dest="jobs",
237
type=int,
- default=mp.cpu_count(),
238
+ default=cpu_count,
239
help="number of jobs to run (default is number of cores)")
240
241
"-clang",
0 commit comments