Skip to content

Commit

Permalink
[utils] Fix regexp in llvm/utils/extract_vplan.py to extract VPlans.
Browse files Browse the repository at this point in the history
Regarding this bug in Bugzilla: https://bugs.llvm.org/show_bug.cgi?id=46451

I went ahead and fixed the regexp pattern and now Python script is able
to extract vplan graphs from the log files. Additionally some test for
this would be nice to have but I'm not sure are Python scripts tested
in LLVM and if so where they live.

Reviewed By: fhahn

Differential Revision: https://reviews.llvm.org/D86068
  • Loading branch information
Kazhuu authored and fhahn committed Aug 19, 2020
1 parent 8351e80 commit c789939
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion llvm/utils/extract_vplan.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
matches = re.findall(pattern, sys.stdin.read())

for vplan in matches:
m = re.search("graph \[.+(VF=.+,UF.+), ", vplan)
m = re.search("graph \[.+(VF=.+,UF.+)", vplan)
if not m:
raise ValueError("Can't get the right VPlan name")
name = re.sub('[^a-zA-Z0-9]', '', m.group(1))
Expand Down

0 comments on commit c789939

Please sign in to comment.