diff options
author | Kazu Hirata <kazu@google.com> | 2024-11-19 19:33:26 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-11-19 19:33:26 -0800 |
commit | f97c610d1f824bcd3e078560c836aaaffaaf69b0 (patch) | |
tree | 9fb79e809970403f7e3379ae43a5534437d290d8 /llvm/lib/ExecutionEngine/ExecutionEngine.cpp | |
parent | a2e266b3463844b92b082698aaf201fdd8757c32 (diff) | |
download | llvm-f97c610d1f824bcd3e078560c836aaaffaaf69b0.zip llvm-f97c610d1f824bcd3e078560c836aaaffaaf69b0.tar.gz llvm-f97c610d1f824bcd3e078560c836aaaffaaf69b0.tar.bz2 |
[memprof] Add MemProfReader::takeMemProfData (#116769)
This patch adds MemProfReader::takeMemProfData, a function to return
the complete MemProf profile from the reader. We can directly pass
its return value to InstrProfWriter::addMemProfData without having to
deal with the indivual components of the MemProf profile. The new
function is named "take", but it doesn't do std::move yet because of
type differences (DenseMap v.s. MapVector).
The end state I'm trying to get to is roughly as follows:
- MemProfReader accepts IndexedMemProfData as a parameter as opposed
to the three individual components (frames, call stacks, and
records).
- MemProfReader keeps IndexedMemProfData as a class member without
decomposing it into its individual components.
- MemProfReader returns IndexedMemProfData like:
IndexedMemProfData takeMemProfData() {
return std::move(MemProfData);
}
Diffstat (limited to 'llvm/lib/ExecutionEngine/ExecutionEngine.cpp')
0 files changed, 0 insertions, 0 deletions