[Bug middle-end/81657] [8 Regression] FAIL: gcc.dg/20050503-1.c scan-assembler-not call

wilco at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Fri Jan 19 12:23:00 GMT 2018


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81657

--- Comment #14 from Wilco <wilco at gcc dot gnu.org> ---
(In reply to Jakub Jelinek from comment #11)
> No matter what, I don't see how you could use much common infrastructure
> here.
> Say if the tailcall pass sees strlen (something) + something being returned,
> it could turn that into strchr (something, 0), because both functions are
> standard.
> We can't do that if we see memcpy (x, y, len) + len, because mempcpy is not
> a C standard function, while memcpy is, so if the information that mempcpy
> was originally used is lost, then it is completely lost.

I believe there is a way to check whether you've seen a declaration. If that
fails you can still know whether a function originally contained mempcpy just
like alloca.


More information about the Gcc-bugs mailing list