aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/CodeGen/TargetPassConfig.cpp
diff options
context:
space:
mode:
authorEric Fiselier <eric@efcs.ca>2019-06-08 01:31:19 +0000
committerEric Fiselier <eric@efcs.ca>2019-06-08 01:31:19 +0000
commitd63dd874ecbdcbc9bdcfc4fde4e372ad2f605ba5 (patch)
treef2560935bef45f0387e3d662423c9291d1fe682f /llvm/lib/CodeGen/TargetPassConfig.cpp
parent3ba09eda0c7970087f8bfe09206e33a665f51298 (diff)
downloadllvm-d63dd874ecbdcbc9bdcfc4fde4e372ad2f605ba5.zip
llvm-d63dd874ecbdcbc9bdcfc4fde4e372ad2f605ba5.tar.gz
llvm-d63dd874ecbdcbc9bdcfc4fde4e372ad2f605ba5.tar.bz2
Substantially reduce instantiations and debug size of std::function
std::function uses a standard allocator to manage its memory, however standard allocators are templates and using them correctly requires a stupid amount of instantiations. This leads to a substantial increase in debug info and object sizes. This patch addresses the issue by dropping the allocator when possible and using raw new and delete to get memory. This change decreases the object file size for the test func.wrap.func.con/F.pass.cpp by 33% and the final binary by 29% (when compiled with -g -ggnu-pubnames -gpubnames). It also roughly halfs the number of entries in the pubnames and pubtype sections. llvm-svn: 362865
Diffstat (limited to 'llvm/lib/CodeGen/TargetPassConfig.cpp')
0 files changed, 0 insertions, 0 deletions