rms_prggetstats(3)
NAME
rms_prggetstats – Return resource usage information for a program
SYNOPSIS
cc [ flag ... ] file ... -lrmscall [ library ... ]
#include <rms/rmscall.h>
int rms_prggetstats(int id, prgstats_t *stats);
PARAMETERS
id Program identifier.
stats Pointer to a program statistics structure.
DESCRIPTION
rms_prggetstats() returns resource usage information for the processes of a parallel
program on the calling node. The RMS kernel module sums resource usage over the
processes in a program. The statistics returned by rms_prggetstats() are the sum
over all processes belonging to program id on this node, including those that have
already exited.
Setting id to -1 instructs the RMS kernel module to return values for the caller’s
program. Resource utilization statistics are available to the owner of the program and to
any process with administrator privileges.
/*
* program statistics
*/
typedef struct {
uint64_t etime; /* elapsed cpu time (millisecs) */
uint64_t atime; /* allocated cpu time (millisecs) */
uint64_t utime; /* user cpu time (millisecs) */
uint64_t stime; /* system cpu time (millisecs) */
int ncpus; /* number of cpus allocated */
int flags; /* program status flags */
int mem; /* max memory size in megabytes */
int pageflts /* number of page faults */
uint64_t memint; /* memory integral */
} prgstats_t;
RMS Kernel Module C-13