[PATCH] Add builtin memmove and bcopy

Kaveh R. Ghazi ghazi@caip.rutgers.edu
Mon Apr 28 02:01:00 GMT 2003


 > +      /* If src is a string constant and strings are not writable,
 > +       we can use normal memcpy.  */
 > +      if (!flag_writable_strings && c_getstr (src))
 > +      return expand_builtin_memcpy (arglist, target, mode, 0);

More generally, can't we call memcpy if we're sure src and dest don't
alias each other?


 > +static rtx
 > +expand_builtin_bcopy (exp)
 > +     tree exp;
 > +{
 > +  tree arglist = TREE_OPERAND (exp, 1);

Minor nit, this function probably can take arglist as it's parameter
rather than exp, since all it does it dig out arglist.


		--Kaveh
--
Kaveh R. Ghazi			ghazi@caip.rutgers.edu



More information about the Gcc-patches mailing list