--  Verada predefined library: package System (Ada RM 13.7), for a 64-bit target. An address is
--  a number of storage units. The named numbers state Verada's own limits: the integer types
--  go to 128 bits (Long_Long_Long_Integer), a modulus to 2 ** 128, a floating-point type to
--  IEEE binary64's 15 digits, an ordinary fixed-point value to 64 bits.
package System
  with Pure
is
   type Name is (Verada);

   System_Name : constant Name := Verada;

   --  the bounds of the predefined integer types: Long_Long_Long_Integer's
   Min_Int : constant := Long_Long_Long_Integer'First;
   Max_Int : constant := Long_Long_Long_Integer'Last;

   --  the largest modulus of a modular type, and of one whose modulus is not a power of two
   Max_Binary_Modulus : constant := 2 ** 128;
   Max_Nonbinary_Modulus : constant := 2 ** 64 - 1;

   --  the most digits of a floating-point type, with or without a range (binary64)
   Max_Base_Digits : constant := 15;
   Max_Digits : constant := 15;

   --  the binary digits of an ordinary fixed-point value, and the finest delta of one
   --  whose range is -1.0 .. 1.0
   Max_Mantissa : constant := 63;
   Fine_Delta : constant := 2.0 ** (-63);

   --  the clock's step, in seconds: Ada.Real_Time's nanosecond
   Tick : constant := 0.000_000_001;

   Storage_Unit : constant := 8;
   Word_Size : constant := 64;
   Memory_Size : constant := 2 ** 64;

   type Address is mod Memory_Size;

   Null_Address : constant Address := 0;

   --  the order of bits in a storage unit (RM 13.5.3): this target's is little-endian
   type Bit_Order is (High_Order_First, Low_Order_First);
   Default_Bit_Order : constant Bit_Order := Low_Order_First;

   --  priorities (RM D.1), as GNAT's on this target
   subtype Any_Priority is Integer range 0 .. 98;
   subtype Priority is Any_Priority range 0 .. 97;
   subtype Interrupt_Priority is Any_Priority range 98 .. 98;

   Default_Priority : constant Priority := 48;
end System;
