This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] MIPS: Add option to work around CN68XXP1 PREF errata.


The CN68XXP1 is a member of the OCTEON family of MIPS64 based SOCs. The CPUs on this device have an erratum where execution of PREF instructions with hints in the range 0-4 and 6-24 occasionally lead to undefined behavior.

We have implemented a work around in the assembler where we replace PREF instructions that might fail with PREF 28. This work around is enabled/disabled with the new command line options '-mfix-cn63xxp1' / '-mno-fix-cn63xxp1'.

Tested with --target=mips64-octeon-linux-gnu, no regressions.

OK to commit?

src/gas:
2010-09-27  David Daney  <ddaney@caviumnetworks.com>

	* config/tc-mips.c (mips_fix_cn63xxp1): New variable.
	(mips_ip):  Add errata work around when mips_fix_cn63xxp1 set.
	(OPTION_FIX_CN63XXP1, OPTION_NO_FIX_CN63XXP1): New enum options
	enumerations.
	(md_longopts): Add options for -mfix-cn63xxp1 and -mno-fix-cn63xxp1.
	(md_parse_option): Handle OPTION_FIX_CN63XXP1 and
	OPTION_NO_FIX_CN63XXP1.
	(md_show_usage): Add documentation for -mfix-cn63xxp1.
	* doc/c-mips.texi (-mfix-cn63xxp1, -mno-fix-cn63xxp1): Document
	the new options.

src/gas/testsuite:
2010-09-27  David Daney  <ddaney@caviumnetworks.com>

	* gas/mips/mips.exp (octeon-pref): Run the new test.
	* gas/mips/octeon-pref.s: New test.
	* gas/mips/octeon-pref.d: New expected results for the new test.

Attachment: fix-cn63xxp1.patch
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]