Debian Codegraph @

gcc/testsuite/gcc.target/loongarch/vect-shift-imm-round.c

raw
1 /* { dg-do compile } */
2 /* { dg-options "-O2 -march=loongarch64 -mlsx" } */
3 /* { dg-final { scan-assembler "vsrari\\.w\t\\\$vr\[0-9\]+,\\\$vr\[0-9\]+,15" } } */
4
5 int x __attribute__ ((vector_size (16)));
6
7 void
8 f (void)
9 {
10 x = (x + (1 << 14)) >> 15;
11 }