Back to index

glibc  2.9
Classes | Defines | Typedefs | Enumerations
resource.h File Reference
#include <bits/types.h>
#include <bits/time.h>

Go to the source code of this file.

Classes

struct  rlimit
struct  rusage

Defines

#define RLIMIT_CPU   RLIMIT_CPU
#define RLIMIT_FSIZE   RLIMIT_FSIZE
#define RLIMIT_DATA   RLIMIT_DATA
#define RLIMIT_STACK   RLIMIT_STACK
#define RLIMIT_CORE   RLIMIT_CORE
#define RLIMIT_RSS   __RLIMIT_RSS
#define RLIMIT_NOFILE   RLIMIT_NOFILE
#define RLIMIT_OFILE   __RLIMIT_OFILE
#define RLIMIT_AS   RLIMIT_AS
#define RLIMIT_NPROC   __RLIMIT_NPROC
#define RLIMIT_MEMLOCK   __RLIMIT_MEMLOCK
#define RLIMIT_LOCKS   __RLIMIT_LOCKS
#define RLIMIT_SIGPENDING   __RLIMIT_SIGPENDING
#define RLIMIT_MSGQUEUE   __RLIMIT_MSGQUEUE
#define RLIMIT_NICE   __RLIMIT_NICE
#define RLIMIT_RTPRIO   __RLIMIT_RTPRIO
#define RLIMIT_NLIMITS   __RLIMIT_NLIMITS
#define RLIM_NLIMITS   __RLIM_NLIMITS
#define RLIM_INFINITY   ((unsigned long int)(~0UL))
#define RLIM_SAVED_MAX   RLIM_INFINITY
#define RLIM_SAVED_CUR   RLIM_INFINITY
#define RUSAGE_SELF   RUSAGE_SELF
#define RUSAGE_CHILDREN   RUSAGE_CHILDREN
#define __need_timeval
#define PRIO_MIN   -20 /* Minimum priority a process can have. */
#define PRIO_MAX   20 /* Maximum priority a process can have. */
#define PRIO_PROCESS   PRIO_PROCESS
#define PRIO_PGRP   PRIO_PGRP
#define PRIO_USER   PRIO_USER

Typedefs

typedef __rlim_t rlim_t

Enumerations

