mirror of
https://gitee.com/openharmony/developtools_hiperf
synced 2024-12-03 13:21:53 +00:00
告警清理
Signed-off-by:wenlong12 <wenlong12@huawei.com> Signed-off-by: wenlong12 <wenlong12@huawei.com>
This commit is contained in:
parent
0ebf77838c
commit
bd8cd6727b
@ -82,9 +82,6 @@ auto LinkNode<Key, Val>::GetLinkNode(Link *plink)
|
||||
{
|
||||
if (plink) {
|
||||
LinkNode<Key, Val> *pnode {nullptr};
|
||||
if (pnode == nullptr) {
|
||||
return nullptr;
|
||||
}
|
||||
Link* offset = &pnode->link_;
|
||||
auto nodeAddr = reinterpret_cast<char*>(plink) - reinterpret_cast<char*>(offset);
|
||||
return reinterpret_cast<LinkNode<Key, Val>*>(nodeAddr);
|
||||
|
@ -921,10 +921,6 @@ public:
|
||||
HLOGD("the symbol file is %s.", filePath_.c_str());
|
||||
if (StringEndsWith(filePath_, ".hap") || StringEndsWith(filePath_, ".hsp")) {
|
||||
dfxExtractor_ = std::make_unique<DfxExtractor>(filePath_);
|
||||
if (dfxExtractor_ == nullptr) {
|
||||
HLOGD("DfxExtractor create failed.");
|
||||
return false;
|
||||
}
|
||||
if (!dfxExtractor_->GetHapAbcInfo(loadOffSet_, abcDataPtr_, abcDataSize_)) {
|
||||
HLOGD("failed to call GetHapAbcInfo, the symbol file is:%s", filePath_.c_str());
|
||||
return false;
|
||||
@ -1193,16 +1189,18 @@ const DfxSymbol SymbolsFile::GetSymbolWithVaddr(uint64_t vaddrInFile)
|
||||
6 6
|
||||
7 7
|
||||
*/
|
||||
if (found != symbols_.begin() && found != symbols_.end()) {
|
||||
if (found != symbols_.begin()) {
|
||||
found = std::prev(found);
|
||||
if (found->Contain(vaddrInFile)) {
|
||||
found->offsetToVaddr_ = vaddrInFile - found->funcVaddr_;
|
||||
if (!found->matched_) {
|
||||
found->matched_ = true;
|
||||
matchedSymbols_.push_back(&(*found));
|
||||
if (found != symbols_.end()) {
|
||||
if (found->Contain(vaddrInFile)) {
|
||||
found->offsetToVaddr_ = vaddrInFile - found->funcVaddr_;
|
||||
if (!found->matched_) {
|
||||
found->matched_ = true;
|
||||
matchedSymbols_.push_back(&(*found));
|
||||
}
|
||||
symbol = *found; // copy
|
||||
HLOGV("found '%s' for vaddr 0x%016" PRIx64 "", symbol.ToString().c_str(), vaddrInFile);
|
||||
}
|
||||
symbol = *found; // copy
|
||||
HLOGV("found '%s' for vaddr 0x%016" PRIx64 "", symbol.ToString().c_str(), vaddrInFile);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -142,7 +142,7 @@ std::shared_ptr<DfxMap> VirtualThread::FindMapByFileInfo(const std::string name,
|
||||
|
||||
std::shared_ptr<DfxMap> VirtualThread::FindFirstMapByFileInfo(const std::string name) const
|
||||
{
|
||||
for (auto &map : memMaps_) {
|
||||
for (const auto &map : memMaps_) {
|
||||
if (map == nullptr || name != map->name) {
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user