public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug ipa/98744] New: [11 Regression] ICE in gimple_call_arg, at gimple.h:3246 since r11-6735-g424deca72b63e644
@ 2021-01-19 10:38 marxin at gcc dot gnu.org
  2021-01-19 10:39 ` [Bug ipa/98744] " marxin at gcc dot gnu.org
                   ` (11 more replies)
  0 siblings, 12 replies; 13+ messages in thread
From: marxin at gcc dot gnu.org @ 2021-01-19 10:38 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 98744
           Summary: [11 Regression] ICE in gimple_call_arg, at
                    gimple.h:3246 since r11-6735-g424deca72b63e644
           Product: gcc
           Version: 11.0
            Status: UNCONFIRMED
          Keywords: ice-on-valid-code
          Severity: normal
          Priority: P3
         Component: ipa
          Assignee: unassigned at gcc dot gnu.org
          Reporter: marxin at gcc dot gnu.org
                CC: jamborm at gcc dot gnu.org, jason at gcc dot gnu.org,
                    marxin at gcc dot gnu.org
  Target Milestone: ---

I see the following ICE for:

$ cat elide.C
struct A {};
struct B : virtual A {};
struct C : B {
  C() : B(B()) {}
};
int main() { C c; return 0; }

$ g++ elide.C -c -Wmaybe-uninitialized -fno-inline -O2 -c
during GIMPLE pass: uninit
elide.C: In constructor ‘C::C()’:
elide.C:4:3: internal compiler error: in gimple_call_arg, at gimple.h:3246
    4 |   C() : B(B()) {}
      |   ^
0x85ddd8 gimple_call_arg
        /home/marxin/Programming/gcc/gcc/gimple.h:3246
0x85ddd8 gimple_call_arg
        /home/marxin/Programming/gcc/gcc/gimple.h:3244
0x85ddd8 maybe_warn_pass_by_reference
        /home/marxin/Programming/gcc/gcc/tree-ssa-uninit.c:515
0x85ddd8 warn_uninitialized_vars
        /home/marxin/Programming/gcc/gcc/tree-ssa-uninit.c:648
0x1382507 execute
        /home/marxin/Programming/gcc/gcc/tree-ssa-uninit.c:3019
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.

What happens is that:
#2  0x0000000001383cef in maybe_warn_pass_by_reference (stmt=0x7ffff7552630,
wlims=...) at /home/marxin/Programming/gcc/gcc/tree-ssa-uninit.c:531

(gdb) p debug_gimple_stmt(stmt)
B::__ct_base .isra (_1);

which is an ISRA clone, but the gimple_call_fntype function declaration has 2
arguments:

(gdb) pct(fntype)

void B::<T3e0> (struct B *, const void *)

@Martin: Is it expected or should be the decl adjusted after IPA SRA is done?

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

end of thread, other threads:[~2021-01-22 18:09 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-01-19 10:38 [Bug ipa/98744] New: [11 Regression] ICE in gimple_call_arg, at gimple.h:3246 since r11-6735-g424deca72b63e644 marxin at gcc dot gnu.org
2021-01-19 10:39 ` [Bug ipa/98744] " marxin at gcc dot gnu.org
2021-01-19 10:42 ` rguenth at gcc dot gnu.org
2021-01-20 16:58 ` jamborm at gcc dot gnu.org
2021-01-20 17:25 ` [Bug c++/98744] " jamborm at gcc dot gnu.org
2021-01-20 20:24 ` msebor at gcc dot gnu.org
2021-01-21  8:32 ` marxin at gcc dot gnu.org
2021-01-21 10:45 ` jakub at gcc dot gnu.org
2021-01-22  9:41 ` jakub at gcc dot gnu.org
2021-01-22 16:48 ` jason at gcc dot gnu.org
2021-01-22 17:00 ` jason at gcc dot gnu.org
2021-01-22 18:09 ` cvs-commit at gcc dot gnu.org
2021-01-22 18:09 ` jason 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).