enum  __rlimit_resource {
  RLIMIT_CPU, RLIMIT_CPU, RLIMIT_FSIZE, RLIMIT_FSIZE,
  RLIMIT_DATA, RLIMIT_DATA, RLIMIT_STACK, RLIMIT_STACK,
  RLIMIT_CORE, RLIMIT_CORE, RLIMIT_RSS, RLIMIT_RSS,
  RLIMIT_MEMLOCK, RLIMIT_MEMLOCK, RLIMIT_NPROC, RLIMIT_NPROC,
  RLIMIT_OFILE, RLIMIT_NOFILE = RLIMIT_OFILE, RLIMIT_OFILE, RLIMIT_NOFILE = RLIMIT_OFILE,
  RLIMIT_SBSIZE, RLIMIT_SBSIZE, RLIMIT_AS, RLIMIT_VMEM = RLIMIT_AS,
  RLIMIT_AS, RLIMIT_VMEM = RLIMIT_AS, RLIMIT_NLIMITS, RLIM_NLIMITS = RLIMIT_NLIMITS,
  RLIMIT_CPU, RLIMIT_CPU, RLIMIT_FSIZE, RLIMIT_FSIZE,
  RLIMIT_DATA, RLIMIT_DATA, RLIMIT_STACK, RLIMIT_STACK,
  RLIMIT_CORE, RLIMIT_CORE, RLIMIT_RSS, RLIMIT_RSS,
  RLIMIT_NOFILE, RLIMIT_OFILE = RLIMIT_NOFILE, RLIMIT_NOFILE, RLIMIT_OFILE = RLIMIT_NOFILE,
  RLIM_NLIMITS, RLIMIT_CPU = 0, RLIMIT_CPU = 0, RLIMIT_FSIZE = 1,
  RLIMIT_FSIZE = 1, RLIMIT_DATA = 2, RLIMIT_DATA = 2, RLIMIT_STACK = 3,
  RLIMIT_STACK = 3, RLIMIT_CORE = 4, RLIMIT_CORE = 4, RLIMIT_RSS = 5,
  RLIMIT_RSS = 5, RLIMIT_AS = 6, RLIMIT_AS = 6, RLIMIT_NOFILE = 7,
  RLIMIT_OFILE = RLIMIT_NOFILE, RLIMIT_NOFILE = 7, RLIMIT_OFILE = RLIMIT_NOFILE, RLIM_NLIMITS,
  RLIMIT_CPU = 0, RLIMIT_CPU = 0, RLIMIT_FSIZE = 1, RLIMIT_FSIZE = 1,
  RLIMIT_DATA = 2, RLIMIT_DATA = 2, RLIMIT_STACK = 3, RLIMIT_STACK = 3,
  RLIMIT_CORE = 4, RLIMIT_CORE = 4, __RLIMIT_RSS = 7, RLIMIT_NOFILE = 5,
  __RLIMIT_OFILE = RLIMIT_NOFILE, RLIMIT_NOFILE = 5, RLIMIT_AS = 6, RLIMIT_AS = 6,
  __RLIMIT_NPROC = 8, __RLIMIT_MEMLOCK = 9, __RLIMIT_LOCKS = 10, __RLIMIT_SIGPENDING = 11,
  __RLIMIT_MSGQUEUE = 12, __RLIMIT_NICE = 13, __RLIMIT_RTPRIO = 14, __RLIMIT_NLIMITS = 15,
  __RLIM_NLIMITS, RLIMIT_CPU = 0, RLIMIT_CPU = 0, RLIMIT_FSIZE = 1,
  RLIMIT_FSIZE = 1, RLIMIT_DATA = 2, RLIMIT_DATA = 2, RLIMIT_STACK = 3,
  RLIMIT_STACK = 3, RLIMIT_CORE = 4, RLIMIT_CORE = 4, __RLIMIT_RSS = 5,
  RLIMIT_NOFILE = 6, __RLIMIT_OFILE = RLIMIT_NOFILE, RLIMIT_NOFILE = 6, RLIMIT_AS = 7,
  RLIMIT_AS = 7, __RLIMIT_NPROC = 8, __RLIMIT_MEMLOCK = 9, __RLIMIT_LOCKS = 10,
  __RLIMIT_SIGPENDING = 11, __RLIMIT_MSGQUEUE = 12, __RLIMIT_NICE = 13, __RLIMIT_RTPRIO = 14,
  __RLIMIT_NLIMITS = 15, __RLIM_NLIMITS, RLIMIT_CPU = 0, RLIMIT_CPU = 0,
  RLIMIT_FSIZE = 1, RLIMIT_FSIZE = 1, RLIMIT_DATA = 2, RLIMIT_DATA = 2,
  RLIMIT_STACK = 3, RLIMIT_STACK = 3, RLIMIT_CORE = 4, RLIMIT_CORE = 4,
  __RLIMIT_RSS = 5, RLIMIT_NOFILE = 7, __RLIMIT_OFILE = RLIMIT_NOFILE, RLIMIT_NOFILE = 7,
  RLIMIT_AS = 9, RLIMIT_AS = 9, __RLIMIT_NPROC = 6, __RLIMIT_MEMLOCK = 8,
  __RLIMIT_LOCKS = 10, __RLIMIT_SIGPENDING = 11, __RLIMIT_MSGQUEUE = 12, __RLIMIT_NICE = 13,
  __RLIMIT_RTPRIO = 14, __RLIMIT_NLIMITS = 15, __RLIM_NLIMITS, RLIMIT_CPU = 0,
  RLIMIT_CPU = 0, RLIMIT_FSIZE = 1, RLIMIT_FSIZE = 1, RLIMIT_DATA = 2,
  RLIMIT_DATA = 2, RLIMIT_STACK = 3, RLIMIT_STACK = 3, RLIMIT_CORE = 4,
  RLIMIT_CORE = 4, __RLIMIT_RSS = 5, RLIMIT_NOFILE = 6, __RLIMIT_OFILE = RLIMIT_NOFILE,
  RLIMIT_NOFILE = 6, RLIMIT_AS = 9, RLIMIT_AS = 9, __RLIMIT_NPROC = 7,
  __RLIMIT_MEMLOCK = 8, __RLIMIT_LOCKS = 10, __RLIMIT_SIGPENDING = 11, __RLIMIT_MSGQUEUE = 12,
  __RLIMIT_NICE = 13, __RLIMIT_RTPRIO = 14, __RLIMIT_NLIMITS = 15, __RLIM_NLIMITS
}
enum  __rusage_who {
  RUSAGE_SELF = 0, RUSAGE_SELF = 0, RUSAGE_CHILDREN, RUSAGE_SELF = 0,
  RUSAGE_SELF = 0, RUSAGE_CHILDREN, RUSAGE_SELF = 0, RUSAGE_SELF = 0,
  RUSAGE_CHILDREN, RUSAGE_SELF = 0, RUSAGE_SELF = 0, RUSAGE_CHILDREN = -1,
  RUSAGE_CHILDREN = -1, RUSAGE_SELF = 0, RUSAGE_SELF = 0, RUSAGE_CHILDREN = -1,
  RUSAGE_CHILDREN = -1, RUSAGE_SELF = 0, RUSAGE_SELF = 0, RUSAGE_CHILDREN = -1,
  RUSAGE_CHILDREN = -1, RUSAGE_SELF = 0, RUSAGE_SELF = 0, RUSAGE_CHILDREN = -1,
  RUSAGE_CHILDREN = -1
}
enum  __priority_which {
  PRIO_PROCESS = 0, PRIO_PGRP = 1, PRIO_USER = 2, PRIO_PROCESS = 0,
  PRIO_PGRP = 1, PRIO_USER = 2, PRIO_PROCESS = 0, PRIO_PROCESS = 0,
  PRIO_PGRP = 1, PRIO_PGRP = 1, PRIO_USER, PRIO_PROCESS = 0,
  PRIO_PROCESS = 0, PRIO_PGRP = 1, PRIO_PGRP = 1, PRIO_USER,
  PRIO_PROCESS = 0, PRIO_PROCESS = 0, PRIO_PGRP = 1, PRIO_PGRP = 1,
  PRIO_USER, PRIO_PROCESS = 0, PRIO_PROCESS = 0, PRIO_PGRP = 1,
  PRIO_PGRP = 1, PRIO_USER, PRIO_PROCESS = 0, PRIO_PROCESS = 0,
  PRIO_PGRP = 1, PRIO_PGRP = 1, PRIO_USER
}

