Machine encodings on IBM i
Use this information to learn about the structure of the MDENC field in the message descriptor.
For more information about the message descriptor, see MQMD (Message descriptor) on IBM i.
The MDENC field is a 32-bit integer that is divided into four separate subfields; these subfields identify:- The encoding used for binary integers
- The encoding used for packed-decimal integers
- The encoding used for floating-point numbers
- Reserved bits
Each subfield is identified by a bit mask which has 1-bits in the positions corresponding to the subfield, and 0-bits elsewhere. The bits are numbered such that bit 0 is the most significant bit, and bit 31 the least significant bit. The following masks are defined:
- ENIMSK
- Mask for binary-integer encoding.
This subfield occupies bit positions 28 through 31 within the MDENC field.
- ENDMSK
- Mask for packed-decimal-integer encoding.
This subfield occupies bit positions 24 through 27 within the MDENC field.
- ENFMSK
- Mask for floating-point encoding.
This subfield occupies bit positions 20 through 23 within the MDENC field.
- ENRMSK
- Mask for reserved bits.
This subfield occupies bit positions 0 through 19 within the MDENC field.
- Binary-integer encoding on IBM i
Valid values for binary-integer encoding. - Packed-decimal-integer encoding on IBM i
Valid values for packed-decimal-integer encoding - Floating-point encoding on IBM i
Valid values for floating-point encoding - Constructing encodings on IBM i
To construct a value for the MDENC field in MQMD, the relevant constants that describe the required encodings should be added. - Analyzing encodings on IBM i
The MDENC field contains subfields; because of this, applications that need to examine the integer, packed decimal, or float encoding should use the technique described in this topic. - Summary of machine architecture encodings on IBM i
A table summarizing encodings for machine architectures.
Parent topic: IBM i Application Programming Reference (ILE/RPG)