diff options
Diffstat (limited to 'llvm/utils/UpdateTestChecks/common.py')
-rw-r--r-- | llvm/utils/UpdateTestChecks/common.py | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/llvm/utils/UpdateTestChecks/common.py b/llvm/utils/UpdateTestChecks/common.py index d1fd884..5c3775e 100644 --- a/llvm/utils/UpdateTestChecks/common.py +++ b/llvm/utils/UpdateTestChecks/common.py @@ -32,6 +32,14 @@ Version changelog: DEFAULT_VERSION = 4 +SUPPORTED_ANALYSES = { + "Branch Probability Analysis", + "Cost Model Analysis", + "Loop Access Analysis", + "Scalar Evolution Analysis", +} + + class Regex(object): """Wrap a compiled regular expression object to allow deep copy of a regexp. This is required for the deep copy done in do_scrub. @@ -773,12 +781,7 @@ class FunctionTestBuilder: ) if "analysis" in m.groupdict(): analysis = m.group("analysis") - supported_analyses = { - "cost model analysis", - "scalar evolution analysis", - "loop access analysis", - } - if analysis.lower() not in supported_analyses: + if analysis not in SUPPORTED_ANALYSES: warn("Unsupported analysis mode: %r!" % (analysis,)) if func.startswith("stress"): # We only use the last line of the function body for stress tests. |