Class Documentation

struct rlimit

Definition at line 101 of file resource.h.

Class Members
rlim_t rlim_cur
rlim_t rlim_max
struct rusage

Definition at line 137 of file resource.h.

Class Members
long int ru_idrss
long int ru_inblock
long int ru_isrss
long int ru_ixrss
long int ru_majflt
long int ru_maxrss
long int ru_minflt
long int ru_msgrcv
long int ru_msgsnd
long int ru_nivcsw
long int ru_nsignals
long int ru_nswap
long int ru_nvcsw
long int ru_oublock

Define Documentation

#define __need_timeval

Definition at line 173 of file resource.h.

#define PRIO_MAX   20 /* Maximum priority a process can have. */

Definition at line 221 of file resource.h.

#define PRIO_MIN   -20 /* Minimum priority a process can have. */

Definition at line 220 of file resource.h.

#define PRIO_PGRP   PRIO_PGRP

Definition at line 230 of file resource.h.

#define PRIO_PROCESS   PRIO_PROCESS

Definition at line 228 of file resource.h.

#define PRIO_USER   PRIO_USER
#define RLIM_INFINITY   ((unsigned long int)(~0UL))

Definition at line 111 of file resource.h.

Definition at line 122 of file resource.h.

Definition at line 121 of file resource.h.

#define RLIMIT_AS   RLIMIT_AS

Definition at line 70 of file resource.h.

#define RLIMIT_CORE   RLIMIT_CORE

Definition at line 53 of file resource.h.

#define RLIMIT_CPU   RLIMIT_CPU

Definition at line 37 of file resource.h.

#define RLIMIT_DATA   RLIMIT_DATA

Definition at line 45 of file resource.h.

#define RLIMIT_FSIZE   RLIMIT_FSIZE

Definition at line 41 of file resource.h.

Definition at line 82 of file resource.h.

Definition at line 78 of file resource.h.

Definition at line 90 of file resource.h.

#define RLIMIT_NICE   __RLIMIT_NICE

Definition at line 96 of file resource.h.

Definition at line 65 of file resource.h.

Definition at line 74 of file resource.h.

Definition at line 66 of file resource.h.

#define RLIMIT_RSS   __RLIMIT_RSS

Definition at line 60 of file resource.h.

Definition at line 101 of file resource.h.

Definition at line 86 of file resource.h.

#define RLIMIT_STACK   RLIMIT_STACK

Definition at line 49 of file resource.h.

Definition at line 162 of file resource.h.

#define RUSAGE_SELF   RUSAGE_SELF

Definition at line 158 of file resource.h.


