Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought



  getcpuid(2)                         CLIX                         getcpuid(2)



  NAME

    getcpuid - Returns a CLIPPER processor identifier

  LIBRARY

    Intergraph XIO Library (libix.a)

  SYNOPSIS

    #include <sysclip.h>
    int getcpuid(
      int *id );

  PARAMETERS

    id   Points to a CPU processor identifier.

  DESCRIPTION

    The getcpuid() function returns the CPU processor identifier from the
    CLIPPER system status word.

    Current values for processor IDs are as follows:

    Value   Processor
    _____   _________
      0       C100
      1       C200
      2       C300
      4       C400

  EXAMPLES

    To determine your machine's CPU processor identifier:

    int id;
    extern getcupid();

    id=getcpuid(&id);
    switch(id){
         case C1_R1: printf("A C100 system.\n");
                     break;
         case C2_R2: printf("A C200 system.\n");
                     break;
         case C3_R3: printf("A C300 system.\n");
                     break;
         case C4_R4: printf("A C400 system.\n");
                     break;
         default:    perror("getcpuid error");
    }



  2/94 - Intergraph Corporation                                              1






  getcpuid(2)                         CLIX                         getcpuid(2)



  RETURN VALUES

    Upon successful completion, the value of the CPU processor identifier is
    returned.  Otherwise, a value of -1 is returned and errno is set to
    indicate the error.

  ERRORS

    The getcpuid() function fails if the following is true:

    [EFAULT]
           The value of id points to a nonwritable memory address.










































  2                                              Intergraph Corporation - 2/94




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