[patch 1/4] update nios2 opcodes interface

Sandra Loosemore sandra@codesourcery.com
Thu Oct 23 03:24:00 GMT 2014


This patch implements changes to the nios2 opcodes interface intended to 
support the future addition of new instruction formats and encodings.

The major changes here are:

- Everything specific to the original Nios II instruction formats and 
encoding now includes "R1" in the name, and all the defines have has 
been moved to their own .h file.

- The format of each instruction is now made explicit in struct 
nios2_opcode.

- GET_INSN_FIELD and SET_INSN_FIELD are gone, replaced by new accessor 
macros specific to each instruction format.  As a consequence of this, 
code that formerly accessed e.g. the A register field of instructions of 
multiple formats, with the assumption that it always occupies the same 
bits, needs to be rewritten with a switch on the instruction format to 
use the appropriate accessor macro for the format of the particular 
instruction involved.

- The data structure used for register name->number mappings now has 
some additional attributes in it, too; these are used for correctness 
checking in the assembler now.

-Sandra

-------------- next part --------------
A non-text attachment was scrubbed...
Name: binutils-refactor-opcodes.log
Type: text/x-log
Size: 2694 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20141023/b40681a1/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: binutils-refactor-opcodes.patch
Type: text/x-patch
Size: 64998 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20141023/b40681a1/attachment-0001.bin>


More information about the Binutils mailing list