aboutsummaryrefslogtreecommitdiff
path: root/llvm/docs/tutorial
diff options
context:
space:
mode:
authorMin-Yih Hsu <min.hsu@sifive.com>2024-01-12 16:34:39 -0800
committerGitHub <noreply@github.com>2024-01-12 16:34:39 -0800
commit3edf82d5566ed5c9898f52b5591c05f6366d6bac (patch)
tree86484c5b16360cc13ff1054ae908313b28c74b45 /llvm/docs/tutorial
parent5ca2d75f2046612978ba71c4b36714b2a0a01886 (diff)
downloadllvm-3edf82d5566ed5c9898f52b5591c05f6366d6bac.zip
llvm-3edf82d5566ed5c9898f52b5591c05f6366d6bac.tar.gz
llvm-3edf82d5566ed5c9898f52b5591c05f6366d6bac.tar.bz2
[XRay] Reserve memory space ahead-of-time when reading native format log (#76853)
XRay used to struggle reading large log files. It turned out the bottleneck was primarily caused by the reallocation happens when appending log entries into a std::vector. This patch reserves the memory space ahead-of-time since the number of entries is known for most cases. Making llvm-xray runs 1.8 times faster and uses 1.4 times less physical memory when reading large (~2.6GB) log files.
Diffstat (limited to 'llvm/docs/tutorial')
0 files changed, 0 insertions, 0 deletions