if (dtd->dtd_data.ctti_size < 1)
break;
+ /* In BTF the CHAR `encoding' seems to not be used, so clear it
+ here. */
+ dtd->dtd_u.dtu_enc.cte_format &= ~BTF_INT_CHAR;
+
encoding = BTF_INT_DATA (dtd->dtd_u.dtu_enc.cte_format,
dtd->dtd_u.dtu_enc.cte_offset,
dtd->dtd_u.dtu_enc.cte_bits);
| 0 | encoding | offset | 00 | bits |
encoding:
signed 1 << 24
- char 2 << 24
+ char 2 << 24 (not used)
+ bool 4 << 24
All offsets in this test should be 0.
This test does _not_ check number of bits, as it may vary between targets.
/* { dg-do compile } */
/* { dg-options "-O0 -gbtf -dA" } */
-/* Check for 8 BTF_KIND_INT types. */
-/* { dg-final { scan-assembler-times "\[\t \]0x1000000\[\t \]+\[^\n\]*btt_info" 8 } } */
+/* Check for 9 BTF_KIND_INT types. */
+/* { dg-final { scan-assembler-times "\[\t \]0x1000000\[\t \]+\[^\n\]*btt_info" 9 } } */
-/* Check the signed/char flags, but not bit size. */
-/* { dg-final { scan-assembler-times "\[\t \]0x10000..\[\t \]+\[^\n\]*bti_encoding" 3 } } */
-/* { dg-final { scan-assembler-times "\[\t \]0x20000..\[\t \]+\[^\n\]*bti_encoding" 1 } } */
-/* { dg-final { scan-assembler-times "\[\t \]0x30000..\[\t \]+\[^\n\]*bti_encoding" 1 } } */
+/* Check the signed flags, but not bit size. */
+/* { dg-final { scan-assembler-times "\[\t \]0x10000..\[\t \]+\[^\n\]*bti_encoding" 4 } } */
+/* { dg-final { scan-assembler-times "\[\t \]0x..\[\t \]+\[^\n\]*bti_encoding" 3 } } */
+/* { dg-final { scan-assembler-times "\[\t \]0x.\[\t \]+\[^\n\]*bti_encoding" 1 } } */
+/* { dg-final { scan-assembler-times "\[\t \]0x40000..\[\t \]+\[^\n\]*bti_encoding" 1 } } */
/* Check that there is a string entry for each type name. */
/* { dg-final { scan-assembler-times "ascii \"unsigned char.0\"\[\t \]+\[^\n\]*btf_string" 1 } } */
unsigned long int g = 77;
signed long int h = 88;
+
+_Bool x = 1;