This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] Workaround for Janus 2CC core errata
- From: Daniel Gutson <dgutson at codesourcery dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Thu, 06 Aug 2009 19:34:14 -0300
- Subject: Re: [PATCH] Workaround for Janus 2CC core errata
- References: <4A4B0186.6070809@codesourcery.com>
Hi,
any update on this?
Thanks!
Daniel.
Daniel Gutson wrote:
The attached patch implements a work-around for an errata in the Janus
2CC core.
I tested this by running the gcc test suite, including the two new test
cases I added in this patch.
If accepted, please commit if for me since I don't have write access.
Thanks,
Daniel.
2009-07-01 Daniel Gutson <dgutson@codesourcery.com>
gcc/
* config/arm/arm.md (*addsi3_carryin_shift): Added "length" clause
to handle the extra NOP.
(andsi_not_shiftsi_si): Likewise.
(*thumb1_ashlsi3): Likewise.
(*thumb1_ashrsi3): Likewise.
(*thumb1_lshrsi3): Likewise.
(*thumb1_rotrsi3): Likewise.
(*arm_shiftsi3): Likewise.
(*shiftsi3_compare0): Likewise.
(*shiftsi3_compare0_scratch): Likewise.
(*arm_notsi_shiftsi): Likewise.
(*arm_notsi_shiftsi_compare0): Likewise.
(*arm_not_shiftsi_compare0_scratch): Likewise.
(*arm_cmpsi_shiftsi): Likewise.
(*arm_cmpsi_shiftsi_swp): Likewise.
(*arm_cmpsi_negshiftsi_si): Likewise.
(*arith_shiftsi): Likewise.
(*arith_shiftsi_compare0): Likewise.
(*arith_shiftsi_compare0_scratch): Likewise.
(*sub_shiftsi): Likewise.
(*sub_shiftsi_compare0): Likewise.
(*sub_shiftsi_compare0_scratch): Likewise.
(*if_shift_move): Likewise.
(*if_move_shift): Likewise.
(*if_shift_shift): Likewise.
(*thumb1_ashlsi3_janus2): New. Duplicated pattern to handle the
extra NOP.
(*thumb1_ashrsi3_janus2): Likewise.
(*thumb1_lshrsi3_janus2): Likewise.
(*thumb1_rotrsi3_janus2): Likewise.
* config/arm/arm.c (arm_print_operand): Added the nop after the %S
pattern.
(arm_override_options): Added handling of the -mfix-janus-2cc flag
* config/arm/arm.h (janus2_code): Declare.
* config/arm/arm.opt (-mfix-janus-2cc): New.
gcc/testsuite/
* lib/target-supports.exp (check_effective_target_arm_no_thumb): New
function.
* gcc.target/arm/janus-2cc-shift-1.c: New.
* gcc.target/arm/janus-2cc-shift-2.c: New.
--
Daniel Gutson
CodeSourcery
www.codesourcery.com