Skip to content

Commit

Permalink
[BOLT][NFC] Drop MMap events for deleted files
Browse files Browse the repository at this point in the history
Don't parse/handle mmap events with "(deleted)" filename.

Reviewed By: #bolt, rafauler

Differential Revision: https://reviews.llvm.org/D151948
  • Loading branch information
aaupov committed Jun 5, 2023
1 parent db98ac0 commit a478a09
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions bolt/lib/Profile/DataAggregator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1978,6 +1978,8 @@ std::error_code DataAggregator::parseMMapEvents() {
std::pair<StringRef, MMapInfo> FileMMapInfo = FileMMapInfoRes.get();
if (FileMMapInfo.second.PID == -1)
continue;
if (FileMMapInfo.first.equals("(deleted)"))
continue;

// Consider only the first mapping of the file for any given PID
auto Range = GlobalMMapInfo.equal_range(FileMMapInfo.first);
Expand Down

0 comments on commit a478a09

Please sign in to comment.