Skip to content
Ingo Albrecht edited this page Feb 25, 2014 · 3 revisions

Locators

See Locators.

CPU count

We could use a method for determining the number of CPUs / cores available on a system. This would be a bit of C wrapped in Dylan.

For Windows, this is pretty much:

SYSTEM_INFO info;
GetSystemInfo(&info);

return info.dwNumberOfProcessors;

And for Linux and Mac OS X:

return sysconf(_SC_NPROCESSORS_ONLN);

Something else is likely needed for FreeBSD.

Clone this wiki locally