mirror of
https://github.com/gperftools/gperftools
synced 2024-12-23 15:52:10 +00:00
100e657c50
* google-perftools: version 0.98 release * Add ProfilerStartWithOptions() (cgd) * Change tcmalloc_minimal to not do any stack-tracing at all (csilvers) * Prefer mmap to sbrk for 64-buit debug mode (sanjay) * Fix accounting for some tcmalloc stats (sanjay) * Use setrlimit() to keep unittests from killing the machine (odo) * Fix a bug when sbrk-ing near address 4G (csilvers) * Make MallocHook thread-safe (jyasskin) * Fix windows build for MemoryBarrier (jyasskin) * Fix CPU-profiler docs to mention correct libs (csilvers) * Fix for GetHeapProfile() when heap-profiling is off (maxim) * Avoid realloc resizing ping-pongs using hysteresis (csilvers) * Add --callgrind output support to pprof (klimek) * Fix profiler.h and heap-profiler.h to be C-compatible (csilvers) * Break malloc_hook.h into two parts to reduce dependencies (csilvers) * Better handle systems that don't implement mmap (csilvers) * PORTING: disable system_alloc_unittest for msvc (csilvers) * PORTING: Makefile tweaks to build better on cygwin (csilvers) git-svn-id: http://gperftools.googlecode.com/svn/trunk@52 6b5cf1ce-ec42-a296-1ba9-69fdba395a50
46 lines
2.1 KiB
Plaintext
46 lines
2.1 KiB
Plaintext
This project has begun being ported to Windows. A working solution
|
|
file exists in this directory:
|
|
google-perftools.sln
|
|
|
|
You can load this solution file into either VC++ 7.1 (Visual Studio
|
|
2003) or VC++ 8.0 (Visual Studio 2005) -- in the latter case, it will
|
|
automatically convert the files to the latest format for you.
|
|
|
|
When you build the solution, it will create a number of unittests,
|
|
which you can run by hand (or, more easily, under the Visual Studio
|
|
debugger) to make sure everything is working properly on your system.
|
|
The binaries will end up in a directory called "debug" or "release" in
|
|
the top-level directory (next to the .sln file).
|
|
|
|
Note that these systems are set to build in Debug mode by default.
|
|
You may want to change them to Release mode.
|
|
|
|
To use tcmalloc_minimal in your own projects, you should only need to
|
|
build the dll and install it someplace, so you can link it into
|
|
further binaries. Note that the tcmalloc DLL is compiled with
|
|
the "Multithreaded DLL" CRT library -- this is required so we can
|
|
override malloc in user applications. This means, to use the tcmalloc
|
|
DLL, your applcation must link in the "Multithreaded DLL" CRT library
|
|
as well. (It is a TODO to try to remove this restriction in the
|
|
future.)
|
|
|
|
You can also link tcmalloc code in statically -- see the example
|
|
project tcmalloc_minimal_unittest-static, which does this. For this
|
|
to work, you'll need to add "/D PERFTOOLS_DLL_DECL=" to the compile
|
|
line of every perftools .cc file. For reasons I don't fully
|
|
understand yet, you still need to use the "DLL" CRT library even when
|
|
statically linking. Again, you can look at the
|
|
tcmalloc_minimal_unittest-static project, which does this.
|
|
|
|
Note that the other features of perftools, such as the cpu-profiler,
|
|
heap-profiler, and leak-checker, have not yet been ported to Windows.
|
|
|
|
I have little experience with Windows programming, so there may be
|
|
better ways to set this up than I've done! If you run across any
|
|
problems, please post to the google-perftools Google Group, or report
|
|
them on the google-perftools Google Code site:
|
|
http://groups.google.com/group/google-perftools
|
|
http://code.google.com/p/google-perftools/issues/list
|
|
|
|
-- craig
|