This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: C++ PATCH: PR 16405


Richard Henderson wrote:
On Thu, Dec 23, 2004 at 12:12:45AM -0800, Mark Mitchell wrote:

+ 	      && (TYPE_MAIN_VARIANT (TREE_TYPE (TREE_OPERAND (pointer, 0)))
+ 		  == TYPE_MAIN_VARIANT (TREE_TYPE (*from_p))))


lang_hooks.types_compatible_p?

I couldn't convince myself this was safe.

+ extern "C"
+ void *memcpy (void *dest, const void *src, __SIZE_TYPE__ n)
+ {
+   ++i;
+ }


Does the testcase really start up?

I forgot the dg-do run (I'll fix shortly), but I'm not sure that's what you mean.


In some cases you'll wind
up invoking this memcpy before we even get to main.  See the
sort of contortions we go through in gcc.c-torture/execute/builtins/
for testing this sort of thing.

That's why I set i to zero in main.


--
Mark Mitchell
CodeSourcery, LLC
mark@codesourcery.com
(916) 791-8304


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]