Use NUMPROC(NOPFD) whenever your numeric internal decimal and zoned decimal data might use nonpreferred signs.
NUMPROC option syntax .-NOPFD-. >>-NUMPROC(-+-PFD---+-)---------------------------------------->< '-MIG---'
Default is: NUMPROC(NOPFD)
Abbreviations are: None
The compiler accepts any valid sign configuration: X'A', X'B', X'C', X'D', X'E', or X'F'. NUMPROC(NOPFD) is the recommended option in most cases.
NUMPROC(PFD) improves the performance of processing numeric internal decimal and zoned decimal data. Use this option only if your program data agrees exactly with the following IBM system standards:
Zoned decimal, unsigned: High-order 4 bits of the sign byte contain X'F'.
Zoned decimal, signed overpunch: High-order 4 bits of the sign byte contain X'C' if the number is positive or 0, and X'D' if it is not.
Zoned decimal, separate sign: Separate sign contains the character '+' if the number is positive or 0, and '-' if it is not.
Internal decimal, unsigned: Low-order 4 bits of the low-order byte contain X'F'.
Internal decimal, signed: Low-order 4 bits of the low-order byte contain X'C' if the number is positive or 0, and X'D' if it is not.
Data produced by COBOL arithmetic statements conforms to the above IBM system standards. However, using REDEFINES and group moves could change data so that it no longer conforms. If you use NUMPROC(PFD), use the INITIALIZE statement to initialize data fields, rather than using group moves.
Using NUMPROC(PFD) can affect class tests for numeric data. You should use NUMPROC(NOPFD) or NUMPROC(MIG) if a COBOL program calls programs written in PL/I or FORTRAN.
Sign representation is affected not only by the NUMPROC option, but also by the installation-time option NUMCLS.
Use NUMPROC(MIG) to aid in migrating OS/VS COBOL programs to Enterprise COBOL. When NUMPROC(MIG) is in effect, the following processing occurs:
related tasks
Checking for incompatible data (numeric class test)
related references
Sign representation of zoned and packed-decimal data