[PATCH] D110424: [llvm-profgen] Ignore invalid perf line in LBR record

Wenlei He via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Sep 24 09:18:06 PDT 2021


wenlei added inline comments.


================
Comment at: llvm/tools/llvm-profgen/PerfReader.cpp:424
   if (!Records.empty() && Records[0].find('/') == StringRef::npos) {
     Index = 1;
   }
----------------
We need to make sure this is a number? 

Anything else we should check? Wondering if regex can make things easier and more robust.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D110424/new/

https://reviews.llvm.org/D110424



More information about the llvm-commits mailing list