DataMuseum.dk

Presents historical artifacts from the history of:

Rational R1000/400 Tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about Rational R1000/400 Tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download
Index: ┃ B T

⟦02b2877c5⟧ TextFile

    Length: 3231 (0xc9f)
    Types: TextFile
    Names: »B«

Derivation

└─⟦516dceb10⟧ Bits:30000751 8mm tape, Rational 1000, RCI_VADS
    └─ ⟦9a14c9417⟧ »DATA« 
        └─⟦this⟧ 

TextFile


-- Copyright 1986, 1987, 1988 Verdix Corporation

WITH Machine_Code;
PACKAGE BODY V_Bits IS

   PRAGMA Suppress (All_Checks);
   PRAGMA Suppress (Exception_Tables);

   PROCEDURE B_And (L, R : Integer; X : OUT Integer) IS
      USE Machine_Code;
   BEGIN
      Code_2'(Move_L, L'Ref, D0);
      Code_2'(Move_L, R'Ref, D1);
      Code_2'(And_L, D0, D1);
      Code_2'(Move_L, D1, X'Ref);
   END B_And;
   PRAGMA Inline_Only (B_And);

   FUNCTION Bit_And (L, R : Integer) RETURN Integer IS
      X : Integer;
   BEGIN
      B_And (L, R, X);
      RETURN X;
   END Bit_And;
   PRAGMA Inline_Only (Bit_And);


   PROCEDURE B_Or (L, R : Integer; X : OUT Integer) IS
      USE Machine_Code;
   BEGIN
      Code_2'(Move_L, L'Ref, D0);
      Code_2'(Move_L, R'Ref, D1);
      Code_2'(Or_L, D0, D1);
      Code_2'(Move_L, D1, X'Ref);
   END B_Or;
   PRAGMA Inline_Only (B_Or);

   FUNCTION Bit_Or (L, R : Integer) RETURN Integer IS
      X : Integer;
   BEGIN
      B_Or (L, R, X);
      RETURN X;
   END Bit_Or;
   PRAGMA Inline_Only (Bit_Or);


   PROCEDURE B_Xor (L, R : Integer; X : OUT Integer) IS
      USE Machine_Code;
   BEGIN
      Code_2'(Move_L, L'Ref, D0);
      Code_2'(Move_L, R'Ref, D1);
      Code_2'(Eor_L, D0, D1);
      Code_2'(Move_L, D1, X'Ref);
   END B_Xor;
   PRAGMA Inline_Only (B_Xor);

   FUNCTION Bit_Xor (L, R : Integer) RETURN Integer IS
      X : Integer;
   BEGIN
      B_Xor (L, R, X);
      RETURN X;
   END Bit_Xor;
   PRAGMA Inline_Only (Bit_Xor);


   PROCEDURE B_Neg (L : Integer; X : OUT Integer) IS
      USE Machine_Code;
   BEGIN
      Code_2'(Move_L, L'Ref, D0);
      Code_2'(Eori_L, +(-1), D0);
      Code_2'(Move_L, D0, X'Ref);
   END B_Neg;
   PRAGMA Inline_Only (B_Neg);

   FUNCTION Bit_Neg (L : Integer) RETURN Integer IS
      X : Integer;
   BEGIN
      B_Neg (L, X);
      RETURN X;
   END Bit_Neg;
   PRAGMA Inline_Only (Bit_Neg);

   PROCEDURE B_Sra (L, Cnt : Integer; X : OUT Integer) IS
      USE Machine_Code;
   BEGIN
      Code_2'(Move_L, Cnt'Ref, D0);
      Code_2'(Move_L, L'Ref, D1);
      Code_2'(Asr_L, D0, D1);
      Code_2'(Move_L, D1, X'Ref);
   END B_Sra;
   PRAGMA Inline_Only (B_Sra);

   FUNCTION Bit_Sra (L, Cnt : Integer) RETURN Integer IS
      X : Integer;
   BEGIN
      B_Sra (L, Cnt, X);
      RETURN X;
   END Bit_Sra;
   PRAGMA Inline_Only (Bit_Sra);

   PROCEDURE B_Srl (L, Cnt : Integer; X : OUT Integer) IS
      USE Machine_Code;
   BEGIN
      Code_2'(Move_L, Cnt'Ref, D0);
      Code_2'(Move_L, L'Ref, D1);
      Code_2'(Lsr_L, D0, D1);
      Code_2'(Move_L, D1, X'Ref);
   END B_Srl;
   PRAGMA Inline_Only (B_Srl);

   FUNCTION Bit_Srl (L, Cnt : Integer) RETURN Integer IS
      X : Integer;
   BEGIN
      B_Srl (L, Cnt, X);
      RETURN X;
   END Bit_Srl;
   PRAGMA Inline_Only (Bit_Srl);

   PROCEDURE B_Sll (L, Cnt : Integer; X : OUT Integer) IS
      USE Machine_Code;
   BEGIN
      Code_2'(Move_L, Cnt'Ref, D0);
      Code_2'(Move_L, L'Ref, D1);
      Code_2'(Lsl_L, D0, D1);
      Code_2'(Move_L, D1, X'Ref);
   END B_Sll;
   PRAGMA Inline_Only (B_Sll);

   FUNCTION Bit_Sll (L, Cnt : Integer) RETURN Integer IS
      X : Integer;
   BEGIN
      B_Sll (L, Cnt, X);
      RETURN X;
   END Bit_Sll;
   PRAGMA Inline_Only (Bit_Sll);

END V_Bits;