[PATCH][GAS][MSP430] Improve NOP warnings/insertion behaviour around interrupt state changes

Jozef Lawrynowicz jozef.l@mittosystems.com
Sun Nov 25 13:31:00 GMT 2018


The attached patch for the assembler improves the handling of NOPs around
interrupt state changes for MSP430.

Currently the assembler will insert a NOP after an interrupt state change for
both 430 and 430x ISA. Unless the interrupt state change instruction is
explicitly "EINT", then a generic message about how a NOP might be needed after
an interrupt state change is emitted.

The new behaviour tightens the constraints for warning about NOPs for the 430
ISA, so NOPs are only inserted/warned about when needed:
- 430 and 430x ISA require a NOP after DINT.
- Only the 430x ISA requires NOP before EINT
- Only the 430x ISA requires NOP after every EINT. CPU42 errata.

There are also some new messages to better describe where NOPs are being
inserted/are thought to be required.

Another change is some logic to interpret the value being written
to the SR when the constant generator is used as the source, to understand if
interrupts will be enabled or disabled as a result of the instruction.

Also added many new tests.

If the patch is acceptable, I would appreciate if someone would apply it for
me, as I don't have write access.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-GAS-MSP430-Improve-NOP-warnings-insertion-behaviour-.patch
Type: text/x-patch
Size: 41206 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20181125/6728a54b/attachment.bin>


More information about the Binutils mailing list