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/7010: Bug in 3.1 with inline memcpy


> #include <string.h>
> 
> int main()
> {
>  char dst[16];
>  char src[16];
>  int tocopy = 5;
> 
>  memcpy (dst+5, src, tocopy);
> 
>  return 0;
> }

Oh no, another pasto in my code :(
I am just proffreading both functions to catch similar bugs, if they
exists.

Bootstrapped/regtested branch, OK for mainline/branch?
Ok to add testcase into mainline testsuite?

Thu Jun 13 18:03:55 CEST 2002  Jan Hubicka  <jh@suse.cz>
	* i386.c (ix86_expand_movstr):  Fix pasto.
Index: i386.c
===================================================================
RCS file: /cvs/gcc/egcs/gcc/config/i386/i386.c,v
retrieving revision 1.423
diff -c -3 -p -r1.423 i386.c
*** i386.c	12 Jun 2002 14:51:07 -0000	1.423
--- i386.c	13 Jun 2002 16:03:44 -0000
*************** ix86_expand_movstr (dst, src, count_exp,
*** 9913,9919 ****
        if (count == 0 && align < desired_alignment)
  	{
  	  label = gen_label_rtx ();
! 	  emit_cmp_and_jump_insns (countreg, GEN_INT (UNITS_PER_WORD - 1),
  				   LEU, 0, counter_mode, 1, label);
  	}
        if (align <= 1)
--- 9913,9919 ----
        if (count == 0 && align < desired_alignment)
  	{
  	  label = gen_label_rtx ();
! 	  emit_cmp_and_jump_insns (countreg, GEN_INT (desired_alignment - 1),
  				   LEU, 0, counter_mode, 1, label);
  	}
        if (align <= 1)


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