cl-cpus

2018-04-30

Get number of CPUs

Upstream URL

github.com/muyinliu/cl-cpus

Author

Muyinliu Xing <muyinliu@gmail.com>

License

ISC
README

cl-cpus

cl-cpus is a Common Lisp feature to get number of CPUs.

License

Copyright (c) 2017 Muyinliu Xing Released under the ISC License.

Note: the Linux part of code comes from Edmound Weitz's book Common Lisp Recipes.

Compatibility

Common LispLinuxMacUnixWindows
SBCLYesYesYes
CCLYesYesYes

Note: I don't have Unix system so haven't test on Unix yet.

Install and load with QuickLisp

In shell:

git clone https://github.com/muyinliu/cl-cpus.git
cp -r cl-cpus ~/quicklisp/local-projects/

In Common Lisp:

(ql:quickload 'cl-cpus)

Usage

(cpus:get-number-of-processors)

will get number of CPUs:

8

Dependencies (1)

  • cffi
  • GitHub
  • Quicklisp