From 71d5a2540a98c81f5bcaeb48805e0e2881f530ef Mon Sep 17 00:00:00 2001 From: Dimitry Andric Date: Sun, 16 Apr 2017 16:01:22 +0000 Subject: Vendor import of llvm trunk r300422: https://llvm.org/svn/llvm-project/llvm/trunk@300422 --- utils/update_test_checks.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'utils/update_test_checks.py') diff --git a/utils/update_test_checks.py b/utils/update_test_checks.py index 92ab5ef6599c..cace9023106f 100755 --- a/utils/update_test_checks.py +++ b/utils/update_test_checks.py @@ -66,11 +66,11 @@ OPT_FUNCTION_RE = re.compile( r'^\s*define\s+(?:internal\s+)?[^@]*@(?P[\w-]+?)\s*\(' r'(\s+)?[^)]*[^{]*\{\n(?P.*?)^\}$', flags=(re.M | re.S)) -CHECK_PREFIX_RE = re.compile('--check-prefix=(\S+)') +CHECK_PREFIX_RE = re.compile('--?check-prefix(?:es)?=(\S+)') CHECK_RE = re.compile(r'^\s*;\s*([^:]+?)(?:-NEXT|-NOT|-DAG|-LABEL)?:') # Match things that look at identifiers, but only if they are followed by # spaces, commas, paren, or end of the string -IR_VALUE_RE = re.compile(r'(\s+)%(.+?)([,\s\(\)]|\Z)') +IR_VALUE_RE = re.compile(r'(\s+)%([\w\.]+?)([,\s\(\)]|\Z)') # Invoke the tool that is being tested. @@ -324,8 +324,8 @@ def main(): tool_cmd_args = tool_cmd[len(tool_basename):].strip() tool_cmd_args = tool_cmd_args.replace('< %s', '').replace('%s', '').strip() - check_prefixes = [m.group(1) - for m in CHECK_PREFIX_RE.finditer(filecheck_cmd)] + check_prefixes = [item for m in CHECK_PREFIX_RE.finditer(filecheck_cmd) + for item in m.group(1).split(',')] if not check_prefixes: check_prefixes = ['CHECK'] -- cgit v1.2.3