[Bug tree-optimization/86241] duplicate strlen-like snprintf calls not folded
rguenth at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Jun 21 09:10:00 GMT 2018
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86241
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |missed-optimization
--- Comment #1 from Richard Biener <rguenth at gcc dot gnu.org> ---
The alias machinery knows nothing about "type" rules for function calls so I
don't see how this is possible w/o running into the same issue as with removing
the redundant strlen call.
That is, for g() hopefully we fold the snprintf to strlen. Not sure why
that's done only late during the strlen pass and not by gimple_fold ().
More information about the Gcc-bugs
mailing list