Skip to content

Commit

Permalink
hwasan: adjust wording in expected output in tests
Browse files Browse the repository at this point in the history
gcc/testsuite/ChangeLog:

	* c-c++-common/hwasan/asan-pr70541.c: Adjust wording of expected
	output.
	* c-c++-common/hwasan/heap-overflow.c: Likewise.
	* c-c++-common/hwasan/sanity-check-pure-c.c: Likewise.
	* c-c++-common/hwasan/use-after-free.c: Likewise.
  • Loading branch information
marxin committed Apr 30, 2023
1 parent 54765c8 commit 84e7d62
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion gcc/testsuite/c-c++-common/hwasan/asan-pr70541.c
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,4 @@ int main() {
/* { dg-output "HWAddressSanitizer: tag-mismatch on address 0x\[0-9a-f\]*.*" } */
/* { dg-output "READ of size 4 at 0x\[0-9a-f\]* tags: \[\[:xdigit:\]\]\[\[:xdigit:\]\]/\[\[:xdigit:\]\]\[\[:xdigit:\]\] \\(ptr/mem\\) in thread T0.*" } */
/* { dg-output "freed by thread T0 here:.*" } */
/* { dg-output "previously allocated here:" } */
/* { dg-output "previously allocated by thread T0 here:" } */
4 changes: 2 additions & 2 deletions gcc/testsuite/c-c++-common/hwasan/heap-overflow.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,6 @@ int main(int argc, char **argv) {

/* { dg-output "HWAddressSanitizer: tag-mismatch on address 0x\[0-9a-f\]*.*" } */
/* { dg-output "READ of size 1 at 0x\[0-9a-f\]* tags: \[\[:xdigit:\]\]\[\[:xdigit:\]\]/\[\[:xdigit:\]\]\[\[:xdigit:\]\].* \\(ptr/mem\\) in thread T0.*" } */
/* { dg-output "located 0 bytes after 10-byte region.*" } */
/* { dg-output "allocated here:.*" } */
/* { dg-output "located 0 bytes after a 10-byte region.*" } */
/* { dg-output "allocated by thread T0 here:.*" } */
/* { dg-output "#1 0x\[0-9a-f\]+ +in _*main \[^\n\r]*heap-overflow.c:18" } */
4 changes: 2 additions & 2 deletions gcc/testsuite/c-c++-common/hwasan/sanity-check-pure-c.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,6 @@ int main() {

/* { dg-output "HWAddressSanitizer: tag-mismatch on address 0x\[0-9a-f\]*.*" } */
/* { dg-output "READ of size 1 at 0x\[0-9a-f\]* tags: \[\[:xdigit:\]\]\[\[:xdigit:\]\]/\[\[:xdigit:\]\]\[\[:xdigit:\]\] \\(ptr/mem\\) in thread T0.*" } */
/* { dg-output "located 5 bytes inside of 10-byte region.*" } */
/* { dg-output "located 5 bytes inside a 10-byte region.*" } */
/* { dg-output "freed by thread T0 here:.*" } */
/* { dg-output "previously allocated here:" } */
/* { dg-output "previously allocated by thread T0 here:" } */
4 changes: 2 additions & 2 deletions gcc/testsuite/c-c++-common/hwasan/use-after-free.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ int main() {

/* { dg-output "HWAddressSanitizer: tag-mismatch on address 0x\[0-9a-f\]*.*" } */
/* { dg-output "READ of size 1 at 0x\[0-9a-f\]* tags: \[\[:xdigit:\]\]\[\[:xdigit:\]\]/\[\[:xdigit:\]\]\[\[:xdigit:\]\] \\(ptr/mem\\) in thread T0.*" } */
/* { dg-output "is located 5 bytes inside of 10-byte region.*" } */
/* { dg-output "is located 5 bytes inside a 10-byte region.*" } */
/* { dg-output "freed by thread T0 here:.*" } */
/* { dg-output "#1\[^\n\r]*main\[^\n\r]*use-after-free.c:17.*" } */
/* { dg-output "previously allocated here:.*" } */
/* { dg-output "previously allocated by thread T0 here:.*" } */
/* { dg-output "#1\[^\n\r]*main\[^\n\r]*use-after-free.c:16" } */

0 comments on commit 84e7d62

Please sign in to comment.