]> granicus.if.org Git - llvm/commitdiff
[opt-viewer] Teach optrecord.py about !Failure tags
authorJessica Paquette <jpaquette@apple.com>
Wed, 27 Mar 2019 18:35:04 +0000 (18:35 +0000)
committerJessica Paquette <jpaquette@apple.com>
Wed, 27 Mar 2019 18:35:04 +0000 (18:35 +0000)
WarnMissedTransforms.cpp produces remarks that use !Failure tags.

These weren't supported in optrecord.py, so if you encountered one in any of
the tools, the tool would crash.

Add them as a type of missed optimization.

Differential Revision: https://reviews.llvm.org/D59895

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@357110 91177308-0d34-0410-b5e6-96231b3b80d8

tools/opt-viewer/optrecord.py

index 81d6da9ed6e8cda2cb389a5f32de282918b27373..f6fd772689a9c5479392a2c517ca0e56249a95d9 100644 (file)
@@ -264,6 +264,8 @@ class Missed(Remark):
     def color(self):
         return "red"
 
+class Failure(Missed):
+    yaml_tag = '!Failure'
 
 def get_remarks(input_file, filter_=None):
     max_hotness = 0