aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorIndu Bhagat <indu.bhagat@oracle.com>2021-07-06 16:02:38 -0700
committerIndu Bhagat <indu.bhagat@oracle.com>2021-07-06 16:02:38 -0700
commit97bcacfb5ac49afa4e305489dd110cc446451549 (patch)
tree7d280735a354cfda1d4e4d25e3b459c88d94bd29 /gcc
parente8db5f70f27b6de8139339ef1866eaa153c2bf67 (diff)
downloadgcc-97bcacfb5ac49afa4e305489dd110cc446451549.zip
gcc-97bcacfb5ac49afa4e305489dd110cc446451549.tar.gz
gcc-97bcacfb5ac49afa4e305489dd110cc446451549.tar.bz2
CTF testsuite: Remove explicit check on ctv_typeidx
The value of ctv_typeidx is the CTF type ID of the data type of the associated variable. The order in which the CTF types are added can change across platforms and also as the code evolves, hence changing the CTF type ID. As there is no direct and portable method of testing that the data type of a CTF variable is of a specific kind, remove the check on ctv_typeidx. This also fixes a subset of failures as seen on Darwin. 2021-07-06 Indu Bhagat <indu.bhagat@oracle.com> gcc/testsuite/ChangeLog: PR debug/101283 * gcc.dg/debug/ctf/ctf-attr-mode-1.c: Remove the check for ctv_typeidx.
Diffstat (limited to 'gcc')
-rw-r--r--gcc/testsuite/gcc.dg/debug/ctf/ctf-attr-mode-1.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/gcc/testsuite/gcc.dg/debug/ctf/ctf-attr-mode-1.c b/gcc/testsuite/gcc.dg/debug/ctf/ctf-attr-mode-1.c
index fc3af03..c4801a7 100644
--- a/gcc/testsuite/gcc.dg/debug/ctf/ctf-attr-mode-1.c
+++ b/gcc/testsuite/gcc.dg/debug/ctf/ctf-attr-mode-1.c
@@ -1,7 +1,10 @@
/* Test CTF generation works well with ((mode)) attribute.
In this testcase, CTF should report type of bqi to be an enum and
- not an int. */
+ not an int. Also, CTF for typedef of enum should exist. However, there
+ are no direct and portable methods of checking that a CTF type / CTF
+ variable refers to a specific CTF type, so this testcase merely asserts
+ for existence of individual CTF records. */
/* { dg-do compile ) */
/* { dg-options "-O0 -gctf -dA" } */
@@ -16,7 +19,5 @@
/* { dg-final { scan-assembler-times "\[\t \]0x22000003\[\t \]+\[^\n\]*ctt_info" 1 } } */
/* { dg-final { scan-assembler-times "\[\t \]0x2a000000\[\t \]+\[^\n\]*ctt_info" 1 } } */
-/* { dg-final { scan-assembler-times "\[\t \]0x3\[\t \]+\[^\n\]*ctv_typeidx" 1} } */
-
typedef enum { B1 = 1, B2 = 2, B3 = 3 } B;
B __attribute__ ((mode (QI))) bqi;