(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
debug/
btf/
btf-bitfields-4.c
       1  /* Test BTF generation for non-representable bitfields.
       2  
       3     Due to the limitations of BTF, we only have 24 bits in which to store
       4     the bitfield offset (in bits, from the beginning of the struct).
       5  
       6     In this test, we construct a structure such that the bitfield will have
       7     an offset so large as to be unrepresentable in BTF. We expect that the
       8     resulting BTF will describe the rest of the structure, ignoring the
       9     non-representable bitfield.  */
      10  
      11  /* { dg-do compile } */
      12  /* { dg-options "-O0 -gbtf -dA" } */
      13  
      14  /* Struct with 3 members and no bitfield (kind_flag not set).  */
      15  /* { dg-final { scan-assembler-times "\[\t \]0x4000003\[\t \]+\[^\n\]*btt_info" 1 } } */
      16  
      17  struct bigly
      18  {
      19    int a;
      20    int b[((0xffffff + 1) / (8 * sizeof (int)))];
      21    unsigned unsup : 7;
      22    char c;
      23  } big;