Annotation of 41BSD/sys/h/vmclust.h, revision 1.1

1.1     ! root        1: /*     vmclust.h       4.1     11/9/80 */
        !             2: 
        !             3: /*
        !             4:  * Page clustering macros.
        !             5:  * 
        !             6:  * dirtycl(pte)                        is the page cluster dirty?
        !             7:  * anycl(pte,fld)              does any pte in the cluster has fld set?
        !             8:  * zapcl(pte,fld) = val                set all fields fld in the cluster to val
        !             9:  * distcl(pte)                 distribute high bits to cluster; note that
        !            10:  *                             distcl copies everything but pg_pfnum,
        !            11:  *                             INCLUDING pg_m!!!
        !            12:  *
        !            13:  * In all cases, pte must be the low pte in the cluster, even if
        !            14:  * the segment grows backwards (e.g. the stack).
        !            15:  */
        !            16: #define        H(pte)  ((struct hpte *)(pte))
        !            17: 
        !            18: #if CLSIZE==1
        !            19: #define        dirtycl(pte)    dirty(pte)
        !            20: #define        anycl(pte,fld)  ((pte)->fld)
        !            21: #define        zapcl(pte,fld)  (pte)->fld
        !            22: #define        distcl(pte)
        !            23: #endif
        !            24: 
        !            25: #if CLSIZE==2
        !            26: #define        dirtycl(pte)    (dirty(pte) || dirty((pte)+1))
        !            27: #define        anycl(pte,fld)  ((pte)->fld || (((pte)+1)->fld))
        !            28: #define        zapcl(pte,fld)  (pte)[1].fld = (pte)[0].fld
        !            29: #endif
        !            30: 
        !            31: #if CLSIZE==4
        !            32: #define        dirtycl(pte) \
        !            33:     (dirty(pte) || dirty((pte)+1) || dirty((pte)+2) || dirty((pte)+3))
        !            34: #define        anycl(pte,fld) \
        !            35:     ((pte)->fld || (((pte)+1)->fld) || (((pte)+2)->fld) || (((pte)+3)->fld))
        !            36: #define        zapcl(pte,fld) \
        !            37:     (pte)[3].fld = (pte)[2].fld = (pte)[1].fld = (pte)[0].fld
        !            38: #endif
        !            39: 
        !            40: #ifndef distcl
        !            41: #define        distcl(pte)     zapcl(H(pte),pg_high)
        !            42: #endif

unix.superglobalmegacorp.com

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