This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC 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]

Re: Fix Thumb-2 NEON ICE


Joseph S. Myers writes:
 > This patch fixes an ICE for Thumb-2 NEON on the included testcase.
 > 
 > output_move_neon has operands[0]
 > 
 >   (mem:V16QI (plus:SI (reg:SI 3 r3) (const_int -256)))
 > 
 > and operands[1]
 > 
 >   (reg:V16QI 95 d16)
 > 
 > and calls adjust_address (mem, SImode, 8 * i).  This ends up
 > validating the address for SImode, but the offset of -256 is not valid
 > for SImode for Thumb-2.  The new address is only used with vldr/vstr
 > instructions; there seems to be no need for it to be valid for SImode,
 > so this patch makes it use DImode instead, for which all valid NEON
 > offsets are accepted.
 > 
 > Tested with no regressions with cross to arm-none-eabi.  OK to commit?
 > 
 > 2009-10-08  Joseph Myers  <joseph@codesourcery.com>
 > 
 > 	* config/arm/arm.c (output_move_neon): Use DImode in call to
 > 	adjust_address.
 > 
 > testsuite:
 > 2009-10-08  Joseph Myers  <joseph@codesourcery.com>
 > 
 > 	* gcc.target/arm/neon-thumb2-move.c: New test.

This test case also ICEs gcc-4.4.2, but not gcc-4.3.4.
Will you apply the patch to the 4.4 branch too?

I checked that the patch applies to 4.4.2 and fixes the ICE,
but I haven't tested it beyond that.

/Mikael


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