available_threads


NAME

available_threads - returns information about current thread usage


SYNOPSIS

  SUBROUTINE AVAILABLE_THREADS( NTOTAL, NUSING)
  INTEGER NTOTAL, NUSING
 
  SUBROUTINE AVAILABLE_THREADS_64( NTOTAL, NUSING)
  INTEGER*8 NTOTAL, NUSING
 

F95 INTERFACE

  SUBROUTINE AVAILABLE_THREADS( NTOTAL, NUSING)
  INTEGER :: NTOTAL, NUSING
 
  SUBROUTINE AVAILABLE_THREADS_64( NTOTAL, NUSING)
  INTEGER(8) :: NTOTAL, NUSING
 

C INTERFACE

#include <sunperf.h>

void available_threads(int *ntotal, int *nusing);

void available_threads_64(long *ntotal, long *nusing);


PURPOSE

available_threads threads returns NTOTAL, which is the total number of CPUs available to the job (generally the number of CPUs presently on-line in the partition), and NUSING, which is the sum of the current Use numbers for all threads specified in USE_THREADS. If NTOTAL < NUSING then the system is potentially overcommitted.


ARGUMENTS

* NTOTAL (output)
Total number of CPUs available.

* NUSING (output)
Sum of current Use numbers for all threads specified in USE_THREADS.