@@ -827,13 +827,8 @@ bool DataAggregator::doTrace(const LBREntry &First, const LBREntry &Second,
827827 << FromFunc->getPrintName () << " :"
828828 << Twine::utohexstr (First.To ) << " to "
829829 << Twine::utohexstr (Second.From ) << " .\n " );
830- for (auto [From, To] : *FTs) {
831- if (BAT) {
832- From = BAT->translate (FromFunc->getAddress (), From, /* IsBranchSrc=*/ true );
833- To = BAT->translate (FromFunc->getAddress (), To, /* IsBranchSrc=*/ false );
834- }
830+ for (auto [From, To] : *FTs)
835831 doIntraBranch (*ParentFunc, From, To, Count, false );
836- }
837832
838833 return true ;
839834}
@@ -972,7 +967,7 @@ bool DataAggregator::recordExit(BinaryFunction &BF, uint64_t From, bool Mispred,
972967 return true ;
973968}
974969
975- ErrorOr<LBREntry> DataAggregator::parseLBREntry () {
970+ ErrorOr<DataAggregator:: LBREntry> DataAggregator::parseLBREntry () {
976971 LBREntry Res;
977972 ErrorOr<StringRef> FromStrRes = parseString (' /' );
978973 if (std::error_code EC = FromStrRes.getError ())
@@ -2289,6 +2284,7 @@ std::error_code DataAggregator::writeBATYAML(BinaryContext &BC,
22892284 YamlBF.Id = BF->getFunctionNumber ();
22902285 YamlBF.Hash = BAT->getBFHash (FuncAddress);
22912286 YamlBF.ExecCount = BF->getKnownExecutionCount ();
2287+ YamlBF.ExternEntryCount = BF->getExternEntryCount ();
22922288 YamlBF.NumBasicBlocks = BAT->getNumBasicBlocks (FuncAddress);
22932289 const BoltAddressTranslation::BBHashMapTy &BlockMap =
22942290 BAT->getBBHashMap (FuncAddress);
@@ -2398,16 +2394,10 @@ std::error_code DataAggregator::writeBATYAML(BinaryContext &BC,
23982394
23992395void DataAggregator::dump () const { DataReader::dump (); }
24002396
2401- void DataAggregator::dump (const LBREntry &LBR) const {
2402- Diag << " From: " << Twine::utohexstr (LBR.From )
2403- << " To: " << Twine::utohexstr (LBR.To ) << " Mispred? " << LBR.Mispred
2404- << " \n " ;
2405- }
2406-
24072397void DataAggregator::dump (const PerfBranchSample &Sample) const {
24082398 Diag << " Sample LBR entries: " << Sample.LBR .size () << " \n " ;
24092399 for (const LBREntry &LBR : Sample.LBR )
2410- dump ( LBR) ;
2400+ Diag << LBR << ' \n ' ;
24112401}
24122402
24132403void DataAggregator::dump (const PerfMemSample &Sample) const {
0 commit comments