source: git/omalloc/omStats.h @ 39497b

spielwiese
Last change on this file since 39497b was 13fe1b, checked in by Hans Schönemann <hannes@…>, 23 years ago
*hannes: DecAlpha-ccc-port git-svn-id: file:///usr/local/Singular/svn/trunk@5409 2c84dea3-7e68-4137-9b89-c4e89433aadc
  • Property mode set to 100644
File size: 2.3 KB
Line 
1/*******************************************************************
2 *  File:    omStats.h
3 *  Purpose: declaration of statistics related stuff
4 *  Author:  obachman (Olaf Bachmann)
5 *  Created: 11/99
6 *  Version: $Id: omStats.h,v 1.4 2001-04-30 09:02:11 Singular Exp $
7 *******************************************************************/
8#ifndef OM_STATS_H
9#define OM_STATS_H
10
11struct omInfo_s
12{
13  long MaxBytesSystem;      /* set in omUpdateInfo(), is more accurate with malloc support   */
14  long CurrentBytesSystem;  /* set in omUpdateInfo(), is more accurate with malloc support */
15  long MaxBytesSbrk;        /* always up-to-date, not very accurate, needs omInintInfo() */
16  long CurrentBytesSbrk;    /* set in omUpdateInfo(), needs omInintInfo() */
17  long MaxBytesMmap;        /* set in omUpdateInfo(), not very accurate */
18  long CurrentBytesMmap;    /* set in omUpdateInfo(), not very accurate */
19  long UsedBytes;           /* set in omUpdateInfo() */
20  long AvailBytes;          /* set in omUpdateInfo() */
21  long UsedBytesMalloc;     /* set in omUpdateInfo(), needs malloc support */
22  long AvailBytesMalloc;    /* set in omUpdateInfo(), needs malloc support */
23  long MaxBytesFromMalloc;      /* always kept up-to-date */
24  long CurrentBytesFromMalloc;  /* always kept up-to-date */
25  long MaxBytesFromValloc;      /* always kept up-to-date */
26  long CurrentBytesFromValloc;  /* always kept up-to-date */
27  long UsedBytesFromValloc; /* set in omUpdateInfo()  */
28  long AvailBytesFromValloc;/* set in omUpdateInfo()  */
29  long MaxPages;            /* always kept up-to-date */
30  long UsedPages;           /* always kept up-to-date */
31  long AvailPages;          /* always kept up-to-date */
32  long MaxRegionsAlloc;     /* always kept up-to-date */
33  long CurrentRegionsAlloc; /* always kept up-to-date */
34};
35
36/* returns a copy of omallinfo struct */
37extern struct omInfo_s omGetInfo();
38/* the struct itself which is always up-to-date */
39/* use read-only */
40extern struct omInfo_s om_Info;
41/* update the global info struct */
42extern void omUpdateInfo();
43/* initialize such that sbrk can be measured */
44extern void omInitInfo();
45extern void omPrintStats(FILE* fd);
46extern void omPrintInfo(FILE* fd);
47
48/*BEGINPRIVATE*/
49/* used internally to keep track of sbrk */
50extern unsigned long om_SbrkInit;
51/*ENDPRIVATE*/
52#endif /* OM_STATS_H */
Note: See TracBrowser for help on using the repository browser.