Debian Codegraph @

gcc/testsuite/gcc.target/cris/peep2-movulsr.c

raw
1 /* { dg-do compile } */
2 /* { dg-final { scan-assembler "movu.w " } } */
3 /* { dg-final { scan-assembler "movu.b " } } */
4 /* { dg-final { scan-assembler-not "and.. " } } */
5 /* { dg-options "-O2" } */
6
7 /* Test the "movulsrb", "movulsrw" peephole2:s trivially. */
8
9 unsigned int
10 movulsrb (unsigned int x)
11 {
12 return (x & 255) >> 1;
13 }
14
15 unsigned int
16 movulsrw (unsigned int x)
17 {
18 return (x & 65535) >> 4;
19 }