Issue #5291 has been updated by Charlie Savage. FYI, pairing a xalloc with a free can be fatal on windows depending on how Ruby is built (mingw is safe, VC++ isn't) and what runtime c libaries are used. See the "Caution" note at the bottom of: http://msdn.microsoft.com/en-us/library/2kzt1wy3%28v=vs.71%29.aspx Thanks for fixing them! ---------------------------------------- Feature #5291: Enabling GC Profiler GC_PROFILE_MORE_DETAIL and CALC_EXACT_MALLOC_SIZE http://redmine.ruby-lang.org/issues/5291 Author: Charlie Savage Status: Open Priority: Normal Assignee: Category: core Target version: 1.9.3 I would like to hook ruby-prof into the new GC profiler. However, by default a lot of the profile stats are disabled by these two defines in gcc.c. #define GC_PROFILE_MORE_DETAIL 0 #define CALC_EXACT_MALLOC_SIZE 0 To turn on these stats, you have to modify the ruby source code! That is a high barrier for most people. So would it be possible to: * Set them to 1 by default. Or would this be too much of a performance hit? - or - * Remove the lines entirely and then change the logic in the file from this: #if GC_PROFILE_MORE_DETAIL To this: #if defined?(GC_PROFILE_MORE_DETAIL) Then when buildig Ruby you could tell the compiler to define the symbols (-DGC_PROFILE_MORE_DETAIL). - or - * Add these two defines to the ./configure script so they end up in config.h. That would make it easy for users to enable them if they wish, and would be also allow ruby-prof to use them too. Would a patch be accepted to do this? -- http://redmine.ruby-lang.org