OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [testsuite/] [gcc.misc-tests/] [i386-pf-athlon-1.c] - Diff between revs 149 and 154

Go to most recent revision | Only display areas with differences | Details | Blame | View Log

Rev 149 Rev 154
/* Test that the correct data prefetch instructions are generated for i386
/* Test that the correct data prefetch instructions are generated for i386
   variants that use 3DNow! prefetchw or SSE prefetch instructions with
   variants that use 3DNow! prefetchw or SSE prefetch instructions with
   locality hints.  */
   locality hints.  */
 
 
/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
/* { dg-do compile { target i?86-*-* x86_64-*-* } } */
/* { dg-require-effective-target ilp32 } */
/* { dg-require-effective-target ilp32 } */
 
 
extern void exit (int);
extern void exit (int);
 
 
char *msg = "howdy there";
char *msg = "howdy there";
 
 
void foo (char *p)
void foo (char *p)
{
{
  __builtin_prefetch (p, 0, 0);
  __builtin_prefetch (p, 0, 0);
  __builtin_prefetch (p, 0, 1);
  __builtin_prefetch (p, 0, 1);
  __builtin_prefetch (p, 0, 2);
  __builtin_prefetch (p, 0, 2);
  __builtin_prefetch (p, 0, 3);
  __builtin_prefetch (p, 0, 3);
  __builtin_prefetch (p, 1, 0);
  __builtin_prefetch (p, 1, 0);
  __builtin_prefetch (p, 1, 1);
  __builtin_prefetch (p, 1, 1);
  __builtin_prefetch (p, 1, 2);
  __builtin_prefetch (p, 1, 2);
  __builtin_prefetch (p, 1, 3);
  __builtin_prefetch (p, 1, 3);
}
}
 
 
int main ()
int main ()
{
{
  foo (msg);
  foo (msg);
  exit (0);
  exit (0);
}
}
 
 
/* { dg-final { scan-assembler "prefetchw" } } */
/* { dg-final { scan-assembler "prefetchw" } } */
/* { dg-final { scan-assembler "prefetchnta" } } */
/* { dg-final { scan-assembler "prefetchnta" } } */
/* { dg-final { scan-assembler "prefetcht" } } */
/* { dg-final { scan-assembler "prefetcht" } } */
 
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.