Typedef Documentation

typedef __rlim_t rlim_t

Definition at line 127 of file resource.h.


Enumeration Type Documentation

Enumerator:
PRIO_PROCESS 
PRIO_PGRP 
PRIO_USER 
PRIO_PROCESS 
PRIO_PGRP 
PRIO_USER 
PRIO_PROCESS 
PRIO_PROCESS 
PRIO_PGRP 
PRIO_PGRP 
PRIO_USER 
PRIO_PROCESS 
PRIO_PROCESS 
PRIO_PGRP 
PRIO_PGRP 
PRIO_USER 
PRIO_PROCESS 
PRIO_PROCESS 
PRIO_PGRP 
PRIO_PGRP 
PRIO_USER 
PRIO_PROCESS 
PRIO_PROCESS 
PRIO_PGRP 
PRIO_PGRP 
PRIO_USER 
PRIO_PROCESS 
PRIO_PROCESS 
PRIO_PGRP 
PRIO_PGRP 
PRIO_USER 

Definition at line 225 of file resource.h.

{
  PRIO_PROCESS = 0,         /* WHO is a process ID.  */
#define PRIO_PROCESS PRIO_PROCESS
  PRIO_PGRP = 1,            /* WHO is a process group ID.  */
#define PRIO_PGRP PRIO_PGRP
  PRIO_USER = 2                    /* WHO is a user ID.  */
#define PRIO_USER PRIO_USER
};
Enumerator:
RLIMIT_CPU 
RLIMIT_CPU 
RLIMIT_FSIZE 
RLIMIT_FSIZE 
RLIMIT_DATA 
RLIMIT_DATA 
RLIMIT_STACK 
RLIMIT_STACK 
RLIMIT_CORE 
RLIMIT_CORE 
RLIMIT_RSS 
RLIMIT_RSS 
RLIMIT_MEMLOCK 
RLIMIT_MEMLOCK 
RLIMIT_NPROC 
RLIMIT_NPROC 
RLIMIT_OFILE 
RLIMIT_NOFILE 
RLIMIT_OFILE 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 
RLIMIT_CORE 
__RLIMIT_RSS 
RLIMIT_NOFILE 
__RLIMIT_OFILE 
RLIMIT_NOFILE 
RLIMIT_AS 
RLIMIT_AS 
__RLIMIT_NPROC 
__RLIMIT_MEMLOCK 
__RLIMIT_LOCKS 
__RLIMIT_SIGPENDING 
__RLIMIT_MSGQUEUE 
__RLIMIT_NICE 
__RLIMIT_RTPRIO 
__RLIMIT_NLIMITS 
__RLIM_NLIMITS 
RLIMIT_CPU 
RLIMIT_CPU 
RLIMIT_FSIZE 
RLIMIT_FSIZE 
RLIMIT_DATA 
RLIMIT_DATA 
RLIMIT_STACK 
RLIMIT_STACK 
RLIMIT_CORE 
RLIMIT_CORE 
__RLIMIT_RSS 
RLIMIT_NOFILE 
__RLIMIT_OFILE 
RLIMIT_NOFILE 
RLIMIT_AS 
RLIMIT_AS 
__RLIMIT_NPROC 
__RLIMIT_MEMLOCK 
__RLIMIT_LOCKS 
__RLIMIT_SIGPENDING 
__RLIMIT_MSGQUEUE 
__RLIMIT_NICE 
__RLIMIT_RTPRIO 
__RLIMIT_NLIMITS 
__RLIM_NLIMITS 
RLIMIT_CPU 
RLIMIT_CPU 
RLIMIT_FSIZE 
RLIMIT_FSIZE 
RLIMIT_DATA 
RLIMIT_DATA 
RLIMIT_STACK 
RLIMIT_STACK 
RLIMIT_CORE 
RLIMIT_CORE 
__RLIMIT_RSS 
RLIMIT_NOFILE 
__RLIMIT_OFILE 
RLIMIT_NOFILE 
RLIMIT_AS 
RLIMIT_AS 
__RLIMIT_NPROC 
__RLIMIT_MEMLOCK 
__RLIMIT_LOCKS 
__RLIMIT_SIGPENDING 
__RLIMIT_MSGQUEUE 
__RLIMIT_NICE 
__RLIMIT_RTPRIO 
__RLIMIT_NLIMITS 
__RLIM_NLIMITS 

Definition at line 33 of file resource.h.

