[PATCH] D155110: [memprof] Fix use-after-free in peekBuildIds.
Snehasish Kumar via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jul 12 14:08:24 PDT 2023
snehasish added a comment.
In D155110#4495040 <https://reviews.llvm.org/D155110#4495040>, @tejohnson wrote:
> lgtm but you could also consider collapsing both BuildIds and BuildIdsSet into a single SetVector for conciseness.
I did consider this prior to sending out the patch. Since SetVector::takeVector return a SmallVector we need to either
- create a new result std::vector prior to avoid changing the return type, negating the benefit
- update the return type which breaks downstream usage and will need to be updated
Since this isn't performance critical I chose the simplest approach.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D155110/new/
https://reviews.llvm.org/D155110
More information about the llvm-commits
mailing list