[clang] Introduce paged vector (PR #66430)
Sergei Barannikov via cfe-commits
cfe-commits at lists.llvm.org
Fri Sep 15 04:28:13 PDT 2023
s-barannikov wrote:
> Why don't just turn SLocEntry into a POD (if it is not yet already) and use SmallVector::resize_for_overwrite? That way the vector will not be initialized and the OS will only allocate physical memory on the first access to a page.
Never mind, it isn't "just", the class is more complex than it looks, and there is also QualType.
Still, the introduced class partially repeats the work done by the operating system, that is allocating pages on first access.
I can't suggest how this fact can be used though.
https://github.com/llvm/llvm-project/pull/66430
More information about the cfe-commits
mailing list