Commit: MSP430: Add support for silicon errata
Nick Clifton
nickc@redhat.com
Thu Oct 22 15:25:00 GMT 2015
Hi Guys,
I am checking in the patch below to add support for fixing various
MSP430 CPU silicon errata in the assembler. Two new options are
implemented:
-msilicon-errata=<name>[,<name>...]
Implements a fixup for named silicon errata. Multiple silicon
errata can be specified by multiple uses of the -msilicon-errata
option and/or by including the errata names, separated by commas,
on an individual -msilicon-errata option. The option acts silently
except when handling errata cpu42. Errata names currently
recognised by the assembler are:
cpu4
PUSH #4 and PUSH #8 need longer encodings on the MSP430.
This option is enabled by default, and cannot be disabled.
cpu8
Do not set the stack pointer to an odd value.
cpu11
Do not update the status register and the PC in the same
instruction.
cpu12
Do not use the PC in a CMP or BIT instruction.
cpu13
Do not use an arithmetic instruction to modify the status
register.
cpu19
Insert NOP after CPUOFF.
cpu42
Warn where a NOP ought to be present after enabling interrupts.
cpu42+
Add NOP after enabling interrupts.
-msilicon-errata-warn=<name>[,<name>...]
Like the -msilicon-errata option except that instead of fixing the
specified errata, a warning message is issued instead. This option
can be used alongside -msilicon-errata to generate messages whenever
a problem is fixed, or on its own in order to inspect code for
potential problems.
Cheers
Nick
gas/ChangeLog
2015-10-22 Nick Clifton <nickc@redhat.com>
* config/tc-msp430.c (PUSH_1X_WORKAROUND): Delete.
(OPTION_SILICON_ERRATA): Define.
(OPTION_SILICON_WARN): Define.
(md_parse_opton): Handle silicon errata options.
(md_longopts): Add silicon errata options.
(ms_show_usage): Report silicon errata options.
(msp430_srcoperand): Handle silicon errata.
(msp430_operands): Likewise. Improve nop insertion.
(msp430_fix_adjustable): Update warning generation.
* doc/c-msp430.texi: Document silicon errata options.
gas/testsuite/ChangeLog
2015-10-22 Nick Clifton <nickc@redhat.com>
* gas/msp430/errata_fixes.s: New test source file.
* gas/msp430/errata_fixes.d: New test control file.
* gas/msp430/errata_warns.s: New test source file.
* gas/msp430/errata_warns.d: New test control file.
* gas/msp430/errata_warns.l: New test message file.
* gas/msp430/msp430.exp: Run the new tests.
* gas/msp430/bad.l: Update expected warning messages
* gas/msp430/msp430.exp: Run the new tests.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: msp430.silicon-errata.patch
Type: text/x-patch
Size: 26483 bytes
Desc: not available
URL: <https://sourceware.org/pipermail/binutils/attachments/20151022/baa6c41b/attachment.bin>
More information about the Binutils
mailing list