New tests.
[mono.git] / mono / profiler / ChangeLog
1 2009-08-18  Christian Hergert  <chris@dronelabs.com>
2
3         * mono-profiler-aot.c:
4         * mono-cov.c: Add missing method declarations.
5
6 2009-08-14  Massimiliano Mantione <massi@ximian.com>
7         * mono-profiler-logging.c (disable_profiler):
8         Flush buffers synchronously so the GUI knows when we are done.
9
10 2009-08-14  Massimiliano Mantione <massi@ximian.com>
11         * mono-profiler-logging.c:
12         - Added user thread reading commands from a local tcp port.
13         - Fixed file flushing after writing a block.
14         - Force full buffer flushing after disabling the profiler.
15
16 2009-08-06  Massimiliano Mantione <massi@ximian.com>
17         * mono-profiler-logging.c:
18         - Avoid registering the writer thread with the runtime unless when
19         it must create a heap snapshot.
20         - Simplified buffer flushing when an appdomain, image or assembly is
21         unloaded (now it can be done in the current thread).
22         - During shutdown, moved "code chunk cleanup" is a region of code
23         that holds the profiler lock.
24
25 2009-07-29  Massimiliano Mantione <massi@ximian.com>
26         * mono-profiler-logging.c: Implemented data structures to keep track
27         of code buffers produced by the runtime, and used them instead of
28         jit_info_table_find for the statistical profiler.
29         This eliminates crashes related to problems with the writer thread and
30         its registration to the runtime.
31
32 2009-06-18  Massimiliano Mantione <massi@ximian.com>
33         * mono-profiler-logging.c: Removed debugging printf statement.
34
35 2009-06-18  Massimiliano Mantione <massi@ximian.com>
36         * mono-profiler-logging.c:
37         Added assembly information to classes and wrapper flag to methods.
38
39 2009-05-25  Massimiliano Mantione <massi@ximian.com>
40         * mono-profiler-logging.c (write_thread_data_block): Only emit initial
41         stack snippet if we are tracking stacks.
42
43 2009-05-25  Massimiliano Mantione <massi@ximian.com>
44         * mono-profiler-logging.c (setup_user_options): Avoid tracking stacks
45         and emitting allocation caller information if we are already emitting
46         method enter and exit events.
47
48 2009-04-06  Massimiliano Mantione <massi@ximian.com>
49         * mono-profiler-logging.c: Added monitor contention profiling.
50         - Changed RESERVE_EVENTS to require a call to the new 
51         COMMIT_RESERVED_EVENTS macro after we have filled the event slots
52         (this allows to acquire all the event slots atomically).
53         - Created utility function "save_stack_delta".
54         - Created "monitor_event" callback.
55         - renamed "handle_heap_profiling" as "process_gc_event" because it
56         must be used also to help avoid interferences between garbage
57         collections and monitor profiling.
58
59 2009-03-23  Massimiliano Mantione <massi@ximian.com>
60         * mono-profiler-logging.c: Removed useless "gc-signal" option (the
61         newer "heap=<SIGNAL>" format of the "heap" option does the same thing).
62
63 2009-03-16  Massimiliano Mantione <massi@ximian.com>
64         * mono-profiler-logging.c: When checking if an elf file is valid,
65         avoid mapping it in memory until we know it's usable (avoids virtual
66         memory fragmentation issues).
67
68 2009-01-25  Massimiliano Mantione <massi@ximian.com>
69         * mono-profiler-logging.c: Bug fixing.
70         The issue is that while reading /proc/self/maps is can happen that
71         the last regions (typically [vsyscall] and [vsdo]) are reported more
72         than once (or anyway are read more than once, even when usng the plain
73         "read" call with no buffering), and I found no workaround for this.
74         So the code must be careful and throw away the duplicates.
75         - restore_old_regions: work starting from the new regions instead of
76         the old ones.
77         - sort_regions: introduce a "throw away the duplicates" pass.
78         - fix_region_references: added a pass to make sure that the elf files
79         always reference the new regions and not the old ones.
80         - refresh_memory_regions: call "sort_regions" before
81         "restore_old_regions" so we know we have no duplicates.
82
83 2009-01-18  Massimiliano Mantione <massi@ximian.com>
84         * mono-profiler-logging.c: Bug fixing.
85         - profiler_executable_memory_region_destroy: fixed a cut&paste mistake
86         causing a double free.
87         - executable_file_open: allow the code to look at all files, and fix
88         building of "files->new_files" list.
89         - executable_file_free: set "file->section_regions" to NULL when
90         freeing it (for safety).
91
92 2008-12-31  Massimiliano Mantione <massi@ximian.com>
93         * mono-profiler-logging.c: added "save-allocation-caller" option.
94
95 2008-12-30  Massimiliano Mantione <massi@ximian.com>
96         * mono-profiler-logging.c:
97         - profiler_executable_memory_region_destroy: fixed memory region
98         unloading.
99         - executable_file_add_region_reference: likewise.
100         - executable_file_close: likewise.
101         - executable_file_open: fixed file name handling.
102         - parse_map_line: likewise.
103         - scan_process_regions: likewise.
104         - statistical_call_chain: exit loop if the writer thread is busy.
105
106 2008-12-11  Massimiliano Mantione <massi@ximian.com>
107         * mono-profiler-logging.c:
108         - executable_file_open: Proper remember of already opened files.
109         - ProfilerStatisticalData: use unsigned values so the index never
110         trips over and becomes negative.
111         - statistical_call_chain, statistical_hit: likewise.
112
113 2008-12-11  Massimiliano Mantione <massi@ximian.com>
114         * mono-profiler-logging.c: Added defaults to command line options.
115
116 2008-12-01  Massimiliano Mantione <massi@ximian.com>
117         * mono-profiler-logging.c:
118         - ProfilerThreadStack: added "last_written_frame" and "written_frames"
119         fields to keep track of the call stacks actually written, so that we
120         can "replay" the full call stack at the beginning of each event block
121         (which allows the decoder to read blocks in random order and still see
122         all the call stacks correctly).
123         - gc_event: Fixed event creation sequence.
124         - Improved event logging (debugging) code.
125
126 2008-11-04  Massimiliano Mantione <massi@ximian.com>
127         * mono-profiler-logging.c:
128         Make sure that stack sections can be fully reconstructed even reading
129         only one block.
130
131 2008-10-10  Massimiliano Mantione <massi@ximian.com>
132         * mono-profiler-logging.c:
133         Added "aci" option to emit the object "id" at each allocation. 
134
135 2008-10-10  Massimiliano Mantione <massi@ximian.com>
136         * mono-profiler-logging.c:
137         Added support for handling the stack trace of each allocation event.
138         - MonoProfilerDirectives: added directive to state that allocations
139         have stack traces (not strictly needed, but simplifirs the decoder).
140         - ProfilerEventData: gave one more bit to code (and one less to value).
141         - MonoProfilerEvents: Added "stack section" event to record stack state.
142         - ProfilerThreadStack: added last_saved_top to track what we just saved.
143         - _MonoProfiler::action_flags: Added save_allocation_caller and
144         save_allocation_stack to state what we do for allocations.
145         - All "thread_stack_..." functions: Track last_saved_top.
146         - Added thread_stack_count_unsaved_frames utilty function.
147         - write_directives_block: handle ALLOCATIONS_HAVE_STACK directive.
148         - Added write_stack_section_event function.
149         - write_event: also handle emission of stack sections.
150         - Reworked all the "STORE_EVENT_..." macros to work on arbitrary event
151         slots (needed for stack sections), and as a consequence fixed all the
152         functions that use them.
153         - object_allocated: save "delta" stack section if needed.
154         - setup_user_options: handle new "sas" option.
155
156 2008-09-08  Massimiliano Mantione <massi@ximian.com>
157         * Makefile.am: Don't build the profilers if DISABLE_PROFILER is set.
158
159 2008-09-08  Massimiliano Mantione <massi@ximian.com>
160         * mono-profiler-logging.c:
161         - setup_user_options: made so that the user has to explicitly request
162         the "f" mode when the "h" is asked, otherwise the number of snapshot
163         blocks in the file is very confusing.
164         - Added three icalls to control the profiler from the profiled
165         application.
166
167 2008-08-28  Zoltan Varga  <vargaz@gmail.com>
168
169         * mono-profiler-logging.c (detect_fast_timer): Add missing return type.
170
171 2008-08-21  Massimiliano Mantione <massi@ximian.com>
172         * mono-profiler-logging.c: Added support for correct accounting of
173         allocations which happened at JIT time.
174
175 2008-08-20  Massimiliano Mantione <massi@ximian.com>
176         * mono-profiler-logging.c: Added directives block, and used it to
177         state that "allocation attribution" done using the stack tracking (so
178         that allocation callers are directly written in the log file).
179
180 2008-07-28  Massimiliano Mantione <massi@ximian.com>
181         * mono-profiler-logging.c: Added stack tracking (even if still unused).
182
183 2008-07-28  Massimiliano Mantione <massi@ximian.com>
184         * mono-profiler-logging.c: Fix bug 412473:
185         - write_statistical_data_block: check if the current MonoThread still
186         exists, and if not avoid calling mono_jit_info_table_find.
187         - profiler_shutdown: flush everything in the current thread.
188
189 2008-07-28  Massimiliano Mantione <massi@ximian.com>
190         * mono-profiler-logging.c: Fix the "allocation summaries" feature
191         (I committed it but it never really worked until now).
192
193 2008-07-04  Massimiliano Mantione <massi@ximian.com>
194         * mono-profiler-logging.c: Emit full type names for loaded classes
195         (patch by Rodrigo Kumpera).
196
197 2008-07-04  Massimiliano Mantione <massi@ximian.com>
198         * mono-profiler-logging.c: Use the new "runtime initialized" hook.
199
200 2008-07-04  Massimiliano Mantione <massi@ximian.com>
201         * mono-profiler-logging.c: Fix an embarassingly stupid problem with
202         buffer sizes.
203
204 2008-07-03  Massimiliano Mantione <massi@ximian.com>
205         * mono-profiler-logging.c: Changed the way to wait for the writer
206         thread to avoid passing an invalid handle to pthread_join.
207
208 2008-06-28  Massimiliano Mantione <massi@ximian.com>
209         * mono-profiler-logging.c: When offloading flushing to the writer
210         thread, first check that it still exists.
211
212 2008-06-25  Massimiliano Mantione <massi@ximian.com>
213         * mono-profiler-logging.c: Offload more flushing to the writer thread,
214         and fix the shutdown sequence.
215
216 2008-06-25  Massimiliano Mantione <massi@ximian.com>
217         * mono-profiler-logging.c: Made so that at appdomain unload the
218         buffers are flushed by the profiler worker thread (which we know
219         is registered with the runtime).
220
221 2008-06-25  Massimiliano Mantione <massi@ximian.com>
222         * mono-profiler-logging.c: Added more logging code.
223
224 2008-06-25  Massimiliano Mantione <massi@ximian.com>
225         * mono-profiler-logging.c: Record also the domain of each statistical
226         hit, so that mono_jit_info_table_find works properly.
227
228 2008-06-25  Massimiliano Mantione <massi@ximian.com>
229         * mono-profiler-logging.c: Fixed breakage introduced in r105966
230
231 2008-06-17  Massimiliano Mantione <massi@ximian.com>
232         * mono-profiler-logging.c: Implemented signal based enable-disable
233         toggling for the statistical and enter-exit events.
234
235 2008-06-17  Massimiliano Mantione <massi@ximian.com>
236         * mono-profiler-logging.c (write_statistical_hit): Use the proper
237         domain instead of trying to get one.
238
239 2008-06-16  Massimiliano Mantione <massi@ximian.com>
240         * mono-profiler-logging.c (module_end_load, assembly_end_load):
241         Properly check the return value of "mono_assembly_fill_assembly_name",
242         otherwise "mono_stringify_assembly_name" can crash.
243
244 2008-06-16  Massimiliano Mantione <massi@ximian.com>
245         * mono-profiler-logging.c: Fix a segfault on shutdown (see Marek's
246         fix for the default profiler in r105466, the problem is the same.
247
248 2008-06-16  Massimiliano Mantione <massi@ximian.com>
249         * mono-profiler-logging.c: Initial implementation of summary report
250         for allocations at each collection.
251
252 2008-05-23  Massimiliano Mantione <massi@ximian.com>
253         * mono-profiler-logging.c: Fix warnings x86 and remove debugging code.
254
255 2008-05-23  Massimiliano Mantione <massi@ximian.com>
256         * mono-profiler-logging.c: Fix the build on x86.
257
258 2008-05-23  Massimiliano Mantione <massi@ximian.com>
259         * mono-profiler-logging.c: Support call chains (backtrace) in the
260         stat profiler.
261
262 2008-05-12  Massimiliano Mantione <massi@ximian.com>
263         * mono-profiler-logging.c (handle_heap_profiling): Flush all data
264         buffers, so that objext allocation events are written before the heap
265         description (which contains the "object free" events).
266
267 2008-05-12  Massimiliano Mantione <massi@ximian.com>
268         * mono-profiler-logging.c: Added support for a global counter of all
269         garbage collections, so that the file decoder can correlate the
270         events properly.
271
272 2008-05-12  Massimiliano Mantione <massi@ximian.com>
273         * mono-profiler-logging.c: Fixed a bug that prevented using rdtsc,
274         and enabled rdtsc by default,adding a command line option to revert
275         to using gettimeofday.
276
277 2008-05-02  Massimiliano Mantione <massi@ximian.com>
278          * mono-profiler-logging.c: Turned DEBUG_STATISTICAL_PROFILER off...
279
280 2008-05-02  Massimiliano Mantione <massi@ximian.com>
281          * mono-profiler-logging.c : Rework statistical profiler, adding the
282          ability to scan symbol tables in elf files instead of using dladdr
283          (dladdr skips lots of symbols which this way we get correctly).
284
285 2008-04-16  Massimiliano Mantione <massi@ximian.com>
286          * mono-profiler-logging.c (gc_event): Fix deadlock condition.
287
288 2008-04-16  Massimiliano Mantione <massi@ximian.com>
289          * mono-profiler-logging.c (write_current_block): Added an incremental
290          "counter delta" field to the block header, so that each block has a
291          timestamp directly in the header.
292          This will allow tools to know when a block has been emitted without
293          decoding (even without reading) the block contents.
294          So, if the user is only interested in blocks emitted in a certain
295          time interval, the tool can seek into the file instead of reading the
296          block contents.
297          Of course this breaks the file format, but at this stage we can still
298          do it, and... better now than later.
299
300 2008-04-10  Massimiliano Mantione <massi@ximian.com>
301         * mono-profiler-logging.c (profiler_heap_scan): removed debugging code
302         and therefore removed unconditional inclusion of signal.h (it is now
303         included anyway on Unix platforms).
304
305 2008-04-10  Massimiliano Mantione <massi@ximian.com>
306         * mono-profiler-logging.c: Added possibiliy of requesting heap
307         snapshots with a signal (like heap-shot).
308
309 2008-04-02  Rodrigo Kumpera <rkumpera@novell.com>
310
311         * mono-profiler-logging.c: Fix the arm build. G_BREAKPOINT() does
312         a "raise(SIGTRAL)" and in some platforms <signal.h> must be included.
313
314 2008-03-28  Massimiliano Mantione <massi@ximian.com>
315         * mono-profiler-logging.c: Added option to append a suffix to the
316         default file name.
317
318 2008-03-27  Massimiliano Mantione <massi@ximian.com>
319         * mono-profiler-logging.c: setup_user_options: set default log file
320         name to the name of the executed application.
321
322 2008-03-26  Massimiliano Mantione <massi@ximian.com>
323         * Makefile.am: enabled the logging profiler on Linux.
324
325 2008-03-26  Massimiliano Mantione <massi@ximian.com>
326         * mono-profiler-logging.c: Attach and detach the writer thread.
327
328 2008-03-25  Massimiliano Mantione <massi@ximian.com>
329         * mono-profiler-logging.c: Fixed bug with memory region indexes.
330
331 2008-03-18  Massimiliano Mantione <massi@ximian.com>
332         * mono-profiler-logging.c:
333         OPEN_FILE(): Fixed file creation.
334         [UN]LOCK_PROFILER(): Removed logging message.
335
336 2008-03-11  Massimiliano Mantione <massi@ximian.com>
337         * mono-profiler-logging.c: Fixed heap profiler, added a new way to
338         get the symbol names for unmanaged functions, and fixed lots of bugs.
339
340 2008-01-08  Massimiliano Mantione <massi@ximian.com>
341         * mono-profiler-logging.c: First code drop of new logging profiler
342         (and shamefully forgot to set HAS_OPROFILE to 0...).
343         * Makefile.am: Added logging profiler, but commented in out to avoid
344         breaking the build on Windows.
345
346 2005-07-25  Zoltan Varga  <vargaz@freemail.hu>
347
348         * mono-cov.c: Applied patch from Iain McCoy (iain@mccoy.id.au). Fixes
349         #75619.
350
351 2003-11-12  Jackson Harper  <jackson@ximian.com>
352
353         * mono-cov.c: Change default assembly name to mscorlib.dll
354         
355 Tue Jul 1 11:26:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
356
357         * Makefile.am: added.
358
359 Mon Jun 16 18:21:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
360
361         * mono-cov.c: coverage profiler.
362