CPU ID definition
During the assembly process the assembler determines the smallest instruction set containing all the instructions and gives a CPU ID value indicating the instruction set.
During the assembly process the assembler determines which instruction set (from a list of several complete instruction sets defined in the architectures or processor implementations) is the smallest instruction set containing all the instructions used in the program. The program is given a CPU ID value indicating this instruction set. Therefore a CPU ID indicates the target environment on which the object code can be run. The CPU ID value for the program is an assembler output value included in the XCOFF object file generated by the assembler.
CPU ID can have the following values:
Value | Description |
---|---|
com | All instructions used in the program are in the PowerPC® and POWER® family architecture intersection. (The com instruction set is the smallest instruction set.) |
ppc | All instructions used in the program are in the PowerPC® architecture, 32-bit mode, but the program does not satisfy the conditions for CPU ID value com. (The ppc instruction set is a superset of the com instruction set.) |
pwr | All instructions used in the program are in the POWER® family architecture, POWER® family implementation, but the program does not satisfy the conditions for CPU ID value com. (The pwr instruction set is a superset of the com instruction set.) |
pwr2 | All instructions used in the program are in the POWER® family architecture, POWER2™ implementation, but the program does not satisfy the conditions for CPU ID values com, ppc, or pwr. (The pwr2 instruction set is a superset of the pwr instruction set.) |
any | The program contains a mixture of instructions from the valid architectures or implementations, or contains implementation-unique instructions.The program does not satisfy the conditions for CPU ID values com, ppc, pwr, or pwr2. (The any instruction set is the largest instruction set.) |
The assembler output value CPU ID is not the same thing as the assembly mode. The assembly mode (determined by the -m flag of the as command and by use of the .machine pseudo-op in the program) determines which instructions the assembler accepts without errors or warnings. The CPU ID is an output value indicating which instructions are actually used.
In the output XCOFF file, the CPU ID is stored in the low-order byte of the n_type field in a symbol table entry with the C_FILE storage class. The following list shows the low-order byte values and corresponding CPU IDs:
Low-Order Byte | CPU ID |
---|---|
0 | Not a defined value. An invalid value or object was assembled prior to definition of the CPU-ID field. |
1 | ppc |
2 | ppc64 |
3 | com |
4 | pwr |
5 | any |
6 | 601 |
7 | 603 |
8 | 604 |
10 | power |
16 | 620 |
17 | A35 |
18 | pwr5 |
19 | ppc970 or 970 |
20 | pwr6 |
21 | vec |
22 | pwr5x |
23 | pwr6e |
24 | pwr7 |
25 | pwr8 |
26 | pwr9 |
27 | pwr10 |
224 | pwr2 or pwrx |