{
  /* Per-process CPU limit, in seconds.  */
  RLIMIT_CPU = 0,
#define RLIMIT_CPU RLIMIT_CPU

  /* Largest file that can be created, in bytes.  */
  RLIMIT_FSIZE = 1,
#define       RLIMIT_FSIZE RLIMIT_FSIZE

  /* Maximum size of data segment, in bytes.  */
  RLIMIT_DATA = 2,
#define       RLIMIT_DATA RLIMIT_DATA

  /* Maximum size of stack segment, in bytes.  */
  RLIMIT_STACK = 3,
#define       RLIMIT_STACK RLIMIT_STACK

  /* Largest core file that can be created, in bytes.  */
  RLIMIT_CORE = 4,
#define       RLIMIT_CORE RLIMIT_CORE

  /* Largest resident set size, in bytes.
     This affects swapping; processes that are exceeding their
     resident set size will be more likely to have physical memory
     taken from them.  */
  __RLIMIT_RSS = 5,
#define       RLIMIT_RSS __RLIMIT_RSS

  /* Number of open files.  */
  RLIMIT_NOFILE = 7,
  __RLIMIT_OFILE = RLIMIT_NOFILE, /* BSD name for same.  */
#define RLIMIT_NOFILE RLIMIT_NOFILE
#define RLIMIT_OFILE __RLIMIT_OFILE

  /* Address space limit.  */
  RLIMIT_AS = 9,
#define RLIMIT_AS RLIMIT_AS

  /* Number of processes.  */
  __RLIMIT_NPROC = 6,
#define RLIMIT_NPROC __RLIMIT_NPROC

  /* Locked-in-memory address space.  */
  __RLIMIT_MEMLOCK = 8,
#define RLIMIT_MEMLOCK __RLIMIT_MEMLOCK

  /* Maximum number of file locks.  */
  __RLIMIT_LOCKS = 10,
#define RLIMIT_LOCKS __RLIMIT_LOCKS

  /* Maximum number of pending signals.  */
  __RLIMIT_SIGPENDING = 11,
#define RLIMIT_SIGPENDING __RLIMIT_SIGPENDING

  /* Maximum bytes in POSIX message queues.  */
  __RLIMIT_MSGQUEUE = 12,
#define RLIMIT_MSGQUEUE __RLIMIT_MSGQUEUE

  /* Maximum nice priority allowed to raise to.
     Nice levels 19 .. -20 correspond to 0 .. 39
     values of this resource limit.  */
  __RLIMIT_NICE = 13,
#define RLIMIT_NICE __RLIMIT_NICE

  /* Maximum realtime priority allowed for non-priviledged
     processes.  */
  __RLIMIT_RTPRIO = 14,
#define RLIMIT_RTPRIO __RLIMIT_RTPRIO

  __RLIMIT_NLIMITS = 15,
  __RLIM_NLIMITS = __RLIMIT_NLIMITS
#define RLIMIT_NLIMITS __RLIMIT_NLIMITS
#define RLIM_NLIMITS __RLIM_NLIMITS
};
Enumerator:
RUSAGE_SELF 
RUSAGE_SELF 
RUSAGE_CHILDREN 
RUSAGE_SELF 
RUSAGE_SELF 
RUSAGE_CHILDREN 
RUSAGE_SELF 
RUSAGE_SELF 
RUSAGE_CHILDREN 
RUSAGE_SELF 
RUSAGE_SELF 
RUSAGE_CHILDREN 
RUSAGE_CHILDREN 
RUSAGE_SELF 
RUSAGE_SELF 
RUSAGE_CHILDREN 
RUSAGE_CHILDREN 
RUSAGE_SELF 
RUSAGE_SELF 
RUSAGE_CHILDREN 
RUSAGE_CHILDREN 
RUSAGE_SELF 
RUSAGE_SELF 
RUSAGE_CHILDREN 
RUSAGE_CHILDREN 

Definition at line 154 of file resource.h.

{
  /* The calling process.  */
  RUSAGE_SELF = 0,
#define RUSAGE_SELF RUSAGE_SELF

  /* All of its terminated child processes.  */
  RUSAGE_CHILDREN = -1,
#define RUSAGE_CHILDREN RUSAGE_CHILDREN

#ifdef __USE_GNU
  /* The calling thread.  */
  RUSAGE_THREAD = 1
# define RUSAGE_THREAD RUSAGE_THREAD
  /* Name for the same functionality on Solaris.  */
# define RUSAGE_LWP RUSAGE_THREAD
#endif
};