Bob Wilson - [Xtensa] fix reload failure for floating-point literal (original) (raw)
This is the mail archive of the gcc-patches@gcc.gnu.orgmailing 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] |
- From: Bob Wilson
- To: GCC Patches
- Date: Mon, 05 Feb 2007 14:57:34 -0800
- Subject: [Xtensa] fix reload failure for floating-point literal
This fixes a problem where a floating-point literal is stored in the constant pool and reload tries to load it directly into a floating-point register. Xtensa can only load literals into the general registers, and the instruction's constraints cannot be satisfied. The root cause for this is a SUBREG wrapped around the MEM for the literal. I've tested and committed this on mainline. The problem was first seen on 4.1, so I'll also apply this to the 4.2 branch, and the 4.1 branch after the current release is out of the way.2007-02-05 Bob Wilson bob.wilson@acm.org * config/xtensa/xtensa.c (constantpool_mem_p): Skip over SUBREGs.
Index: config/xtensa/xtensa.c
--- config/xtensa/xtensa.c (revision 121533) +++ config/xtensa/xtensa.c (working copy) @@ -449,6 +449,8 @@ int constantpool_mem_p (rtx op) {
- if (GET_CODE (op) == SUBREG)
- op = SUBREG_REG (op);
if (GET_CODE (op) == MEM) return constantpool_address_p (XEXP (op, 0)); return FALSE;
Index Nav: | [Date Index] [Subject Index] [Author Index] [Thread Index] | |
---|---|---|
Message Nav: | [Date Prev] [Date Next] | [Thread Prev] [Thread Next] |