(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.target/
aarch64/
cmpimm_branch_1.c
       1  /* { dg-do compile } */
       2  /* { dg-options "-save-temps -O2" } */
       3  
       4  /* Test that we emit a sub+subs sequence rather than mov+movk+cmp.  */
       5  
       6  void g (void);
       7  void
       8  foo (int x)
       9  {
      10    if (x != 0x123456)
      11      g ();
      12  }
      13  
      14  void
      15  fool (long long x)
      16  {
      17    if (x != 0x123456)
      18      g ();
      19  }
      20  
      21  /* { dg-final { scan-assembler-not "cmp\tw\[0-9\]*.*" } } */
      22  /* { dg-final { scan-assembler-not "cmp\tx\[0-9\]*.*" } } */
      23  /* { dg-final { scan-assembler-times "sub\tw\[0-9\]+.*" 1 } } */
      24  /* { dg-final { scan-assembler-times "sub\tx\[0-9\]+.*" 1 } } */
      25  /* { dg-final { scan-assembler-times "subs\tw\[0-9\]+.*" 1 } } */
      26  /* { dg-final { scan-assembler-times "subs\tx\[0-9\]+.*" 1 } } */