diff options
author | Massimiliano Mantione <massi@mono-cvs.ximian.com> | 2008-08-21 14:25:29 +0400 |
---|---|---|
committer | Massimiliano Mantione <massi@mono-cvs.ximian.com> | 2008-08-21 14:25:29 +0400 |
commit | 721257a0fc79bcd95e83adacc8973514932433e7 (patch) | |
tree | 7cb593febb1bbb4d23d8288e8f17cc761c03fdb8 /Mono.Profiler | |
parent | 6fcabb91700f6c38b5682d29f92658493b6f531b (diff) |
Added support for correct accounting of allocations which happened at JIT time.
svn path=/trunk/mono-tools/; revision=111249
Diffstat (limited to 'Mono.Profiler')
-rw-r--r-- | Mono.Profiler/profiler-file-decoder/ChangeLog | 4 | ||||
-rw-r--r-- | Mono.Profiler/profiler-file-decoder/Main.cs | 10 |
2 files changed, 13 insertions, 1 deletions
diff --git a/Mono.Profiler/profiler-file-decoder/ChangeLog b/Mono.Profiler/profiler-file-decoder/ChangeLog index d5c04afb..899f523a 100644 --- a/Mono.Profiler/profiler-file-decoder/ChangeLog +++ b/Mono.Profiler/profiler-file-decoder/ChangeLog @@ -1,3 +1,7 @@ +2008-08-21 Massimiliano Mantione <massi@ximian.com> + * Main.cs: Added support for correct accounting of allocations + which happened at JIT time. + 2008-08-20 Massimiliano Mantione <massi@ximian.com> * Main.cs: Ignore decoding exceptions but print the stack trace. diff --git a/Mono.Profiler/profiler-file-decoder/Main.cs b/Mono.Profiler/profiler-file-decoder/Main.cs index 1042a7ef..bafabe6c 100644 --- a/Mono.Profiler/profiler-file-decoder/Main.cs +++ b/Mono.Profiler/profiler-file-decoder/Main.cs @@ -58,7 +58,15 @@ namespace Mono.Profiler Array.Sort (allocationsPerMethodArray, LoadedClass.AllocationsPerMethod.CompareByAllocatedBytes); Array.Reverse (allocationsPerMethodArray); foreach (LoadedClass.AllocationsPerMethod allocationsPerMethod in allocationsPerMethodArray) { - writer.WriteLine (" {0} bytes from {1}.{2}", allocationsPerMethod.AllocatedBytes, allocationsPerMethod.Method.Class.Name, allocationsPerMethod.Method.Name); + writer.WriteLine (" {0} bytes ({1} instances) from {2}.{3}", allocationsPerMethod.AllocatedBytes, allocationsPerMethod.AllocatedInstances, allocationsPerMethod.Method.Class.Name, allocationsPerMethod.Method.Name); + } + } + if (c.MethodsAtJitTimeCount > 0) { + allocationsPerMethodArray = c.MethodsAtJitTime; + Array.Sort (allocationsPerMethodArray, LoadedClass.AllocationsPerMethod.CompareByAllocatedBytes); + Array.Reverse (allocationsPerMethodArray); + foreach (LoadedClass.AllocationsPerMethod allocationsPerMethod in allocationsPerMethodArray) { + writer.WriteLine (" {0} bytes ({1} instances) at JIT time of {2}.{3}", allocationsPerMethod.AllocatedBytes, allocationsPerMethod.AllocatedInstances, allocationsPerMethod.Method.Class.Name, allocationsPerMethod.Method.Name); } } } |