summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Support/Host.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'llvm/lib/Support/Host.cpp')
-rw-r--r--llvm/lib/Support/Host.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Support/Host.cpp b/llvm/lib/Support/Host.cpp
index fa3cd9a0966..e4a9b504a76 100644
--- a/llvm/lib/Support/Host.cpp
+++ b/llvm/lib/Support/Host.cpp
@@ -1194,7 +1194,7 @@ StringRef sys::getHostCPUName() { return "generic"; }
// On Linux, the number of physical cores can be computed from /proc/cpuinfo,
// using the number of unique physical/core id pairs. The following
// implementation reads the /proc/cpuinfo format on an x86_64 system.
-int computeHostNumPhysicalCores() {
+static int computeHostNumPhysicalCores() {
// Read /proc/cpuinfo as a stream (until EOF reached). It cannot be
// mmapped because it appears to have 0 size.
llvm::ErrorOr<std::unique_ptr<llvm::MemoryBuffer>> Text =
@@ -1236,7 +1236,7 @@ int computeHostNumPhysicalCores() {
}
#else
// On other systems, return -1 to indicate unknown.
-int computeHostNumPhysicalCores() { return -1; }
+static int computeHostNumPhysicalCores() { return -1; }
#endif
int sys::getHostNumPhysicalCores() {
OpenPOWER on IntegriCloud