Merge -r 127928:132243 from trunk
[official-gcc.git] / gcc / testsuite / gcc.target / cris / builtin_ctz_v8.c
blob853b1740aac7db4412dfffefe34e0782757686ec
1 /* Check that we use the swap insn for ctz by checking assembler output.
2 The swap instruction was implemented in v8. */
3 /* { dg-do compile } */
4 /* { dg-skip-if "" { "cris*-*-elf" } { "-march*" } { "" } } */
5 /* { dg-options "-O2 -march=v8" } */
6 /* { dg-final { scan-assembler "\[ \t\]swapwbr\[ \t\]" } } */
8 int
9 f (int a)
11 return __builtin_ctz(a);