gcc-43-pr39429.patch 938 B

123456789101112131415161718192021222324
  1. From: Michael Olbrich <m.olbrich@pengutronix.de>
  2. Subject: Fix: compiler create bad asm codes.
  3. See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39429 for details.
  4. Signed-off-by: Michael Olbrich <m.olbrich@pengutronix.de>
  5. ---
  6. gcc/config/arm/arm.c | 2 +-
  7. 1 file changed, 1 insertion(+), 1 deletion(-)
  8. Index: b/gcc/config/arm/arm.c
  9. ===================================================================
  10. --- a/gcc/config/arm/arm.c
  11. +++ b/gcc/config/arm/arm.c
  12. @@ -6838,7 +6838,7 @@ adjacent_mem_locations (rtx a, rtx b)
  13. /* Don't accept any offset that will require multiple
  14. instructions to handle, since this would cause the
  15. arith_adjacentmem pattern to output an overlong sequence. */
  16. - if (!const_ok_for_op (PLUS, val0) || !const_ok_for_op (PLUS, val1))
  17. + if (!const_ok_for_op (val0, PLUS) || !const_ok_for_op (val1, PLUS))
  18. return 0;
  19. /* Don't allow an eliminable register: register elimination can make