public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug middle-end/53303] New: Reload/RA issue on paradoxical subreg of subword regsiter for big endian targets
@ 2012-05-10  9:05 aurelien.buhrig.gcc at gmail dot com
  2012-05-10 22:48 ` [Bug middle-end/53303] Reload/RA issue on word-sized paradoxical subregs for big-endian targets ebotcazou at gcc dot gnu.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: aurelien.buhrig.gcc at gmail dot com @ 2012-05-10  9:05 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53303

             Bug #: 53303
           Summary: Reload/RA issue on paradoxical subreg of subword
                    regsiter for big endian targets
    Classification: Unclassified
           Product: gcc
           Version: 4.6.3
            Status: UNCONFIRMED
          Severity: critical
          Priority: P3
         Component: middle-end
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: aurelien.buhrig.gcc@gmail.com


There is a RA issue with paradoxical subreg of sub-word register on big endian
targets.

It occurs on a private target but seems also to occur on the sparc 64-bit
target for 32-bit FP registers, and perhaps on hp-pa.

http://gcc.gnu.org/ml/gcc/2012-05/msg00028.html

The given workarounds do not work for my backend.

The target has SImode word_mode and for such an insn (generated during
combine):
(set (subreg:SI (reg:QI 21) 0)
     (lshiftrt:SI (reg/v:SI 24) (const_int 31 [0x1f]))

reg:QI 21 is reloaded into (reg:QI 0 r0 [orig:21] [21]).

r0 is a HI register, which makes find_dummy_reload generating a segfault after
computing  the subreg:SI regno, which is then -1.


I quickly had a look at assign_hard_reg (ira-color.c) but it seems the
information about such paradoxical subreg is not available from ira_allocno_t
nor ira_object_t when choosing the hard reg, and I'm not sure what to do.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug middle-end/53303] Reload/RA issue on word-sized paradoxical subregs for big-endian targets
  2012-05-10  9:05 [Bug middle-end/53303] New: Reload/RA issue on paradoxical subreg of subword regsiter for big endian targets aurelien.buhrig.gcc at gmail dot com
@ 2012-05-10 22:48 ` ebotcazou at gcc dot gnu.org
  2012-05-24  7:51 ` aurelien.buhrig.gcc at gmail dot com
  2012-06-18 16:14 ` [Bug middle-end/53303] Reload/RA issue on word paradoxical subregs aurelien.buhrig.gcc at gmail dot com
  2 siblings, 0 replies; 4+ messages in thread
From: ebotcazou at gcc dot gnu.org @ 2012-05-10 22:48 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53303

Eric Botcazou <ebotcazou at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
   Last reconfirmed|                            |2012-05-10
                 CC|                            |ebotcazou at gcc dot
                   |                            |gnu.org
            Version|4.6.3                       |4.8.0
            Summary|Reload/RA issue on          |Reload/RA issue on
                   |paradoxical subreg of       |word-sized paradoxical
                   |subword regsiter for big    |subregs for big-endian
                   |endian targets              |targets
     Ever Confirmed|0                           |1
           Severity|critical                    |major

--- Comment #1 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2012-05-10 22:42:55 UTC ---
This isn't critical for the FSF compiler, but nevertheless a major issue on BE.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug middle-end/53303] Reload/RA issue on word-sized paradoxical subregs for big-endian targets
  2012-05-10  9:05 [Bug middle-end/53303] New: Reload/RA issue on paradoxical subreg of subword regsiter for big endian targets aurelien.buhrig.gcc at gmail dot com
  2012-05-10 22:48 ` [Bug middle-end/53303] Reload/RA issue on word-sized paradoxical subregs for big-endian targets ebotcazou at gcc dot gnu.org
@ 2012-05-24  7:51 ` aurelien.buhrig.gcc at gmail dot com
  2012-06-18 16:14 ` [Bug middle-end/53303] Reload/RA issue on word paradoxical subregs aurelien.buhrig.gcc at gmail dot com
  2 siblings, 0 replies; 4+ messages in thread
From: aurelien.buhrig.gcc at gmail dot com @ 2012-05-24  7:51 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53303

--- Comment #2 from Aurelien Buhrig <aurelien.buhrig.gcc at gmail dot com> 2012-05-24 07:43:39 UTC ---
This bug is very annoying for me. I can't really work around it.
Let me know if there is something I can do to help fixing it...

Cheers,


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [Bug middle-end/53303] Reload/RA issue on word paradoxical subregs
  2012-05-10  9:05 [Bug middle-end/53303] New: Reload/RA issue on paradoxical subreg of subword regsiter for big endian targets aurelien.buhrig.gcc at gmail dot com
  2012-05-10 22:48 ` [Bug middle-end/53303] Reload/RA issue on word-sized paradoxical subregs for big-endian targets ebotcazou at gcc dot gnu.org
  2012-05-24  7:51 ` aurelien.buhrig.gcc at gmail dot com
@ 2012-06-18 16:14 ` aurelien.buhrig.gcc at gmail dot com
  2 siblings, 0 replies; 4+ messages in thread
From: aurelien.buhrig.gcc at gmail dot com @ 2012-06-18 16:14 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53303

Aurelien Buhrig <aurelien.buhrig.gcc at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|Reload/RA issue on          |Reload/RA issue on word
                   |word-sized paradoxical      |paradoxical subregs
                   |subregs for big-endian      |
                   |targets                     |

--- Comment #3 from Aurelien Buhrig <aurelien.buhrig.gcc at gmail dot com> 2012-06-18 16:14:17 UTC ---
This bug does not depends on endianess.
It also occurs on little endian target, when RA allocates such a paradoxical
register with the last hardware register which is smaller than a word (in
comparison with the first register for big-endian targets).


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-06-18 16:14 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-05-10  9:05 [Bug middle-end/53303] New: Reload/RA issue on paradoxical subreg of subword regsiter for big endian targets aurelien.buhrig.gcc at gmail dot com
2012-05-10 22:48 ` [Bug middle-end/53303] Reload/RA issue on word-sized paradoxical subregs for big-endian targets ebotcazou at gcc dot gnu.org
2012-05-24  7:51 ` aurelien.buhrig.gcc at gmail dot com
2012-06-18 16:14 ` [Bug middle-end/53303] Reload/RA issue on word paradoxical subregs aurelien.buhrig.gcc at gmail dot com

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).