[compiler-rt] r273475 - [asan] Relax a flaky invalid-pointer-pairs test
Anna Zaks via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 22 13:52:21 PDT 2016
Author: zaks
Date: Wed Jun 22 15:52:21 2016
New Revision: 273475
URL: http://llvm.org/viewvc/llvm-project?rev=273475&view=rev
Log:
[asan] Relax a flaky invalid-pointer-pairs test
This test is flaky. Specifically, on some Mac configurations we see the
__sanitizer_ptr_cmp as the 0th frame. Let's relax it to not require that
f is in frame #0.
61396==ERROR: AddressSanitizer: invalid-pointer-pair: 0x01e00510 0x01e004d0
0 0x18f5a3 in __sanitizer_ptr_cmp ... libclang_rt.asan_osx_dynamic.dylib+0xaf5a3)
1 0xdd924 in f(char, char*, char*) ... invalid-pointer-pairs.cc:14:14
Differential Revision: http://reviews.llvm.org/D21588
Modified:
compiler-rt/trunk/test/asan/TestCases/invalid-pointer-pairs.cc
Modified: compiler-rt/trunk/test/asan/TestCases/invalid-pointer-pairs.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/test/asan/TestCases/invalid-pointer-pairs.cc?rev=273475&r1=273474&r2=273475&view=diff
==============================================================================
--- compiler-rt/trunk/test/asan/TestCases/invalid-pointer-pairs.cc (original)
+++ compiler-rt/trunk/test/asan/TestCases/invalid-pointer-pairs.cc Wed Jun 22 15:52:21 2016
@@ -13,10 +13,10 @@ int f(char c, char *p, char *q) {
// [[PTR1:0x[0-9a-f]+]] [[PTR2:0x[0-9a-f]+]]
switch (c) {
case 'g':
- // CMP: #0 {{.*}} in f({{char, char\*, char\*|char,char \*,char \*}}) {{.*}}invalid-pointer-pairs.cc:[[@LINE+1]]:14
+ // CMP: #{{[0-9]+ .*}} in f({{char, char\*, char\*|char,char \*,char \*}}) {{.*}}invalid-pointer-pairs.cc:[[@LINE+1]]:14
return p > q;
case 's':
- // SUB: #0 {{.*}} in f({{char, char\*, char\*|char,char \*,char \*}}) {{.*}}invalid-pointer-pairs.cc:[[@LINE+1]]:14
+ // SUB: #{{[0-9]+ .*}} in f({{char, char\*, char\*|char,char \*,char \*}}) {{.*}}invalid-pointer-pairs.cc:[[@LINE+1]]:14
return p - q;
case 'k': {
// OK-NOT: ERROR
@@ -26,7 +26,7 @@ int f(char c, char *p, char *q) {
case 'f': {
char *p3 = p + 20;
free(p);
- // FREE: #0 {{.*}} in f({{char, char\*, char\*|char,char \*,char \*}}) {{.*}}invalid-pointer-pairs.cc:[[@LINE+2]]:14
+ // FREE: #{{[0-9]+ .*}} in f({{char, char\*, char\*|char,char \*,char \*}}) {{.*}}invalid-pointer-pairs.cc:[[@LINE+2]]:14
// FREE: freed by thread
return p < p3;
}
More information about the llvm-commits
mailing list