How comp, comp-1 ... comp-5 are implemented is implementation dependent.
Format Normal Implementation
Comp Big endian binary integer
Comp-1 4 byte floating point
Comp-2 8 byte floating point
Comp-3 Packed decimal 123 is stored as x'123c'
Comp-5 Binary Integer optermised for performance.
Big Endian on the Mainframe, Little Endian on Intel Hardware
Ibm Compilers normally support Comp, Comp-4, Comp-5 in sizes of 2,4,8 bytes. GNU Cobolo support sizes of 1,2,4,8.
Comp-1, Comp-2 fields are defined without a picture clause:
03 Floating-Field Comp-1.
03 Double-Field Comp-2
For other Comp's are picture is entered:
03 Big-Endian Pic S9(4) Comp.
03 Packed-Decimal Pic S9(5) Comp.