From: John David Anglin <dave.anglin@bell.net>
To: GCC Patches <gcc-patches@gcc.gnu.org>
Subject: [committed] Fix PR target/68729
Date: Thu, 10 Dec 2015 01:00:00 -0000 [thread overview]
Message-ID: <44C2892E-5289-466D-A36E-E3EC693979D2@bell.net> (raw)
[-- Attachment #1: Type: text/plain, Size: 539 bytes --]
The attached fixes an ICE building gridengine. The problem is we are asked to do an HImode reload
for a floating pointing register. However, we can only do 32 and 64-bit loads and stores to/from floating
point registers.
The problem is resolved by not checking that the mode requested is consistent with the modes of the
input and output operands.
Tested on hppa-unknown-linux-gnu, hppa2.0w-hp-hpux11.11 and hppa64-hp-hpux11.11. Committed
to trunk and active branches.
Dave
--
John David Anglin dave.anglin@bell.net
[-- Attachment #2: pa.c.d.txt --]
[-- Type: text/plain, Size: 2449 bytes --]
2015-12-09 John David Anglin <danglin@gcc.gnu.org>
PR target/68729
* config/pa/pa.c (pa_emit_move_sequence): Don't check that mode is
consistent with modes of the input and output operands when doing
reloads to and from floating point registers. Do reload for all
address forms.
Index: config/pa/pa.c
===================================================================
--- config/pa/pa.c (revision 231326)
+++ config/pa/pa.c (working copy)
@@ -1683,11 +1683,10 @@
REG+D addresses where D does not fit in 5 or 14 bits, including
(subreg (mem (addr))) cases. */
if (scratch_reg
- && fp_reg_operand (operand0, mode)
+ && FP_REG_P (operand0)
&& (MEM_P (operand1)
|| (GET_CODE (operand1) == SUBREG
- && MEM_P (XEXP (operand1, 0))))
- && !floating_point_store_memory_operand (operand1, mode))
+ && MEM_P (XEXP (operand1, 0)))))
{
if (GET_CODE (operand1) == SUBREG)
operand1 = XEXP (operand1, 0);
@@ -1699,10 +1698,8 @@
/* D might not fit in 14 bits either; for such cases load D into
scratch reg. */
- if (reg_plus_base_memory_operand (operand1, mode)
- && !(TARGET_PA_20
- && !TARGET_ELF32
- && INT_14_BITS (XEXP (XEXP (operand1, 0), 1))))
+ if (reg_plus_base_memory_operand (operand1, GET_MODE (operand1))
+ && !INT_14_BITS (XEXP (XEXP (operand1, 0), 1)))
{
emit_move_insn (scratch_reg, XEXP (XEXP (operand1, 0), 1));
emit_move_insn (scratch_reg,
@@ -1718,11 +1715,10 @@
return 1;
}
else if (scratch_reg
- && fp_reg_operand (operand1, mode)
+ && FP_REG_P (operand1)
&& (MEM_P (operand0)
|| (GET_CODE (operand0) == SUBREG
- && MEM_P (XEXP (operand0, 0))))
- && !floating_point_store_memory_operand (operand0, mode))
+ && MEM_P (XEXP (operand0, 0)))))
{
if (GET_CODE (operand0) == SUBREG)
operand0 = XEXP (operand0, 0);
@@ -1734,10 +1730,8 @@
/* D might not fit in 14 bits either; for such cases load D into
scratch reg. */
- if (reg_plus_base_memory_operand (operand0, mode)
- && !(TARGET_PA_20
- && !TARGET_ELF32
- && INT_14_BITS (XEXP (XEXP (operand0, 0), 1))))
+ if (reg_plus_base_memory_operand (operand0, GET_MODE (operand0))
+ && !INT_14_BITS (XEXP (XEXP (operand0, 0), 1)))
{
emit_move_insn (scratch_reg, XEXP (XEXP (operand0, 0), 1));
emit_move_insn (scratch_reg, gen_rtx_fmt_ee (GET_CODE (XEXP (operand0,
next reply other threads:[~2015-12-10 1:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-10 1:00 John David Anglin [this message]
[not found] ` <6B7806D6-C14A-4226-8056-C043BD62874A@bell.net>
2016-01-12 1:50 ` John David Anglin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=44C2892E-5289-466D-A36E-E3EC693979D2@bell.net \
--to=dave.anglin@bell.net \
--cc=gcc-patches@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).