Upload upstream chromium 108.0.5359.1
[platform/framework/web/chromium-efl.git] / build / toolchain / get_cpu_count.py
1 # Copyright 2018 The Chromium Authors
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
4
5 # This script shows cpu count to specify capacity of action pool.
6
7 from __future__ import print_function
8
9 import multiprocessing
10 import sys
11
12 def main():
13   try:
14     cpu_count = multiprocessing.cpu_count()
15   except:
16     cpu_count = 1
17
18   print(cpu_count)
19   return 0
20
21
22 if __name__ == '__main__':
23   sys.exit(main())