From f3d6b759e194bbf3eb703dacedfffb16f264161f Mon Sep 17 00:00:00 2001 From: Dmitry Vyukov Date: Mon, 7 Dec 2015 07:27:50 -0800 Subject: [PATCH] Fix new sancov tests * gcc.dg/sancov/sancov.exp: Load asan-dg.exp. * gcc.dg/sancov/asan.c: Don't run when asan is not available. From-SVN: r231364 --- gcc/testsuite/ChangeLog | 5 +++++ gcc/testsuite/gcc.dg/sancov/asan.c | 2 +- gcc/testsuite/gcc.dg/sancov/sancov.exp | 1 + 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 0c96d70676e..a937bb3b118 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2015-12-06 Dmitry Vyukov + + * gcc.dg/sancov/sancov.exp: Load asan-dg.exp. + * gcc.dg/sancov/asan.c: Don't run when asan is not available. + 2015-12-07 Nathan Sidwell * gcc.target/nvptx/decl-init.c: New. diff --git a/gcc/testsuite/gcc.dg/sancov/asan.c b/gcc/testsuite/gcc.dg/sancov/asan.c index f566ed2cd4d..64a36b54a92 100644 --- a/gcc/testsuite/gcc.dg/sancov/asan.c +++ b/gcc/testsuite/gcc.dg/sancov/asan.c @@ -3,7 +3,7 @@ - coverage does not instrument asan-emitted basic blocks - asan considers coverage callback as "nonfreeing" (thus 1 asan store callback. */ -/* { dg-do compile } */ +/* { dg-do compile { target fsanitize_address } } */ /* { dg-options "-fsanitize-coverage=trace-pc -fsanitize=address -fdump-tree-optimized" } */ void foo(volatile int *a, int *b) diff --git a/gcc/testsuite/gcc.dg/sancov/sancov.exp b/gcc/testsuite/gcc.dg/sancov/sancov.exp index e36d743a3cd..a9b48e21633 100644 --- a/gcc/testsuite/gcc.dg/sancov/sancov.exp +++ b/gcc/testsuite/gcc.dg/sancov/sancov.exp @@ -17,6 +17,7 @@ # . load_lib gcc-dg.exp +load_lib asan-dg.exp load_lib torture-options.exp dg-init -- 2.30.2