janestreet / magic-trace

magic-trace collects and displays high-resolution traces of what a process is doing
https://magic-trace.org
MIT License
4.7k stars 93 forks source link

Allow extra spacing in cbr regex to not crash on some perf outputs #235

Closed lamoreauxaj closed 2 years ago

lamoreauxaj commented 2 years ago

I noticed when perf outputs frequencies which are three digits, then the output includes some extra spaces (in two places). I just added some extra logic to the regex to avoid this issue anymore. And I added the failure test case.