Bug 71524 - [7 Regression] internal compiler error: in binds_to_current_def_p, at symtab.c:2232
Summary: [7 Regression] internal compiler error: in binds_to_current_def_p, at symtab....
Status: RESOLVED DUPLICATE of bug 77674
Alias: None
Product: gcc
Classification: Unclassified
Component: middle-end (show other bugs)
Version: 7.0
: P3 normal
Target Milestone: 7.0
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-06-13 16:39 UTC by H.J. Lu
Modified: 2016-11-21 22:04 UTC (History)
3 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2016-06-13 00:00:00


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description H.J. Lu 2016-06-13 16:39:30 UTC
[hjl@gnu-13 gcc]$ cat /tmp/x.c
static int implementation2 (void)
{
  return 2;
}

static void *resolver2 (void)
{
  return (void *)implementation2;
}

static int func2 (void) __attribute__ ((ifunc ("resolver2")));

void *
get_func2 (void)
{
  return &func2;
}

int
call_func2 (void)
{
  if (get_func2 () != &func2)
    __builtin_abort ();

  return func2 ();
}
[hjl@gnu-13 gcc]$ ./xgcc -B./ -m32 -O3 -S /tmp/x.c -o /tmp/x.s 
func2/2 (func2) @0x7f7ce5b892e0
  Type: function definition analyzed alias
  Visibility: prevailing_def_ironly
  Address is taken.
  References: resolver2/1 (alias)
  Referring: get_func2/3 (addr)
  Availability: overwritable
  First run: 0
  Function flags:
  Called by: call_func2/4 (1.00 per call) 
  Calls: 
/tmp/x.c:26:1: internal compiler error: in binds_to_current_def_p, at symtab.c:2232
 }
 ^
0x7469bc symtab_node::binds_to_current_def_p(symtab_node*)
	../../src-trunk/gcc/symtab.c:2232
0x126c68f worse_state
	../../src-trunk/gcc/ipa-pure-const.c:477
0x126c68f propagate_pure_const
	../../src-trunk/gcc/ipa-pure-const.c:1343
0x126c68f execute
	../../src-trunk/gcc/ipa-pure-const.c:1676
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.
[hjl@gnu-13 gcc]$
Comment 1 H.J. Lu 2016-06-13 18:29:19 UTC
It is caused by r70018.
Comment 2 Alexander Monakov 2016-06-26 07:25:35 UTC
(In reply to H.J. Lu from comment #1)
> It is caused by r70018.

Did you mean (one of the) fixes for PR70018? Do you have the commit id?
Comment 3 H.J. Lu 2016-06-26 12:41:18 UTC
(In reply to H.J. Lu from comment #1)
> It is caused by r70018.

Oops.  It was caused by r235065.
Comment 4 Jeffrey A. Law 2016-11-21 22:04:49 UTC
Duplicate

*** This bug has been marked as a duplicate of bug 77674 ***