The attached patch disables two asan tests introduced in r194458 which are 
invalid
on darwin. The g++.dg/asan/interception-test-1.C test is invalid on darwin 
since 
mac function interposition is used instead of interception. The 
c-c++-common/asan/swapcontext-test-1.c
test is invalid as ucontext support was deprecated in darwin10 and removed 
completely
in darwin11. Tested on x86_64-apple-darwin10. Okay for gcc trunk?
         Jack
gcc/testsuite/

2012-12-13  Jack Howarth <howa...@bromo.med.uc.edu>

        PR 55679/sanitizer
        * g++.dg/asan/interception-test-1.C: Skip on darwin.
        * c-c++-common/asan/swapcontext-test-1.c: Likewise.

Index: gcc/testsuite/g++.dg/asan/interception-test-1.C
===================================================================
--- gcc/testsuite/g++.dg/asan/interception-test-1.C     (revision 194483)
+++ gcc/testsuite/g++.dg/asan/interception-test-1.C     (working copy)
@@ -3,6 +3,7 @@
 // { dg-do run }
 // { dg-options "-fno-builtin-malloc -fno-builtin-free" }
 // { dg-shouldfail "asan" }
+// { dg-skip-if "Darwin uses mac function interposition" { *-*-darwin* } }
 
 #include <stdlib.h>
 #include <stdio.h>
Index: gcc/testsuite/c-c++-common/asan/swapcontext-test-1.c
===================================================================
--- gcc/testsuite/c-c++-common/asan/swapcontext-test-1.c        (revision 
194483)
+++ gcc/testsuite/c-c++-common/asan/swapcontext-test-1.c        (working copy)
@@ -1,6 +1,7 @@
 /* Check that ASan plays well with easy cases of makecontext/swapcontext. */
 
 /* { dg-do run { target swapcontext } } */
+// { dg-skip-if "Ucontext support deprecated on darwin" { *-*-darwin* } }
 
 #include <stdio.h>
 #include <ucontext.h>

Reply via email to