[PERF2BOLT] Do not issue parsing error on weird build ids
In weird entries we were issueing a parse error. For example, in line 5 here: 6862acc063b0aa86595f52ff81628577df4296ff a.so 6862acc063b0aa86595f52ff81628577df4296ff a.so 6862acc063b0aa86595f52ff81628577df4296ff a.so db758cb3c970044e78d5a4c99b011708a9995636 bin1 60326683eab31acfd03435d9ed4ff9a8 bin2 7d448e51851b4bdb33eac84f90e74628a14a5f00 b.so 742aa26e0211794356cc25f415c25230a26aa045 c.so Error reading BOLT data input file: line 89, column 33: malformed field Fix that. Reviewed By: #bolt, Amir Differential Revision: https://reviews.llvm.org/D134822
This commit is contained in:
@@ -2147,7 +2147,8 @@ DataAggregator::parseNameBuildIDPair() {
|
||||
|
||||
// If one of the strings is missing, don't issue a parsing error, but still
|
||||
// do not return a value.
|
||||
if (ParsingBuf[0] == '\n')
|
||||
consumeAllRemainingFS();
|
||||
if (checkAndConsumeNewLine())
|
||||
return NoneType();
|
||||
|
||||
ErrorOr<StringRef> NameStr = parseString(FieldSeparator, true);
|
||||
|
||||
Reference in New Issue
Block a user