Skip to content

Commit

Permalink
chore: update formatting on perfparser.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
lievenhey committed Jun 6, 2024
1 parent a722283 commit 18b298d
Showing 1 changed file with 58 additions and 29 deletions.
87 changes: 58 additions & 29 deletions src/parsers/perf/perfparser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,11 @@ QDataStream& operator>>(QDataStream& stream, Record& record)

QDebug operator<<(QDebug stream, const Record& record)
{
stream.noquote().nospace() << "Record{" << "pid=" << record.pid << ", " << "tid=" << record.tid << ", "
<< "time=" << record.time << ", " << "cpu=" << record.cpu << "}";
stream.noquote().nospace() << "Record{"
<< "pid=" << record.pid << ", "
<< "tid=" << record.tid << ", "
<< "time=" << record.time << ", "
<< "cpu=" << record.cpu << "}";
return stream;
}

Expand All @@ -73,7 +76,8 @@ QDataStream& operator>>(QDataStream& stream, StringId& stringId)

QDebug operator<<(QDebug stream, StringId stringId)
{
stream.noquote().nospace() << "String{" << "id=" << stringId.id << "}";
stream.noquote().nospace() << "String{"
<< "id=" << stringId.id << "}";
return stream;
}

Expand Down Expand Up @@ -105,7 +109,8 @@ QDataStream& operator>>(QDataStream& stream, AttributesDefinition& attributesDef

QDebug operator<<(QDebug stream, const AttributesDefinition& attributesDefinition)
{
stream.noquote().nospace() << "AttributesDefinition{" << "id=" << attributesDefinition.id << ", "
stream.noquote().nospace() << "AttributesDefinition{"
<< "id=" << attributesDefinition.id << ", "
<< "type=" << attributesDefinition.type << ", "
<< "config=" << attributesDefinition.config << ", "
<< "name=" << attributesDefinition.name << ", "
Expand All @@ -126,8 +131,8 @@ QDataStream& operator>>(QDataStream& stream, Command& command)

QDebug operator<<(QDebug stream, const Command& command)
{
stream.noquote().nospace() << "Command{" << static_cast<const Record&>(command) << ", " << "comm=" << command.comm
<< "}";
stream.noquote().nospace() << "Command{" << static_cast<const Record&>(command) << ", "
<< "comm=" << command.comm << "}";
return stream;
}

Expand Down Expand Up @@ -184,9 +189,12 @@ QDataStream& operator>>(QDataStream& stream, Location& location)

QDebug operator<<(QDebug stream, const Location& location)
{
stream.noquote().nospace() << "Location{" << "address=0x" << Qt::hex << location.address << Qt::dec << ", "
<< "relAddr=" << location.relAddr << ", " << "file=" << location.file << ", "
<< "pid=" << location.pid << ", " << "line=" << location.line << ", "
stream.noquote().nospace() << "Location{"
<< "address=0x" << Qt::hex << location.address << Qt::dec << ", "
<< "relAddr=" << location.relAddr << ", "
<< "file=" << location.file << ", "
<< "pid=" << location.pid << ", "
<< "line=" << location.line << ", "
<< "column=" << location.column << ", "
<< "parentLocationId=" << location.parentLocationId << "}";
return stream;
Expand All @@ -205,7 +213,8 @@ QDataStream& operator>>(QDataStream& stream, LocationDefinition& locationDefinit

QDebug operator<<(QDebug stream, const LocationDefinition& locationDefinition)
{
stream.noquote().nospace() << "LocationDefinition{" << "id=" << locationDefinition.id << ", "
stream.noquote().nospace() << "LocationDefinition{"
<< "id=" << locationDefinition.id << ", "
<< "location=" << locationDefinition.location << "}";
return stream;
}
Expand All @@ -230,10 +239,15 @@ QDataStream& operator>>(QDataStream& stream, Symbol& symbol)

QDebug operator<<(QDebug stream, const Symbol& symbol)
{
stream.noquote().nospace() << "Symbol{" << "name=" << symbol.name << ", " << "relAddr=" << symbol.relAddr << ", "
<< "size=" << symbol.size << ", " << "binary=" << symbol.binary << ", "
<< "path=" << symbol.path << ", " << "actualPath=" << symbol.actualPath << ", "
<< "isKernel=" << symbol.isKernel << ", " << "isInline=" << symbol.isInline << "}";
stream.noquote().nospace() << "Symbol{"
<< "name=" << symbol.name << ", "
<< "relAddr=" << symbol.relAddr << ", "
<< "size=" << symbol.size << ", "
<< "binary=" << symbol.binary << ", "
<< "path=" << symbol.path << ", "
<< "actualPath=" << symbol.actualPath << ", "
<< "isKernel=" << symbol.isKernel << ", "
<< "isInline=" << symbol.isInline << "}";
return stream;
}

Expand All @@ -250,7 +264,8 @@ QDataStream& operator>>(QDataStream& stream, SymbolDefinition& symbolDefinition)

QDebug operator<<(QDebug stream, const SymbolDefinition& symbolDefinition)
{
stream.noquote().nospace() << "SymbolDefinition{" << "id=" << symbolDefinition.id << ", "
stream.noquote().nospace() << "SymbolDefinition{"
<< "id=" << symbolDefinition.id << ", "
<< "symbol=" << symbolDefinition.symbol << "}";
return stream;
}
Expand All @@ -268,7 +283,8 @@ QDataStream& operator>>(QDataStream& stream, SampleCost& sampleCost)

QDebug operator<<(QDebug stream, SampleCost sampleCost)
{
stream.noquote().nospace() << "SampleCost{" << "attributeId=" << sampleCost.attributeId << ", "
stream.noquote().nospace() << "SampleCost{"
<< "attributeId=" << sampleCost.attributeId << ", "
<< "cost=" << sampleCost.cost << "}";
return stream;
}
Expand All @@ -287,9 +303,10 @@ QDataStream& operator>>(QDataStream& stream, Sample& sample)

QDebug operator<<(QDebug stream, const Sample& sample)
{
stream.noquote().nospace() << "Sample{" << static_cast<const Record&>(sample) << ", " << "frames=" << sample.frames
<< ", " << "guessedFrames=" << sample.guessedFrames << ", " << "costs=" << sample.costs
<< "}";
stream.noquote().nospace() << "Sample{" << static_cast<const Record&>(sample) << ", "
<< "frames=" << sample.frames << ", "
<< "guessedFrames=" << sample.guessedFrames << ", "
<< "costs=" << sample.costs << "}";
return stream;
}

Expand Down Expand Up @@ -323,7 +340,8 @@ QDataStream& operator>>(QDataStream& stream, StringDefinition& stringDefinition)

QDebug operator<<(QDebug stream, const StringDefinition& stringDefinition)
{
stream.noquote().nospace() << "StringDefinition{" << "id=" << stringDefinition.id << ", "
stream.noquote().nospace() << "StringDefinition{"
<< "id=" << stringDefinition.id << ", "
<< "string=" << stringDefinition.string << "}";
return stream;
}
Expand Down Expand Up @@ -359,7 +377,9 @@ QDataStream& operator>>(QDataStream& stream, BuildId& buildId)

QDebug operator<<(QDebug stream, const BuildId& buildId)
{
stream.noquote().nospace() << "BuildId{" << "pid=" << buildId.pid << ", " << "id=" << buildId.id.toHex() << ", "
stream.noquote().nospace() << "BuildId{"
<< "pid=" << buildId.pid << ", "
<< "id=" << buildId.id.toHex() << ", "
<< "fileName=" << buildId.fileName << "}";
return stream;
}
Expand All @@ -379,8 +399,10 @@ QDataStream& operator>>(QDataStream& stream, NumaNode& numaNode)

QDebug operator<<(QDebug stream, const NumaNode& numaNode)
{
stream.noquote().nospace() << "NumaNode{" << "nodeId=" << numaNode.nodeId << ", "
<< "memTotal=" << numaNode.memTotal << ", " << "memFree=" << numaNode.memFree << ", "
stream.noquote().nospace() << "NumaNode{"
<< "nodeId=" << numaNode.nodeId << ", "
<< "memTotal=" << numaNode.memTotal << ", "
<< "memFree=" << numaNode.memFree << ", "
<< "topology=" << numaNode.topology << "}";
return stream;
}
Expand All @@ -398,7 +420,9 @@ QDataStream& operator>>(QDataStream& stream, Pmu& pmu)

QDebug operator<<(QDebug stream, const Pmu& pmu)
{
stream.noquote().nospace() << "Pmu{" << "type=" << pmu.type << ", " << "name=" << pmu.name << "}";
stream.noquote().nospace() << "Pmu{"
<< "type=" << pmu.type << ", "
<< "name=" << pmu.name << "}";
return stream;
}

Expand All @@ -416,7 +440,8 @@ QDataStream& operator>>(QDataStream& stream, GroupDesc& groupDesc)

QDebug operator<<(QDebug stream, const GroupDesc& groupDesc)
{
stream.noquote().nospace() << "GroupDesc{" << "name=" << groupDesc.name << ", "
stream.noquote().nospace() << "GroupDesc{"
<< "name=" << groupDesc.name << ", "
<< "leaderIndex=" << groupDesc.leaderIndex << ", "
<< "numMembers=" << groupDesc.numMembers << "}";
return stream;
Expand Down Expand Up @@ -456,10 +481,12 @@ QDataStream& operator>>(QDataStream& stream, FeaturesDefinition& featuresDefinit

QDebug operator<<(QDebug stream, const FeaturesDefinition& featuresDefinition)
{
stream.noquote().nospace() << "FeaturesDefinition{" << "hostName=" << featuresDefinition.hostName << ", "
stream.noquote().nospace() << "FeaturesDefinition{"
<< "hostName=" << featuresDefinition.hostName << ", "
<< "osRelease=" << featuresDefinition.osRelease << ", "
<< "version=" << featuresDefinition.version << ", " << "arch=" << featuresDefinition.arch
<< ", " << "nrCpusOnline=" << featuresDefinition.nrCpusOnline << ", "
<< "version=" << featuresDefinition.version << ", "
<< "arch=" << featuresDefinition.arch << ", "
<< "nrCpusOnline=" << featuresDefinition.nrCpusOnline << ", "
<< "nrCpusAvailable=" << featuresDefinition.nrCpusAvailable << ", "
<< "cpuDesc=" << featuresDefinition.cpuDesc << ", "
<< "cpuId=" << featuresDefinition.cpuId << ", "
Expand Down Expand Up @@ -501,7 +528,9 @@ QDataStream& operator>>(QDataStream& stream, Error& error)

QDebug operator<<(QDebug stream, const Error& error)
{
stream.noquote().nospace() << "Error{" << "code=" << error.code << ", " << "message=" << error.message << "}";
stream.noquote().nospace() << "Error{"
<< "code=" << error.code << ", "
<< "message=" << error.message << "}";
return stream;
}

Expand Down

0 comments on commit 18b298d

Please sign in to comment.