[Bug tree-optimization/63583] New: ICF does not check that the template strings are the same
pinskia at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Sat Oct 18 01:22:00 GMT 2014
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63583
Bug ID: 63583
Summary: ICF does not check that the template strings are the
same
Product: gcc
Version: 5.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
Assignee: unassigned at gcc dot gnu.org
Reporter: pinskia at gcc dot gnu.org
Take:
static int f(int t) __attribute__((noinline));
static int g(int t) __attribute__((noinline));
static int g(int t)
{
asm("addl %0, 1": "+r"(t));
return t;
}
static int f(int t)
{
asm("addq %0, -1": "+r"(t));
return t;
}
int h(int t)
{
return f(t) + g(t);
}
--- CUT ---
ICF decides both g and f are the same function but they are not due to the
different strings in the inline-asm.
More information about the Gcc-bugs
mailing list