[all-commits] [llvm/llvm-project] 35a003: [MemProf][NFC] Clear each IndexedMemProfRecord aft...
Teresa Johnson via All-commits
all-commits at lists.llvm.org
Fri Dec 15 11:38:48 PST 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 35a003c2b21082f3c47c8b01d9d1955af5ab098e
https://github.com/llvm/llvm-project/commit/35a003c2b21082f3c47c8b01d9d1955af5ab098e
Author: Teresa Johnson <tejohnson at google.com>
Date: 2023-12-15 (Fri, 15 Dec 2023)
Changed paths:
M llvm/include/llvm/ProfileData/MemProf.h
M llvm/lib/ProfileData/InstrProfWriter.cpp
Log Message:
-----------
[MemProf][NFC] Clear each IndexedMemProfRecord after it is written (#75205)
The on-disk hash table for the memprof writer holds copies of all the
memprof records to be written. These hold a lot of memory in aggregate,
due to the lists of alloc sites (which each have a list of context
frames) and call sites. Clear each one after emitting it.
This drops the peak memory when writing a very large indexed memprof
profile by about 2.5G.
More information about the All-commits
mailing list