aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorKito Cheng <kito.cheng@sifive.com>2020-07-15 11:25:53 +0800
committerKito Cheng <kito.cheng@sifive.com>2020-08-06 10:59:58 +0800
commita96a44120a24b745be39bc4990aa46dbaece55e0 (patch)
tree4588a955cd2e7906fe29794e06d6d6ce8bc9586f /scripts
parent7e46b8a3d009ae223c5859df62e825ffcc2059ce (diff)
downloadriscv-gnu-toolchain-a96a44120a24b745be39bc4990aa46dbaece55e0.zip
riscv-gnu-toolchain-a96a44120a24b745be39bc4990aa46dbaece55e0.tar.gz
riscv-gnu-toolchain-a96a44120a24b745be39bc4990aa46dbaece55e0.tar.bz2
Allowlist might contain XPASS and FAIL for same case in sametime
e.g. The testcase already fail, the second XPASS is kind of false positive. FAIL: gcc.dg/analyzer/taint-1.c XPASS: gcc.dg/analyzer/taint-1.c
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/testsuite-filter7
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/testsuite-filter b/scripts/testsuite-filter
index 31ee7f0..6812d33 100755
--- a/scripts/testsuite-filter
+++ b/scripts/testsuite-filter
@@ -128,7 +128,9 @@ def read_white_lists(white_list_files, is_gcc):
print ("Each line must contail <STATUS>: .*")
print ("e.g. FAIL: g++.dg/pr83239.C")
print ("Or starts with # for comment")
- white_lists[key] = l
+ if key not in white_lists:
+ white_lists[key] = []
+ white_lists[key].append(l)
else:
white_lists.add(l)
@@ -206,7 +208,8 @@ def filter_result(tool, libc, white_list_base_dir, unexpected_results):
for ur in unexpected_result:
key = ur.split(' ')[1]
if key in white_list and \
- ur.startswith(white_list[key]):
+ any(map(lambda x:ur.startswith(x),
+ white_list[key])):
# This item can be ignored
continue
else: