2009-07-17 Richard Guenther <rguenther@suse.de>
[official-gcc.git] / gcc / testsuite / gcc.target / mips / cache-1.c
blob05cb40791576d8f75b5d2bd6ec013675340ee369
1 /* { dg-options "-O2 isa>=3" } */
3 NOMIPS16 void
4 f1 (int *area)
6 __builtin_mips_cache (20, area);
9 NOMIPS16 void
10 f2 (const short *area)
12 __builtin_mips_cache (24, area + 10);
15 NOMIPS16 void
16 f3 (volatile unsigned int *area, int offset)
18 __builtin_mips_cache (0, area + offset);
21 NOMIPS16 void
22 f4 (const volatile unsigned char *area)
24 __builtin_mips_cache (4, area - 80);
27 /* { dg-final { scan-assembler "\tcache\t0x14,0\\(\\\$4\\)" } } */
28 /* { dg-final { scan-assembler "\tcache\t0x18,20\\(\\\$4\\)" } } */
29 /* { dg-final { scan-assembler "\tcache\t0x0,0\\(\\\$.\\)" } } */
30 /* { dg-final { scan-assembler "\tcache\t0x4,-80\\(\\\$4\\)" } } */