diff options
author | csilvers <csilvers@6b5cf1ce-ec42-a296-1ba9-69fdba395a50> | 2008-09-19 20:06:40 +0000 |
---|---|---|
committer | csilvers <csilvers@6b5cf1ce-ec42-a296-1ba9-69fdba395a50> | 2008-09-19 20:06:40 +0000 |
commit | 106aef86ce5697cf44bdbec90ab6833b9254d273 (patch) | |
tree | 5f105b677eb6b76afcbdc752778ed5ae14e63462 /src/system-alloc.cc | |
parent | 100e657c5092bc274424286a728db5116a4bbc54 (diff) | |
download | gperftools-106aef86ce5697cf44bdbec90ab6833b9254d273.tar.gz |
Thu Sep 18 16:00:27 2008 Google Inc. <opensource@google.com>
* google-perftools: version 0.99 release
* Add IsHeapProfileRunning (csilvers)
* Add C shims for some of the C++ header files (csilvers)
* Fix heap profile file clean-up logic (maxim)
* Rename linuxthreads.c to .cc for better compiler support (csilvers)
* Add source info to disassembly in pprof (sanjay)
* Use open instead of fopen to avoid memory alloc (csilvers)
* Disable malloc extensions when running under valgrind (kcc)
* BUG FIX: Fix out-of-bound error by reordering a check (larryz)
* Add Options struct to ProfileData (cgd)
* Correct PC-handling of --base in pprof (csilvers)
* Handle 1 function occurring twice in an image (sanjay)
* Improve stack-data cleaning (maxim)
* Use 'struct Foo' to make header C compatible (csilvers)
* Add 'total' line to pprof --text (csilvers)
* Pre-allocate buffer for heap-profiler to avoid OOM errors (csilvers)
* Allow a few more env-settings to control tcmalloc (csilvers)
* Document some of the issues involving thread-local storage (csilvers)
* BUG FIX: Define strtoll and friends for windows (csilvers)
git-svn-id: http://gperftools.googlecode.com/svn/trunk@54 6b5cf1ce-ec42-a296-1ba9-69fdba395a50
Diffstat (limited to 'src/system-alloc.cc')
-rw-r--r-- | src/system-alloc.cc | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/system-alloc.cc b/src/system-alloc.cc index b262b42..0645735 100644 --- a/src/system-alloc.cc +++ b/src/system-alloc.cc @@ -89,13 +89,16 @@ static size_t pagesize = 0; // Configuration parameters. -DEFINE_int32(malloc_devmem_start, 0, +DEFINE_int32(malloc_devmem_start, + EnvToInt("TCMALLOC_DEVMEM_START", 0), "Physical memory starting location in MB for /dev/mem allocation." " Setting this to 0 disables /dev/mem allocation"); -DEFINE_int32(malloc_devmem_limit, 0, +DEFINE_int32(malloc_devmem_limit, + EnvToInt("TCMALLOC_DEVMEM_LIMIT", 0), "Physical memory limit location in MB for /dev/mem allocation." " Setting this to 0 means no limit."); -DEFINE_bool(malloc_skip_mmap, false, +DEFINE_bool(malloc_skip_mmap, + EnvToBool("TCMALLOC_SKIP_MMAP", false), "Whether mmap can be used to obtain memory."); // static allocators @@ -129,7 +132,7 @@ static char devmem_space[sizeof(DevMemSysAllocator)]; static const int kStaticAllocators = 3; // kMaxDynamicAllocators + kStaticAllocators; static const int kMaxAllocators = 5; -SysAllocator *allocators[kMaxAllocators]; +static SysAllocator *allocators[kMaxAllocators]; bool RegisterSystemAllocator(SysAllocator *a, int priority) { SpinLockHolder lock_holder(&spinlock); |