Header And Logo

PostgreSQL
| The world's most advanced open source database.

rusagestub.h

Go to the documentation of this file.
00001 /*-------------------------------------------------------------------------
00002  *
00003  * rusagestub.h
00004  *    Stubs for getrusage(3).
00005  *
00006  *
00007  * Portions Copyright (c) 1996-2013, PostgreSQL Global Development Group
00008  * Portions Copyright (c) 1994, Regents of the University of California
00009  *
00010  * src/include/rusagestub.h
00011  *
00012  *-------------------------------------------------------------------------
00013  */
00014 #ifndef RUSAGESTUB_H
00015 #define RUSAGESTUB_H
00016 
00017 #include <sys/time.h>           /* for struct timeval */
00018 #ifndef WIN32
00019 #include <sys/times.h>          /* for struct tms */
00020 #endif
00021 #include <limits.h>             /* for CLK_TCK */
00022 
00023 #define RUSAGE_SELF     0
00024 #define RUSAGE_CHILDREN (-1)
00025 
00026 struct rusage
00027 {
00028     struct timeval ru_utime;    /* user time used */
00029     struct timeval ru_stime;    /* system time used */
00030 };
00031 
00032 extern int  getrusage(int who, struct rusage * rusage);
00033 
00034 #endif   /* RUSAGESTUB_H */