Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ getsb(3C) — DG/UX 4.00

Media Vault

Software Library

Restoration Projects

Artifacts Sought



                                                                getsb(3C)



        _________________________________________________________________
        getsb                                           $builtin function
        Return the current stack base pointer.
        _________________________________________________________________


        Calling Sequence

        #include <dglib.h>
        short int *getsb(), *curwsb;
        curwsb = getsb();

        (or)

        $builtin short *getsb();
        short int *curwsb;
        curwsb = getsb();


        Description

        Use the getsb function to retrieve the value stored at the wide
        stack base (WSB).  The first version of the calling sequence
        noted above uses a function call.  The second might generate
        smaller or faster code, but might not run under other C
        compilers.


        Returns

        The getsb function returns a pointer to the value.


        Related Functions

        See also the getsl and getsp functions.


        Example

        /* Program test for the getsb() function */

        #include <stdio.h>
        #include <dglib.h>

        short int  *curwsb, *getsb();

        main() {
            printf("Value at WSB = %o.\n", curwsb = getsb());
        }




        DG/UX 4.00                                                 Page 1
               Licensed material--property of copyright holder(s)





                                                                getsb(3C)



        A call to the program test generates the output

        Value at WSB = 16000012504.

        (This value will vary.)

















































        DG/UX 4.00                                                 Page 2
               Licensed material--property of copyright holder(s)



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026