1  /* { dg-options "-O2 -fdump-rtl-expand -mtune=core2" } */
       2  /* { dg-skip-if "" { ! { i?86-*-* x86_64-*-* } } } */
       3  
       4  long buffer1[128], buffer2[128];
       5  char *x;
       6  
       7  void foo(long *r)
       8  {
       9    x = (char *)r;
      10    asm volatile("" ::: "memory");
      11  }
      12  
      13  void
      14  __attribute__((noinline))
      15  compute()
      16  {
      17    volatile int n = 24;
      18    __builtin_memcpy (buffer1, buffer2, n);
      19    foo (&buffer1[0]);
      20  }
      21  
      22  int
      23  main()
      24  {
      25    for (unsigned i = 0; i < 10000; i++)
      26      compute ();
      27  
      28    return 0;
      29  }
      30  
      31  /* { dg-final-use-not-autofdo { scan-rtl-dump "Selected stringop expansion strategy: rep_byte" "expand" } } */