May 2015
Intermediate to advanced
296 pages
5h 10m
English
If the instructions need to be specific for how they are encoded with respect to bit fields, this can be done by specifying the bit field in the .td file when defining an instruction.
To include instruction encoding while defining instructions, proceed with the following steps:
add instruction will have some defined encoding for its instruction. The size of the instruction is 32 bits, and the encoding for it is as follows:bits 0 to 3 -> src2, second register operand bits 4 to 11 -> all zeros bits 12 to 15 -> dst, for destination register bits 16 to 19 -> src1, first register operand bit 20 -> zero bit 21 to 24 -> for opcode bit 25 to 27 -> all zeros bit ...
Read now
Unlock full access