> extern int foo(void);
>
> int main(void)
> {
> return foo() * 0;
> }
This is because gimple part of optimizers for some reason leads to the
following in the optimized dump:
main ()
{
:
foo ();
return 0;
}
and only RTL optimizers do the trick.
This is weird since pure/const detect funct
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47205
Summary: GCC emits optimized out noinline function
Product: gcc
Version: 4.6.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: lto
AssignedTo: unassig...