diff options
| author | Giampaolo Rodola <g.rodola@gmail.com> | 2018-03-30 19:34:02 +0200 |
|---|---|---|
| committer | Giampaolo Rodola <g.rodola@gmail.com> | 2018-03-30 19:34:02 +0200 |
| commit | 9aaa941efacf8a47c3a0555eb17eb5c3c167e832 (patch) | |
| tree | 8acd709740fce13aee2d07326fc9b1425f1b3039 | |
| parent | 2ae94f99b89639a96335f24cddc3ac556fdc2b59 (diff) | |
| download | psutil-9aaa941efacf8a47c3a0555eb17eb5c3c167e832.tar.gz | |
remove unused code
| -rw-r--r-- | psutil/_psutil_windows.c | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/psutil/_psutil_windows.c b/psutil/_psutil_windows.c index 2e55f81c..2c1e0fe1 100644 --- a/psutil/_psutil_windows.c +++ b/psutil/_psutil_windows.c @@ -195,23 +195,6 @@ psutil_get_nic_addresses() { } -// Helper function to count set bits in the cpu_count() processor mask. -DWORD -psutil_cpu_count_set_bits(ULONG_PTR bitMask) { - DWORD LSHIFT = sizeof(ULONG_PTR) * 8 - 1; - DWORD bitSetCount = 0; - ULONG_PTR bitTest = (ULONG_PTR)1 << LSHIFT; - DWORD i; - - for (i = 0; i <= LSHIFT; ++i) { - bitSetCount += ((bitMask & bitTest) ? 1 : 0); - bitTest /= 2; - } - - return bitSetCount; -} - - /* * Return the number of logical, active CPUs. See discussion at: * https://bugs.python.org/issue33166#msg314631 |
