[Bug tree-optimization/27798] New: gimplifying "return CONSTANT" creates unneeded temporaties
dann at godzilla dot ics dot uci dot edu
gcc-bugzilla@gcc.gnu.org
Mon May 29 17:41:00 GMT 2006
int zero { return 0; }
is gimplified to:
zero ()
{
int D.2115;
D.2115 = 0;
return D.2115;
}
The D.2115 temporary is not needed, the return value is constant, it is of the
same type as the function return type, and return CONSTANT is valid
gimple.
Not creating the temporary should save some memory and processing time later.
--
Summary: gimplifying "return CONSTANT" creates unneeded
temporaties
Product: gcc
Version: 4.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: tree-optimization
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: dann at godzilla dot ics dot uci dot edu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=27798
More information about the Gcc-bugs
mailing list