mirror of
https://git.rwth-aachen.de/acs/public/villas/node/
synced 2025-03-09 00:00:00 +01:00
remove support for Darwin/macOS
This commit is contained in:
parent
d22855d16c
commit
e53f65ccc5
3 changed files with 1 additions and 18 deletions
|
@ -31,11 +31,6 @@
|
|||
#include <cinttypes>
|
||||
#include <x86intrin.h>
|
||||
|
||||
#ifdef __APPLE__
|
||||
#include <sys/types.h>
|
||||
#include <sys/sysctl.h>
|
||||
#endif
|
||||
|
||||
#include <villas/kernel/kernel.hpp>
|
||||
|
||||
#ifndef bit_TSC
|
||||
|
|
|
@ -81,7 +81,7 @@ int villas::kernel::getCachelineSize()
|
|||
#endif
|
||||
}
|
||||
|
||||
#if defined(__linux__) || defined(__APPLE__)
|
||||
#if defined(__linux__)
|
||||
int villas::kernel::getPageSize()
|
||||
{
|
||||
return sysconf(_SC_PAGESIZE);
|
||||
|
|
|
@ -55,18 +55,6 @@ int tsc_init(struct Tsc *t)
|
|||
ret = kernel::get_cpu_frequency(&t->frequency);
|
||||
if (ret)
|
||||
return ret;
|
||||
#elif defined(__APPLE__)
|
||||
int64_t frequency;
|
||||
size_t lenp = sizeof(frequency);
|
||||
|
||||
/** @todo machdep.tsc.frequency seems to be a measured frequency (based on local APIC?
|
||||
* We should figure out which frequency is more accurate */
|
||||
// ret = sysctlbyname("hw.cpufrequency", &frequency, &lenp, nullptr, 0);
|
||||
ret = sysctlbyname("machdep.tsc.frequency", &frequency, &lenp, nullptr, 0);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
||||
t->frequency = frequency;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue