Bound program access |
---|
|
Translates the data specified by source string into the receiver. Translate length specifies the number of bytes to translate. Each byte of the source string is translated using the corresponding entry in the translation table specified by translate table.
Contrast this operation with XLATEB, which does not support overlapping operands.
Bytes are translated as follows:
The translation table is exactly 256 bytes in length and specifies the translated values for the 256 possible byte values. The results are undefined if the table is less than 256 bytes.
If receiver overlaps with source string and/or translate table, the overlapped operands are updated for every byte translated. The operation proceeds from left to right, one byte at a time. The following example shows the results of an overlapped operands translate operation. Receiver, source string, and translate table are coincident, with a value of hex 050403020103.
Hex 050403020103 - Initial value
Hex 030403020103 - After the 1st character is translated
Hex 030103020103 - After the 2nd character is translated
Hex 030102020103 - After the 3rd character is translated
Hex 030102020103 - After the 4th character is translated
Hex 030102020103 - After the 5th character is translated
Hex 030102020102 - After the 6th character, the final result
06 Addressing
08 Argument/Parameter
22 Object Access
24 Pointer Specification
44 Protection Violation