int f(int lay) { static int syncsize, init; if (init == 0) syncsize = 1344, init = 1; return syncsize; }
store-ccp should handle that. -- Summary: missed CCP Product: gcc Version: 4.4.0 Status: UNCONFIRMED Keywords: missed-optimization Severity: normal Priority: P3 Component: tree-optimization AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: rguenth at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=36188