This is an archive of the discontinued LLVM Phabricator instance.

[CSSPGO][NFC] Fix a debug dump issue.
ClosedPublic

Authored by hoy on Mar 26 2021, 1:18 PM.

Details

Summary

During context promotion, intermediate nodes that are on a call path but do not come with a profile can be promoted together with their parent nodes. Do not print sample context string for such nodes since they do not have profile.

Diff Detail

Event Timeline

hoy created this revision.Mar 26 2021, 1:18 PM
hoy requested review of this revision.Mar 26 2021, 1:18 PM
Herald added a project: Restricted Project. · View Herald TranscriptMar 26 2021, 1:18 PM

The printing and the wording were intentional - here we're promoting a context, and it doesn't have to be a context with profile. I wanted to capture the tree transformation, not limited to nodes with profile.

hoy added a comment.Mar 26 2021, 3:45 PM

The printing and the wording were intentional - here we're promoting a context, and it doesn't have to be a context with profile. I wanted to capture the tree transformation, not limited to nodes with profile.

I see. If there's a descendent node with a profile along the current path, the tree transformation can be captured by the promotion of the descendent later? The printing AVs because of a null ToNode->getFunctionSamples().

wenlei accepted this revision.Mar 26 2021, 3:54 PM
In D99441#2653927, @hoy wrote:

The printing and the wording were intentional - here we're promoting a context, and it doesn't have to be a context with profile. I wanted to capture the tree transformation, not limited to nodes with profile.

I see. If there's a descendent node with a profile along the current path, the tree transformation can be captured by the promotion of the descendent later? The printing AVs because of a null ToNode->getFunctionSamples().

Oh, I didn't notice the AV. In that case, avoid AV is more important. Thanks for the fix.

This revision is now accepted and ready to land.Mar 26 2021, 3:54 PM
This revision was automatically updated to reflect the committed changes.