[PATCH] D115550: [CSSPGO][llvm-profgen] Fix external address issues of perf reader (return to external addr part)
Hongtao Yu via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Dec 14 10:57:37 PST 2021
hoy added inline comments.
================
Comment at: llvm/tools/llvm-profgen/PerfReader.h:433
bool pushFrame(UnwindState::ProfiledFrame *Cur) {
+ assert(!Cur->IsArtificialFrame() && "Push an artificial frame.");
Stack.push_back(Cur->Address);
----------------
wenlei wrote:
> wlei wrote:
> > hoy wrote:
> > > wenlei wrote:
> > > > nit: if we don't expect pushing artificial frame, the message can be explicit, something like "Artificial frame not expected for context stack."
> > > Or we just return false for artificial frames so that it doesn't need to be handled on the caller side?
> > Sounds good, changed to return false for external frame.
> I actually think that it's cleaner to handle this on caller side and assert we don't have external frame when it comes here.
Sounds good to me.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D115550/new/
https://reviews.llvm.org/D115550
More information about the llvm-commits
mailing list