re PR middle-end/27095 (O2 produces duplicate code)

PR middle-end/27095
	* gcc.dg/pr27095.c: New.

From-SVN: r113340
This commit is contained in:
Alan Modra 2006-04-28 03:36:15 +00:00 committed by Alan Modra
parent 33a1b314e5
commit 5cd9edb524
2 changed files with 19 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2006-04-28 Alan Modra <amodra@bigpond.net.au>
PR middle-end/27095
* gcc.dg/pr27095.c: New.
2006-04-27 Mark Mitchell <mark@codesourcery.com>
PR c++/27292

View File

@ -0,0 +1,14 @@
/* { dg-do compile } */
/* { dg-options "-O2" } */
extern void *memset (void *, int, __SIZE_TYPE__);
extern __SIZE_TYPE__ strlen (const char *);
int
main (int argc, char **argv)
{
char x[8] = "abc";
memset (x, argc, strlen (x));
return 0;
}
/* { dg-final { scan-assembler-not "(?n)strlen\(.*\n\)+.*strlen" } } */