Skip to content
Commit 34935408 authored by Alexey Lapshin's avatar Alexey Lapshin
Browse files

[DebugInfo][NFC] Erase capacity in DWARFUnit::clearDIEs().

DWARFUnit::clearDIEs() uses std::vector::shrink_to_fit() to make
capacity of DieArray matched with its size(). The shrink_to_fit()
is not binding request to make capacity match with size().
Thus the memory could still be reserved after DWARFUnit::clearDIEs()
is called. This patch erases capacity when DWARFUnit::clearDIEs() is requested.
So the memory occupied by dies would be freed.

Differential Revision: https://reviews.llvm.org/D109499
parent 6593cd3f
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment