public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/107645] New: internal compiler error: RTL check: expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at config/m68k/predicates.md:144
@ 2022-11-11 16:53 jcmvbkbc at gcc dot gnu.org
  2022-11-11 18:54 ` [Bug target/107645] " jcmvbkbc at gcc dot gnu.org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: jcmvbkbc at gcc dot gnu.org @ 2022-11-11 16:53 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107645

            Bug ID: 107645
           Summary: internal compiler error: RTL check: expected elt 0
                    type 'e' or 'u', have 'E' (rtx unspec) in
                    symbolic_operand_1, at config/m68k/predicates.md:144
           Product: gcc
           Version: 13.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: target
          Assignee: unassigned at gcc dot gnu.org
          Reporter: jcmvbkbc at gcc dot gnu.org
  Target Milestone: ---

Created attachment 53884
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=53884&action=edit
_gcov_indirect_call_profiler_v4.i

Building gcc with --enable-checking=all for target=m68k-linux-uclibc breaks
with the following error message:

gcc/libgcc/libgcov-profiler.c: In function ‘__gcov_indirect_call_profiler_v4’:
gcc/libgcc/libgcov-profiler.c:173:1: internal compiler error: RTL check:
expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at
config/m68k/predicates.md:144

It can be reproduced with the following command line and the attached source:

cc1 -O2 -fPIC -g -fno-stack-protector -mcpu=68040
_gcov_indirect_call_profiler_v4.i

Bisection points to the following revision: r0-93570-g75df395f15f2

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

* [Bug target/107645] internal compiler error: RTL check: expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at config/m68k/predicates.md:144
  2022-11-11 16:53 [Bug target/107645] New: internal compiler error: RTL check: expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at config/m68k/predicates.md:144 jcmvbkbc at gcc dot gnu.org
@ 2022-11-11 18:54 ` jcmvbkbc at gcc dot gnu.org
  2022-11-16 12:36 ` cvs-commit at gcc dot gnu.org
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: jcmvbkbc at gcc dot gnu.org @ 2022-11-11 18:54 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107645

--- Comment #1 from jcmvbkbc at gcc dot gnu.org ---
ICE in the reproducer is generated when predicate 'symbolic_operand' is applied
to the 'const' node in the following rtl:

(insn 342 341 343 35 (set (reg:SI 97)
        (mem/u:SI (plus:SI (reg:SI 13 %a5)
                (const:SI (unspec:SI [
                            (symbol_ref:SI ("__gcov_kvp_dynamic_pool_index")
[flags 0x40]  <var_decl 0x7f9e83fe7cf0 __gcov_kvp_dynamic_pool_index>)
                            (const_int 0 [0])
                        ] 6))) [0  S4 A8])) "gcc/libgcc/libgcov.h":472:44 55
{*movsi_m68k2}
     (expr_list:REG_EQUAL (symbol_ref:SI ("__gcov_kvp_dynamic_pool_index")
[flags 0x40]  <var_decl 0x7f9e83fe7cf0 __gcov_kvp_dynamic_pool_index>)
        (nil)))

Wrapping symbolic expressions into the unspec was added in the commit that
implemented TLS for m68k, but the 'CONST' case in the predicate code was not
updated to filter wrapped expressions out.

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

* [Bug target/107645] internal compiler error: RTL check: expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at config/m68k/predicates.md:144
  2022-11-11 16:53 [Bug target/107645] New: internal compiler error: RTL check: expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at config/m68k/predicates.md:144 jcmvbkbc at gcc dot gnu.org
  2022-11-11 18:54 ` [Bug target/107645] " jcmvbkbc at gcc dot gnu.org
@ 2022-11-16 12:36 ` cvs-commit at gcc dot gnu.org
  2022-11-16 12:38 ` jcmvbkbc at gcc dot gnu.org
  2022-11-28 22:23 ` pinskia at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-11-16 12:36 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107645

--- Comment #2 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Max Filippov <jcmvbkbc@gcc.gnu.org>:

https://gcc.gnu.org/g:99c9cbcc3ba3e005bad790a600853266a81d95ee

commit r13-4086-g99c9cbcc3ba3e005bad790a600853266a81d95ee
Author: Max Filippov <jcmvbkbc@gmail.com>
Date:   Wed Nov 9 00:39:50 2022 -0800

    gcc: m68k: fix PR target/107645

    gcc/
            PR target/107645
            * config/m68k/predicates.md (symbolic_operand): Return false
            when UNSPEC is under the CONST node.

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

* [Bug target/107645] internal compiler error: RTL check: expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at config/m68k/predicates.md:144
  2022-11-11 16:53 [Bug target/107645] New: internal compiler error: RTL check: expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at config/m68k/predicates.md:144 jcmvbkbc at gcc dot gnu.org
  2022-11-11 18:54 ` [Bug target/107645] " jcmvbkbc at gcc dot gnu.org
  2022-11-16 12:36 ` cvs-commit at gcc dot gnu.org
@ 2022-11-16 12:38 ` jcmvbkbc at gcc dot gnu.org
  2022-11-28 22:23 ` pinskia at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: jcmvbkbc at gcc dot gnu.org @ 2022-11-16 12:38 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107645

jcmvbkbc at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         Resolution|---                         |FIXED
             Status|UNCONFIRMED                 |RESOLVED

--- Comment #3 from jcmvbkbc at gcc dot gnu.org ---
Fix applied to master.

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

* [Bug target/107645] internal compiler error: RTL check: expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at config/m68k/predicates.md:144
  2022-11-11 16:53 [Bug target/107645] New: internal compiler error: RTL check: expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at config/m68k/predicates.md:144 jcmvbkbc at gcc dot gnu.org
                   ` (2 preceding siblings ...)
  2022-11-16 12:38 ` jcmvbkbc at gcc dot gnu.org
@ 2022-11-28 22:23 ` pinskia at gcc dot gnu.org
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-11-28 22:23 UTC (permalink / raw)
  To: gcc-bugs

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107645

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |13.0

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

end of thread, other threads:[~2022-11-28 22:23 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-11 16:53 [Bug target/107645] New: internal compiler error: RTL check: expected elt 0 type 'e' or 'u', have 'E' (rtx unspec) in symbolic_operand_1, at config/m68k/predicates.md:144 jcmvbkbc at gcc dot gnu.org
2022-11-11 18:54 ` [Bug target/107645] " jcmvbkbc at gcc dot gnu.org
2022-11-16 12:36 ` cvs-commit at gcc dot gnu.org
2022-11-16 12:38 ` jcmvbkbc at gcc dot gnu.org
2022-11-28 22:23 ` pinskia at gcc dot gnu.org

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