aboutsummaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authorDavid Goulet <dgoulet@torproject.org>2022-10-31 11:21:21 -0400
committerDavid Goulet <dgoulet@torproject.org>2022-10-31 11:21:21 -0400
commit65a85a9d23bde693336790f6aeed8771638ff118 (patch)
treef8fca43e90c51ce7b6d63fbf0a4ef64a587371db /src/lib
parent19b080f2aaffe8e6d9e83a7ca7593a3e01eecef9 (diff)
parent5db238f3e3df54b11cf376d57d2cd89257b594f8 (diff)
downloadtor-65a85a9d23bde693336790f6aeed8771638ff118.tar.gz
tor-65a85a9d23bde693336790f6aeed8771638ff118.zip
Merge branch 'maint-0.4.7'
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/thread/numcpus.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/lib/thread/numcpus.c b/src/lib/thread/numcpus.c
index 2c2589fdfe..e0ddb69931 100644
--- a/src/lib/thread/numcpus.c
+++ b/src/lib/thread/numcpus.c
@@ -70,7 +70,11 @@ compute_num_cpus_impl(void)
#endif /* defined(_WIN32) || ... */
}
-#define MAX_DETECTABLE_CPUS 16
+/** This is an arbitrary number but at this point in time, it is not that
+ * uncommon to see servers up to that amount of CPUs. Most servers will likely
+ * be around 16 to 32 cores now. Lets take advantage of large machines! The
+ * "NumCPUs" torrc option overrides this maximum. */
+#define MAX_DETECTABLE_CPUS 128
/** Return how many CPUs we are running with. We assume that nobody is
* using hot-swappable CPUs, so we don't recompute this after the first