[PATCH] D20148: Idea for avoiding memory allocation calls.

Rong Xu via llvm-commits llvm-commits at lists.llvm.org
Wed May 11 00:25:11 PDT 2016


xur added a comment.

This avoids calloc in lprofCreateBufferIO() which is not used at all if there is not value profiles.

But how about the malloc calls from  setFilenamePossiblyWithPid() and truncateCurrentFile(). They are not from value profiling, but they also call dynamic memory allocation.

Maybe we should convert all these into alloca or using pre-allocated memory.

David and I are working on to get the profile runtime malloc free (or at least avoiding re-entrance to malloc) in the past few days. Hopefully we can have some discussion on this soon.


Repository:
  rL LLVM

http://reviews.llvm.org/D20148





More information about the llvm-commits mailing list