Annotation of coherent/d/usr/lib/misc/larges.h, revision 1.1

1.1     ! root        1: /* larges.h */
        !             2: /* Model-dependent definitions for i8086 assembler sources. */
        !             3: 
        !             4: #ifndef        LARGES_H
        !             5: #define        LARGES_H
        !             6: 
        !             7: #if    LARGE
        !             8: #define        LARGECODE 1
        !             9: #define LARGEDATA 1
        !            10: #endif
        !            11: 
        !            12: #if    LARGECODE
        !            13: /* LARGE code: calls, jumps and returns are far, code pointer is 4 bytes. */
        !            14: #define        Gcall   xcall
        !            15: #define Gicall xicall
        !            16: #define Gijmp  xijmp
        !            17: #define        Gjmp    xjmp
        !            18: #define Gptr   .dword
        !            19: #define        Gret    xret
        !            20: #define        CPL     4
        !            21: #else
        !            22: /* SMALL code: calls, jumps and returns are near, code pointer is 2 bytes. */
        !            23: #define        Gcall   call
        !            24: #define Gicall icall
        !            25: #define Gijmp  ijmp
        !            26: #define Gjmp   jmp
        !            27: #define Gptr   .word
        !            28: #define        Gret    ret
        !            29: #define        CPL     2
        !            30: #endif
        !            31: 
        !            32: #if    LARGEDATA
        !            33: /* LARGE data: segment registers must be loaded to map data, escapes required. */
        !            34: /* Data pointer is 4 bytes. */
        !            35: #define Gdptr  .dword
        !            36: #define        Lds     lds
        !            37: #define        Les     les
        !            38: #define        Map(sreg, temp, val)    mov     temp, val;      mov     sreg, temp
        !            39: #define        Pes     es:
        !            40: #define        Pss     ss:
        !            41: #define        DPL     4
        !            42: #else
        !            43: /* SMALL data: DS==ES==SS, no escapes required. */
        !            44: /* Data pointer is 2 bytes. */
        !            45: #define Gdptr  .word
        !            46: #define        Lds     mov
        !            47: #define Les    mov
        !            48: #define        Map(sreg, temp, val)
        !            49: #define        Pes
        !            50: #define        Pss
        !            51: #define        DPL     2
        !            52: #endif
        !            53: 
        !            54: /* Function entry and exit: preserve C register variables, initialize BP. */
        !            55: /* No automatics allocated. */
        !            56: #define Enter(x)       .globl x; x: push si; push di; push bp; mov bp, sp
        !            57: #define Leave          pop bp; pop di; pop si; Gret
        !            58: #define LEFTARG        CPL+6
        !            59: 
        !            60: #define        RASIZE  CPL
        !            61: #define        PTRSIZE DPL
        !            62: 
        !            63: #endif

unix.superglobalmegacorp.com

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