diff options
author | Ludovic Courtès <ludo@gnu.org> | 2011-04-25 22:41:58 +0200 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2011-04-25 22:41:58 +0200 |
commit | d20912e67d810ce5eb9dc1b8f8afd8c22aa2451b (patch) | |
tree | 987f0fd1150c26e230547b21c076f867fca1b1e9 /test-suite | |
parent | bbec4602457ed3e139e9dae99b4b495a3bc5eb71 (diff) | |
download | guile-d20912e67d810ce5eb9dc1b8f8afd8c22aa2451b.tar.gz |
Move `{total,current}-processor-count' outside of `posix.c'.
* libguile/posix.c (scm_total_processor_count,
scm_current_processor_count): Move to...
* libguile/threads.c: ... here.
* libguile/posix.h (scm_total_processor_count,
scm_current_processor_count): Move declarations to...
* libguile/threads.h: ... here.
* test-suite/tests/posix.test ("nproc"): Move tests to...
* test-suite/tests/threads.test: ... here.
Diffstat (limited to 'test-suite')
-rw-r--r-- | test-suite/tests/posix.test | 13 | ||||
-rw-r--r-- | test-suite/tests/threads.test | 14 |
2 files changed, 14 insertions, 13 deletions
diff --git a/test-suite/tests/posix.test b/test-suite/tests/posix.test index 79f3a92ae..9679042a6 100644 --- a/test-suite/tests/posix.test +++ b/test-suite/tests/posix.test @@ -198,16 +198,3 @@ (setaffinity (getpid) mask) (equal? mask (getaffinity (getpid)))) (throw 'unresolved)))) - -;; -;; nproc -;; - -(with-test-prefix "nproc" - - (pass-if "total-processor-count" - (>= (total-processor-count) 1)) - - (pass-if "current-processor-count" - (and (>= (current-processor-count) 1) - (>= (total-processor-count) (current-processor-count))))) diff --git a/test-suite/tests/threads.test b/test-suite/tests/threads.test index 1166247c4..db002f245 100644 --- a/test-suite/tests/threads.test +++ b/test-suite/tests/threads.test @@ -463,3 +463,17 @@ (lambda () (lock-mutex m)) (lambda key (set! success #t))) success))))) + + +;; +;; nproc +;; + +(with-test-prefix "nproc" + + (pass-if "total-processor-count" + (>= (total-processor-count) 1)) + + (pass-if "current-processor-count" + (and (>= (current-processor-count) 1) + (>= (total-processor-count) (current-processor-count))))) |