+Tue Jan 21 18:01:35 CET 2003 Jan Hubicka <jh@suse.cz>
+
+ * gcc.c-torture/execute/990208-1.c: Add noinline attributes as needed.
+ * gcc.c-torture/execute/eeprof-1.c: Likewise.
+ * gcc.c-torture/execute/stdio-opt-*.c: Likewise.
+ * gcc.c-torture/execute/string-opt-*.c: Likewise.
+
2003-01-20 Nick Clifton <nickc@redhat.com>
* gcc.c-torture/execute/20030117-1.c: New test case. Exposes
}
}
+__attribute__ ((noinline))
static void f(int cond)
{
doit (&ptr1, cond);
}
+__attribute__ ((noinline))
static void g(int cond)
{
doit (&ptr2, cond);
}
+__attribute__ ((noinline))
static void bar(void);
int main()
void (*last_fn_entered)();
void (*last_fn_exited)();
+__attribute__ ((noinline))
int main () NOCHK;
+__attribute__ ((noinline))
void foo ()
{
ASSERT (last_fn_entered == foo);
}
+__attribute__ ((noinline))
static void foo2 ()
{
ASSERT (entry_calls == 1 && exit_calls == 0);
ASSERT (last_fn_exited == foo);
}
+__attribute__ ((noinline))
void nfoo (void) NOCHK;
void nfoo ()
{
void __cyg_profile_func_enter (void (*fn)(), void (*parent)()) NOCHK;
void __cyg_profile_func_exit (void (*fn)(), void (*parent)()) NOCHK;
+__attribute__ ((noinline))
void __cyg_profile_func_enter (void (*fn)(), void (*parent)())
{
entry_calls++;
last_fn_entered = fn;
}
+__attribute__ ((noinline))
void __cyg_profile_func_exit (void (*fn)(), void (*parent)())
{
exit_calls++;
+
/* Origin: Kaveh Ghazi <ghazi@caip.rutgers.edu> 2002-05-27. */
/* Use a different function for each test so the link failures
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static int
fputs(const char *string, FILE *stream)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static int
printf (const char *string, ...)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static int
fprintf (FILE *stream, const char *string, ...)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static char *
strstr(const char *s1, const char *s2)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static char *
strncat (char *s1, const char *s2, size_t n)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static size_t
strspn (const char *s1, const char *s2)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static size_t
strcspn (const char *s1, const char *s2)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static size_t
strlen (const char *s)
{
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static void *
memset (void *s, int c, size_t n)
{
abort ();
}
+__attribute__ ((noinline))
static void *
memcpy (void *dest, const void *src, size_t n)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static int
memcmp (const char *p1, const char *p2, size_t len)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static int
memcmp (const void *s1, const void *s2, size_t len)
{
#else
/* When not optimizing, the above tests may generate references to
the function link_error, but should never actually call it. */
+__attribute__ ((noinline))
static void
link_error ()
{
/* When optimizing, most of the above cases should be transformed into
something else. So any remaining calls to the original function
for short lengths should abort. */
+__attribute__ ((noinline))
static void *
memset (void *dst, int c, size_t len)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static char *
strpbrk(const char *s1, const char *s2)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static __SIZE_TYPE__
strlen (const char *s)
{
abort ();
}
+__attribute__ ((noinline))
static int
strcmp (const char *s1, const char *s2)
{
abort ();
}
+__attribute__ ((noinline))
static char *
strrchr (const char *s, int c)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static char *
strchr (const char *s, int c)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static char *
strcpy (char *d, const char *s)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static char *
strncpy(char *s1, const char *s2, size_t n)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static int
strncmp(const char *s1, const char *s2, size_t n)
{
/* When optimizing, all the above cases should be transformed into
something else. So any remaining calls to the original function
should abort. */
+__attribute__ ((noinline))
static char *
strcat (char *s1, const char *s2)
{