aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2021-06-21 09:33:55 +0000
committerGitHub <noreply@github.com>2021-06-21 09:33:55 +0000
commit7d3157eec84ef8620f4648200f54b293e561b8c4 (patch)
treeea151c53744428c8ae9984bac03e25c279e0b533 /gcc
parent8528f4b25f59cf10c093715d56f7a37c4ab6b732 (diff)
parent485f4cf7a672b66c1a15c6bdf275f2f06c173f56 (diff)
downloadgcc-7d3157eec84ef8620f4648200f54b293e561b8c4.zip
gcc-7d3157eec84ef8620f4648200f54b293e561b8c4.tar.gz
gcc-7d3157eec84ef8620f4648200f54b293e561b8c4.tar.bz2
Merge #513
513: Fix up test suite buglets r=philberty a=tromey Mark Wielaard pointed out that the i8u8.rs test that I recently introduced has a bug: it checks the DW_AT_language attribute, not DW_AT_encoding. Sorry about this. This patch fixes this problem. I've verified that this notices the failure after temporarily backing out the corresponding GCC change. This patch also fixes another problem that he found, namely that it's possible for these tests to find the wrong answer, because the hex value that is checked for might be a prefix of some longer value. This patch also adds a whitespace check to avoid this potential problem. Co-authored-by: Tom Tromey <tom@tromey.com>
Diffstat (limited to 'gcc')
-rw-r--r--gcc/testsuite/rust/debug/chartype.rs2
-rw-r--r--gcc/testsuite/rust/debug/i8u8.rs4
-rw-r--r--gcc/testsuite/rust/debug/lang.rs2
-rw-r--r--gcc/testsuite/rust/debug/oldlang.rs2
4 files changed, 5 insertions, 5 deletions
diff --git a/gcc/testsuite/rust/debug/chartype.rs b/gcc/testsuite/rust/debug/chartype.rs
index 5504481..69e7ab0 100644
--- a/gcc/testsuite/rust/debug/chartype.rs
+++ b/gcc/testsuite/rust/debug/chartype.rs
@@ -6,5 +6,5 @@ fn main () {
// DW_ATE_UTF entered in DWARF 4.
// { dg-options "-w -gdwarf-4 -dA" }
// DW_ATE_UTF = 0x10
-// { dg-final { scan-assembler "0x10\[^\n\r]* DW_AT_encoding" } } */
+// { dg-final { scan-assembler "0x10\[ \t]\[^\n\r]* DW_AT_encoding" } } */
}
diff --git a/gcc/testsuite/rust/debug/i8u8.rs b/gcc/testsuite/rust/debug/i8u8.rs
index 8f0dd19..1cd21a4 100644
--- a/gcc/testsuite/rust/debug/i8u8.rs
+++ b/gcc/testsuite/rust/debug/i8u8.rs
@@ -6,7 +6,7 @@ fn main () {
// Use -w to avoid warnings about the unused variables
// { dg-options "-w -g -dA" }
// DW_ATE_signed_char = 6
-// { dg-final { scan-assembler-not "0x6\[^\n\r]* DW_AT_language" } } */
+// { dg-final { scan-assembler-not "0x6\[ \t]\[^\n\r]* DW_AT_encoding" } } */
// DW_ATE_unsigned_char = 8
-// { dg-final { scan-assembler-not "0x8\[^\n\r]* DW_AT_language" } } */
+// { dg-final { scan-assembler-not "0x8\[ \t]\[^\n\r]* DW_AT_encoding" } } */
}
diff --git a/gcc/testsuite/rust/debug/lang.rs b/gcc/testsuite/rust/debug/lang.rs
index eec5264..12e0b58 100644
--- a/gcc/testsuite/rust/debug/lang.rs
+++ b/gcc/testsuite/rust/debug/lang.rs
@@ -2,5 +2,5 @@ fn main () {
// { dg-do compile }
// { dg-options "-gdwarf-5 -dA" }
// DW_LANG_Rust is 0x1c
-// { dg-final { scan-assembler "0x1c\[^\n\r]* DW_AT_language" } } */
+// { dg-final { scan-assembler "0x1c\[ \t]\[^\n\r]* DW_AT_language" } } */
}
diff --git a/gcc/testsuite/rust/debug/oldlang.rs b/gcc/testsuite/rust/debug/oldlang.rs
index d80a5db..ddacf0e 100644
--- a/gcc/testsuite/rust/debug/oldlang.rs
+++ b/gcc/testsuite/rust/debug/oldlang.rs
@@ -2,5 +2,5 @@ fn main () {
// { dg-do compile }
// { dg-options "-gstrict-dwarf -gdwarf-3 -dA" }
// DW_LANG_Rust_old is 0x9000
-// { dg-final { scan-assembler "0x9000\[^\n\r]* DW_AT_language" } } */
+// { dg-final { scan-assembler "0x9000\[ \t]\[^\n\r]* DW_AT_language" } } */
}