Annotation of coherent/a/usr/include.b4ps2/mon.h, revision 1.1.1.1

1.1       root        1: /* (-lgl
                      2:  *     COHERENT Version 4.0
                      3:  *     Copyright (c) 1982, 1992 by Mark Williams Company.
                      4:  *     All rights reserved. May not be copied without permission.
                      5:  -lgl) */
                      6: /*
                      7:  * mon.h
                      8:  * Program profiling (monitor) header.
                      9:  *
                     10:  * A call to monitor() creates a mon.out file structured as follows:
                     11:  *     header                  struct m_hdr
                     12:  *     function count array    struct m_func[m_nfuncs]
                     13:  *     profil buffer           short[m_nbins]
                     14:  * The profil data scales the pc as follows:
                     15:  *     bin number = (pc - low pc) * (scale/2) / (1<<16)
                     16:  */
                     17: 
                     18: #ifndef        _MON_H
                     19: #define        _MON_H
                     20: 
                     21: #include <sys/types.h>
                     22: 
                     23: #ifndef NULL
                     24: #define        NULL    ((char *)0)
                     25: #endif
                     26: 
                     27: struct m_hdr   {
                     28:        unsigned short  m_nbins;        /* number of bins               */
                     29:        unsigned short  m_scale;        /* scale factor                 */
                     30:        unsigned short  m_nfuncs;       /* number of function counts    */
                     31:        vaddr_t         m_lowpc;        /* lowest pc to monitor         */
                     32:        vaddr_t         m_lowsp;        /* lowest sp in scount          */
                     33:        vaddr_t         m_hisp;         /* highest sp in scount         */
                     34: };
                     35: 
                     36: struct m_func  {
                     37:        vaddr_t         m_addr;         /* address in function          */
                     38:        long            m_ncalls;       /* number of times function called */
                     39: };
                     40: 
                     41: /*
                     42:  * The C compiler allocates an m_flst structure for each function
                     43:  * compiled with the -VPROF option.
                     44:  */
                     45: struct m_flst  {
                     46:        struct  m_func  m_data;         /* data on this function        */
                     47:        struct  m_flst  *m_link;        /* link to next function in list */
                     48: };
                     49: 
                     50: #endif
                     51: 
                     52: /* end of mon.h */

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.