2007-12-19 Martin Baulig <martin@ximian.com>
[mono.git] / mono / mini / ChangeLog
1 2007-12-19  Martin Baulig  <martin@ximian.com>
2
3         * mono-dbg.[ch]: New files.  Initial version of the debugger
4         runtime library.  We only use this for generics at the moment.
5
6         * Makefile.am: Create libmono-dbg.la if the debugger is supported;
7         also install <mono/jit/mono-dbg.h>.
8
9 2007-12-15  Zoltan Varga  <vargaz@gmail.com>
10
11         * mini.c (mono_method_to_ir): Fix a warning.
12
13 2007-12-14  Zoltan Varga  <vargaz@gmail.com>
14
15         * mini-ops.h: Add OP_SWITCH.
16
17         * mini.c graph.c ssa.c aliasing.c mini-<ARCH>.c inssel-<ARCH>.brg: Avoid using
18         CEE_SWITCH in back-end code, use OP_SWITCH instead.
19
20 2007-12-11  Geoff Norton  <gnorton@novell.com>
21
22         * mini-s390x.c: Minor change to the MAX() define to allow
23         it to compile with other gcc versions.
24
25 2007-12-11  Geoff Norton  <gnorton@novell.com>
26
27         * cpu-s390x.md:
28         * mini-s390x.c: Implement sext_i4 to fix the build on s390x
29
30 2007-12-11  Rodrigo Kumpera  <rkumpera@novell.com>
31
32         exceptions-arm.c (mono_arch_get_restore_context): Restore
33         the frame pointer.
34
35         exceptions-arm.c (throw_exception): Save the frame pointer.
36         This is a partial fix for #323747. Only the client side is
37         fixed.
38
39 2007-12-11  Rodrigo Kumpera  <rkumpera@novell.com>
40
41         * mini.c (mono_method_to_ir): Verbose message in CEE_NEWOBJ
42         was using an unrelated variable to log the class which
43         needed the cctor to be called. This was crashing on arm.
44
45 2007-12-09  Robert Jordan  <robertj@gmx.net>
46
47         * mini-x86.c (mono_arch_emit_epilog):
48         Consider all kinds of 64-bit types. Fixes #323114.
49
50 2007-12-08  Zoltan Varga  <vargaz@gmail.com>
51
52         * tramp-amd64.c (mono_arch_create_trampoline_code): Clean up the code a bit.
53
54 2007-12-07  Zoltan Varga  <vargaz@gmail.com>
55
56         * mini-amd64.c (peephole_pass): Add a missing instruction check.
57
58 Fri Dec 7 22:08:23 CET 2007 Paolo Molaro <lupus@ximian.com>
59
60         * mini.c: run type ctor before allocating an object, not only
61         when running it's constructor method (fixes at least part of bug #342507).
62
63 2007-12-07  Zoltan Varga  <vargaz@gmail.com>
64         
65         * mini-trampolines.c (mono_delegate_trampoline): Fix a warning.
66         
67         * mini-trampolines.c (mono_generic_class_init_trampoline): Remove a debug printf.
68         * mini.h mini-amd64.c mini-x86.c: Get rid of the mono_arch_find_vtable () 
69         function.
70
71         * tramp-x86.c tramp-amd64.c mini-trampolines.c: Pass the vtable argument to
72         mono_generic_class_init_trampoline () the same as it is done with the other
73         trampolines.
74
75         * mini-arm.h mini-arm.c tramp-arm.c inssel-arm.brg cpu-arm.md 
76         aot-runtime.c aot-compiler.c: Implement AOT support.    
77
78 2007-12-07  Mark Probst  <mark.probst@gmail.com>
79
80         * mini-trampolines.c (mono_generic_class_init_trampoline): Fixed
81         build for archs which don't have the vtable trampoline defined
82         yet.
83
84 2007-12-07  Zoltan Varga  <vargaz@gmail.com>
85
86         * tramp-x86.c (mono_arch_create_trampoline_code): Fix the build.
87
88         * tramp-ppc.c (mono_arch_create_trampoline_code): Use the new helper function.
89
90         * mini-trampolines.c (mono_get_trampoline_func): New helper function.
91
92         * tramp-<ARCH>.c: Use the new helper function.
93
94 2007-12-07  Mark Probst  <mark.probst@gmail.com>
95
96         * inssel.brg: Added a pattern for the OP_TRAMPCALL_VTABLE
97         trampoline call, which takes a vtable argument.
98
99         * graph.c, mini-ops.h, local-propagation.c, aliasing.c: Treat
100         OP_TRAMPCALL_VTABLEs like other calls.
101
102         * mini-amd64.c, mini-amd64.h, mini-x86.c, mini-x86.h: Designated a
103         register to hold the vtable argument to the OP_TRAMPCALL_VTABLE
104         call.  Implemented a support function which fetches the vtable
105         from a register set.
106
107         * mini.c, mini.h, tramp-amd64.c, tramp-x86.c, mini-trampolines.c:
108         Implemented a generic class init trampoline, using the
109         OP_TRAMPCALL_VTABLE opcode.
110
111         * mini.c: Implemented static field access when sharing generic
112         code.  This implies initing the class using the new
113         OP_TRAMPCALL_VTABLE call.
114
115 2007-12-07  Mark Probst  <mark.probst@gmail.com>
116
117         * mini.c: Don't compile methods with sharing enabled if their
118         classes are disabled for sharing.
119
120 2007-12-06  Zoltan Varga  <vargaz@gmail.com>
121
122         * inssel.brg: Add a missing sign extension to the GETCHR and array access
123         opcodes. Fixes #346563.
124
125         * objects.cs: Add a new test.
126
127         * aot-compiler.c (emit_method_code): Put back an #ifdef which is needed.
128
129         * mini-<ARCH>.h mini.c aot-compiler.c aot-runtime.c: Get rid of the
130         HAVE_PIC_AOT define and use AOT_SUPPORTED instead.
131
132 2007-12-06  Zoltan Varga  <vargaz@gmail.com>
133
134         * mini-arm.h mini-arm.c: Add support for the common vtable trampoline.
135
136 2007-12-03  Zoltan Varga  <vargaz@gmail.com>
137
138         * mini-arm.c (mono_arch_emit_exceptions): Avoid uninitialized memory in the
139         code stream.
140
141 2007-12-02  Zoltan Varga  <vargaz@gmail.com>
142
143         * patch-info.h (PATCH_INFO): Add DELEGATE_TRAMPOLINE.
144
145         * mini.c aot-compiler.c aot-runtime.c: Implement the delegate creation 
146         optimization in the AOT case.
147         
148 2007-11-30  Zoltan Varga  <vargaz@gmail.com>
149
150         * aot-runtime (mono_aot_get_method_from_vt_slot): Add support for multi-byte method ref encodings.
151         
152         * aot-runtime.c (decode_klass_ref): Implement decoding of generic instances.
153
154         * aot-compiler.c (encode_klass_ref): Implement proper encoding of generic instances.
155
156         * mini.c (mono_method_to_ir): Optimize the common ldftn+create delegate combination.
157
158         * mini-trampolines.c (mono_delegate_trampoline): Add some code to handle the case when the delegate
159         is created by the inlined delegate ctor.
160
161         * mini-x86.c (mono_arch_output_basic_block): Unify div/rem code and handle the case when sreg2 is EDX.  
162
163         * mini.c (mono_jit_compile_method_inner): Replace calls to delegate invoke with the trampoline here too.
164
165 2007-11-29  Zoltan Varga  <vargaz@gmail.com>
166
167         * cpu-x86.md: Fix the length of ckfinite.
168
169 2007-11-28  Zoltan Varga  <vargaz@gmail.com>
170
171         * mini-x86.c (mono_arch_output_basic_block): Unify div/rem code and handle the case when sreg2 is EDX.
172         
173         * mini-x86.c (mono_arch_output_basic_block): Clean up the fp stack properly in CKFINITE.
174         (mono_arch_output_basic_block): Get rid of unused last_ins and last_offset.
175
176         * mini-x86.c (mono_arch_output_basic_block): Add some micro optimizations.
177
178         * mini-x86.c inssel-x86.brg cpu-x86.md: Move the implementation of the 
179         OP_START_HANDLER/OP_ENDFINALLY/OP_ENDFILTER opcodes to mini-x86.c.
180
181 2007-11-28  Martin Baulig  <martin@ximian.com>
182
183         * mini-x86.c
184         (mono_arch_get_delegate_invoke_impl): Call mono_debug_add_delegate_trampoline()
185         after creating the trampoline.
186
187 2007-11-27  Zoltan Varga  <vargaz@gmail.com>
188
189         * aot-runtime.c (load_aot_module): Check runtime version if needed.
190
191         * aot-compiler.c: Add bind-to-runtime-version for producing AOT files which only load into a runtime with
192         the same version.
193
194         * generic-sharing.c (mono_helper_get_rgctx_other_ptr): Change the signature to take the calling class
195         instead of the calling method to help AOT.
196
197         * mini.c (get_runtime_generic_context_other_ptr): Update after the change.
198
199 2007-11-26  Zoltan Varga  <vargaz@gmail.com>
200
201         * aot-runtime.c (mono_aot_init_vtable): Simplify this if MONO_ARCH_COMMON_VTABLE_TRAMPOLINE
202         is defined.
203
204 2007-11-23  Zoltan Varga  <vargaz@gmail.com>
205
206         * aot-compiler.c (emit_class_name_table): Properly encode generic class names.
207         
208         * aot-compiler.c (compile_method): Correct check for generic method definitions.
209         (encode_method_ref): No need to handle generic method definitions specially.
210
211         * mini.h (MONO_AOT_FILE_VERSION): Bump this.
212
213         * aot-runtime.c (decode_klass_ref): Clean this up and rename from 
214         decode_klass_info.
215
216         * aot-compiler.c (encode_klass_ref): Clean this up and rename from
217         encode_klass_info.
218         (compile_method): Enable generic sharing.
219
220 2007-11-22  Zoltan Varga  <vargaz@gmail.com>
221
222         * mini.c (get_runtime_generic_context_other_ptr): Disable AOT here.
223         (mini_method_compile): Add preliminary support for AOTing shared generic code.
224
225         * aot-compiler.c (compile_method): Add preliminary support for AOTing shared
226         generic code.
227
228         * mini-trampolines.c: Fix a warning.
229
230         * mini.c (get_runtime_generic_context_other_ptr): Use NEW_METHODCONST instead of
231         NEW_PCONST.
232         (mono_method_to_ir): Use NEW_DOMAINCONST in one place.
233         (generic_class_is_reference_type): Remove unused function.
234
235         * mini-trampolines.c (mono_magic_trampoline): Avoid loading metadata if possible
236         in the generic vtable trampoline case.
237
238         * aot-runtime.c (mono_aot_init_vtable): Use the generic vtable trampoline.
239         
240         * aot-runtime.c (mono_aot_get_method_from_vt_slot): New helper function to
241         return an AOT method based on a vtable slot.
242
243         * aot-compiler.c (compile_method): Avoid AOTing synchronized methods for now.
244
245         * mini.c (mini_get_vtable_trampoline): Export this.
246
247 2007-11-22  Martin Baulig  <martin@ximian.com>
248
249         * debug-debugger.h
250         (MonoDebuggerInfo): Move `debugger_version' up.
251
252 2007-11-22  Martin Baulig  <martin@ximian.com>
253
254         * mini-amd64.c
255         (mono_arch_get_delegate_invoke_impl): Call mono_debug_add_delegate_trampoline().
256
257         * mini-trampolines.c
258         (mono_delegate_trampoline): Call mono_debugger_trampoline_compiled()
259         after compiling the method.
260
261 2007-11-20  Martin Baulig  <martin@ximian.com>
262
263         * debug-mini.c
264         (mono_debugger_insert_method_breakpoint): Moved into mono-debug-debugger.c.
265         (mono_debugger_remove_breakpoint): Likewise.
266         (mono_debugger_check_breakpoints): Likewise.
267
268         * debug-debugger.c: Implement the new breakpoint interface here.
269
270 2007-11-18  Zoltan Varga  <vargaz@gmail.com>
271
272         * mini-amd64.c (mono_arch_output_basic_block): Unify the implementation of
273         CEE_CONV_I1/SEXT_I1 and I2 since they are the same.
274
275         * mini-x86.c (mono_arch_output_basic_block): Ditto.     
276
277 2007-11-17  Zoltan Varga  <vargaz@gmail.com>
278
279         * mini-amd64.c (mono_arch_output_basic_block): Fix a typo.
280
281         * mini-x86.c (mono_arch_get_inst_for_method): Remove code which is now in
282         mini.c.
283
284         * mini-ia64.c (mono_arch_get_inst_for_method): Remove code which is now in
285         mini.c.
286
287         * mini-amd64.c (mono_arch_compute_omit_fp): Disable fp elimination for methods
288         returning a vtype in a register.
289
290         * mini.c (mini_get_inst_for_method): Move the handling of the atomic operations
291         here from the arch specific code.
292
293         * mini-amd64.c (mono_arch_get_inst_for_method): Remove code which is now in
294         mini.c.
295
296         * mini-amd64.c (mono_arch_output_basic_block): Add some micro optimizations.
297         (mono_arch_emit_prolog): Increment maximum prolog size.
298
299         * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Move the implementation of the
300         START_HANDLER/ENDFINALLY/ENDFILTER opcodes to mini-amd64.c.
301
302         * mini-x86.c (get_call_info): Receive a MonoCompile instead of a 
303         MonoGenericSharingContext.
304
305         * mini-ia64.c (get_call_info): Receive a MonoCompile instead of a 
306         MonoGenericSharingContext. Allocate memory from the cfg mempool.
307
308 2007-11-15  Mark Probst  <mark.probst@gmail.com>
309
310         * mini.c, mini.h, generic-sharing.c: Functions for producing code
311         which extract fields out of the runtime generic context.  Full
312         sharing of the NEWARR opcode.
313
314 Thu Nov 15 14:20:21 CET 2007 Paolo Molaro <lupus@ximian.com>
315
316         * abcremoval.c, mini.c, ssa.c, ssapre.c: updated to implement
317         --enable-minimal=ssa.
318
319 2007-11-13  Zoltan Varga  <vargaz@gmail.com>
320
321         * mini-trampolines.c (mono_delegate_trampoline): Update after 
322         mono_marshal_get_delegate_invoke () signature change.
323
324 2007-11-13  Mark Probst  <mark.probst@gmail.com>
325
326         * mini.c: Removed the shared context in favor of the generic
327         sharing context.  Allocate the MonoJitInfo structure with room for
328         the generic sharing context if it's needed.
329
330         * mini.h: Remove MonoGenericSharingContext declaration.  It's in
331         domain-internals.h now.
332
333         * mini-x86.c: Pass the generic sharing context to get_call_info ().
334
335         * generic-sharing.c: Several changes for working without a shared
336         context and instead operating on open types instead.
337
338 2007-11-12  David S. Miller  <davem@davemloft.net>
339
340        * inssel-sparc.brg: Fix double instruction emit.
341
342 2007-11-12  Zoltan Varga  <vargaz@gmail.com>
343
344         * mini.c (mono_jit_runtime_invoke): Avoid trying to compile the Array 
345         Get/Set/Address methods.
346         
347         * mini.c debug-debugger.c mini-trampolines.c: Update after 
348         mono_marshal_get_delegate_invoke signature change.
349
350 2007-11-12  Rodrigo Kumpera  <rkumpera@novell.com>
351
352         * cpu-arm.md: Increase the max size of OP_THROW to 24 bytes.
353         This can happens with dynamic methods. Fixes the other bug in #322722.
354
355 2007-11-12  Rodrigo Kumpera  <rkumpera@novell.com>
356
357         * tramp-arm.c (mono_arch_patch_callsite): Support patching
358         BX call sequence.
359
360         * mini-arm.c (arm_patch): Implement patching of BX call
361         sequence. Fixes one of the bugs in #322722.
362
363 2007-11-03  David S. Miller  <davem@huronp11.davemloft.net>
364
365        * mini-sparc.c (mono_arch_flush_icache): Make more efficient
366        under Linux.  We only need to flush every 32-byte cache line.    
367
368 2007-11-07  Massimiliano Mantione  <massi@ximian.com>
369
370         * mini.c:
371         move_basic_block_to_end: Add branches when needed, eventually creating
372         a new BB.
373         optimize_branches: added a parameter that tells if it's ok to create
374         new BBs (doing is "df_visit" has been called is (IMHO) a nightmare),
375         and avoid calling move_basic_block_to_end when it's not ok.
376         Fixes bug 318677.
377
378 2007-11-07  Mark Probst  <mark.probst@gmail.com>
379
380         * mini.c: Abort inlining call to InitializeArray if something
381         looks wrong.  Let the icall handle it, which now has proper safety
382         checks.
383
384 2007-11-05  Rodrigo Kumpera  <rkumpera@novell.com>
385
386         * mini.c (mono_spill_call): add support for soft-float.
387
388         * mini.c (mono_method_to_ir): add support for soft-float
389         to inlined functions that return float.
390
391         * mini.c (mono_method_to_ir): add support for soft-float
392         to cee_stsfld opcode on float fields.
393
394 2007-11-05  Geoff Norton  <gnorton@novell.com>
395
396         * mini-x86.h: Fix the structure access for X86 Leopard.
397
398
399 2007-11-05  Martin Baulig  <martin@ximian.com>
400
401         * mini-trampolines.c
402         (mono_magic_trampoline): Call mono_debugger_trampoline_compiled()
403         after compiling the method to notify the debugger.
404
405 2007-11-05  Martin Baulig  <martin@ximian.com>
406
407         * debug-debugger.h (MonoDebuggerInfo): Use the new breakpoint tables.
408
409 2007-11-02  Zoltan Varga  <vargaz@gmail.com>
410
411         * mini-sparc.c (EMIT_COND_SYSTEM_EXCEPTION_GENERAL): Applied patch from
412         David Miller <davem@davemloft.net>. Allow larger offsets in branches.
413
414 2007-11-01  Zoltan Varga  <vargaz@gmail.com>
415
416         * mini-amd64.c (mono_arch_emit_prolog): Check the domain as well for
417         native-to-managed wrappers.
418         
419 2007-11-01  Geoff Norton  <gnorton@novell.com>
420
421         * mini-ppc.h, mini-x86.h:  Handle Leopards renaming of some structure 
422         members.
423
424 Wed Oct 31 20:23:14 CET 2007 Paolo Molaro <lupus@ximian.com>
425
426         * mini.c, mini-x86.c: when getting back from unmanaged code
427         to managed via a marshaled delegate we also need to set the
428         right domain.
429
430 Wed Oct 31 19:53:33 CET 2007 Paolo Molaro <lupus@ximian.com>
431
432         * mini-amd64.c, mini-amd64.h, tramp-amd64.c: breakpoint table support
433         for amd64.
434
435 Wed Oct 31 19:29:30 CET 2007 Paolo Molaro <lupus@ximian.com>
436
437         * mini.c, mini.h, mini-x86, tramp-x86.c, mini-x86.h: added API to
438         let the debugger or other external agents to tell the JIT when
439         a sw breakpoint has been inserted in the code that the JIT needs
440         to be able to inspect.
441
442 2007-10-31  Martin Baulig  <martin@ximian.com>
443
444         * debug-debugger.h
445         (MonoDebuggerInfo): Remove `runtime_class_init'.
446
447 2007-10-30  Martin Baulig  <martin@ximian.com>
448
449         * debug-mini.h
450         (mono_debugger_thread_created): Added `MonoThread *' argument.
451         (mono_debugger_extended_notification): New public method.
452         (mono_debugger_trampoline_compiled): New public method.
453
454         * debug-mini.c
455         (MonoDebuggerThreadInfo): Added `thread' and
456         `extended_notifications' fields.
457
458         * debug-debugger.c
459         (debugger_executable_code_buffer): New static variable.
460
461         * debug-debugger.h
462         (MonoDebuggerInfo): Added `executable_code_buffer',
463         `executable_code_buffer_size', `breakpoint_info_area',
464         `breakpoint_table' and `breakpoint_table_size'.
465
466 2007-10-26  Rodrigo Kumpera  <rkumpera@novell.com>
467
468         * mini-arm.c (mono_arch_build_imt_thunk): Take the advantage
469         that IP  either is an unused value or the vtable pointer. IMT 
470         calls use vtable + offset now. Reduced by almost half the size
471         of IMT entries.
472
473 2007-10-26  Jonathan Chambers <joncham@gmail.com>
474
475         * mini-amd64.c: Begin Win64 port. Use AMD64_ARG_REG#
476         defines to access param registers. Replace long usage with
477         gsize as sizeof(long) != sizeof(void*) on Win64.
478
479         * mini-amd64.h: Add %rdi and %rsi to MonoLMF structure
480         on Win64. Fix intrinsic, use _AddressOfReturnAddress
481         instead of non-existant _GetAddressOfReturnAddress.
482
483         * tramp-amd64.c: Use AMD64_ARG_REG#     defines to access 
484         param registers. Save/restore %rdi and %rsi in MonoLMF.
485
486         * exceptions-amd64.c: Use AMD64_ARG_REG# defines to access 
487         param registers. Modify (throw_exception) signature to take 
488         %rdi and %rsi on Win64. 
489
490         Code is contributed under MIT/X11 license.
491
492 Thu Oct 25 23:06:58 CEST 2007 Paolo Molaro <lupus@ximian.com>
493
494         * helpers.c: unlink debugging output files.
495
496 2007-10-25  Zoltan Varga  <vargaz@gmail.com>
497
498         * mini.c: Move mono_create_ftnptr () to object.c.
499
500 2007-10-24  Rodrigo Kumpera  <rkumpera@novell.com>
501
502         * helpers.c (mono_disassemble_code): MonoCompile parameter is now
503         optional. This function can now be used to disassemble code generated
504         outside the JIT such as trampolines and IMT thunks.
505
506         * mini-arm.h: defined MONO_ARCH_HAVE_IMT.
507
508         * mini-arm.c (decode_vcall_slot_from_ldr): added, extract the
509         vtable pointer from a ldr instruction.
510
511         * mini-arm.c (mono_arch_get_vcall_slot_addr): support the
512         new IMT call sequence.
513
514         * mini-arm.c (mono_arch_output_basic_block): emit the IMT
515         call sequence for interface invocations.
516
517         * mini-arm.c (mono_arch_emit_imt_argument): added, required
518         for imt support. This function is empty since IMT on ARM requires no
519         special handling on the IR side.
520
521         * mini-arm.c (mono_arch_find_imt_method): added, required for
522         imt support.
523
524         * mini-arm.c (mono_arch_find_this_argument): added, required
525         for imt support.
526
527         * mini-arm.c (arm_emit_value_and_patch_ldr): added, patches
528         a ldr instruction to load a value stored in the code stream.
529
530         * mini-arm.c (mono_arch_build_imt_thunk):added, required
531         for imt support.
532
533
534 2007-10-23  Zoltan Varga  <vargaz@gmail.com>
535
536         * mini.c (mini_init): Install the jump trampoline callback.
537
538 Tue Oct 23 17:07:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
539
540         * mini-trampolines.c: handle synchronized methods with the common
541         vtable trampoline (bug #335601).
542
543 2007-10-17  Zoltan Varga  <vargaz@gmail.com>
544
545         * mini-ia64.h mini-amd64.c: Add support for the common vtable trampoline.
546
547         * inssel.brg (mini_emit_virtual_call): Fix the computation of ins->inst_offset on
548         64 bit platforms.
549
550         * mini-ia64.h mini-ia64.c: Add support for IMT.
551
552         * mini-x86.c (mono_arch_emit_prolog): Increase the size allocated for the
553         prolog. Fixes #331958.
554
555 2007-10-15  Zoltan Varga  <vargaz@gmail.com>
556
557         * mini-sparc.h mini-sparc.c: Add support for the common vtable trampoline.
558
559 Mon Oct 15 11:18:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
560
561         * mini-ppc.c, mini-ppc.h: ppc support for the common vtable
562         trampoline.
563
564 Mon Oct 15 10:41:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
565
566         * mini-amd64.c, mini-amd64.h: amd64 support for the common vtable
567         trampoline.
568
569 Mon Oct 15 10:39:26 CEST 2007 Paolo Molaro <lupus@ximian.com>
570
571         * mini-x86.c, mini-x86.h: x86 support for the common vtable
572         trampoline.
573
574 Mon Oct 15 10:37:15 CEST 2007 Paolo Molaro <lupus@ximian.com>
575
576         * mini-trampolines.c: changed the magic rampoline to understand
577         the common vtable trampoline method: the method to invoke is
578         determined by the vtable displacement of the call.
579
580 Mon Oct 15 10:35:12 CEST 2007 Paolo Molaro <lupus@ximian.com>
581
582         * mini.c, mini.h: register the common vtable trampoline if the
583         architecture supports it.
584
585 Mon Oct 15 09:50:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
586
587         * cpu-amd64.md: use the correct max length for tls_get.
588
589 2007-10-14  Zoltan Varga  <vargaz@gmail.com>
590
591         * mini.c (mono_method_to_ir): Use mini_get_class in CEE_LDELEM_ANY and
592         CEE_STELEM_ANY. Fixes #333696.
593
594 Thu Oct 11 18:04:29 CEST 2007 Paolo Molaro <lupus@ximian.com>
595
596         * exceptions-x86.c: provide more graceful handling of the case where
597         we followed a bogus function pointer from managed code (bug #332866).
598
599 2007-10-11  Mark Probst  <mark.probst@gmail.com>
600
601         * mini.h, mini.c: Introduced the MonoGenericSharingContext, which
602         replaces the generic_shared flag and will carry more information
603         in the future.
604
605         * generic-sharing.c: Added mini_type_stack_size() which allows
606         allows open types if given a generic sharing context.
607         mini_get_basic_type_from_generic() takes a
608         MonoGenericSharingContext* instead of a MonoCompile* now.
609
610         * mini-alpha.c, mini-amd64.c, mini-arm.c, mini-hppa.c,
611         mini-ia64.c, mini-mips.c, mini-ppc.c, mini-s390.c, mini-s390x.c,
612         mini-sparc.c, mini-x86.c: Trivial changes required by the two
613         changes above.  Just passing arguments through to the right
614         places.
615
616 Wed Oct 10 19:44:42 CEST 2007 Paolo Molaro <lupus@ximian.com>
617
618         * mini-arm.c: unify the call emission to emit_code_seq().
619
620 Wed Oct 10 13:05:46 CEST 2007 Paolo Molaro <lupus@ximian.com>
621
622         * tramp-arm.c: reduced the trampoline size.
623
624 2007-10-10  Mark Probst  <mark.probst@gmail.com>
625
626         * generic-sharing.c, mini.h, mini-amd64.c, mini-x86.c: Moved type
627         variable handling out of arch-specific code.
628
629 Wed Oct 10 10:49:28 CEST 2007 Paolo Molaro <lupus@ximian.com>
630
631         * mini-arm.c: implemented fast delegate dispatch.
632
633 2007-10-09  Zoltan Varga  <vargaz@gmail.com>
634
635         * mini-amd64.c (mono_arch_compute_omit_fp): Add more checks to ensure
636         that fp elimination is turned off if the space required by locals is too
637         big. Fixes #331958.
638
639 Tue Oct 9 21:01:03 CEST 2007 Paolo Molaro <lupus@ximian.com>
640
641         * Makefile.am, mini-arm.c, mini-arm.h, tramp-arm.c: ported
642         ARM to the new style trampoline.
643
644 2007-10-09  Zoltan Varga  <vargaz@gmail.com>
645
646         * tramp-amd64.c: Rework the specific trampoline code to make it smaller.
647
648         * mini-amd64.h mini-amd64.c: Export amd64_patch as mono_amd64_patch.
649
650 2007-10-09  Martin Baulig  <martin@ximian.com>
651
652         * debug-debugger.h
653         (MonoDebuggerMetadataInfo): Added `field_info_type_offset' and
654         `field_info_offset_offset'.     
655
656 Tue Oct 9 09:47:51 CEST 2007 Paolo Molaro <lupus@ximian.com>
657
658         * mini-ppc.c, mini-ppc.h, mini-ops.h, inssel-ppc.brg, cpu-g4.md:
659         removed more internal usage of the r11 register and made it available
660         to the register allocator.
661
662 2007-10-08  Mark Probst  <mark.probst@gmail.com>
663
664         * mini.c, mini-amd64.c, mini-x86.c: Allow open generic contexts
665         when sharing generics and treat type variables as references.
666
667 Mon Oct 8 10:55:38 CEST 2007 Paolo Molaro <lupus@ximian.com>
668
669         * mini-ppc.c: started removing the internal uses of register r11
670         to eventually allow the register allocator to manage it as an
671         additional available register.
672
673 Mon Oct 8 14:25:39 CEST 2007 Paolo Molaro <lupus@ximian.com>
674
675         * tramp-amd64.c: fixed memory corruption in the trampoline generation.
676
677 Mon Oct 8 12:06:33 CEST 2007 Paolo Molaro <lupus@ximian.com>
678
679         * tramp-ppc.c, tramp-x86.c: reduce the alignment requirements for
680         specific trampolines as they are not performance critical as a jump
681         target (maybe align as before only for AOT code?). This saves about
682         200 KB of native code on x86 for monodevelop startup.
683
684 Mon Oct 8 10:04:40 CEST 2007 Paolo Molaro <lupus@ximian.com>
685
686         * tramp-ppc.c: reduce the size of the trampolines, saves 160KB on
687         monodevelop startup.
688
689 2007-10-06  Zoltan Varga  <vargaz@gmail.com>
690
691         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Allow signed displacements.
692
693         * mini-sparc.h mini-sparc.c: Implement IMT support.
694
695         * tramp-sparc.c (mono_arch_create_trampoline_code): Rework the trampoline code so
696         its smaller and doesn't clobber sparc_g1.
697
698         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Update after trampoline changes.
699
700 Fri Oct 5 18:28:11 CEST 2007 Paolo Molaro <lupus@ximian.com>
701
702         * mini-ppc.c: optimized the size of the IMT thunks a bit.
703
704 Fri Oct 5 18:08:30 CEST 2007 Paolo Molaro <lupus@ximian.com>
705
706         * mini-ppc.c: implemented fast delegate invocation.
707
708 Fri Oct 5 00:01:05 CEST 2007 Paolo Molaro <lupus@ximian.com>
709
710         * mini-ppc.h, mini-ppc.c: IMT support for the PPC architecture.
711
712 Thu Oct 4 22:04:49 CEST 2007 Paolo Molaro <lupus@ximian.com>
713
714         * mini-ppc.c, mini-ppc.h, tramp-ppc.c, Makefile.am: port the PPC
715         code to the new style trampoline in preparation for IMT support.
716
717 Thu Oct 4 19:01:59 CEST 2007 Paolo Molaro <lupus@ximian.com>
718
719         * mini-ppc.c, tramp-ppc.c: don't use r13 as it's used by the PPC EABI
720         systems already. This also reduces the specific trampiline sizes and
721         prepares for the use of r12 as the IMT identifier register.
722
723 Thu Oct 4 16:38:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
724
725         * mini-mips.h: endianess fix (simplified from a patch by
726         Thomas Kunze <thommy@tabao.de>, bug #323737).
727
728 Thu Oct 4 14:43:49 CEST 2007 Paolo Molaro <lupus@ximian.com>
729
730         * exceptions-ppc.c, mini-ppc.h: refactor to use macros
731         to access ucontext fields and enable netbsd support
732         (partially from Magnus Henoch <mange@freemail.hu>).
733
734 Thu Oct 4 12:35:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
735
736         * genmdesc.pl: patch from Henryk Plötz <henryk@openmoko.org> to
737         use the preprocessor from the CPP env var if it is set.
738
739 Wed Oct 3 17:11:38 CEST 2007 Paolo Molaro <lupus@ximian.com>
740
741         * mini-trampolines.c: fixed an assertion and moved it earlier in the
742         code, before interface_offset gets used.
743
744 2007-10-02  Zoltan Varga  <vargaz@gmail.com>
745
746         * mini-trampolines.c (mono_convert_imt_slot_to_vtable_slot): Call 
747         mono_class_setup_vtable () before accessing klass->vtable.
748
749 2007-10-01  Zoltan Varga  <vargaz@gmail.com>
750
751         * aot-compiler.c (get_plt_index): Rework the handling of wrappers to be not so
752         hackish.
753
754 Mon Oct 1 15:00:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
755
756         * mini.c, mini-trampolines.c, mini.h: enable the lazy filling of the
757         IMT slots (this saves hundreds of KB of memory in programs like
758         IronPython and Monodevelop).
759
760 Mon Oct 1 14:44:19 CEST 2007 Paolo Molaro <lupus@ximian.com>
761
762         * mini.c: print the delegate counter.
763
764 Mon Oct 1 14:36:50 CEST 2007 Paolo Molaro <lupus@ximian.com>
765
766         * mini-x86.c: make it easier to enable the debugging code for IMT
767         slots.
768
769 2007-09-28  Martin Baulig  <martin@ximian.com>
770
771         * debug-debugger.h
772         (MonoDebuggerMetadataInfo): Add `klass_image_offset',
773         `mono_method_klass_offset' and `mono_method_token_offset'.
774
775 2007-09-20  Mark Probst  <mark.probst@gmail.com>
776
777         * mini.c: First generics sharing implementation.  Can only share
778         in very simple cases.  If sharing doesn't work it falls back to
779         dedicated compilation.
780
781         * mini.h: Flag in MonoCompile to specify whether generic
782         compilation is shared.  Flags enum for marking which generic inst
783         of a context is used.  Prototypes for helper functions.
784
785         * generic-sharing.c: Helper functions for generic method sharing.
786
787         * optflags-def.h: Optimization flag (gshared) for enabling generic
788         method sharing added.
789
790         * Makefile.am: generic-sharing.c added.
791
792 2007-09-19 Daniel Nauck <dna@mono-project.de>
793
794         * mini.c (mono_thread_abort): fixed typo in r86014. It should be '==' instead of '!='.
795
796 2007-09-19  Massimiliano Mantione  <massi@ximian.com>
797         * mini.c (mono_thread_abort): Correctly handle ThreadAbortException,
798         fixes bug 325507.
799
800 2007-09-19  Martin Baulig  <martin@ximian.com>
801
802         * mini.c (mini_cleanup): Only call mono_debugger_cleanup() here;
803         mono_debug_cleanup() is now part of mono_cleanup().
804
805 2007-09-18  Zoltan Varga  <vargaz@gmail.com>
806
807         * driver.c (mono_main): Fix a warning.
808
809 2007-09-17  Zoltan Varga  <vargaz@gmail.com>
810
811         * aot-compiler.c: Optimize various parts when processing large assemblies.
812         Fixes ##325568.
813
814         * mini.c (mono_patch_info_hash): Improve hash function.
815
816 2007-09-14  Jonathan Chambers <joncham@gmail.com>
817
818         * mini-exceptions.c: Add HAVE_UNISTD_H check around include.
819         
820         Code is contributed under MIT/X11 license.
821
822 2007-09-14  Zoltan Varga  <vargaz@gmail.com>
823
824         * mini.c (mini_init): Fix a leak.
825
826         * debug-mini.c (mono_debug_free_method_jit_info): Fix a leak.
827
828 Fri Sep 14 12:53:13 CEST 2007 Paolo Molaro <lupus@ximian.com>
829
830         * mini.c: redirect string.InternalAllocStr() to the managed allocator.
831
832 2007-09-14  Zoltan Varga  <vargaz@gmail.com>
833
834         * mini-amd64.c (mono_arch_find_imt_method): Add support for AOT code.
835
836 2007-09-13  Zoltan Varga  <vargaz@gmail.com>
837
838         * Makefile.am generics-variant-types.2.il generics.cs: Add some generics
839         variance tests.
840
841         * inssel.brg: Reorganize the isinst/castclass code to reduce code duplication.
842
843         * mini.c (handle_alloc): Enable managed allocators in AOT code.
844
845         * aot-compiler.c (encode_patch): Add support for MONO_WRAPPER_ALLOC.
846
847         * aot-runtime.c (decode_patch_info): Ditto.
848
849 2007-09-12  Jonathan Chambers <joncham@gmail.com>
850
851         * mini-x86.c (mono_arch_get_delegate_invoke_impl): Implement
852         static case. Cache delegates in architecture specific code, 
853         based on number of parameters.
854         
855         * mini-amd64.c (mono_arch_get_delegate_invoke_impl): Cache delegates
856         in architecture specific code, based on number of parameters.
857         
858         * mini-trampolines.c (mono_delegate_trampoline): Architecture specific 
859         caching happen in architecture specific code now.
860         
861         Code is contributed under MIT/X11 license.
862
863 2007-09-12  Jonathan Chambers <joncham@gmail.com>
864
865         * mini.h, mini.c, mini-x86.c, mini-amd64.c, mini-hppa.c, mini-mips.c,
866         mini-s390x.c, mini-arm.c, mini-ia64.c, mini-sparc.c, mini-ppc.c, mini-alpha.c,
867         mini-s390.c: Add mono_arch_init and mono_arch_cleanup methods.
868
869         Code is contributed under MIT/X11 license.
870
871 2007-05-15  Massimiliano Mantione  <massi@ximian.com>
872         * mini.c: (mono_thread_abort) Fixed bug #82416.
873
874 Tue Sep 11 16:15:53 CEST 2007 Paolo Molaro <lupus@ximian.com>
875
876         * mini.: hook the new managed GC allocation feature into the JIT.
877
878 Tue Sep 11 16:14:16 CEST 2007 Paolo Molaro <lupus@ximian.com>
879
880         * mini.c: implementation for the new runtime tls opcode.
881
882 2007-09-11  Martin Baulig  <martin@ximian.com>
883
884         * debug-debugger.h
885         (MonoDebuggerMetadataInfo): Add `mono_method_flags_offset' and
886         `mono_method_inflated_offset'.
887
888 2007-09-07  Zoltan Varga  <vargaz@gmail.com>
889
890         * driver.c mini.h mini.c: Add a new devel command line option for injecting
891         async exceptions into a method.
892
893         * mini-amd64.h mini-amd64.c: Implement injecting of async exceptions for the
894         purpose of testing whenever the unwinder works at every instruction.
895
896 Thu Sep 6 12:42:14 CEST 2007 Paolo Molaro <lupus@ximian.com>
897
898         * mini.c: check accessibility of method used in ldftn (fixes
899         bug #82635).
900
901 2007-09-04  Zoltan Varga  <vargaz@gmail.com>
902
903         * mini-amd64.c (mono_arch_output_basic_block): Fix a warning.
904
905         * inssel.brg: Fix a warning.
906
907 2007-09-03  Martin Baulig  <martin@ximian.com>
908
909         * debug-debugger.c: `MONO_DEBUGGER_EVENT_INITIALIZE_MANAGED_CODE'
910         now takes the `main_method' as argument.
911
912 2007-09-02  Zoltan Varga  <vargaz@gmail.com>
913
914         * cpu-sparc.md (endfilter): Add missing src1:i argument.
915
916 2007-08-30  Jonathan Chambers <joncham@gmail.com>
917
918         * driver.c: include the cil-coff.h header on Windows.
919         
920         Code is contributed under MIT/X11 license.
921
922 Thu Aug 30 16:17:23 CEST 2007 Paolo Molaro <lupus@ximian.com>
923
924         * mini.c, driver.c: don't include the cil-coff.h header.
925
926 Thu Aug 30 14:50:53 CEST 2007 Paolo Molaro <lupus@ximian.com>
927
928         * mini.c: flag places that needs fixes fo soft-float support.
929
930 Wed Aug 29 18:26:20 CEST 2007 Paolo Molaro <lupus@ximian.com>
931
932         * mini.h, inssel-float.brg: fix soft-float constant loads on big
933         endian systems (partially from Dean Jenkins, bug #81924).
934
935 2007-08-28  Mark Probst  <mark.probst@gmail.com>
936
937         * mini.c (check_linkdemand): Remove embedded reference object in
938         call to LinkDemandSecurityException.
939         (mono_jit_compile_method_inner): Call LinkDemandSecurityException
940         with an IntPtr instead of a reference object.
941
942 2007-08-28  Zoltan Varga  <vargaz@gmail.com>
943
944         * mini.c (handle_initobj): Handle alignment properly.
945
946         * inssel.brg (mini_emit_memset): Ditto. 
947
948         * inssel.brg (mini_emit_memcpy): Ditto. 
949
950         * inssel-sparc.brg: Ditto.              
951
952         * mini.h mini.c inssel-*.brg: Pass alignment information to OP_MEMCPY/MEMSET.
953
954 2007-08-26  Zoltan Varga  <vargaz@gmail.com>
955
956         * mini-exceptions.c (mono_handle_exception_internal): Skip the first frame for
957         exceptions raised in unmanaged code. Fixes part of #82594.
958
959 2007-08-24  Mark Probst  <mark.probst@gmail.com>
960
961         * mini.c (mono_method_to_ir), declsec.c
962         (mono_declsec_linkdemand_aptc): Fixed custom attr leaks.
963
964 2007-08-22  Martin Baulig  <martin@ximian.com>
965
966         * debug-mini.h
967         (MonoDebuggerThreadInfo): New typedef.
968         (mono_debugger_thread_table): New global variable.
969         (mono_debugger_thread_created): New public function.
970         (mono_debugger_thread_cleanup): New public function.
971
972         * debug-debugger.h
973         (MonoDebuggerInfo):
974         - removed `get_current_thread' and `lookup_assembly'.
975         - removed `data_table'.
976         - added `thread_table'.
977
978         * mini.c
979         (mono_thread_start_cb): Call mono_debugger_thread_created().
980         (mono_thread_attach_cb): Likewise.
981         (mini_thread_cleanup): Call mono_debugger_thread_cleanup().
982         (mini_cleanup): Move mono_debug_cleanup() down, after free'ing the
983         initial domain.
984
985         * driver.c (mono_main): Move mono_debug_init() up, before calling
986         mini_init(); mono_debug_init_1() and mono_debug_init_2() are gone.
987
988 Tue Aug 21 16:40:04 CEST 2007 Paolo Molaro <lupus@ximian.com>
989
990         * mini-x86.c, inssel-x86.brg: group multiple stack adjustments
991         together when passing several arguments of type double (gives a small
992         speedup and saves a few bytes of generated code).
993
994 2007-08-20  Jb Evain  <jbevain@novell.com>
995
996         * mini.c (mono_method_to_ir): fix leak on InvalidProgramException.
997
998 2007-08-20  Jb Evain  <jbevain@novell.com>
999
1000         * mini.c (mono_method_to_ir): throw MethodAccessException
1001         and FieldAccessException instead of InvalidProgramException.
1002
1003 2007-08-20  Mark Probst  <mark.probst@gmail.com>
1004
1005         * mini.c: CoreCLR security checks.
1006
1007         * mini.h: Removed MonoSecurityMode (moved to
1008         metadata/security-manager.h) and mono_security_mode global var
1009         (replaced by set/get functions in security-manager.h).
1010
1011         * driver.c: Added "core-clr-test" security mode for testing.  Used
1012         set-function for setting security mode.
1013
1014 2007-08-17  Mark Probst  <mark.probst@gmail.com>
1015
1016         * mini.c: MonoJitInfo's are freed hazardously now.  Statistics for
1017         the new jit_info_table.
1018
1019         * driver.c: Test code for the new jit_info_table (enabled by the
1020         define MONO_JIT_INFO_TABLE_TEST).
1021
1022 2007-08-14  Zoltan Varga  <vargaz@gmail.com>
1023
1024         * tramp-amd64.c (mono_arch_nullify_class_init_trampoline): Fix
1025         detection of call <REG> instruction sequence. Fixes build on freebsd.
1026
1027 2007-08-13  Zoltan Varga  <vargaz@gmail.com>
1028
1029         * mini-exceptions.c: Fix a warning.
1030
1031 2007-08-11  Zoltan Varga  <vargaz@gmail.com>
1032
1033         * exceptions-amd64.c (mono_arch_handle_altstack_exception): Enable the new
1034         stack overflow handling code on amd64 too.
1035
1036         * mini-exceptions.c (mono_setup_altstack): Make this use 
1037         mono_thread_get_stack_bounds ().
1038
1039         * mini-x86.h: Disable sigaltstack on solaris x86.
1040
1041 2007-08-10  Zoltan Varga  <vargaz@gmail.com>
1042
1043         * mini-exceptions.c (mono_setup_altstack): Enable this to work on solaris x86.
1044
1045 2007-08-10  Geoff Norton  <gnorton@customerdna.com>
1046
1047         * tramp-x86.c: Remove some unneeded alignment changes on Apple.  Fixes #82387.
1048
1049 2007-08-08  Zoltan Varga  <vargaz@gmail.com>
1050
1051         * mini-exceptions.c (mono_print_thread_dump): Enable this on amd64 too.
1052
1053         * mini-amd64.h (MONO_INIT_CONTEXT_FROM_FUNC): Fix a warning.
1054
1055 2007-08-03  Neale Ferguson <neale@sinenomine.net>
1056
1057         * mini-s390.c (add_general): Adjust offset calculation to take into account of rounding up
1058         due to alignment.
1059
1060 Thu Aug 2 17:36:22 CEST 2007 Paolo Molaro <lupus@ximian.com>
1061
1062         * mini-ppc.c: avoid an invalid encoding of unsigned right shift by 0
1063         to be emitted (bug #82281).
1064
1065 2007-08-01  Martin Baulig  <martin@ximian.com>
1066
1067         Merged the `debugger-dublin' branch.
1068
1069         * debug-debugger.h (MonoDebuggerInfo):
1070         Removed the `old_*' compatibility entries.
1071         Added `debugger_version' and `data_table'.
1072         Renamed `get_method_addr_or_bpt' -> `insert_breakpoint'.
1073         Renamed `remove_method_breakpoint' -> `remove_breakpoint'.
1074
1075         * debug-mini.c
1076         (MiniDebugMethodBreakpointInfo): Add `address_list'.
1077         (mono_debugger_check_breakpoints): Take a `MonoDebugMethodAddress *'
1078         instead of a `gconstpointer'.
1079         (mono_debugger_insert_method_breakpoint): Return a
1080         `MonoDebugMethodAddressList *'.
1081
1082 2007-06-28  Martin Baulig  <martin@ximian.com>
1083
1084         * debug-debugger.h (MonoDebuggerInfo): Added `debugger_version'.
1085
1086 2007-08-01  Zoltan Varga  <vargaz@gmail.com>
1087
1088         * mini-amd64.h (MONO_INIT_CONTEXT_FROM_FUNC): Avoid using 
1089         __builtin_frame_address () since it is broken on older gcc versions.
1090
1091 Tue Jul 31 17:34:42 CEST 2007 Paolo Molaro <lupus@ximian.com>
1092
1093         * mini.c, mini.h, mini-exceptions.c: added a bit of documentation
1094         on the stack overflow handling and made the managed stack overflows
1095         catchable in most cases using soft guard pages.
1096         * exceptions-x86.c: added code to restore the protection in the soft
1097         guard pages at the end of exception handling.
1098
1099 2007-07-31  Zoltan Varga  <vargaz@gmail.com>
1100
1101         * mini.c (SIG_HANDLER_SIGNATURE): Fix a warning.
1102
1103 Mon Jul 30 17:43:13 CEST 2007 Paolo Molaro <lupus@ximian.com>
1104
1105         * exceptions-ppc.c, mini-ppc.h: arch-specific stack overflow
1106         exception handling.
1107
1108 Mon Jul 30 17:38:13 CEST 2007 Paolo Molaro <lupus@ximian.com>
1109
1110         * mini-alpha.h, mini-ia64.h, mini-sparc.h: disable the altstack
1111         signal handling support until it has been ported to the new mechanism.
1112         * mini.c: fixed stack overflow detection and use the new
1113         architecture code  to handle signals on the altstack.
1114
1115 Mon Jul 30 17:33:02 CEST 2007 Paolo Molaro <lupus@ximian.com>
1116
1117         * exceptions-amd64.c, mini-amd64.h: amd64 code to handle
1118         stack overflows on the alt stack.
1119
1120 Mon Jul 30 17:29:56 CEST 2007 Paolo Molaro <lupus@ximian.com>
1121
1122         * exceptions-x86.c, mini-x86.h, mini.h: new code to handle
1123         stack overflows on the alt stack.
1124
1125 Mon Jul 30 11:50:06 CEST 2007 Paolo Molaro <lupus@ximian.com>
1126
1127         * exceptions-ppc.c: cleanup preparing for altstack support.
1128
1129 Mon Jul 30 11:31:24 CEST 2007 Paolo Molaro <lupus@ximian.com>
1130
1131         * exceptions-arm.c: cleanup preparing for altstack support.
1132
1133 2007-07-27  Mark Probst  <mark.probst@gmail.com>
1134
1135         * mini.c (print_jit_stats): Output hazard pointer stats.
1136
1137 2007-07-26  Mark Probst  <mark.probst@gmail.com>
1138
1139         * driver.c, mini.c: Replaced security mode flags with a single
1140         enum variable.
1141
1142 Thu Jul 26 20:12:12 CEST 2007 Paolo Molaro <lupus@ximian.com>
1143
1144         * mini.c, mini-exceptions.c: cleanup the sigaltstack code.
1145
1146 2007-07-25  Mark Probst  <mark.probst@gmail.com>
1147
1148         * mini.c, mini.h, driver.c (mono_main): Added command-line flag
1149         (which doesn't do anything yet) for activating Core CLR
1150         (Silverlight) security.
1151
1152 Tue Jul 24 21:16:17 CEST 2007 Paolo Molaro <lupus@ximian.com>
1153
1154         * mini-codegen.c: work around a possible gcc bug on arm.
1155
1156 Tue Jul 24 17:20:19 CEST 2007 Paolo Molaro <lupus@ximian.com>
1157
1158         * driver.c, mini-x86.h, mini-amd64.h: print a nice error
1159         message for platforms that don't support AOT compilation.
1160
1161 Mon Jul 23 10:29:29 CEST 2007 Paolo Molaro <lupus@ximian.com>
1162
1163         * mini.h, mini.c, driver.c: temporary smcs hack.
1164
1165 Mon Jul 23 09:29:34 CEST 2007 Paolo Molaro <lupus@ximian.com>
1166
1167         * mini-arm.h, mini-arm.c: arm EABI fixes.
1168
1169 2007-07-22  Zoltan Varga  <vargaz@gmail.com>
1170
1171         * exceptions-x86.c (mono_arch_find_jit_info): Handle the lmf->method == NULL
1172         case.
1173
1174         * tramp-x86.c (mono_arch_create_trampoline_code): Only set lmf->method for
1175         trampolines taking a method argument.
1176
1177         * mini-x86.h (MonoLMF): Add an 'esp' field plus comments.
1178
1179         * mini-x86.c (mono_arch_emit_prolog): Update after changes to the LMF structure.
1180         * tramp-x86.c (mono_arch_create_trampoline_code): Ditto.
1181
1182         * exceptions-x86.c (mono_arch_get_jit_info): Properly clean up the stack after
1183         JIT compilation throws an exception. Fixes #82050.
1184
1185 2007-07-19  Mark Probst  <mark.probst@gmail.com>
1186
1187         * mini.c: Removed the MonoLoaderErrorKind enum and replaced it
1188         with the MONO_EXCEPTION_ defines.
1189
1190 2007-07-17  Zoltan Varga  <vargaz@gmail.com>
1191
1192         * mini-amd64.c (mono_arch_find_imt_method): Handle mov reg,IMM64 case. Fixes
1193         #82117.
1194         
1195         * mini-amd64.c (mono_arch_find_imt_method): Add some debug code to help find out
1196         the cause of an assertion.
1197
1198 Mon Jul 16 19:31:21 CEST 2007 Paolo Molaro <lupus@ximian.com>
1199
1200         * mini.c, jit-icalls.c: mono_get_inflated_method() is obsolete,
1201         removed.
1202
1203 2007-07-15  Zoltan Varga  <vargaz@gmail.com>
1204
1205         * mini-amd64.c (mono_arch_build_imt_thunk): Remove the non-32bit MonoMethod
1206         assert. Should fix #82103.
1207
1208 2007-07-14  Zoltan Varga  <vargaz@gmail.com>
1209
1210         * mini-exceptions.c (mono_jit_walk_stack_from_ctx): Use MONO_CONTEXT_GET_SP ()
1211         here too. Fixes #82095.
1212
1213         * mini-amd64.c (mono_arch_build_imt_thunk): Add support for non-32bit MonoMethod
1214         addresses.
1215
1216         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add a couple asserts.
1217
1218         * mini-amd64.h: Enable IMT for amd64.
1219         
1220         * mini-amd64.c (mono_arch_build_imt_thunk): Optimize IMT thunk size.
1221
1222 2007-07-12  Zoltan Varga  <vargaz@gmail.com>
1223
1224         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add support for IMT call sequences.
1225
1226 2007-07-12  Mark Probst  <mark.probst@gmail.com>
1227
1228         * mini.c (check_linkdemand, mono_method_to_ir): Abort compilation
1229         as soon as check_linkdemand sets an exception_type.
1230
1231 Thu Jul 12 12:18:22 CEST 2007 Paolo Molaro <lupus@ximian.com>
1232
1233         * mini-x86.c: fixed offsets for IMT call sequence.
1234         * mini-x86.h: enable IMT again.
1235
1236 2007-07-11  Zoltan Varga  <vargaz@gmail.com>
1237
1238         * trace.c (mono_trace_enter_method): Decode MonoType too.
1239
1240         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Handle signed displacements too.
1241
1242         * mini.h mini-x86.h mini-trampolines.c: Change the signature of mono_arch_find_imt_method () to pass the calling code address too.
1243
1244         * mini-amd64.c: Add preliminary IMT implementation.
1245         
1246 Wed Jul 11 18:21:30 CEST 2007 Paolo Molaro <lupus@ximian.com>
1247
1248         * mini-x86.c: adjusted mono_arch_get_vcall_slot_addr () to
1249         understand the new IMT-base interface invocation (thanks to
1250         Daniel Nauck for the report and the remote debugging session).
1251
1252 Wed Jul 11 14:54:39 CEST 2007 Paolo Molaro <lupus@ximian.com>
1253
1254         * mini-x86.c: size and speed optimizations for the IMT bsearch.
1255
1256 2007-07-11  Zoltan Varga  <vargaz@gmail.com>
1257
1258         * Makefile.am (aotcheck): Make this actually use the AOTed code.
1259
1260 Wed Jul 11 12:41:32 CEST 2007 Paolo Molaro <lupus@ximian.com>
1261
1262         * mini-trampolines.c: implement AOT IMT support.
1263         * mini-x86.h: enable IMT support for wider testing.
1264
1265 2007-07-10  Zoltan Varga  <vargaz@gmail.com>
1266
1267         * inssel.brg (emit_imt_argument): Add aot support here.
1268
1269         * aot-runtime.c (decode_patch_info): Fix reading of MONO_PATCH_INFO_METHOD.
1270
1271 Tue Jul 10 17:50:58 CEST 2007 Paolo Molaro <lupus@ximian.com>
1272
1273         * mini-x86.c, mini-x86.h, tramp-x86.c: x86 arch-specific changes
1274         of the IMT implementation, partially from massi, with my
1275         implementation of the bsearch sequence. Disabled by default until
1276         the AOT code is implemented.
1277
1278 2007-07-10  Zoltan Varga  <vargaz@gmail.com>
1279
1280         * cpu-x86.md: The source argument of sext_i1/i2 must by a byte reg.
1281
1282         * inssel-x86.brg: Add reg:ldind.i1(regvar) rules. Fixes #82056.
1283
1284 Tue Jul 10 17:33:12 CEST 2007 Paolo Molaro <lupus@ximian.com>
1285
1286         * inssel.brg, mini.c, mini.h, mini-trampolines.c:
1287         arch-independent IMT JIT code from Massimiliano
1288         Mantione (massi@ximian.com) with small cleanups from me.
1289
1290 Tue Jul 10 13:07:24 CEST 2007 Paolo Molaro <lupus@ximian.com>
1291
1292         * Makefile.am: fix svn invocation to get the svn revision to be
1293         independent of the local language (build fix).
1294
1295 2007-07-09  Mark Probst  <mark.probst@gmail.com>
1296
1297         * mini.c (inline_method): Reset cfg->exception_type if the
1298         inlining is aborted.  Fixes: 82049.
1299
1300 Mon Jul 9 17:26:47 CEST 2007 Paolo Molaro <lupus@ximian.com>
1301
1302         * mini.c: remove assert from exception handling code when exception_ptr
1303         is not set.
1304
1305 2007-07-05  Zoltan Varga  <vargaz@gmail.com>
1306
1307         * mini.c (mono_codegen): Add an assert.
1308
1309         * mini-x86.c (mono_arch_emit_prolog): Allocate space for the profiler method 
1310         enter and leave code.
1311         * mini-amd64.c (mono_arch_emit_prolog): Likewise.
1312
1313 Thu Jul 5 20:12:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
1314
1315         * mini-ppc.c: fixed memory corruption for localloc(0)
1316         (bug #81852).
1317
1318 2007-07-05  Zoltan Varga  <vargaz@gmail.com>
1319         
1320         * mini.c: Fix warnings.
1321
1322 Wed Jul 4 15:30:36 CEST 2007 Paolo Molaro <lupus@ximian.com>
1323
1324         * optflags-def.h, mini-x86.c: added sse2 optimization flag and use it
1325         to emit better double->int conversions.
1326
1327 Tue Jul 3 19:42:16 CEST 2007 Paolo Molaro <lupus@ximian.com>
1328
1329         * mini.c: the provided Min/Max optimizations are valid for unisgned
1330         ints.
1331
1332 2007-07-03  Rodrigo Kumpera  <rkumpera@novell.com>
1333
1334         * mini.c (can_access_method, can_access_field): methods moved to metadata/class.c and renamed to mono_method_can_access_method and mono_method_can_acesss_field
1335
1336 2007-06-28  Miguel de Icaza  <miguel@novell.com>
1337
1338         * mini.c (mono_running_on_valgrind): Add support for reporting the
1339         method and  its boundaries to valgrind.
1340
1341 2007-06-28  Martin Baulig  <martin@ximian.com>
1342
1343         * debug-debugger.h (MonoDebuggerInfo): Added `debugger_version'.
1344
1345 2007-06-25  Zoltan Varga  <vargaz@gmail.com>
1346
1347         * ssa.c (visit_inst): Add support for OP_BR. Fixes #81946.
1348
1349         * generic.2.cs: Add new test case.
1350
1351 2007-06-25  Martin Baulig  <martin@ximian.com>
1352
1353         Merged the `debugger-dublin' branch.
1354
1355         * debug-mini.c
1356         (mono_debugger_insert_method_breakpoint): New public method.
1357         (mono_debugger_remove_method_breakpoint): Likewise.
1358         (mono_debugger_check_breakpoints): New static method.
1359         (mono_debug_close_method): Call mono_debugger_check_breakpoints().
1360
1361         * debug-debugger.h (MonoDebuggerInfo):
1362         Renamed (to keep backward compatibility in the vtable):
1363         `insert_breakpoint' -> `old_insert_breakpoint'.
1364         `remove_breakpoint' -> `old_remove_breakpoint'.
1365         `create_string' -> `old_create_string'.
1366         `lookup_class' -> `old_lookup_class'.
1367         `lookup_type' -> removed; changed into a dummy field.
1368         `lookup_assembly' -> `old_lookup_assembly'.
1369         Added (same functionality, but different signature):
1370         `create_string', `lookup_class', `lookup_assembly'
1371         Added new:
1372         `get_method_addr_or_bpt', `remove_method_breakpoint',
1373         `runtime_class_init'.
1374
1375         * debug-debugger.c: Merged the `debugger-dublin' branch.
1376
1377 2007-06-23  Zoltan Varga  <vargaz@gmail.com>
1378
1379         * mini-amd64.c (peephole_pass_1): Optimize away moves at the beginning of the bb as
1380         well.
1381         (peephole_pass): Likewise.
1382
1383 Fri Jun 22 09:17:08 CEST 2007 Paolo Molaro <lupus@ximian.com>
1384
1385         * driver.c: hopefully make setaffinity work also for ancient
1386         versions of linux.
1387
1388 2007-06-22  Atsushi Enomoto  <atsushi@ximian.com>
1389
1390         * driver.c : win32 build fix.
1391
1392 Thu Jun 21 19:24:03 CEST 2007 Paolo Molaro <lupus@ximian.com>
1393
1394         * driver.c: check for the MONO_NO_SMP env var and bind to a single
1395         processor if it is set.
1396
1397 2007-06-21  Martin Baulig  <martin@ximian.com>
1398
1399         * debug-mini.h: New file.
1400
1401         * debug-mini.c
1402         (mono_debugger_insert_breakpoint_full): Moved here from
1403         ../metadata/mono-debug-debugger.c.
1404         (mono_debugger_remove_breakpoint): Likewise.
1405         (mono_debugger_breakpoint_callback): Likewise.
1406
1407 2007-06-15  Raja R Harinath  <rharinath@novell.com>
1408
1409         * jit-icalls.c (mono_helper_compile_generic_method): Update to
1410         changes in MonoGenericClass.
1411
1412 2007-06-14  Zoltan Varga  <vargaz@gmail.com>
1413
1414         * mini-codegen.c (mono_opcode_to_type): Fix ia64 build.
1415
1416 2007-06-14  Raja R Harinath  <rharinath@novell.com>
1417
1418         * jit-icalls.c (mono_helper_compile_generic_method): Update to
1419         removal of MonoGenericMethod.
1420
1421 Thu Jun 14 12:42:04 CEST 2007 Paolo Molaro <lupus@ximian.com>
1422
1423         * mini-exceptions.c: hooks for the exception events profiling API.
1424
1425 2007-06-14  Randolph Chung  <tausq@debian.org>
1426
1427         * Makefile.ma: Add hppa target.
1428         * mini-arch.h: Include mini-hppa.h
1429         * cpu-hppa.md, exceptions-hppa.c, inssel-hppa.brg, mini-hppa.c,
1430         mini-hppa.h, tramp-hppa.c: New files for 32-bit HPPA port.
1431         Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
1432
1433 2007-06-14  Randolph Chung  <tausq@debian.org>
1434
1435         * inssel.brg: Add rules for "chained" compare-branch operations so that
1436         a single compare op can affect multiple branches.  Adjust cost for
1437         OP_CEQ/OP_CGT/OP_CGT_UN/OP_CLT/OP_CLT_UN.
1438         * inssel-long32.brg: Update rules to use compare-branch macros.  Adjust
1439         cost for some rules so that they can more easily be overridden by
1440         per-arch rules (with fixes from lupus).
1441         Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
1442
1443 2007-06-13  Randolph Chung  <tausq@debian.org>
1444
1445         * mini-ops.h: Reorder branch ops so that they match the order of the
1446         corresponding CEE_* ops.  The code expects them this way.
1447         Add new ops for HPPA target.
1448         Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
1449
1450 2007-06-13  Randolph Chung  <tausq@debian.org>
1451
1452         * mini-exceptions.c: Handle cases where the stack grows towards
1453         larger addresses.
1454         Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
1455
1456 Wed Jun 13 19:13:23 CEST 2007 Paolo Molaro <lupus@ximian.com>
1457
1458         * jit-icalls.c, mini.h, mini.c: added virtual generic invoke
1459         counter.
1460         * driver.c: explain where a non-matching corlib is found.
1461
1462 2007-06-13  Mark Probst  <mark.probst@gmail.com>
1463
1464         * mini.c (print_jit_stats): Output dynamic code allocation stats.
1465
1466 2007-06-10  Sanghyeon Seo <sanxiyn@gmail.com>
1467
1468         * mini-exceptions.c: Generate a method profile leave event during
1469         an exception to ensure that the profiler gets notified.
1470
1471 2007-06-07  Zoltan Varga  <vargaz@gmail.com>
1472
1473         * mini-amd64.c (peephole_pass): Merge some small changes from the linear-ir 
1474         branch.
1475
1476         * cpu-amd64.md: Add long_and/or/xor opcodes.
1477
1478 2007-06-06  Wade Berrier  <wberrier@novell.com>
1479
1480         * cpu-s390x.md (shr_imm): Correct the length of shr_imm instruction.
1481         (./class/lib/monolite/mcs.exe:25498): WARNING **: wrong maximal instruction 
1482         length of instruction shr_imm (expected 8, got 10)
1483
1484 2007-06-06  Zoltan Varga  <vargaz@gmail.com>
1485
1486         * mini-ia64.c (mono_arch_output_basic_block): Really fix the build.
1487
1488 2007-06-06  Mark Probst  <mark.probst@gmail.com>
1489
1490         * mini.c, driver.c: Changed MonoDomain.jit_code_hash to a
1491         MonoInternalHashTable again (fixed bug in the internal hash table
1492         code).
1493
1494 2007-06-06  Mark Probst  <mark.probst@gmail.com>
1495
1496         * mini.c, driver.c: Reverted the MonoInternalHashTable changes.
1497         Have to figure out what makes it crash the SWF regression.
1498
1499 2007-06-05  Zoltan Varga  <vargaz@gmail.com>
1500
1501         * mini-ia64.c (mono_arch_lowering_pass): Fix ia64 build.
1502
1503 Tue Jun 5 17:40:04 CEST 2007 Paolo Molaro <lupus@ximian.com>
1504
1505         * mini.c: optimize out the type check when storing null in a
1506         reference array.
1507
1508 2007-06-04  Mark Probst  <mark.probst@gmail.com>
1509
1510         * mini.c, driver.c: Changed MonoDomain.jit_code_hash to a
1511         MonoInternalHashTable.
1512
1513 Mon Jun 4 11:29:43 CEST 2007 Paolo Molaro <lupus@ximian.com>
1514
1515         * inssel.brg, mini.c, mini-ops.h: optimized Math.Mini/Max
1516         signed integer methods.
1517
1518 2007-06-02  Zoltan Varga  <vargaz@gmail.com>
1519
1520         * mini-x86.c (mono_arch_get_delegate_invoke_impl): Disable the static case 
1521         permanently since the current approach doesn't work.
1522
1523 2007-06-02  Zoltan Varga  <vargaz@gmail.com>
1524
1525         * inssel.brg (stmt): Only call delegate->invoke_impl if 
1526         MONO_ARCH_HAVE_CREATE_DELEGATE_TRAMPOLINE is defined.
1527
1528 2007-06-01  Zoltan Varga  <vargaz@gmail.com>
1529
1530         * mini-amd64.c (mono_arch_output_basic_block): Unify div/rem opcodes and handle
1531         the sreg2==rdx case.
1532         
1533         * mini-amd64.c cpu-amd64.md: Correct length of r4const instruction and take into
1534         account if it contains a rex prefix.
1535         (peephole_pass): Handle OP_FMOVE as well.
1536
1537 2007-06-01  Zoltan Varga  <vargaz@gmail.com>
1538
1539         * mini-x86.c (mono_arch_get_delegate_invoke_impl): Disable the static case for now
1540         as it causes regressions.
1541
1542 2007-05-31  Zoltan Varga  <vargaz@gmail.com>
1543
1544         * mini-x86.c (mono_arch_get_delegate_invoke_impl): Implement support for the
1545         static case as well.
1546
1547         * tramp-ia64.c (mono_arch_create_trampoline_code): Fix ia64 build.
1548
1549         * mini-x86.c (mono_arch_get_delegate_invoke_impl): New arch dependent function.
1550         (mono_arch_get_this_arg_from_call): Ditto.
1551
1552         * tramp-x86.c (mono_arch_patch_delegate_trampoline): Removed.
1553
1554         * inssel.brg (mini_emit_virtual_call): Call delegate->Invoke through the delegate's
1555         invoke_impl field.
1556
1557         * mini-amd64.c (mono_arch_get_delegate_invoke_impl): New arch dependent function.
1558         (mono_arch_get_this_arg_from_call): Ditto.
1559
1560         * tramp-amd64.c (mono_arch_patch_delegate_trampoline): Removed.
1561         
1562         * mini-trampolines.c (mono_delegate_trampoline): Complete rewrite. On first call,
1563         try to create optimized invoke code and use that for further invocations. 
1564         Otherwise, use the original mono_marshal_get_delegate_invoke () implementation.
1565
1566         * mini-x86.h mini-ia64.h: Remove MONO_ARCH_HAS_CREATE_DELEGATE_TRAMPOLINE for now.
1567
1568 2007-05-29  Rodrigo Kumpera  <kumpera@gmail.com>
1569
1570         * inssel.brg (mini_emit_virtual_call): Statically dispatch virtual calls to
1571         sealed classes or methods.
1572         *devirtualization.cs: tests for the new optimization
1573
1574 2007-05-29  Zoltan Varga  <vargaz@gmail.com>
1575
1576         * liveness.c (update_gen_kill_set): No need to set VOLATILE flags here, it is done
1577         by the update_volatile () function.
1578
1579 2007-05-27  Zoltan Varga  <vargaz@gmail.com>
1580
1581         * driver.c (mono_main): Call g_thread_init () early since newer glib versions
1582         require it.
1583
1584         * abcremoval.c (mono_perform_abc_removal): Avoid using alloca.
1585
1586 2007-05-24  Jonathan Chambers  <joncham@gmail.com>
1587
1588         * mini.c: Add configure checks for header files.
1589         * mini-x86.c: Add configure checks for header files.
1590         * trace.c: Add configure checks for header files.
1591         * aot-runtime.c: Add configure checks for header files.
1592         * aot-compiler.c: Add configure checks for header files.
1593         * driver.c: Add configure checks for header files.
1594         * mini-codegen.c: Add configure checks for header files.
1595         
1596         Code is contributed under MIT/X11 license.
1597
1598 2007-05-22  Zoltan Varga  <vargaz@gmail.com>
1599
1600         * mini-ia64.c (mono_arch_lowering_pass): Fix the handling of
1601         icompare_imm -128 + op_iclt. Fixes #81703.
1602
1603 2007-05-19  Zoltan Varga  <vargaz@gmail.com>
1604
1605         * mini-codegen.c (mono_local_regalloc): Fix long-shift-regalloc on amd64.
1606
1607 2007-05-15  Massimiliano Mantione  <massi@ximian.com>
1608
1609         * inssel.brg: added "mini_emit_load_intf_bit_reg_vtable", and used it
1610         inside "mini_emit_isninst_iface_cast" and "mini_emit_castclass_iface"
1611         so that all isinst checks now use "interface_bitmap".
1612
1613 2007-05-15  Zoltan Varga  <vargaz@gmail.com>
1614
1615         * cpu-amd64.md (jmp): Fix a warning.
1616
1617         * inssel.brg (CEE_SWITCH): Hopefully fix #80738.
1618
1619         * basic.cs: Add new regression test.
1620
1621         * basic.cs: Remove test which is now in basic-long.cs.
1622
1623         * mini-ia64.c (mono_arch_output_basic_block): Sign extend in CEE_CONV_I8/CEE_CONV_I.
1624
1625         * basic-long.cs: Add new test.
1626         
1627 2007-05-13  Zoltan Varga  <vargaz@gmail.com>
1628
1629         * mini-sparc.c (mono_spillvar_offset_float): Fix sparc build.
1630
1631 2007-05-12  Zoltan Varga  <vargaz@gmail.com>
1632
1633         * cpu-x86.md minix-86.c: Add a peephole_pass_1 () as on amd64.
1634
1635         * mini-x86.c (mono_arch_output_basic_block): Use mono_opcode_to_cond () in a few
1636         places.
1637         
1638         * mini-x86.c (mono_arch_emit_exceptions): Decrease the size of the exception 
1639         throwing code a bit.
1640
1641         * exceptions-x86.c (mono_arch_get_throw_corlib_exception): Decrease the size of 
1642         the exception throwing code a bit.
1643
1644         * mini-x86.c (get_call_info): Allocate result from a mempool.
1645
1646 2007-05-11  Zoltan Varga  <vargaz@gmail.com>
1647
1648         * aot-compiler.c (find_typespec_for_class): Fix the assert.
1649
1650         * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file version.
1651
1652         * mini.h (MonoCompile): Add 'token_info_hash' field.
1653
1654         * mini.c: Save token->method associations during compilation so the AOT 
1655         compiler can use it.
1656         
1657         * aot-compiler.c aot-runtime.c: Add support for compiling non-generic methods
1658         which reference generic classes and methods.
1659
1660 2007-05-10  Zoltan Varga  <vargaz@gmail.com>
1661
1662         * mini.h mini-<ARCH>.h: Get rid of MONO_ARCH_HAS_XP_LOCAL_REGALLOC.
1663
1664         * aot-compiler.c (compile_method): Fix a typo in a comment.
1665
1666         * aot-runtime.c (decode_cached_class_info): Skip generic types.
1667
1668         * aot-compiler.c: Add minimal support for AOTing generic code by skipping 
1669         everything generic.
1670
1671         * mini.c (mono_method_to_ir): Disable AOT when calling helper_compile_generic_method.
1672
1673 2007-05-09  Zoltan Varga  <vargaz@gmail.com>
1674
1675         * mini.h (MonoCompile): Add 'args' field.
1676
1677         * mini.c (mono_compile_create_vars): Store variables representing the arguments
1678         into cfg->args.
1679
1680         * mini-<ARCH>.c: Use cfg->args for accessing the method arguments.
1681
1682 2007-05-08  Zoltan Varga  <vargaz@gmail.com>
1683
1684         * mini.c (mono_compile_get_interface_var): Remove this unused function.
1685
1686         * mini-ops.h inssel.brg mini-<ARCH>.c: Add a new opcode for ckfinite as well.
1687
1688         * mini-ops.h: Introduce new opcodes used in the IR instead of the original CEE_
1689         opcodes for some opcodes.
1690
1691         * mini.h *.brg *.c: Use the new opcodes.
1692
1693 2007-05-08  Massimiliano Mantione  <massi@ximian.com>
1694
1695         * mini.h: Bumped aot revision.
1696
1697         * inssel.brg: modified code generation of type checks for interfaces
1698         to use the new "MonoClass.interface_bitmap" instead of the old
1699         "MonoClass.interface_offsets".
1700
1701 2007-04-30  Zoltan Varga  <vargaz@gmail.com>
1702
1703         * cpu-amd64.md (jmp): Increase the maximum size of the jmp opcode to 128.
1704
1705 2007-04-29  Zoltan Varga  <vargaz@gmail.com>
1706
1707         * abcremoval.c (summarize_integer_value): Handle OP_LCONV_TO_I4 to fix abcrem on
1708         64 bit platforms.
1709
1710 2007-04-27  Neale Ferguson <neale@sinenomine.net>
1711
1712         * mini-s390x.c: Fix MONO_TYPE_VALUETYPE processing.
1713
1714 2007-04-27  Wade Berrier  <wberrier@novell.com>
1715
1716         * mini-s390x.c: Remove redeclaration of CompRelation and CompType (defined in 
1717         mini.h) to fix build.
1718
1719 2007-04-26  Zoltan Varga  <vargaz@gmail.com>
1720
1721         * mini-amd64.c (peephole_pass_1): Fix and reenable this pass.
1722         
1723         * mini-amd64.c (mono_arch_local_regalloc): Disable the new peephole_pass_1 as it
1724         causes the corlib unit tests to fail.
1725
1726 2007-04-25  Zoltan Varga  <vargaz@gmail.com>
1727
1728         * mini-codegen.c (mono_opcode_to_type): Fix a bug in the previous patch.
1729
1730         * mini-amd64.c (peephole_pass_1): New pass to perform before local regalloc.
1731
1732         * mini-codegen.c (mono_opcode_to_cond): New helper function to convert conditional 
1733         opcodes to the comparison relations.
1734
1735         * mini-codegen.c (mono_opcode_to_type): New helper function to convert conditional 
1736         opcodes to their types.
1737         
1738         * mini-ia64.c mini-amd64.c: Use mono_opcode_to_cond and mono_opcode_to_type.
1739
1740         * mini-amd64.c (get_call_info): Allocate the result from the cfg mempool and cache 
1741         it in cfg->arch.cinfo.
1742
1743         * local-propagation.c (mono_local_cprop_bb): Fix a warning.
1744
1745         * mini.h mini.c branch-opts.c: Change bbhash to be an array and store it in 
1746         cfg->cil_offset_to_bb.
1747
1748 2007-04-24  Zoltan Varga  <vargaz@gmail.com>
1749
1750         * liveness.c (optimize_initlocals): New mini-pass to optimize away dead assignments
1751         created becase of initlocals.
1752
1753 2007-04-23  Zoltan Varga  <vargaz@gmail.com>
1754
1755         * mini-alpha.c cpu-alpha.md: More alpha port work from 
1756         Sergey Tikhonov <tsv@solvo.ru>.
1757
1758 2007-04-21  Andreas Faerber  <andreas.faerber@web.de>
1759
1760         * Makefile.am (BUILT_SOURCES): Fix for automake 1.6.x. Fixes #81417.
1761
1762 2007-04-19  Zoltan Varga  <vargaz@gmail.com>
1763
1764         * cpu-s390.md (break): Correct the length of break instruction.
1765
1766 Thu Apr 19 16:28:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
1767
1768         * mini.c: fix a couple of soft-float issues and comments.
1769
1770 2007-04-15  Miguel de Icaza  <miguel@novell.com>
1771
1772         * trace.c (is_filenamechar): - is also a filename char.
1773
1774 2007-04-15  Neale Ferguson <neale@sinenomine.net>
1775
1776         * mini-s390.c: Correct checking for enum type in return value processing.
1777
1778 2007-04-14  Raja R Harinath  <rharinath@novell.com>
1779
1780         * Makefile.am (BUILT_SOURCES): Add 'version.h'.
1781         (version.h): Makefile is in the build directory.
1782
1783 2007-04-06  Andreas Faerber  <andreas.faerber@web.de>
1784
1785         * mini-amd64.h: fix for assertion failure on Solaris/amd64
1786
1787 2007-04-11  Martin Baulig  <martin@ximian.com>
1788
1789         * mini.c (can_access_member): Fix handling of generic classes;
1790         fixes #81259.
1791
1792 2007-04-10  Zoltan Varga  <vargaz@gmail.com>
1793
1794         * aot-runtime.c (mono_aot_plt_resolve): Fix disabling of AOT. Fixes #81316.
1795
1796 2007-04-05  Zoltan Varga  <vargaz@gmail.com>
1797
1798         * aot-runtime.c: Fix disabling of AOT. Fixes #81316.
1799
1800 Fri Mar 23 20:25:31 CET 2007 Paolo Molaro <lupus@ximian.com>
1801
1802         * mini-codegen.c: make sure the right spill amount is
1803         used for fp or integer registers (fixes the float_sub_spill() on ppc).
1804
1805 Fri Mar 23 19:43:35 CET 2007 Paolo Molaro <lupus@ximian.com>
1806
1807         * mini-ppc.c: fixes for the fp_branch_nan test.
1808
1809 2007-03-23  Zoltan Varga  <vargaz@gmail.com>
1810
1811         * basic.cs: Comment out new test which still fails on ia64.
1812
1813 Fri Mar 23 15:54:23 CET 2007 Paolo Molaro <lupus@ximian.com>
1814
1815         * mini.c: immediate shifted or fix (mono_metadata_user_string assert).
1816
1817 Fri Mar 23 12:53:28 CET 2007 Paolo Molaro <lupus@ximian.com>
1818
1819         * mini-ppc.c, mini-ppc.h: struct passing ABI fix (bug #77968).
1820
1821 2007-03-22  Zoltan Varga  <vargaz@gmail.com>
1822
1823         * cfold.c (FOLD_BINOP): Cast the result to gint32 to prevent overflow problems
1824         on 64 bit machines. Fixes part of #80738.
1825
1826         * basic.cs: Add regression test.
1827
1828 2007-03-17  Zoltan Varga  <vargaz@gmail.com>
1829
1830         * inssel.brg basic.cs: Revert previous change to fix build.
1831
1832         * inssel.brg (SWITCH): Clean out the upper word of the switch value on 64 bit
1833         platforms.
1834         
1835         * inssel.brg (SWITCH): Use an integer comparison. Fixes #80738.
1836
1837         * basic.cs: Add new regression test.
1838
1839 2007-03-17  Zoltan Varga  <vargaz@gmail.com>
1840
1841         * mini-ia64.c (mono_arch_emit_prolog): Fix an assert when a function has too
1842         many arguments.
1843
1844 2007-03-16  Neale Ferguson <neale@sinenomine.net>
1845
1846         * cpu-s390x.md: Correct length of break instruction.
1847
1848 2007-03-16  Neale Ferguson <neale@sinenomine.net>
1849
1850         * mini-s390x.c, cpu-s390x.md: Fix #80507 for s390x.
1851         * mini-s390.c, cpu-s390.md: Fix #80507 for s390.
1852
1853 2007-03-15  Jonathan Chambers  <joncham@gmail.com>
1854
1855         * *.c: Begin WIN64 port.
1856         * mini.c:  Use correct register in profiler.
1857         * mini-amd64.c: No inline assembly on Win64.
1858         * mini-amd64.h: Implement MONO_INIT_CONTEXT_FROM_FUNC for Win64.
1859         Only define MONO_ARCH_USE_SIGACTION on non-windows platforms.
1860         * exceptions-amd64.c: Only need gregs_from_ucontext if MONO_ARCH_USE_SIGACTION
1861         is defined. Implement mono_arch_sigctx_to_monoctx, mono_arch_monoctx_to_sigctx, and
1862         mono_arch_ip_from_context for Win64.
1863         
1864         Contributed under MIT/X11 license.
1865
1866 2007-03-15  Zoltan Varga  <vargaz@gmail.com>
1867
1868         * exceptions-amd64.c (seh_handler): Ditto.
1869
1870         * exceptions-x86.c (seh_handler): Fix a memory leak.
1871
1872 Thu Mar 15 13:47:59 CET 2007 Paolo Molaro <lupus@ximian.com>
1873
1874         * mini-arm.c, mini-mips.c, mini-ppc.c, mini-s390.c,
1875         mini-s390x.c: fixed peephole optimizations to deal
1876         correctly with 1 and 2 byte reload avoidance.
1877
1878 Thu Mar 15 10:17:54 CET 2007 Paolo Molaro <lupus@ximian.com>
1879
1880         * cpu-s390.md, cpu-s390x.md: update localloc length.
1881
1882 Wed Mar 14 21:00:19 CET 2007 Paolo Molaro <lupus@ximian.com>
1883
1884         * cpu-g4.md: added missing descriptions.
1885
1886 2007-03-14  Miguel de Icaza  <miguel@novell.com>
1887
1888         *  Makefile.am: Add support so the tail tests are not executed on
1889         PowerPC as that is a known limitation of the PowerPC port.
1890
1891 2007-03-13  Jonathan Chambers  <joncham@gmail.com>
1892
1893         * runmdesc.bat:  Move to msvc directory.
1894         
1895 2007-03-13  Jonathan Chambers  <joncham@gmail.com>
1896
1897         * runmdesc.bat:  Run executable that was produced by the current
1898         target and sent via an argument.
1899         
1900 2007-03-11  Zoltan Varga  <vargaz@gmail.com>
1901
1902         * mini.c (mono_method_to_ir): Fix box+brtrue optimization. Fixes
1903         #81102.
1904
1905         * generics.2.cs: Add regression test.
1906
1907 2007-03-09  Wade berrier  <wberrier@novell.com>
1908
1909         * mini-ppc.h: Undo typo of MONO_CONTEXT_SET_SP (ppc doesn't define this symbol)
1910
1911 2007-03-09  Zoltan Varga  <vargaz@gmail.com>
1912
1913         * aot-runtime.c (load_aot_module): Load all dependent assemblies eagerly since all
1914         AOT code depends on this.
1915
1916 Thu Mar 8 19:36:13 CET 2007 Paolo Molaro <lupus@ximian.com>
1917
1918         * mini.c: more precise tracking of types in the eval stack
1919         (part of fix for bug #81044).
1920
1921 2007-03-07  Zoltan Varga  <vargaz@gmail.com>
1922
1923         * aot-runtime.c (mono_aot_get_class_from_name): Add a cache.
1924
1925         * aot-compiler.c (encode_patch): Remove an obsolete comment.
1926
1927 2007-03-06  Zoltan Varga  <vargaz@gmail.com>
1928
1929         * mini-exceptions.c (mono_handle_native_sigsegv): Fix a warning.
1930
1931         * mini.c (mono_method_to_ir): Add a workaround for bug #80733.
1932
1933 2007-02-22  Zoltan Varga  <vargaz@gmail.com>
1934
1935         * mini.c (type_from_op): Convert CEE_CONV_U to OP_LCONV_TO_U when the argument is
1936         a pointer on 64 bit systems. Fixes #80190.
1937
1938         * iltests.il: Add new regression test.
1939
1940 Tue Feb 20 11:33:28 CET 2007 Paolo Molaro <lupus@ximian.com>
1941
1942         * mini.c: inline a constant for Environment.IsRunningOnWindows.
1943
1944 2007-02-19  Geoff Norton  <gnorton@customerdna.com>
1945
1946         * trace.c: Remove an erroneous alignemnt check when tracing.
1947           Fixes --trace on OSX86.
1948
1949 Wed Feb 14 19:45:56 CET 2007 Paolo Molaro <lupus@ximian.com>
1950
1951         * mini-$(arch).h: initialize SP in context for all the archs.
1952
1953 2007-02-14  Sebastien Pouliot  <sebastien@ximian.com>
1954
1955         * mini-x86.h: Initialize SP in MONO_INIT_CONTEXT_FROM_FUNC. Fix CAS
1956         regressions in the thread tests.
1957
1958 2007-02-14  Zoltan Varga  <vargaz@gmail.com>
1959
1960         * *-alpha.*: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>:
1961         - fixed implementation of LOCALLOC opcode
1962         - implemented non-un compare for floats
1963         - code cleanup
1964         - implementation of FDIV and CKFINITE opcodes
1965         - fixes for latest mono updates
1966         - additional arch opcodes
1967
1968 Mon Feb 12 11:54:16 CET 2007 Paolo Molaro <lupus@ximian.com>
1969
1970         * Makefile.am: simplify and merge rules for cross-compilation.
1971
1972 2007-02-07  Massimiliano Mantione  <massi@ximian.com>
1973
1974         * local-propagation.c: Actually *apply* the fix for bug 80591...
1975
1976 Tue Feb 6 19:03:19 CET 2007 Paolo Molaro <lupus@ximian.com>
1977
1978         * mini-exceptions.c: backuot part of the last change
1979         (fixes cas tests on amd64 related to GetExecutingAssembly ()).
1980
1981 2007-02-06  Massimiliano Mantione  <massi@ximian.com>
1982         * inssel.brg: Fix bug 59286.
1983
1984
1985 Tue Feb 6 12:23:50 CET 2007 Paolo Molaro <lupus@ximian.com>
1986
1987         * mini-exceptions.c: patch from Zoltan to correctly check for
1988         stack boundaries (using the stack register, not the frame register),
1989         fixes bugs #80724, #79717.
1990
1991 2007-02-03  Zoltan Varga  <vargaz@gmail.com>
1992
1993         * mini-ia64.c inssel-sparc.brg mini-sparc.c cpu-sparc.md: Get rid of OP_SETREG/
1994         OP_SETREGIMM, use OP_MOVE/OP_ICONST instead.
1995
1996         * mini-amd64.c (mono_arch_output_basic_block): Fix ATOMIC_EXCHANGE in the
1997         presence of frame pointer elimination.
1998
1999 2007-02-01  Geoff Norton  <gnorton@customerdna.com>
2000         
2001         * mini-x86.h: NetBSD UCONTEX_REG defines.
2002
2003 2007-02-01  Zoltan Varga  <vargaz@gmail.com>
2004
2005         * inssel-amd64.brg: Fix amd64 build.
2006
2007 Thu Feb 1 14:02:09 CET 2007 Paolo Molaro <lupus@ximian.com>
2008
2009         * mini.h: remove extern to workaround what looks likes gcc bug 26905
2010         on amd64.
2011
2012 2007-01-31  Zoltan Varga  <vargaz@gmail.com>
2013
2014         * mini-codegen.c (mono_is_regsize_var): New helper function usable by the back
2015         ends.
2016
2017         * mini-<ARCH>.c: Use mono_is_regsize_var ().
2018
2019 2007-01-30 Mark Mason <mason@broadcom.com>
2020
2021            * exceptions-mips.c: Lots of exception handling fixes, LMFs now work, some cleanups.
2022            * mini-mips.h: Add LMF magic numbers, and fix context set/get macros.
2023            * mini-mips.c: Cleanups, LMF handling now works, optimize store of zero, implement localloc
2024            beginning support for CEE_JMP [not quite working yet]
2025            * tramp-mips.c: LMF handling now works
2026         
2027 2007-01-30  Zoltan Varga  <vargaz@gmail.com>
2028
2029         * mini-amd64.c (peephole_pass): Optimize code common in initlocals blocks.
2030
2031         * mini.h (NULLIFY_INS): New macro.
2032
2033 Tue Jan 30 16:33:33 CET 2007 Paolo Molaro <lupus@ximian.com>
2034
2035         * mini.c: statistical profiler fix for windows, patch
2036         from Tor Lillqvist (tml@novell.com).
2037
2038 2007-01-30  Massimiliano Mantione  <massi@ximian.com>
2039         * local-propagation.c: Fix bug 80591.
2040
2041 Mon Jan 29 12:14:34 CET 2007 Paolo Molaro <lupus@ximian.com>
2042
2043         * Makefile.am: put back the --export-dynamic option as with
2044         the previous gmodule flags (thanks to Robert Jordan).
2045
2046 2007-01-28  Zoltan Varga  <vargaz@gmail.com>
2047
2048         * mini-sparc.c (peephole_pass): Fix #80622 for sparc as well.
2049
2050         mini.h *.c: Allocate fp vregs from the same pool as the int vregs. Use this to
2051         simplify and speed up the local register allocator. Also rename some fields
2052         like iassign->vassign.
2053         
2054         * regalloc.c: Remove some functions which are no longer used since their
2055         inlined version is in mini-codegen.c.
2056         
2057         * mini-codegen.c: Rename mono_regstate2_ functions to mono_regstate_.
2058
2059         * basic.cs objects.cs iltests.il: Merge tests from the linear IL branch.
2060
2061 2007-01-27  Zoltan Varga  <vargaz@gmail.com>
2062
2063         * mini-amd64.c (peephole_pass): Remove optimizations which omit a 
2064         narrowing. Fixes #80622.
2065
2066         * iltests.il: Add new regresssion test. 
2067
2068 Fri Jan 26 18:31:45 CET 2007 Paolo Molaro <lupus@ximian.com>
2069
2070         * mini.h, mini-trampolines.c, aliasing.c, mini-codegen.c,
2071         debug-debugger.c, debug-debugger.h: warning fixes.
2072         * driver.c: updated copyright year and made it fit in one line.
2073
2074 Fri Jan 26 12:48:39 CET 2007 Paolo Molaro <lupus@ximian.com>
2075
2076         * aot-runtime.c: updated to use mono-dl instead of gmodule.
2077
2078 2007-01-25  Zoltan Varga  <vargaz@gmail.com>
2079
2080         * mini-x86.c (mono_arch_output_basic_block): Fix #80507 for x86.
2081
2082         * mini-amd64.c (mono_arch_output_basic_block): Fix #80507 for amd64.
2083
2084         * iltests.il: Add new test for bug #80507.
2085
2086 Wed Jan 24 19:10:28 CET 2007 Paolo Molaro <lupus@ximian.com>
2087
2088         * mini-arm.h: use soft-float also on vfp for now.
2089
2090 Wed Jan 24 14:54:40 CET 2007 Paolo Molaro <lupus@ximian.com>
2091
2092         * mini.c: fix some more soft-float issues.
2093
2094 2007-01-24  Zoltan Varga  <vargaz@gmail.com>
2095
2096         * mini-sparc.h (MONO_ARCH_FRAME_ALIGNMENT): Fix sparc build.
2097
2098 2007-01-24  Massimiliano Mantione  <massi@ximian.com>
2099         * mini-arch.h, , inssel-amd64.brg, mini-x86.c, inssel-x86.brg,
2100         mini-ia64.c, mini-sparc.c, mini-alpha.c: Introduced
2101         MONO_ARCH_LOCALLOC_ALIGNMEENT to fix bug 80498.
2102
2103 Wed Jan 24 12:04:39 GMT 2007 Paolo Molaro <lupus@ximian.com>
2104
2105         * mini-arm.c: typo fix.
2106
2107 2007-01-23  Neale Ferguson <neale@sinenomine.net>
2108
2109         * mini-s390x.c: Use lgb instructions for I1 type variables instead of lb.
2110
2111 2007-01-21  Zoltan Varga  <vargaz@gmail.com>
2112
2113         * mini.c (mono_allocate_stack_slots_full): Allocate memory from the cfg mempool.
2114         Share stack slots for scalar types. Avoid expensive g_list_free () calls.
2115
2116         * mini-x86.c (mono_arch_allocate_vars): Don't free the result of allocate_stack_slots_full.
2117
2118         * mini-amd64.c mini-ia64.c mini-alpha.c: Ditto. 
2119
2120         * mini.h (MonoJitStats): Add a new JIT statistics: locals_stack_size.
2121         
2122         * inssel.brg: Fix a warning.
2123
2124         * mini.h (MonoBasicBlock): Make bb->dominated a GSList.
2125
2126         * abcremoval.c ssa.c ssapre.c: Update after this change.
2127         
2128         * dominators.c (compute_dominators): Allocate bb->dominated from the cfg mempool.
2129
2130         * dominators.c (df_set): Use mono_bitset_union_fast.    
2131
2132 Sat Jan 20 16:59:01 CET 2007 Paolo Molaro <lupus@ximian.com>
2133
2134         * mini.h, genmdesc.c, genmdesc.pl, mini-${arch}.c, cprop.c,
2135         mini-codegen.c: reduce relocations and memory usage for the cpu
2136         description.
2137
2138 2007-01-20  Zoltan Varga  <vargaz@gmail.com>
2139
2140         * mini-codegen.c (mono_regstate2_alloc_int): Optimize this using bsfq on amd64.
2141
2142         * genmdesc.c genmdesc.pl mini.h: Remove some unused fields from the mdesc tables
2143         to reduce their size.
2144
2145 2007-01-19 Mark Mason <mason@broadcom.com>
2146
2147         * exceptions-mips.c: fix mono_arch_ip_from_context(), increase exception debug support.
2148         * mini-mips.c: more configuration macros, support long conditional branches, additional
2149         asserts, fix epilog instrumentation.
2150         * mini-mips.h: use standard stack walk
2151         * cpu-mips.md: increase size of div, rem and conditional branches
2152         
2153 Fri Jan 19 17:23:32 CET 2007 Paolo Molaro <lupus@ximian.com>
2154
2155         * mini.h, mini-codegen.c, mini-$(arch).h: claenup references
2156         to cpu spec data.
2157
2158 2007-01-19  Zoltan Varga  <vargaz@gmail.com>
2159
2160         * aot-compiler.c (encode_klass_info): Allow classes of the form <Type>[][].
2161         (compile_method): Ditto.
2162
2163         * aot-runtime.c (decode_klass_info): Ditto.
2164
2165         * mini.c (mono_method_to_ir): Call mono_get_got_var () in a place where it is
2166         needed by the code generated by inssel.brg. Also fix a warning.
2167
2168 Thu Jan 18 17:55:22 CET 2007 Paolo Molaro <lupus@ximian.com>
2169
2170         * mini.c: deal with enums that become genericinsts by
2171         being nested in a generic class (bug #79956).
2172
2173 Thu Jan 18 16:52:56 CET 2007 Paolo Molaro <lupus@ximian.com>
2174
2175         * mini.c: match the generic definition to check for
2176         private access with generic types (bug #78431).
2177
2178 Thu Jan 18 11:50:13 CET 2007 Paolo Molaro <lupus@ximian.com>
2179
2180         * genmdesc.pl, Makefile.am: perl implementation of genmdesc,
2181         to make life easier for people cross-compiling that insist on not
2182         using scratchbox.
2183
2184 2007-01-17 Mark Mason <mason@broadcom.com>
2185
2186         * inssel-long.brg: patch to deal with mips missing flags
2187         * inssel-long32-mips.brg: implement overflow checks
2188         * insset-mips.brg: implement overflow checks
2189         * mini-mips.h: implement conditional exception handling
2190         * mini-mips.c: add mips_emit_exc_by_name(), implement conditional exception handling.
2191           Remove unused code, minor cleanups.
2192         * exceptions-mips.c: minor cleanups
2193         * mini-ops.h: add mips conditional exception ops
2194         * cpu-mips.md: add mips conditional exception ops
2195
2196         
2197 Wed Jan 17 19:22:34 CET 2007 Paolo Molaro <lupus@ximian.com>
2198
2199         * inssel.brg: patch from Mark Mason <mason@broadcom.com>
2200         to deal with mips missing of flags.
2201
2202 Tue Jan 16 20:01:01 CET 2007 Paolo Molaro <lupus@ximian.com>
2203
2204         * exceptions-ppc.c: execute fault handlers.
2205
2206 Tue Jan 16 19:54:44 CET 2007 Paolo Molaro <lupus@ximian.com>
2207
2208         * mini-ppc.c: handle missing call locationss with FORCE_INDIR_CALL.
2209
2210 Tue Jan 16 13:14:31 CET 2007 Paolo Molaro <lupus@ximian.com>
2211
2212         * mini.c: handle also floating point values in initialize_array.
2213
2214 Tue Jan 16 12:42:40 CET 2007 Paolo Molaro <lupus@ximian.com>
2215
2216         * mini.c, aot-runtime.c, aot-compiler.c: enable aot compilation of
2217         array initialization and make it conditional on the intrins option.
2218
2219 Tue Jan 16 11:28:45 CET 2007 Paolo Molaro <lupus@ximian.com>
2220
2221         * mini.h, patch-info.h, Makefile.am, aot-compiler.c: reduce
2222         relocations and put the patch info names close to the enum definition.
2223
2224 2007-01-15 Mark Mason <mason@broadcom.com>
2225
2226         * basic.cs, exceptions.cs: break up large tests to increase debugability.
2227
2228 Mon Jan 15 18:57:14 CET 2007 Paolo Molaro <lupus@ximian.com>
2229
2230         * mini.c: optimized RuntimeHelpers::InitializeArray () calls.
2231
2232 2007-01-12  Raja R Harinath  <rharinath@novell.com>
2233
2234         * mini.c (mono_method_to_ir): Use new MonoGenericContext accessor.
2235
2236 Thu Jan 11 11:16:42 CET 2007 Paolo Molaro <lupus@ximian.com>
2237
2238         * Makefile.am: distribute the mips sources.
2239
2240 Wed Jan 10 19:49:33 CET 2007 Paolo Molaro <lupus@ximian.com>
2241
2242         * mini-codegen.h: handle bug #80489 here, by excluding ecx
2243         directly.
2244
2245 Wed Jan 10 19:08:05 CET 2007 Paolo Molaro <lupus@ximian.com>
2246
2247         * cpu-x86.md: back out for now as this triggers other regressions.
2248
2249 Wed Jan 10 18:33:16 CET 2007 Paolo Molaro <lupus@ximian.com>
2250
2251         * cpu-x86.md: force src1 and dest regpair for long shift instructions
2252         to eax:edx, so ecx can't get allocated to them (bug #80489).
2253
2254 Tue Jan 9 12:36:11 CET 2007 Paolo Molaro <lupus@ximian.com>
2255
2256         * mini.c, mini-exceptions.c: enabled running fault handlers
2257         (bug #80469).
2258
2259 2007-01-03  Miguel de Icaza  <miguel@novell.com>
2260
2261         * driver.c: If nothing fail, do not use the string "failed",
2262         because it makes it very annoying to view test result logs on the
2263         web. 
2264
2265 2006-12-30  Miguel de Icaza  <miguel@novell.com>
2266
2267         * debug-debugger.c (mono_debugger_main): Rename "main" to
2268         "main_method" to prevent a warning.
2269
2270         Remove a warning for unused field.
2271
2272 2006-12-28  Martin Baulig  <martin@ximian.com>
2273
2274         * debug-debugger.c
2275         (MONO_DEBUGGER__debugger_info): Add `get_lmf_addr'.
2276
2277 2006-12-22  Martin Baulig  <martin@ximian.com>
2278
2279         * mdb-debug-info32.s, mdb-debug-info64.s: New files.
2280         Put a pointer to the `MONO_DEBUGGER__debugger_info' into a
2281         seperate `.mdb_debug_info' section, so we can access it from the
2282         debugger even if the binary is stripped.
2283
2284         * debug-debug.c: Reference the `MONO_DEBUGGER__debugger_info_ptr'
2285         from the `.mdb_debug_info' here to prevent the linker from
2286         removing that section.
2287
2288         * Makefile.am (mono_debugger_sources): Add mdb-debug-info32.s /
2289         mdb-debug-info64.s.
2290
2291 2006-12-19  Robert Jordan  <robertj@gmx.net>
2292
2293         * mini-x86: enable the code to return small structures in
2294         registers for FreeBSD as well. Fixes bug #80278.
2295         * aot-runtime.c: Include sys/wait.h for WEXITSTATUS/WIFEXITED.
2296
2297 Mon Dec 18 19:47:17 CET 2006 Paolo Molaro <lupus@ximian.com>
2298
2299         * mini-x86.c: align the stack when calling the profiler
2300         function instrumenting the prolog (on OSX).
2301
2302 Thu Dec 14 15:22:43 CET 2006 Paolo Molaro <lupus@ximian.com>
2303
2304         * mini.c: emit a break opcode where Debugger.Break () is called.
2305
2306 2006-12-13  Miguel de Icaza  <miguel@novell.com>
2307
2308         * mini.c (mono_method_to_ir): Provide useful information on this
2309         assert, to prevent others from debugging like I did.
2310
2311 Tue Dec 12 17:01:38 CET 2006 Paolo Molaro <lupus@ximian.com>
2312
2313         * mini.c: enable code which was incorrectly commented
2314         (bug #80235).
2315
2316 Tue Dec 12 16:28:15 CET 2006 Paolo Molaro <lupus@ximian.com>
2317
2318         * mini-x86.c: enable on OSX, too, the code to return small
2319         structures in registers.
2320
2321 Mon Dec 11 19:22:35 CET 2006 Paolo Molaro <lupus@ximian.com>
2322
2323         * mini-x86.c: remove the use of the dynamic code manager here, too.
2324
2325 Mon Dec 11 19:08:33 CET 2006 Paolo Molaro <lupus@ximian.com>
2326
2327         * mini.h, debug-debugger.c, tramp-*.c: fixed 
2328         mono_debugger_create_notification_function() to use
2329         mono_global_codeman_reserve () instead of a dynamic code manager.
2330
2331 Tue Dec 5 17:54:50 CET 2006 Paolo Molaro <lupus@ximian.com>
2332
2333         * mini.c, jit-icalls.h, jit-icalls.c: remove the 
2334         ves_array_element_address() jit icall and use a generated
2335         managed method instead (which is about 4 times faster for a rank 3
2336         array access).
2337
2338 2006-11-29  Mark Mason  <mason@broadcom.com>
2339
2340         * basic-calls.cs: additional tests for passing
2341         structures as function arguments.
2342
2343 2006-11-29  Mark Mason  <mason@broadcom.com>
2344
2345         * mini-mips.h: disable custom exception handling
2346         * mini-mips.c: throw/rethrow should use jalr to call
2347         exception stubs.  Fixed bug with passing structures
2348         by value. More support for tracing floating point
2349         functions.
2350
2351 Wed Nov 29 20:28:17 CET 2006 Paolo Molaro <lupus@ximian.com>
2352
2353         * mini.c: fixed typo in the soft-float ldind.r4 handling
2354         (bug #80086).
2355
2356 Wed Nov 29 11:33:03 CET 2006 Paolo Molaro <lupus@ximian.com>
2357
2358         * mini.c, mini.h, driver.c: added --runtime command line
2359         option to select a different runtime than the autodetected one.
2360         * jit.h: added API for embedders to initialize with a specific
2361         runtime version.
2362
2363 Tue Nov 28 21:24:55 CET 2006 Paolo Molaro <lupus@ximian.com>
2364
2365         * mini.c: handle also boxing of r4 values (bug #80024).
2366
2367 Tue Nov 28 19:45:44 CET 2006 Paolo Molaro <lupus@ximian.com>
2368
2369         * mini-ppc.c: force indirect calls until we reserve
2370         enough address space for all the generated code.
2371
2372 Tue Nov 28 20:04:34 GMT 2006 Paolo Molaro <lupus@ximian.com>
2373
2374         * exceptions-arm.c: workaround bugs in the libc definition
2375         of struct ucontext.
2376
2377 Mon Nov 27 15:13:41 CET 2006 Paolo Molaro <lupus@ximian.com>
2378
2379         * inssel.brg: fixes from me and Mark Mason.
2380
2381 2006-11-23  Dick Porter  <dick@ximian.com>
2382
2383         * wapihandles.c (mini_wapi_seminfo): No need to adjust the counter
2384         semaphore display now we've fixed the initial value
2385
2386 Wed Nov 22 11:04:37 CET 2006 Paolo Molaro <lupus@ximian.com>
2387
2388         * inssel.brg: partially revert the last change to fix the build.
2389
2390 2006-11-21  Mark Mason  <mason@broadcom.com>
2391
2392         * inssel.brg: Add and use compare-and-branch macros to support
2393         architectures that do not have condition code registers (ie. MIPS).
2394         * *-mips.{c,brg,md}: Fix copyright statements
2395
2396 2006-11-20  Mark Mason  <mason@broadcom.com>
2397
2398         * Makefile.am: remove mini-codegen.c from list of MIPS sources
2399         * mini.c: Allow GET_CONTEXT to be specified by the arch port
2400         * mini.h: Added declaration for mono_print_ins()
2401         * mini-codegen.c: added ins_spec initializer for MIPS
2402         * mini-codegen.c (mono_call_inst_add_outarg_reg): added asserts for
2403         vreg to be virtual and hreg to be non-virtual.
2404         * mini-codegen.c (mono_spillvar_offset): assert if MIPS - spilling
2405         is not yet working/implemented correctly.
2406         * mini-codegen.c (print_ins): rename to mono_print_ins(), make
2407         non-static, fixup calls to print_ins() from other parts in the file.
2408
2409 2006-11-20  Mark Mason  <mason@broadcom.com>
2410
2411         * basic-calls.cs: added tests for passing structures as arguments
2412         to calls.
2413
2414 Mon Nov 20 19:40:11 CET 2006 Paolo Molaro <lupus@ximian.com>
2415
2416         * inssel-long32.brg: optimize signed division by power of two.
2417
2418 Mon Nov 20 17:37:58 CET 2006 Paolo Molaro <lupus@ximian.com>
2419
2420         * mini-arm.c: added support for interworking with thumb code
2421         (mono must be still be built using the ARM instruction encoding).
2422
2423 2006-11-19  Miguel de Icaza  <miguel@novell.com>
2424
2425         * mini.c (type_from_op): Separate the conditions for OP_EQ as the
2426         verifier has different rules for it.   Fixes a few verifier issues
2427         in the test suite.
2428
2429         * mini-exceptions.c (mono_handle_native_sigsegv): Put the message
2430         at the end, so people know what happened.
2431
2432 Thu Nov 16 14:07:18 CET 2006 Paolo Molaro <lupus@ximian.com>
2433
2434         * brach-opts.c: in optimize_exception_target() make sure we
2435         are in a catch clause (fixes bug #79871).
2436
2437 Thu Nov 16 12:42:13 CET 2006 Paolo Molaro <lupus@ximian.com>
2438
2439         * jit-icalls.c, jit-icalls.h, mini-arm.c, mini.c:
2440         more soft-float support fixes.
2441
2442 Wed Nov 15 18:45:47 GMT 2006 Paolo Molaro <lupus@ximian.com>
2443
2444         * mini-arm.c, inssel-arm.brg: ABI fix for longs and doubles
2445         that are passed half on the stack and half in registers.
2446
2447 Wed Nov 15 17:00:27 CET 2006 Paolo Molaro <lupus@ximian.com>
2448
2449         * mini-ops.h, mini-arch.h, helpers.c, Makefile.am:
2450         more mips integration work from Mark E Mason 
2451         <mark.e.mason@broadcom.com>.
2452
2453 Wed Nov 15 16:34:03 CET 2006 Paolo Molaro <lupus@ximian.com>
2454
2455         * exceptions-mips.c, inssel-mips.brg, mini-mips.h,
2456         cpu-mips.md, inssel-long32-mips.brg, mini-mips.c,
2457         tramp-mips.c: added sources for the mips port, not
2458         integrated in the build yet. Contributed by
2459         Mark E Mason <mark.e.mason@broadcom.com>.
2460
2461 2006-11-14  Neale Ferguson <neale@sinenomine.net>
2462
2463         * mini-s390[x].c (is_regsize_var): Support PTR/FNPTR too.
2464
2465 Tue Nov 14 16:06:37 CET 2006 Paolo Molaro <lupus@ximian.com>
2466
2467         * Makefile.am, inssel-float.brg, inssel-softfloat.brg:
2468         put the soft-float rules in its own file since it seems to
2469         break s390 compilation.
2470
2471 Mon Nov 13 15:54:38 CET 2006 Paolo Molaro <lupus@ximian.com>
2472
2473         * mini-arm.c: fixed wrnings.
2474
2475 Fri Nov 10 19:18:32 CET 2006 Paolo Molaro <lupus@ximian.com>
2476
2477         * mini-arm.c, mini-arm.h, cpu-arm.md, inssel-float.brg,
2478         inssel-arm.brg: ARM support for soft-float.
2479
2480 Fri Nov 10 18:38:15 CET 2006 Paolo Molaro <lupus@ximian.com>
2481
2482         * mini.c, jit-icalls.c, jit-icalls.h: added first cut at handling
2483         loads and stores of 32 bit fp values.
2484
2485 2006-11-10  Zoltan Varga  <vargaz@gmail.com>
2486
2487         * mini-sparc.c (is_regsize_var): Support PTR/FNPTR too.
2488
2489         * tramp-sparc.c (mono_arch_patch_callsite): Fix this function so it actually
2490         works. Fixes #79852 and #79463.
2491
2492 Thu Nov 9 16:56:13 CET 2006 Paolo Molaro <lupus@ximian.com>
2493
2494         * mini.c, mini-codegen.c, jit-icalls.c, jit-icalls.h:
2495         more soft-float support WIP and fixes.
2496
2497 Wed Nov 8 16:40:02 CET 2006 Paolo Molaro <lupus@ximian.com>
2498
2499         * mini-arm.c: some VFP updates.
2500
2501 Tue Nov 7 19:45:51 CET 2006 Paolo Molaro <lupus@ximian.com>
2502
2503         * mini-exceptions.c: 0 is a valid local var offset in some
2504         architectures, don't assert (bug #78508).
2505
2506 Tue Nov 7 18:17:52 GMT 2006 Paolo Molaro <lupus@ximian.com>
2507
2508         * exceptions-arm.c: fixed off by one error in stack walk code.
2509
2510 Tue Nov 7 11:27:26 CET 2006 Paolo Molaro <lupus@ximian.com>
2511
2512         * mini.h, mini.c: more precise tracking of type load exceptions.
2513
2514 2006-11-03  Robert Jordan  <robertj@gmx.net>
2515
2516         * Makefile.am: [WIN32] Add monow.exe target.
2517         * driver.c: [WIN32] Don't detach the console when debugging.
2518         Fixes bug #79797.
2519         
2520 2006-10-30  Miguel de Icaza  <miguel@novell.com>
2521
2522         * tramp-x86.c (mono_arch_patch_delegate_trampoline): Eliminate warning.
2523
2524 2006-10-23  Zoltan Varga  <vargaz@gmail.com>
2525
2526         * aot-compiler.c (emit_method_info): Add a case missed earlier.
2527
2528         * driver.c (mini_regression): Fix --regression with AOT.
2529
2530         * aot-compiler.c (emit_method_info): Fix AOT on amd64.
2531
2532 2006-10-17  Zoltan Varga  <vargaz@gmail.com>
2533
2534         * mini.c (GET_CONTEXT): Correct the definition of this for sparc/linux.
2535
2536         * mini-sparc.h: Don't use sigaction on sparc/linux.
2537
2538         * exceptions-sparc.c: Call mono_arch_flush_icache () in a couple of places.
2539
2540         * mini-sparc.c (mono_sparc_flushw): Call mono_arch_flush_icache ().
2541
2542         * mini-exceptions.c: Add proper include files for getpid ().
2543
2544 2006-10-16  Zoltan Varga  <vargaz@gmail.com>
2545
2546         * aot-runtime.c (mono_aot_get_method): Change this to return the native code
2547         address instead of a MonoJitInfo* to avoid decoding the exception info for the
2548         method.
2549
2550         * aot-runtime.c aot-compiler.c: Use uint16 instead of uint32 entries in the
2551         name cache to reduce its size.
2552
2553         * mini.h (MONO_AOT_FILE_VERSION): Bump aot file format version.
2554
2555 2006-10-15  Zoltan Varga  <vargaz@gmail.com>
2556
2557         * mini-x86.c: Save/restore the current LMF structure more efficiently using
2558         the mono_lmf TLS variable.
2559
2560         * exceptions-x86.c (mono_arch_find_jit_info): Only access lmf->method in 
2561         trampoline lmf frames.  
2562
2563         * mini-sparc.h (MONO_ARCH_ENABLE_EMIT_STATE_OPT): Define this on sparc as well.
2564
2565 2006-10-14  Zoltan Varga  <vargaz@gmail.com>
2566
2567         * mini-amd64.c: Save/restore the current LMF structure more efficiently using
2568         the mono_lmf TLS variable.
2569
2570         * mini-exceptions.c: Access the LMF structure through accessors.
2571
2572         * mini.c: Allow the backends the option for storing the lmf in a dedicated TLS 
2573         variable instead of in jit_tls->lmf.
2574
2575         * mini-x86.c mini-amd64.c: Update after lmf->lmf_addr name change.
2576         
2577         * exceptions-amd64.c (mono_arch_find_jit_info): Only access lmf->method in 
2578         trampoline lmf frames.
2579
2580         * mini-amd64.c (mono_arch_emit_prolog): Do not set lmf->method as it is not needed.
2581
2582 2006-10-12  Zoltan Varga  <vargaz@gmail.com>
2583
2584        * mini.c trace.c mini-x86.c: Revert these too.
2585         
2586        * mini.c trace.c mini-x86.c: Remove warning workarounds after the mono_type_size ()
2587        signature change.
2588
2589 Tue Oct 10 11:35:20 CEST 2006 Paolo Molaro <lupus@ximian.com>
2590
2591         * genmdesc.c: removed now dead code.
2592
2593 2006-10-09  Robert Jordan <robertj@gmx.net>
2594
2595         * mini.c: Disable the CrashReporter on MacOS X; Fixes #74869
2596
2597 Mon Oct 9 17:06:41 CEST 2006 Paolo Molaro <lupus@ximian.com>
2598
2599         * mini.h: do not leave gaps in the opcode values.
2600
2601 Mon Oct 9 16:08:51 CEST 2006 Paolo Molaro <lupus@ximian.com>
2602
2603         * jit-icalls.h: flag functions as internal here, too.
2604
2605 Mon Oct 9 15:58:18 CEST 2006 Paolo Molaro <lupus@ximian.com>
2606
2607         * mini.h, aliasing.h, declsec.h, regalloc.h, trace.h: mark internal
2608         functions with the internal attribute.
2609
2610 Mon Oct 9 15:52:45 CEST 2006 Paolo Molaro <lupus@ximian.com>
2611
2612         * aot-compiler.c: fclose the file descriptor in the profile read loop.
2613
2614 Fri Oct 6 16:01:38 CEST 2006 Paolo Molaro <lupus@ximian.com>
2615
2616         * mini.c, jit-icalls.c, inssel-float.brg: beginnings of support
2617         for soft-float.
2618
2619 2006-10-05  Zoltan Varga  <vargaz@gmail.com>
2620
2621         * mini-x86.c (emit_load_volatile_arguments): New function to handle arguments of
2622         tail calls as on other platforms.
2623
2624         * mini.c (mono_method_to_ir): Fix a few tailcall problems. Fixes #79557.
2625
2626         * iltests.il: Add a few tailcall tests.
2627
2628 Tue Oct 3 16:33:08 CEST 2006 Paolo Molaro <lupus@ximian.com>
2629
2630         * driver.c: fix loop for old compilers (bug #79521).
2631
2632 2006-10-02  Zoltan Varga  <vargaz@gmail.com>
2633
2634         * mini-exceptions.c (ves_icall_get_trace): Remove debug printf.
2635
2636         * aot-runtime.c (mono_aot_get_class_from_name): Avoid a memory allocation.
2637
2638         * aot-compiler.c: Add a new option 'metadata-only' to only emit the cached
2639         metadata without any code.
2640
2641         * mini-exceptions.c (mono_handle_native_sigsegv): Add some code to print out
2642         more precise debugging information using gdb.
2643
2644 2006-09-30  Zoltan Varga  <vargaz@gmail.com>
2645
2646         * inssel-ia64.brg: Make the helper methods static.
2647
2648 Thu Sep 28 16:40:07 CEST 2006 Paolo Molaro <lupus@ximian.com>
2649
2650         * inssel-x86.brg: make the helper methods static.
2651
2652 Thu Sep 28 16:31:32 CEST 2006 Paolo Molaro <lupus@ximian.com>
2653
2654         * inssel-amd64.brg, mini-amd64.c: small cleanup, use inst_call.
2655
2656 Thu Sep 28 15:36:07 CEST 2006 Paolo Molaro <lupus@ximian.com>
2657
2658         * mini.c: updates for monoburg changes.
2659         * inssel.brg: make a few helper functions static as they should.
2660
2661 2006-09-27  Zoltan Varga  <vargaz@gmail.com>
2662
2663         * Makefile.am: Move mini-codegen.c to common_sources.
2664
2665 Wed Sep 27 15:07:08 CEST 2006 Paolo Molaro <lupus@ximian.com>
2666
2667         * mini.h: instroduce inst_call in MonoInst for use in OUTARG
2668         instructions.
2669         * Makefile.am, cpu-g4.md, inssel-ppc.brg, mini-codegen.c, mini-ppc.c,
2670         mini-ppc.h: port to use the common local register allocator.
2671
2672 2006-09-26  Zoltan Varga  <vargaz@gmail.com>
2673
2674         * mini.h: Remove the comment too then.
2675
2676 Tue Sep 26 14:02:58 CEST 2006 Paolo Molaro <lupus@ximian.com>
2677
2678         * mini.h: put back backend.data which is to be used shortly and
2679         doesn't increase the size of MonoInst. If any 64 bit arch aligned
2680         pointers on 4 byte boundaries it'd have much bigger issues running
2681         and you can ifdef it out anyway.
2682
2683 2006-09-26  Zoltan Varga  <vargaz@gmail.com>
2684
2685         * mini.h (MonoInst): Remove backend.data field since it is unused and increases
2686         MonoInst size by 4 bytes on 64 bit machines.
2687
2688 Tue Sep 26 11:57:26 CEST 2006 Paolo Molaro <lupus@ximian.com>
2689
2690         * *.{c,h,brg}: long due removal of the unused field in MonoInst and
2691         replacement with more meaningful field names. Arch maintainers, please
2692         check the assigned names are good enough for your arch.
2693
2694 2006-09-26  Zoltan Varga  <vargaz@gmail.com>
2695
2696         * cpu-ia64.md mini-ia64.c inssel-ia64.brg mini-ops.h: Get rid of the 
2697         OP_IA64_FETCHADD opcodes, use OP_ATOMIC_ADD_IMM_NEW opcodes instead.
2698
2699 Mon Sep 25 11:05:24 CEST 2006 Paolo Molaro <lupus@ximian.com>
2700
2701         * mini.h, driver.c, optflags-def.h, Makefile.am: reduce runtime
2702         relocations and memory requirements, put the optimization flags
2703         definitions in their own file.
2704
2705 2006-09-24  Zoltan Varga  <vargaz@gmail.com>
2706
2707         * jit-icalls.c (mono_helper_stelem_ref): Remove this unused helper function.
2708
2709         * mini.c (mini_init): Remove reference to mono_helper_stelem_ref.
2710
2711 2006-09-22  Zoltan Varga  <vargaz@gmail.com>
2712
2713         * mini-amd64.c (add_valuetype): Fix an uninitialized memory issue.
2714
2715 Thu Sep 21 19:06:09 CEST 2006 Paolo Molaro <lupus@ximian.com>
2716
2717         * inssel.brg: use the correct function to get the size of an item
2718         in an array, given an element class.
2719         * aot-compiler.c: do not access class->class_size directly.
2720
2721 Thu Sep 21 12:10:56 CEST 2006 Paolo Molaro <lupus@ximian.com>
2722
2723         * mini.h, debug-mini.c: added a debugging function to print
2724         info about local variables and arguments in a jitted method.
2725
2726 2006-09-20  Zoltan Varga  <vargaz@gmail.com>
2727
2728         * mini-alpha.c: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>.
2729
2730         * exceptions-ia64.c: Fix some problems reported by Bill Seurer <seurer@us.ibm.com>.
2731
2732 2006-09-19  Zoltan Varga  <vargaz@gmail.com>
2733
2734         * mini-ia64.c (mono_arch_call_opcode): Avoid using the same loop index in the
2735         inner and outer loops when passing vtypes.
2736
2737 Tue Sep 19 17:53:40 CEST 2006 Paolo Molaro <lupus@ximian.com>
2738
2739         * mini-ppc.c: take into account the cpu errata for cache flushing
2740         which caused some random errors (bug #79381).
2741
2742 2006-09-19  Zoltan Varga  <vargaz@gmail.com>
2743
2744         * mini-amd64.c (mono_arch_emit_exceptions): Emit the call to 
2745         mono_arch_throw_corlib_exception using emit_call () too. Fixes #79271.
2746
2747 2006-09-17  Zoltan Varga  <vargaz@gmail.com>
2748
2749         * aot-runtime.c (load_aot_module): Return immeditely if the AOT module was already
2750         loaded.
2751
2752         * exceptions-amd64.c (gregs_from_ucontext): Apply another patch from the
2753         freebsd ports tree.
2754
2755         * mini-amd64.c (emit_call): Avoid near calls on freebsd.
2756         (mono_arch_patch_code): Remove the unused handling of MONO_PATCH_INFO_CLASS_INIT.
2757
2758         * tramp-amd64.c (mono_arch_create_specific_trampoline): Fix check for 32 bitness of
2759         displacement.
2760
2761 2006-09-13  Zoltan Varga  <vargaz@gmail.com>
2762
2763         * aot-runtime.c (load_aot_module_from_cache): Fix PPC build.
2764
2765 2006-09-12  Zoltan Varga  <vargaz@gmail.com>
2766
2767         * mini.c (UNVERIFIED): Add a 'break-on-unverified' MONO_DEBUG option so this 
2768         macro does not have to be changed during debugging.
2769
2770         * cpu-alpha.md inssel-alpha.brg mini-alpha.h mini-alpha.c exceptions-alpha.c tramp-alpha.c: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>.
2771
2772         * cpu-pentium.md: Rename this to cpu-x86.md for consistency with other platforms.
2773
2774         * Makefile.am mini-x86.c mini-codegen.c: Rename pentium_desc to x86_desc.
2775         
2776         * mini.c (mini_get_ldelema_ins): Allow ldelema2d optimization if 
2777         MONO_ARCH_NO_EMULATE_MUL is defined.
2778
2779         * mini-ia64.h (MONO_ARCH_CALLEE_FREGS): Reserve f33 for use by instructions.
2780
2781         * mini-ia64.h: Define MONO_ARCH_NO_EMULATE_MUL.
2782
2783         * mini-ia64.c: Implement CEE_MUL based on gcc emitted code.
2784
2785         * mini-ia64.c (mono_arch_lowering_pass): Optimize store_membase_imm with offset==0.
2786         
2787 2006-09-11  Zoltan Varga  <vargaz@gmail.com>
2788
2789         * mini-x86.h mini-amd64.h mini-exceptions.c: Move the bsd specific MAP_ANON
2790         stuff to mini-exceptions.c where it is used.
2791
2792         * mini-sparc.c (mono_arch_setup_jit_tls_data): Remove the duplicate altstack
2793         setup code, the real one is in mini-exceptions.c.
2794
2795         * mini-amd64.h mini-amd64.c exceptions-amd64.c: Move all dependencies on the
2796         layout of ucontext_t to helper functions in exceptions-amd64.c, as on x86. Add
2797         some changes from the freebsd ports tree.
2798
2799         * mini-amd64.h exceptions-amd64.c: Fix the amd64 build. Get rid of the SC_
2800         constants.
2801         
2802         * mini-amd64.h: Freebsd has MAP_ANON instead of MAP_ANONYMOUS.
2803
2804 Mon Sep 11 13:18:55 CEST 2006 Paolo Molaro <lupus@ximian.com>
2805
2806         * mini.c: on Linux, check for /proc to be mounted
2807         (bug# 79351, novell bug#201204).
2808
2809 Mon Sep 11 13:10:12 CEST 2006 Paolo Molaro <lupus@ximian.com>
2810
2811         * mini.c: handle cases where pthread_attr_getstack() behaves
2812         incorrectly (bug #78096).
2813
2814 Mon Sep 11 11:31:10 BST 2006 Paolo Molaro <lupus@ximian.com>
2815
2816         * mini-arm.c: support larger stack frames (bug #79272).
2817
2818 2006-09-08  Zoltan Varga  <vargaz@gmail.com>
2819
2820         * aot-runtime.c (mono_aot_get_class_from_name): Remove a debug printf.
2821
2822         * aot-compiler.c: Add a hash table to the AOT file mapping class names to typedef 
2823         tokens.
2824
2825         * aot-runtime.c (mono_aot_get_class_from_name): New function used by 
2826         mono_class_from_name () to find a class from its name.
2827
2828         * mini.c (mini_init): Register mono_aot_get_class_from_name () with the runtime.
2829
2830 2006-09-07  Zoltan Varga  <vargaz@gmail.com>
2831
2832         * mini-amd64.c (emit_call): Avoid strstr () call if possible.
2833
2834 2006-09-05  Kornél Pál  <kornelpal@gmail.com>
2835
2836         * Makefile.am: Renamed mono-1.dll to mono.dll. (-avoid-version)
2837
2838 2006-09-04  Zoltan Varga  <vargaz@gmail.com>
2839
2840         * mini.c (mono_icall_get_wrapper): Fix a race condition on initializing
2841         callinfo->trampoline.
2842
2843         * mini-amd64.c (emit_call): Special case calls to the vararg array icalls. Hopefully
2844         fixes #79271.
2845         (mono_arch_patch_code): Add some debug code to help track down similar failures in the
2846         future.
2847
2848 2006-09-03  Zoltan Varga  <vargaz@gmail.com>
2849
2850         * aot-runtime.c (mono_aot_plt_resolve): Add an assert.
2851
2852 2006-09-02  Zoltan Varga  <vargaz@gmail.com>
2853
2854         * tramp-x86.c (mono_arch_create_specific_trampoline): Don't increase
2855         stats.method_trampolines, it is already done by the generic trampoline code.
2856
2857         * tramp-amd64.c (mono_arch_create_specific_trampoline): Ditto.
2858         
2859 2006-09-01  Zoltan Varga  <vargaz@gmail.com>
2860
2861         * mini.c: Remove some references to mono_compile_aot, and use cfg->compile_aot instead.
2862
2863         * aot-runtime.c: Add some tweaks to the MONO_AOT_CACHE functionality.
2864
2865         * tramp-amd64.c (mono_arch_create_specific_trampoline): Fix a FIXME.
2866
2867         * mini.c (print_jit_stats): Print mscorlib mempool size too.
2868         
2869         * mini.c (print_jit_stats): Print new stats.
2870
2871         * *-alpha.c: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>.
2872
2873 2006-08-31  Zoltan Varga  <vargaz@gmail.com>
2874
2875         * mini.c (mini_get_ldelema_ins): Fix verifier error when calling
2876         Address on two dimensional arrays. Fixes #78729.
2877
2878         * mini.h (MonoCompile): Add a 'skip_visibility' field.
2879
2880         * mini.c (method_to_ir): Disable visibility checks if skip_visibility is set on
2881         a method.
2882
2883         * mini-amd64.c (mono_arch_emit_exceptions): Fix assertion introduced by the last change.
2884
2885         * mini.c (mono_runtime_cleanup_handlers): Clean up signal handlers on unix. Fixes
2886         #79130.
2887         
2888         * mini.c (handle_array_new): Applied patch from "briaeros007". Fix
2889         a race condition.
2890         (mini_get_ldelema_ins): Ditto.
2891
2892 2006-08-30  Zoltan Varga  <vargaz@gmail.com>
2893
2894         * mini-amd64.c (mono_arch_emit_exceptions): Align fp constants to 16 bytes.
2895         (mono_arch_output_basic_block): Avoid unaligned accesses in FNEG implementation. 
2896         Fixes #79213.
2897
2898 2006-08-29 Neale Ferguson <neale@sinenomine.net>
2899
2900         * mini-s390.c, mini-s390x.c: Fix VARARG case processing with 0 arguments. Add
2901         mono_arch_get_patch_offset as a dummy entry point to allow successful link. 
2902
2903         * exceptions-s390x.c: Cosmetic change.
2904
2905         * tramp-s390.c: Fix warning.
2906
2907         * cpu-s390.md: Correct length of mul_imm.
2908
2909 Wed Aug 23 19:24:00 CEST 2006 Paolo Molaro <lupus@ximian.com>
2910
2911         * aot-compiler.c: added binary writer with ELF backend
2912         implementation (only on Linux/x86 for now).
2913
2914 2006-08-18  Zoltan Varga  <vargaz@gmail.com>
2915
2916         * Makefile.am: Don't run net 2.0 AOT tests.
2917
2918         * aot-compiler.c (compile_method): Skip methods with tail calls as well.
2919         (mono_compile_assembly): Skip net 2.0 assemblies as well.
2920
2921         * aot-runtime.c (load_patch_info): Fix an uninitialized memory error.
2922
2923 Fri Aug 18 19:38:28 CEST 2006 Paolo Molaro <lupus@ximian.com>
2924
2925         * aot-compiler.c: simplified and refactored the asm-writing code
2926         to allow different backends.
2927
2928 2006-08-18  Zoltan Varga  <vargaz@gmail.com>
2929
2930         * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file format version.
2931
2932         * aot-compiler.c aot-runtime.c: Reorg the GOT slot allocation code a 
2933         little. Share patches of type TYPE_FROM_HANDLE as well.
2934
2935         * mini.c (mono_patch_info_equal): New helper function.
2936         (mono_patch_info_hash): Ditto.
2937
2938         * aot-compiler.c (emit_method_code): Fix s390 build.
2939
2940         * mini.c (mono_allocate_stack_slots_full): Fix yet another place where byref
2941         is not handled because it is stored as a flag and not as a type ctor. Fixes
2942         #79016.
2943
2944 2006-08-17  Zoltan Varga  <vargaz@gmail.com>
2945
2946         * aot-compiler.c: Fix computation of GOT slot statistics.
2947         
2948         * aot-compiler.c aot-runtime.c: Implement sharing of GOT slots for classes/fields.
2949         Also remove support for not PIC AOT.
2950
2951         * mini.h: Bump AOT file format version.
2952
2953         * objects.cs: Add a test for #78990.
2954
2955         * mini-x86.c (mono_arch_output_basic_block): Applied patch from Peter Dettman
2956         (peter.dettman@iinet.net.au). Fixes #79087.
2957
2958         * basic-long.cs: Add a test for the above.
2959
2960 2006-08-16  Zoltan Varga  <vargaz@gmail.com>
2961
2962         * aot-compiler.c (get_got_offset): Add a cache for GOT entries, not yet used.
2963         
2964         * aot-compiler.c (get_plt_index): Add a cache for wrappers too. Simplify the
2965         code somewhat.
2966
2967 2006-08-15  Zoltan Varga  <vargaz@gmail.com>
2968
2969         * mini.c (mini_init): Fix registration of idiv/imul opcodes which can throw
2970         exceptions.
2971
2972 2006-08-10  Jonathan Chambers  <joncham@gmail.com>
2973
2974         * mini.c: Don't verify COM proxy invoke calls
2975         
2976
2977 2006-08-10  Dick Porter  <dick@ximian.com>
2978
2979         * wapihandles.c (mini_wapi_seminfo): More info, to help track down
2980         which process is holding semaphores locked.
2981
2982 2006-08-08  Zoltan Varga  <vargaz@gmail.com>
2983
2984         * mini-ia64.c mini-amd64.c: Fix #79027.
2985
2986         * mini-sparc.c (mono_arch_call_opcode): Fix the previous patch.
2987
2988         * mini-sparc.c (mono_arch_call_opcode): Fix #79027.
2989
2990         * mini-x86.c (mono_arch_call_opcode): Handle the case where there are no
2991         implicit arguments in a vararg call. Fixes #79027.
2992
2993 2006-08-07  Zoltan Varga  <vargaz@freemail.hu>
2994
2995         * mini.c (mono_get_element_address_signature): Use CDECL calling convention on windows. Fixes #78969.
2996         (mono_get_array_new_va_signature): Ditto.
2997
2998 2006-08-05  Zoltan Varga  <vargaz@gmail.com>
2999
3000         * aot-runtime.c: Call init_plt lazily.
3001
3002         * inssel-long.brg: Fix unsigned long->int conversion.
3003
3004         * aot-runtime.c (init_plt): Remove a redundant make_writable () call.
3005
3006         * aot-compiler.c aot-runtime.c: Reorganize the file structure in the amd64 case so
3007         that most data is now in the .rss/.data section.
3008
3009 2006-08-04  Zoltan Varga  <vargaz@gmail.com>
3010
3011         * aot-compiler.c: Correct the computation of the 'direct-calls' statistic.      
3012
3013         * aot-compiler.c: Print the number of methods without GOT slots as a statistics.
3014
3015         * aot-compiler.c aot-runtime.c tramp-amd64.c: Resurrect amd64 AOT support.
3016
3017         * tramp-amd64.c (mono_arch_patch_callsite): Fix a warning.
3018
3019         * jit-icalls.c (mono_helper_compile_generic_method): Unbox vtypes since this is a
3020         virtual call. Fixes #79010.
3021
3022         * mini.c (mono_method_to_ir): Pass an additional out arg to compile_generic_method 
3023         and use the result as the this argument in the real call.
3024
3025         * generics.2.cs: Add a new test for #79010.
3026         
3027 2006-08-03  Zoltan Varga  <vargaz@gmail.com>
3028
3029         * mini-x86.c: Fix a warning.
3030
3031         * aot-compiler.c: Add a bunch of statistics.
3032
3033         * mini.c (inline_method): Disable inlining in out-of-line bblocks.
3034
3035 2006-08-02  Zoltan Varga  <vargaz@gmail.com>
3036
3037         * mini-arch.h Makefile.am mini-ops.h mini-codegen.c: More alpha updates.
3038
3039 2006-08-01  Zoltan Varga  <vargaz@gmail.com>
3040
3041         * cpu-alpha.md inssel-alpha.brg mini-alpha.h mini-alpha.c exceptions-alpha.c tramp-alpha.c: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>.
3042
3043 2006-07-13  Miguel de Icaza  <miguel@novell.com>
3044
3045         * mini.c (mono_method_to_ir): Obtain the original method in the
3046         CIL stream and use this to perform validation.
3047
3048         Fixed: #78816
3049
3050 2006-07-19  Zoltan Varga  <vargaz@gmail.com>
3051
3052         * mini-x86.c (mono_arch_get_argument_info): Fix a warning.
3053         (mono_arch_call_opcode): Ditto.
3054
3055         * mini.c (mono_method_to_ir): Clear ins_flag at the end of CEE_CALL. Fixes
3056         #78826.
3057
3058         * mini.c (mono_patch_info_dup_mp): New helper function.
3059         
3060         * aot-compiler.c (compile_method): Fix some of the memory allocated during
3061         compilation. Fixes #78827.
3062
3063 2006-07-18  Kornél Pál  <kornelpal@gmail.com>
3064
3065         * declsec.c: Use original security informations for
3066           MONO_WRAPPER_MANAGED_TO_MANAGED.
3067
3068 2006-07-15  Jonathan Chambers  <joncham@gmail.com>
3069
3070         * mini.c: Allow Com Interop methods/classes and
3071         don't verify COM wrapper calls
3072         
3073
3074 2006-07-13  Zoltan Varga  <vargaz@gmail.com>
3075
3076         * inssel-long32.brg: Fix long->i4 checked conversion.
3077
3078         * exceptions.cs: Add a test for the above.
3079
3080 2006-07-08  Zoltan Varga  <vargaz@gmail.com>
3081
3082         * mini-exceptions.c (mono_setup_altstack): Fix a memory leak.
3083
3084         * mini.c: Applied patch from Joachim Ante (joe@otee.dk). Fix some shutdown 
3085         leaks.
3086
3087         * helpers.c (mono_disassemble_code): Avoid using fixed temporary files. Fixes
3088         #78775.
3089
3090 2006-07-03  Zoltan Varga  <vargaz@gmail.com>
3091
3092         * mini.c: Fix solaris/x86 exception handling.
3093
3094         * Makefile.am: Get rid of $(ICU_LIBS).
3095
3096 2006-07-02  Zoltan Varga  <vargaz@gmail.com>
3097
3098         * mini-exceptions.c: Fix handling of unhandled SIGSEGV exceptions on ia64.
3099         (ves_icall_System_Security_SecurityFrame_GetSecurityStack): Use MONO_INIT_CONTEXT_FROM_CURRENT.
3100         (ves_icall_System_Security_SecurityFrame_GetSecurityFrame): Ditto.
3101
3102         * mini-ia64.h (MONO_CONTEXT_SET_FUNC): New macro.
3103
3104         * mini-exceptions.c (mono_handle_native_sigsegv): Prevent infinite loops if
3105         this function causes a SIGSEGV.
3106
3107 2006-06-22  Zoltan Varga  <vargaz@gmail.com>
3108
3109         * mini.c: Remove unused solaris/x86 includes.
3110
3111 2006-06-21  Zoltan Varga  <vargaz@gmail.com>
3112
3113         * jit.h: Add G_BEGIN_DECLS/G_END_DECLS.
3114
3115 2006-06-20  Jb Evain  <jbevain@gmail.com>
3116
3117         * cpu-g4.md: fix max length of start_handler instruction.
3118
3119 2006-06-20  Massimiliano Mantione  <massi@ximian.com>
3120         * simple-cee-ops.h, simple-mini-ops.h: Fixed bug 78656.
3121
3122 2006-06-16  Massimiliano Mantione  <massi@ximian.com>
3123         * ssa.c: Fixed bug 78653 for SSA based deadce.
3124         * mini.h: added MONO_INST_DEFINITION_HAS_SIDE_EFFECTS flag go
3125         MonoInst.flags, used in SSA based deadce.
3126         * aliasing.c: Fixed bug 78653 for "fastpath" deadce.
3127         * simple-cee-ops.h, simple-mini-ops.h: Fixed bug 78653.
3128
3129 Thu Jun 15 16:52:46 CEST 2006 Paolo Molaro <lupus@ximian.com>
3130
3131         * tramp-ppc.c: don't use malloc () for trampoline code, sometimes
3132         it can end up using non executable memory on ppc64 systems
3133         running ppc32 userspace (fix from Johannes Berg).
3134
3135 2006-06-14  Dick Porter  <dick@ximian.com>
3136
3137         * wapihandles.c: Fix a bunch of signed/unsigned warnings from gcc
3138         4.1.1
3139
3140 2006-06-13  Massimiliano Mantione  <massi@ximian.com>
3141         * mini.c: Made so that inline is locally disabled if it would
3142         trigger a .cctor, because too many apps depend on this behavior
3143         (which seems to be also the one of the MS CLR).
3144
3145 2006-06-13  Zoltan Varga  <vargaz@gmail.com>
3146
3147         * mini-amd64.c (mono_emit_stack_alloc): Fix initialization of localloc'ed memory.
3148         No idea why this worked before.
3149
3150         * branch-opts.c (mono_branch_optimize_exception_target): Avoid branches
3151         which branch to outer exception clauses since they could skip the
3152         inner finally clauses. Fixes #78633.
3153
3154         * exceptions.cs: Add a test for the above.
3155
3156         * mini.c (merge_basic_blocks): Nullify the branch at the end of the first bb.
3157         Fixes #78629.
3158
3159         * iltests.il: Add a test for the above.
3160
3161 2006-06-12  Zoltan Varga  <vargaz@gmail.com>
3162
3163         * mini.c (remove_block_if_useless): Do not remove the bblock immediately
3164         after the end of a try bblock, to prevent asserts in mini_method_compile ().
3165
3166         * iltests.il: Add a test for the above.
3167
3168 2006-06-10  Zoltan Varga  <vargaz@gmail.com>
3169
3170         * mini-ia64.c (mono_arch_lowering_pass): Remove some code duplication.
3171         
3172         * mini-ia64.c inssel-ia64.brg: Implement the new net 2.0 Interlocked.Add
3173         methods as instrinsics.
3174
3175 2006-06-09  Wade Berrier <wberrier@novell.com>
3176
3177         * Makefile.am: Fix sources list for svn rename so that make dist succeeds
3178         (simple-cee-ops.h ssapre-mini-ops.h)
3179
3180 2006-06-09  Neale Ferguson <neale@sinenomine.net>
3181
3182         * mini-exceptions.c (ves_icall_get_frame_info): Fix this function on s390/s390x.
3183         * mini-s390x.c, mini-s390.c: Correct ATOMIC operations (incorrect register for CS
3184         instruction).
3185         * mini-s390x.h, mini-s390.h: Simplify MCONTEXT_GET_BP.
3186         * cpu-s390x.md: Fix max. length values for a couple of instructions.
3187
3188 2006-06-09  Jonathan Chambers  <jonathan.chambers@ansys.com>
3189
3190         * mini-exceptions.c: Minor fix for building mono in Visual Studio.
3191
3192 2006-06-08  Massimiliano Mantione  <massi@ximian.com>
3193
3194         * ssapre-cee-ops.h: Renamed as "simple-cee-ops.h"
3195         * simple-cee-ops.h: Was "ssapre-cee-ops.h" (renamed).
3196         * ssapre-mini-ops.h: Renamed as "simple-mini-ops.h"
3197         * simple-mini-ops.h: Was "ssapre-mini-ops.h" (renamed).
3198         * local-propagation.c: In mono_cprop_invalidate_values use a whitelist
3199         of opcodes, so that bug 78549 should not happen again.
3200         * ssapre.c: Updated to use the renamed files.
3201
3202 2006-06-08  Zoltan Varga  <vargaz@gmail.com>
3203
3204         * mini-amd64.c (mono_arch_output_basic_block): Fix a wrong reg-reg move 
3205         in OP_ATOMIC_EXCHANGE_I4.
3206
3207 2006-06-07  Wade Berrier <wberrier@novell.com>
3208
3209         * tramp-s390.c: Fix s390 build (add missing pointer declarations 
3210         in mono_debugger_create_notification_function)
3211
3212 2006-06-06  Zoltan Varga  <vargaz@gmail.com>
3213
3214         * mini.c (NEW_AOTCONST_TOKEN): Fix amd64 build.
3215         
3216         * mini.c (type_from_stack_type): Disable some changes which do not
3217         seem to work.
3218
3219         * driver.c: Reenable opts.
3220
3221         * mini.h (MonoStackSlot): New structure to keep track of the verification state
3222         of the evaluation stack.
3223         
3224         * mini.h (MonoBasicBlock): Add a 'stack_state' field to keep track of the
3225         evaluation stack trace at entry to the bblock.
3226
3227         * mini.c (merge_stacks): New function to perform verification of stack merges.
3228         Turned off by default.
3229
3230         * mini.c: Fill up ins->klass for instructions whose type is STACK_OBJ or
3231         STACK_MP.
3232         
3233 2006-06-06  Massimiliano Mantione  <massi@ximian.com>
3234
3235         * local-propagation.c: Fixed bug 78549.
3236
3237 2006-06-04  Zoltan Varga  <vargaz@gmail.com>
3238
3239         * mini-exceptions.c (ves_icall_get_frame_info): Fix this function on ia64.
3240
3241 2006-06-02  Miguel de Icaza  <miguel@novell.com>
3242
3243         * tramp-sparc.c, tramp-ppc.c, tramp-s390.c, tramp-s390x.c,
3244         tramp-arm.c, tramp-ia64.c
3245         (mono_debugger_create_notification_function): Update signature to
3246         new signature and use new protocol for creating the notification
3247         function.  
3248
3249         Should fix the build.
3250
3251 2006-06-02  Geoff Norton  <gnorton@customerdna.com>
3252
3253         * exceptions-ppc.c (mono_jit_walk_stack)
3254         (ves_icall_get_frame_info): Fix the build
3255
3256 2006-06-02  Zoltan Varga  <vargaz@gmail.com>
3257
3258         * mini.c (mono_set_defaults): Fix the handling of -O=-all.
3259
3260 2006-05-31  Raja R Harinath  <rharinath@novell.com>
3261
3262         * il2tests.2.il: New file for generics CIL tests.  Add test for
3263         #78019.
3264         * Makefile.am: Update.
3265
3266         Fix #78019
3267         * mini.c (mono_method_to_ir): Don't apply box+brtrue optimization
3268         to nullable types.
3269
3270 2006-05-30  Massimiliano Mantione  <massi@ximian.com>
3271
3272         * aliasing.c: Fixed bug 78311.
3273
3274 2006-05-29  Martin Baulig  <martin@ximian.com>
3275
3276         * mini-exceptions.c (mono_find_jit_info): When computing the
3277         native offset, check whether we're actually inside the method's
3278         code; call mono_debug_print_stack_frame() to format the frame.
3279         (ves_icall_System_Exception_get_trace): Call
3280         mono_debug_print_stack_frame() to format the stack frame.
3281         (ves_icall_get_trace): Update to the new debugging API.
3282         (mono_jit_walk_stack_from_ctx): Likewise.
3283         (ves_icall_get_frame_info): Likewise.
3284
3285         * mini.c (get_method_from_ip): Use the new debugging API.
3286         (mono_print_method_from_ip): Likewise.
3287
3288         * exceptions-ppc.c
3289         (mono_jit_walk_stack): Use the new debugging API.
3290         (ves_icall_get_frame_info): Likewise.   
3291
3292 2006-05-27  Zoltan Varga  <vargaz@gmail.com>
3293
3294         * mini-amd64.c (mono_arch_output_basic_block): Fix MONO_PROFILE_COVERAGE.
3295
3296 2006-05-25  Massimiliano Mantione  <massi@ximian.com>
3297
3298         * mini.c: Added "limitator" to inline for debugging.
3299
3300 2006-05-24  Martin Baulig  <martin@ximian.com>
3301
3302         * debug-debugger.c (mono_debugger_init): Create a private,
3303         malloc()-based code manager for the notification function and
3304         intentionally leak it on exit.  This fixes the crash-on-exit race
3305         condition.
3306
3307         * tramp-amd64.c
3308         (mono_debugger_create_notification_function): Added
3309         `MonoCodeManager *' argument.
3310
3311         * tramp-x86.c
3312         (mono_debugger_create_notification_function): Added
3313         `MonoCodeManager *' argument.
3314
3315 2006-05-23  Massimiliano Mantione  <massi@ximian.com>
3316
3317         * aliasing.c: Fixed 64 bit issue.
3318         * driver.c: Enabled inline,consprop,copyprop,treeprop,deadce by
3319         default since all known bugs are fixed (one more time!).
3320
3321 Tue May 23 13:47:28 CEST 2006 Paolo Molaro <lupus@ximian.com>
3322
3323         * mini.c: write barrier support.
3324
3325 2006-05-23  Martin Baulig  <martin@ximian.com>
3326
3327         * debug-debugger.c: Revert Paolo's change.  Add comment and #error
3328         check at the top of the file.
3329
3330 Sun May 21 12:22:29 CEST 2006 Paolo Molaro <lupus@ximian.com>
3331
3332         * debug-debugger.c: fix the build. Again. Hopefully Martin will stop
3333         reverting changes without reason and without changelog entries.
3334
3335 2006-05-18  Zoltan Varga  <vargaz@gmail.com>
3336
3337         * mini-sparc.c (mono_arch_output_basic_block): Add support for large stack offets
3338         to a few opcodes. Fixes #78439.
3339
3340         * mini-sparc.c: Rename mono_sparch_break () to mono_arch_break () to improve
3341         consistency with other archs.
3342
3343         * mini-ia64.c (mono_arch_emit_prolog): Remove debug stuff left in by mistake.
3344
3345 Wed May 17 18:07:33 CEST 2006 Paolo Molaro <lupus@ximian.com>
3346
3347         * debug-debugger.c: fix the build.
3348
3349 2006-05-17  Martin Baulig  <martin@ximian.com>
3350
3351         * debug-debugger.c
3352         (debugger_thread_vtable): Moved here from ../metadata/threads.c.
3353         (debugger_init_threads): Formerly known as mono_debugger_init_threads().
3354         (debugger_finalize_threads): Formaly known as mono_debugger_finalize_threads().
3355         (debugger_attach): Call GC_mono_debugger_add_all_threads().
3356
3357 2006-05-11  Zoltan Varga  <vargaz@gmail.com>
3358
3359         * mini.c (mini_init): Call pthread_attr_destroy () to fix a small memory leak.
3360
3361 2006-05-10  Zoltan Varga  <vargaz@gmail.com>
3362
3363         * mini-x86.c (mono_arch_instrument_epilog): Fix handling of 
3364         MONO_TYPE_GENERICINST.
3365         
3366         * mini-amd64.c (mono_arch_instrument_epilog): Fix handling of 
3367         MONO_TYPE_GENERICINST.
3368
3369 2006-05-09  Zoltan Varga  <vargaz@gmail.com>
3370
3371         * mini-x86.c (mono_arch_get_vcall_slot_addr): Add a missing call sequence. Fixes
3372         #78325.
3373
3374 2006-05-08  Zoltan Varga  <vargaz@gmail.com>
3375
3376         * mini.c (mono_create_jump_trampoline): Allocate MonoJitInfo from the domain
3377         mempool.
3378         (mono_jit_free_method): Remove the method from jump_trampoline_hash as well.
3379
3380 2006-05-06  Zoltan Varga  <vargaz@gmail.com>
3381
3382         * mini.c (mini_cleanup): Applied patch from Joachim Ante (joe@otee.dk). Call
3383         mono_trace_cleanup ().
3384
3385         * iltests.il: Fix problem with the newly added test.
3386
3387         * mini-codegen.c (mono_local_regalloc): When changing the dreg of an instruction
3388         due to register constraints, free up the previous hreg. Fixes #78314.
3389
3390         * iltests.il: Add new test for #78314.  
3391
3392         * mini-x86.c (mono_arch_get_inst_for_method): Use OP_ATOMIC_ADD_NEW_I4 for
3393         Interlocked.Add. Fixes #78312.
3394
3395         * mini-amd64.c (mono_arch_get_inst_for_method): Ditto.
3396         
3397 2006-05-05  Zoltan Varga  <vargaz@gmail.com>
3398
3399         * inssel.brg (mini_emit_virtual_call): Fix a warning.
3400
3401 2006-05-05  Martin Baulig  <martin@ximian.com>
3402
3403         * debug-mini.c (mono_debug_open_block): New method.
3404
3405         * mini-amd64.c
3406         (mono_arch_output_basic_block): Call mono_debug_open_block() at
3407         the beginning of each basic block.
3408
3409         * mini-x86.c
3410         (mono_arch_output_basic_block): Call mono_debug_open_block() at
3411         the beginning of each basic block.
3412
3413 2006-05-04  Massimiliano Mantione  <massi@ximian.com>
3414
3415         * driver.c: Disabled inline,consprop,copyprop,treeprop,deadce by
3416         default until I understand why they break the build on amd64.
3417
3418 2006-05-04  Zoltan Varga  <vargaz@gmail.com>
3419
3420         * mini.c (mini_cleanup): Call mono_cleanup ().
3421
3422         * mini.c (UNVERIFIED): New macro to make it easier to track down verification
3423         errors.
3424
3425 2006-05-04  Massimiliano Mantione  <massi@ximian.com>
3426
3427         * aliasing.c: Fixed shameful cut&paste error that caused JIT crashes.
3428         * driver.c: Enabled inline,consprop,copyprop,treeprop,deadce by
3429         default since all known bugs are fixed, and I cannot reproduce bug
3430         77944... I'm asking Matt Hargett to test again after this commit.
3431
3432 2006-04-28  Massimiliano Mantione  <massi@ximian.com>
3433
3434         * mini-codegen.c: Fixed typo that thrashed inline.
3435
3436 2006-04-28  Zoltan Varga  <vargaz@gmail.com>
3437
3438         * dominators.c (compute_dominators): Avoid using a worklist since
3439         it is not correct in some cases. Instead, iterate over all bblocks as
3440         in the original paper. Fixes --compile-all -O=all System.Xml.dll.
3441
3442 2006-04-28  Miguel de Icaza  <miguel@novell.com>
3443
3444         * mini.c (mono_jit_compile_method_inner): Use
3445         mono_prepare_exception_from_error that resets the value
3446         internally.
3447
3448 2006-04-27  Miguel de Icaza  <miguel@novell.com>
3449
3450         * mini.c: Move the mini_loader_error_to_exception to metadata. 
3451         
3452 2006-04-27  Massimiliano Mantione  <massi@ximian.com>
3453
3454         * aliasing.c: Fixed bug 78210.
3455
3456 2006-04-27  Massimiliano Mantione  <massi@ximian.com>
3457
3458         * driver.c: Disabled inline,consprop,copyprop,treeprop,deadce by
3459         default until all their problems (or the ones they trigger) are fixed.
3460
3461 2006-04-26  Zoltan Varga  <vargaz@gmail.com>
3462
3463         * aot-runtime.c (mono_aot_get_method_from_token_inner): Fix the previous patch.
3464         
3465         * aot-runtime.c (mono_aot_get_method_from_token_inner): Mark the method
3466         as loaded only after resolving patches since that could invoke the same method.
3467
3468         * aot-runtime.c (mono_aot_plt_resolve): Fix ppc etc. builds.
3469
3470         * aot-compiler.c: Refactor mono_aot_compile_aot () into a bunch of smaller
3471         functions.
3472
3473         * aot-runtime.c (init_plt): Use a normal trampoline to transfer code to the
3474         AOT loader.
3475
3476         * aot-compiler.c (emit_plt): Pass the plt offset in %eax instead of on the
3477         stack.
3478
3479         * mini-trampolines.c (mono_aot_plt_trampoline): New trampoline to handle calls
3480         made from AOT code through the PLT table.
3481
3482         * mini-x86.h mini-amd64.h: Define MONO_ARCH_AOT_PLT_OFFSET_REG to the register
3483         holding the plt offset when a call is made to the aot plt trampoline.
3484         
3485 2006-04-25  Zoltan Varga  <vargaz@gmail.com>
3486
3487         * aot-runtime.c aot-compiler.c cpu-amd64.md mini-amd64.c: Update parts of the 
3488         amd64 AOT support.
3489
3490         * Makefile.am (common_sources): Fix build breakage.
3491
3492         * aot-runtime.c aot-compiler.c: Reorganize the AOT code yet again: Make all
3493         calls through a jump table similar to the ELF PLT table. Avoid indirect calls for
3494         intra-assembly calls if possible.
3495         
3496         * tramp-*.c: Add new functions for patching/nullifying PLT entries.
3497
3498         * mini-trampolines.c: Handle PLT entries.
3499
3500         * mini.c: Avoid creating a GOT var for calls.
3501
3502         * jit-icalls.c (helper_ldstr_mscorlib): New helper function for loading strings
3503         from mscorlib code.
3504
3505         * jit-icalls.c (helper_newobj_mscorlib): New helper function to create objects
3506         from mscorlib code.
3507
3508         * mini.c (mono_method_to_ir): Use the new helper functions in throw bblocks in
3509         AOT code.       
3510
3511         * mini.h: Bump AOT file format version.
3512         
3513         * mini.c (get_basic_blocks): Fix the calculation of bb->out_of_line so it
3514         covers more cases.
3515
3516 2006-04-25  Martin Baulig  <martin@ximian.com>
3517
3518         * driver.c: Disable copyprop, consprop and inline when running
3519         inside the debugger.
3520
3521 2006-04-25  Martin Baulig  <martin@ximian.com>
3522
3523         * debug-debugger.h (MonoDebuggerInfo): Replaced `get_thread_id'
3524         with `get_current_thread' and added `detach'.
3525         (MonoDebuggerMetadataInfo): Added `thread_size',
3526         `thread_tid_offset', `thread_stack_ptr_offset' and
3527         `thread_end_stack_offset'.
3528
3529 2006-04-25  Zoltan Varga  <vargaz@gmail.com>
3530
3531         * aot.c Makefile.am: Split aot.c into two new files aot-compiler.c and 
3532         aot-runtime.c.
3533
3534         * inssel.brg (mini_emit_load_intf_reg_vtable): Use a new kind of AOT constant
3535         ADJUSTED_IID to avoid the need for adjusting the IID at runtime.
3536
3537         * mini.h (MonoJumpInfoType): Add MONO_PATCH_INFO_ADJUSTED_IID.
3538
3539         * mini.c (mono_resolve_patch_target): Handle ADJUSTED_IID.
3540
3541         * aot.c: Add support for ADJUSTED_IID.  
3542
3543 2006-04-24  Zoltan Varga  <vargaz@gmail.com>
3544
3545         * aot.c (emit_method_order): Don't align method_order_end.
3546
3547         * inssel.brg (stmt): Fix interface calls in AOT code which got broken by
3548         the interface ID changes.
3549
3550 2006-04-21  Dick Porter  <dick@ximian.com>
3551
3552         * mini.c (mini_thread_cleanup): Clear the JIT TLS data when
3553         cleaning up a thread.  Fixes the new part of bug 77470.
3554
3555 2006-04-20  Geoff Norton  <gnorton@customerdna.com>
3556
3557         * mini-ppc.c: Call mono_jit_thread_attach when transitioning a native
3558         to managed wrapper.
3559                      
3560 2006-04-19  Zoltan Varga  <vargaz@gmail.com>
3561
3562         * mini.h mini.c: Remove mono_type_to_ldind/stind () which are now in marshal.c.
3563         
3564         * mini.c (mono_runtime_install_handlers): Handle SIGABRT similarly to
3565         SIGSEGV. Fixes #78072.
3566
3567         * mini-exceptions.c (mono_handle_native_sigsegv): Add a 'signal' argument,
3568         unregister our SIGABRT handler.
3569
3570 2006-04-19  Massimiliano Mantione  <massi@ximian.com>
3571
3572         * mini.c: Disabled inline where it can alter the call stack in a
3573         way visible from managed code.
3574         * driver.c: enabled inline,consprop,copyprop,treeprop,deadce by
3575         default.
3576
3577 2006-04-16  Zoltan Varga  <vargaz@gmail.com>
3578
3579         * mini-amd64.c (mono_arch_emit_prolog): Attach the thread to the runtime as it is done
3580         on other platforms. Fixes #78089.
3581
3582 2006-04-13  Martin Baulig  <martin@ximian.com>
3583
3584         * driver.c: Also check a `MONO_INSIDE_MDB' environment variable to
3585         determine whether we're inside the debugger.
3586
3587         * debug-debugger.h
3588         (MonoDebuggerMetadataInfo): Added all offsets from `MonoDefaults'.
3589
3590 2006-04-12  Zoltan Varga  <vargaz@gmail.com>
3591
3592         * mini.c (mono_method_to_ir): Handle multiple LEAVE statements inside a single
3593         handler clauses. Fixes #78024.
3594
3595         * mini-sparc.c (mono_arch_output_basic_block): Handle large offsets
3596         in the CALL_MEMBASE opcodes. Fixes #78088.
3597         (mono_arch_get_vcall_slot_addr): Ditto.
3598
3599 2006-04-10  Martin Baulig  <martin@ximian.com>
3600
3601         * debug-debugger.c: The thread handling code has now been moved
3602         into ../metadata/threads.c.
3603
3604 2006-04-10  Zoltan Varga  <vargaz@gmail.com>
3605
3606         * driver.c (mono_main): Fix --with-gc=none build.
3607
3608         * mini-codegen.c (mono_spillvar_offset): Improve alignment.
3609         (mono_spillvar_offset_float): Ditto.
3610         (mono_local_regalloc): Only do the OP_MOVE optimization if ins->dreg is a local
3611         hreg, not when its !global, since on ia64, there is a third category: stacked
3612         registers.      
3613
3614 Mon Apr 10 14:39:49 CEST 2006 Paolo Molaro <lupus@ximian.com>
3615
3616         * mini.c: set MonoInst->klass for load field address and a few other
3617         places.
3618
3619 2006-04-10  Zoltan Varga  <vargaz@gmail.com>
3620
3621         * helpers.c (mono_disassemble_code): Emit debug info on amd64 as well.
3622
3623 2006-04-07  Zoltan Varga  <vargaz@gmail.com>
3624
3625         * dominators.c (compute_dominators): Fix yet another bug which surfaced after
3626         the branch opt changes.
3627
3628 2006-04-06  Dick Porter  <dick@ximian.com>
3629
3630         * wapihandles.c (mini_wapi_semdel): Fix parameters in semctl () call.
3631         
3632         * wapihandles.c (mini_wapi_seminfo): 
3633         * driver.c (mono_main): Add semaphore info option
3634
3635 2006-04-05  Zoltan Varga  <vargaz@gmail.com>
3636
3637         * dominators.c (compute_dominators): Fix a bug which surfaced after the recent
3638         branch optimization changes. Fixes #78009.
3639
3640 Wed Apr 5 16:40:33 CEST 2006 Paolo Molaro <lupus@ximian.com>
3641
3642         * mini.c: ignore accessibility of methods in managed->native wrappers.
3643
3644 2006-04-04  Zoltan Varga  <vargaz@gmail.com>
3645
3646         * mini.c (mini_cleanup): Call print_jit_stats () earlier since it accesses metadata.
3647         
3648         * mini.c (mini_cleanup): Free 'emul_opcode_map' as well.
3649
3650 2006-04-03  Zoltan Varga  <vargaz@gmail.com>
3651
3652         * mini.c: Modify the branch optimizations to preserve the invariant that
3653         the entries inside the in_bb and out_bb arrays are unique.
3654         (mono_unlink_bblock): Avoid creation of new arrays.
3655
3656 2006-04-02  Zoltan Varga  <vargaz@gmail.com>
3657
3658         * mini.c (mono_unlink_bblock): Fix regression caused by previous
3659         change (#77992).
3660
3661 2006-04-01  Zoltan Varga  <vargaz@gmail.com>
3662
3663         * mini.c (optimize_branches): Remove the "optimizations" in
3664         the cbranch1/cbranch2 -> branch cases which were causing several
3665         problems in the past. Fixes #77986.
3666
3667 2006-03-31  Chris Toshok  <toshok@ximian.com>
3668
3669         * driver.c (DEFAULT_OPTIMIZATIONS): back out the new set of
3670         default optimizations :(
3671
3672 2006-03-31  Zoltan Varga  <vargaz@gmail.com>
3673
3674         * inssel-x86.brg mini-codegen.c mini.c: Merge some changes/fixes from linear-il
3675         branch.
3676
3677 2006-03-31  Massimiliano Mantione  <massi@ximian.com>
3678
3679         * local-propagation.c: Added comments to structs and removed
3680         "Mono" prefixes from local tree mover types.
3681
3682 2006-03-30  Zoltan Varga  <vargaz@gmail.com>
3683
3684         * Makefile.am (arch_sources): Define this for each architecture so 
3685         libmono_la_SOURCES is defined in one place.
3686
3687 Wed Mar 29 20:51:14 CEST 2006 Paolo Molaro <lupus@ximian.com>
3688
3689         * driver.c, wapihandles.c, Makefile.am: integrate the io-layer utils
3690         from handles/.
3691
3692 Wed Mar 29 17:16:57 CEST 2006 Paolo Molaro <lupus@ximian.com>
3693
3694         * driver.c: print the GC name supplied by configure.
3695
3696 2006-03-29  Massimiliano Mantione  <massi@ximian.com>
3697
3698         * local-propagation.c: Added tree mover, and moved here all the
3699         local propagation code from mini.c
3700         * mini.c: Added support for treeprop, and moved all the local
3701         propagation code to local-propagation.c
3702         * mini.h: Added support for treeprop
3703         * driver.c: Added support for treeprop, enabled consprop, copyprop,
3704         treeprop, inline and deadce by default
3705         * Makefile.am: Added local-propagation.c
3706
3707 2006-03-25  Zoltan Varga  <vargaz@gmail.com>
3708
3709         * exceptions-sparc.c: Applied patch from David S. Miller  <davem@sunset.davemloft.net>: Implement correct support for sparc/linux.
3710
3711 Fri Mar 24 20:07:19 CET 2006 Paolo Molaro <lupus@ximian.com>
3712
3713         * debug-debugger.c: make it compile without the Boehm GC.
3714
3715 Wed Mar 22 18:25:18 CET 2006 Paolo Molaro <lupus@ximian.com>
3716
3717         * mini.c: fixed issue with mismatch when an icall is registered
3718         with multiple names but same address.
3719
3720 Tue Mar 21 15:59:57 CET 2006 Paolo Molaro <lupus@ximian.com>
3721
3722         * declsec.c, mini-exceptions.c: use write barrier to set reference
3723         fields of managed objects.
3724
3725 2006-03-19  Zoltan Varga  <vargaz@gmail.com>
3726
3727         * mini.c (mono_print_method_from_ip): Recognize JIT trampolines as well.
3728         (can_access_internals): Fix a warning.
3729
3730         * mini.c (print_method_from_ip): Rename this to 
3731         mono_print_method_from_ip so it gets exported.
3732
3733         * trace.c: Deal with strings inside StringBuilder's containing garbage
3734         and fix memory leaks. Fixes #77848.
3735
3736 2006-03-19  Zoltan Varga  <vargaz@gmail.com>
3737
3738         * mini.c (mini_init): Disable the setting of GC_stackbottom on ia64. Hopefully
3739         fixes #77787.
3740
3741 2006-03-16 Neale Ferguson <neale@sinenomine.net>
3742         
3743         * mini-s390.c: Remove OP_X86_TEST_NULL.
3744
3745 Thu Mar 16 17:19:04 CET 2006 Paolo Molaro <lupus@ximian.com>
3746
3747         * mini.c: use the correct GetHashCode() for the moving collector.
3748
3749 2006-03-16  Massimiliano Mantione  <massi@ximian.com>
3750
3751         * liveness.c: Regalloc spill cost tuning.
3752
3753 2006-03-15 Neale Ferguson <neale@sinenomine.net>
3754         
3755         * mini-s390x.h: Correct S390_LONG macro.
3756
3757         * mini-s390x.c: Cleanup unused code.
3758
3759 2006-03-15  Zoltan Varga  <vargaz@gmail.com>
3760
3761         * jit-icalls.h: New file.
3762
3763         * Makefile.am mini.c jit-icalls.c: Use a proper include file for the jit
3764         icalls and include that instead of including jit-icalls.c.
3765
3766         * mini-ppc.c (mono_arch_output_basic_block): Remove references to
3767         OP_X86 opcodes.
3768
3769 Tue Mar 14 20:23:53 CET 2006 Paolo Molaro <lupus@ximian.com>
3770
3771         * mini.c: when checking for member accessibility, also check for
3772         friend assemblies and for explicit interface implementations.
3773
3774 2006-03-14  Zoltan Varga  <vargaz@gmail.com>
3775
3776         * mini-codegen.c (mono_local_regalloc): Remove incorrect g_free () calls.
3777
3778         * cpu-arm.md cpu-g4.md: Remove x86_ opcodes.
3779
3780         * mini-x86.h (MONO_ARCH_INST_FIXED_REG): Reorganize the comparisons so
3781         common cases are done first.    
3782
3783         * mini-ops.h: Only define platform specific opcodes on the given platform.
3784
3785         * mini.h regalloc.h mini-codegen.c: Merge optimizations from the linear-il
3786         branch.
3787         
3788 2006-03-14  Martin Baulig  <martin@ximian.com>
3789
3790         Revert Paolo's change from r57348:
3791
3792         * mini.h: don't use gboolean for bitfields.
3793         * mini.c: verifier changes for fields and methods accessibility.
3794
3795 2006-03-13  Neale Ferguson <neale@sinenomine.net>
3796
3797         * mini-s390.h, mini-s390x.h: Fix calls to mono_call_inst_add_outarg_reg.
3798
3799         * mini-s390x.c: Fix conv_r_un.
3800
3801         * cpu-s390, cpu-s390x.md: Fix lengths.
3802
3803 Sun Mar 12 17:31:22 CET 2006 Paolo Molaro <lupus@ximian.com>
3804
3805         * mini.c: nested types have access to all the nesting
3806         levels, not just the enclosing types.
3807
3808 Sun Mar 12 16:23:11 CET 2006 Paolo Molaro <lupus@ximian.com>
3809
3810         * mini.c: added a few more verification checks.
3811
3812 2006-03-12  Zoltan Varga  <vargaz@gmail.com>
3813
3814         * liveness.c: Merge optimizations from the linear-il branch.
3815
3816 2006-03-11  Zoltan Varga  <vargaz@gmail.com>
3817
3818         * mini-ia64.c (emit_call): Add a comment.
3819
3820         * tramp-ia64.c (mono_arch_patch_callsite): Handle indirect calls as well.
3821
3822         * tramp-ia64.c: Fix some warnings.
3823
3824 Sat Mar 11 20:15:59 CET 2006 Paolo Molaro <lupus@ximian.com>
3825
3826         * mini.h: don't use gboolean for bitfields.
3827         * mini.c: verifier changes for fields and methods accessibility.
3828
3829 2006-03-11  Zoltan Varga  <vargaz@gmail.com>
3830
3831         * mini.c (mono_icall_get_wrapper): Fix an ia64 bug introduced by the
3832         lazy icall wrapper changes.
3833
3834         * dominators.c: Replace all the dominator algorithms with faster
3835         ones from the linear-il branch.
3836
3837         * inssel-*.brg: Allocate call->out_ireg_args and call->out_freg_args from
3838         the mempool.
3839
3840         * mini-amd64.h (MONO_ARCH_INST_FIXED_REG): Reorganize the comparisons so
3841         common cases are done first.
3842
3843         * mini-amd64.c: Fix some warnings.
3844
3845         * mini-codegen.c mini-*.c: Allocate call->out_ireg_args and call->out_freg_args
3846         from the mempool.
3847
3848         * mini.c (mono_jit_compile_method_with_opt): Fix a race in the newly
3849         added code.
3850
3851         * mini.h: Add a missing prototype.
3852
3853 2006-03-10  Zoltan Varga  <vargaz@gmail.com>
3854
3855         * mini.c: Compile icall wrappers lazily.
3856
3857         * mini-codegen.c: Use printf instead of g_print since its much faster.
3858
3859         * mini.h (mono_bitset_foreach_bit): Use the faster mono_bitset_find_start ()
3860         function.
3861
3862         * mini.c (optimize_branches): Cache the negative result from 
3863         remove_block_if_useless ().
3864
3865         * mini.c (optimize_branches): Avoid restarting the iteration after each change. 
3866         Also fix some bblock linking issues.
3867
3868         * helpers.c (mono_disassemble_code): Reduce the size of the temporary
3869         assembly files.
3870
3871         * mini.h: Define G_LIKELY/G_UNLIKELY macros for older glib versions.
3872
3873         * mini.h (MonoBasicBlock): Reorganize the fields, putting more frequently
3874         accessed fields first, for better cache behavior.
3875         
3876 Fri Mar 10 18:21:41 CET 2006 Paolo Molaro <lupus@ximian.com>
3877
3878         * mini.c: speedup IList<T> array accesses.
3879
3880 2006-03-09  Zoltan Varga  <vargaz@gmail.com>
3881
3882         * mini.c (mono_method_to_ir): Handle large methods overflowing the 
3883         inline_costs counter. Fixes #77190.
3884
3885 2006-03-06  Zoltan Varga  <vargaz@gmail.com>
3886
3887         * mini-exceptions.c: Call mono_trace_is_enabled () before printing
3888         trace messages. Fixes #77706.
3889
3890 2006-03-04  Martin Baulig  <martin@ximian.com>
3891
3892         * tramp-amd64.c, tramp-x86.c
3893         (mono_debugger_create_notification_function): Use
3894         mono_global_codeman_reserve() to allocate a buffer at runtime and
3895         return it.
3896
3897         * debug-debugger.h (MonoDebuggerInfo): Added `initialize'.
3898
3899         * debug-debugger.c (mono_debugger_init): Dynamically allocate the
3900         notification function at runtime and then call `initialize' in the
3901         `MONO_DEBUGGER__debugger_info' vtable.
3902
3903 2006-03-04  Zoltan Varga  <vargaz@gmail.com>
3904
3905         * iltests.il: Fix a visibility problem.
3906
3907 Wed Mar 1 15:55:25 CET 2006 Paolo Molaro <lupus@ximian.com>
3908
3909         * driver.c, mini.c: add hooks for the counters API.
3910
3911 Wed Mar 1 12:28:04 CET 2006 Paolo Molaro <lupus@ximian.com>
3912
3913         * driver.c: show disabled options.
3914
3915 Wed Mar 1 12:18:51 CET 2006 Paolo Molaro <lupus@ximian.com>
3916
3917         * linear-scan.c: always use cost-driven selection.
3918
3919 2006-02-28  Raja R Harinath  <rharinath@novell.com>
3920
3921         * jit-icalls.c (helper_compile_generic_method): Revert change from
3922         2006-02-24.
3923
3924 Mon Feb 27 18:58:19 GMT 2006 Paolo Molaro <lupus@ximian.com>
3925
3926         * cpu-arm.md, mini-arm.c: implemented MemoryBarrier.
3927
3928 Sat Feb 25 17:39:21 CET 2006 Paolo Molaro <lupus@ximian.com>
3929
3930         * inssel.brg: style fixes, mostly to force the updated monoburg
3931         to run for people using svn.
3932
3933 Sat Feb 25 17:07:42 CET 2006 Paolo Molaro <lupus@ximian.com>
3934
3935         * mini.c: match monoburg changes.
3936
3937 Sat Feb 25 16:04:33 CET 2006 Paolo Molaro <lupus@ximian.com>
3938
3939         * mini.h, mini.c, abcremoval.c, aliasing.c, liveness.c,
3940         ssapre.c, graph.c, ssa.c: put the mono_burg_arity[]
3941         declaration in the header file.
3942
3943 Sat Feb 25 14:19:31 CET 2006 Paolo Molaro <lupus@ximian.com>
3944
3945         * helpers.c: reduce relocations and mem usage.
3946
3947 Sat Feb 25 11:58:16 CET 2006 Paolo Molaro <lupus@ximian.com>
3948
3949         * mini.h, mini-codegen.c: disable logging features if
3950         requested by configure.
3951
3952 Sat Feb 25 11:54:49 CET 2006 Paolo Molaro <lupus@ximian.com>
3953
3954         * mini.c: tiny verifier changes.
3955
3956 Fri Feb 24 18:17:52 CET 2006 Paolo Molaro <lupus@ximian.com>
3957
3958         * mini-ops.h, inssel-x86.brg, tramp-x86.c, mini-x86.c,
3959         cpu-pentium.md: stack alignment changes for osx/x86,
3960         partially from Geoff Norton <gnorton@customerdna.com>.
3961
3962 2006-02-24  Raja R Harinath  <harinath@gmail.com>
3963
3964         * jit-icalls.c (helper_compile_generic_method): Update to changes
3965         in metadata/class.c.
3966
3967 2006-02-24  Zoltan Varga  <vargaz@gmail.com>
3968         
3969         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add a missing check.
3970         
3971         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add support for
3972         interface calls with large offsets.
3973
3974 2006-02-23  Raja R Harinath  <rharinath@novell.com>
3975
3976         * jit-icalls.c (helper_compile_generic_method): Document the
3977         special-case we depend on so that we can inflate the method twice
3978         with the same context with no bad side-effects.
3979
3980 Thu Feb 23 13:45:46 CET 2006 Paolo Molaro <lupus@ximian.com>
3981
3982         * mini-x86.c, mini-amd64.c: fix for case when xen support
3983         is disabled.
3984
3985 Wed Feb 22 19:38:40 CET 2006 Paolo Molaro <lupus@ximian.com>
3986
3987         * mini-x86.c, mini-amd64.c: generate code to access tls items
3988         in a faster way for Xen systems.
3989
3990 Wed Feb 22 10:31:25 CET 2006 Paolo Molaro <lupus@ximian.com>
3991
3992         * exceptions-x86.c, mini-x86.h, driver.c, mini-codegen.c:
3993         updates and compilation fixes for the OSX/x86 port, mostly from
3994         Geoff Norton <gnorton@customerdna.com>.
3995
3996 Tue Feb 21 19:56:55 CET 2006 Paolo Molaro <lupus@ximian.com>
3997
3998         * inssel.brg: faster interface call implementation
3999         to sync with the interface_offsets MonoVTable changes.
4000
4001 Mon Feb 20 10:37:57 CET 2006 Paolo Molaro <lupus@ximian.com>
4002
4003         * mini.c: more verification checks.
4004
4005 Fri Feb 17 19:47:29 CET 2006 Paolo Molaro <lupus@ximian.com>
4006
4007         * mini.c: added a few more verification checks.
4008
4009 2006-02-17      Neale Ferguson <neale@sinenomine.net>
4010
4011         * mini-s390x.c, mini-s390x.h: Check for presence of long displacement
4012         facility on the processor and use it if available.
4013
4014 Fri Feb 17 16:12:52 CET 2006 Paolo Molaro <lupus@ximian.com>
4015
4016         * driver.c, aot.c, mini.c: throw exception if the IL code is
4017         invalid or unverifiable.
4018
4019 2006-02-17  Raja R Harinath  <rharinath@novell.com>
4020
4021         * generics.2.cs (test_0_ldfld_stfld_mro): Use m.struct_field, not
4022         m.StructField.
4023
4024 2006-02-16  Zoltan Varga  <vargaz@gmail.com>
4025
4026         * generics.2.cs: Add some tests for generics ldfld/stfld wrappers.
4027
4028 Wed Feb 15 16:23:17 CET 2006 Paolo Molaro <lupus@ximian.com>
4029
4030         * mini-s390x.c, mini-s390.c, mini.c, mini-amd64.c, mini-arm.c,
4031         mini-ia64.c, mini-sparc.c, mini-x86.c, mini-ppc.c: fixed
4032         handling of instantiated generic valuetypes.
4033
4034 2006-02-11  Zoltan Varga  <vargaz@gmail.com>
4035
4036         * mini-exceptions.c mini-x86.h mini-x86.c: Get rid of 
4037         MONO_INIT_CONTEXT_FROM_CALLER, and use MONO_INIT_CONTEXT_FROM_FUNC
4038         instead.
4039
4040         * generics.2.cs: Revert the nullable reftypes tests.
4041
4042 2006-02-10  Zoltan Varga  <vargaz@gmail.com>
4043
4044         * mini-exceptions.c (MONO_INIT_CONTEXT_FROM_CALLER): Avoid
4045         using __builtin_frame_address (1) as it doesn't work in the presence
4046         of optimizations. Hopefully fixes #77273.
4047
4048         * Makefile.am generics.cs generics.2.cs: Revert the generics.2.cs
4049         -> generics.cs change as it doesn't work with some automake versions.
4050
4051 Thu Feb 9 16:24:44 CET 2006 Paolo Molaro <lupus@ximian.com>
4052
4053         * mini.c: handle systems that sue a different way to
4054         retrieve the stack address of the current thread.
4055
4056 2006-02-09  Zoltan Varga  <vargaz@gmail.com>
4057
4058         * Makefile.am generics.2.cs: Rename this to generics.cs and handle
4059         it specially in the makefile.
4060
4061         * generics.2.cs: Add tests for nullable reference types.
4062
4063 Wed Feb 8 19:33:17 CET 2006 Paolo Molaro <lupus@ximian.com>
4064
4065         * mini.c: always handle the case when mono_jit_init()
4066         is called in a thread different from the main thread,
4067         confusing libgc (bug #77309).
4068
4069 Mon Feb 6 09:01:24 EST 2006 Paolo Molaro <lupus@ximian.com>
4070
4071         * mini-ppc.c: fix handling of exceptions in large methods (bug #74932).
4072
4073 Fri Feb 3 18:51:35 CET 2006 Paolo Molaro <lupus@ximian.com>
4074
4075         * mini.c: change optimize_branches () to use a single loop
4076         and introduce a new optimization to simplify some range checks.
4077
4078 2006-02-03  Martin Baulig  <martin@ximian.com>
4079
4080         * debug-debugger.c (debugger_thread_manager_thread_created): Removed
4081         and merged with debugger_thread_manager_add_thread().
4082         (mono_debugger_main): Call debugger_thread_manager_add_thread() to
4083         inform the debugger about the main thread.
4084
4085 2006-02-03  Zoltan Varga  <vargaz@gmail.com>
4086
4087         * basic.cs: Add test for div.un/rem.un constant folding.
4088
4089 2006-02-03  Neale Ferguson <neale@sinenomine.net>
4090
4091         * cpu-s390x.md: correct int_xor_imm length
4092
4093 2006-02-03  Zoltan Varga  <vargaz@gmail.com>
4094
4095         * generics.2.cs: New test for #77442.
4096
4097         * jit-icalls.c (helper_compile_generic_method): Check for null. Fixes
4098         #77442.
4099
4100 2006-02-02  Martin Baulig  <martin@ximian.com>
4101
4102         * tramp-x86.c, tramp-amd64.c: It's now safe to #include
4103         <mono/metadata/mono-debug-debugger.h>   
4104
4105         * debug-mini.c: Don't #define _IN_THE_MONO_DEBUGGER.
4106
4107 2006-02-02  Martin Baulig  <martin@ximian.com>
4108
4109         * debug-debugger.h: New header file for debug-debugger.c.
4110
4111         * debug-debugger.c: Big API cleanup; don't run the managed Main()
4112         function is a separate thread anymore; add support for attaching.
4113
4114 2006-02-01  Zoltan Varga  <vargaz@gmail.com>
4115
4116         * tramp-x86.c: Fix a warning.
4117
4118 2006-01-31  Zoltan Varga  <vargaz@gmail.com>
4119
4120         * mini-amd64.c (mono_arch_compute_omit_fp): Avoid hitting an assertion
4121         on very large methods.
4122
4123         * aot.c (load_patch_info): Fix a warning.
4124
4125 Mon Jan 30 12:51:10 CET 2006 Paolo Molaro <lupus@ximian.com>
4126
4127         * cpu-pentium.md, mini-x86.c, inssel.brg, inssel-x86.brg,
4128         mini-ops.h: alu membase optimizations.
4129
4130 Fri Jan 27 21:11:08 CET 2006 Paolo Molaro <lupus@ximian.com>
4131
4132         * mini-ops.h, mini.c, inssel.brg, inssel-x86.brg: opcode
4133         to speedup StringBuilder.
4134
4135 2006-01-27  Zoltan Varga  <vargaz@gmail.com>
4136
4137         * dominators.c (mono_compute_natural_loops): Fix detection of
4138         loop body start blocks.
4139
4140         * mini-exceptions.c (mono_print_thread_dump): Fix non x86 builds.
4141
4142 2006-01-26  Zoltan Varga  <vargaz@gmail.com>
4143
4144         * mini.h mini.c mini-exceptions.c: Add thread dump support. Fixes
4145         #75145.
4146
4147 2006-01-25  Massimiliano Mantione  <massi@ximian.com>
4148
4149         * aliasing.c: Fixed aliasing issue on 64 bit archs.
4150
4151 2006-01-25  Martin Baulig  <martin@ximian.com>
4152
4153         * debug-debugger.c: Moved the `MonoDebuggerManager' and
4154         `MonoDebuggerThread' typedefs here from mono-debug-debugger.h and
4155         started to cleanup this file a little bit.
4156
4157 Tue Jan 24 18:20:48 CET 2006 Paolo Molaro <lupus@ximian.com>
4158
4159         * mini.c: optimize a codepath frequently happening in generics code.
4160
4161 2006-01-23  Martin Baulig  <martin@ximian.com>
4162
4163         * Makefile.am: Only compile debug-debugger.c on supported platforms.
4164
4165         * debug-debugger.c: Kill the IO_LAYER() hack and use the io-layer
4166         functions directly.
4167
4168         * driver.c: debug-debugger.c is only available if
4169         `MONO_DEBUGGER_SUPPORTED' is defined.   
4170
4171 2006-01-23  Martin Baulig  <martin@ximian.com>
4172
4173         * debug-debugger.c: Only enable this on platforms where the Mono
4174         Debugger is working (x86 and x86_64).
4175
4176 2006-01-21  Martin Baulig  <martin@ximian.com>
4177
4178         The Mono Debugger is now using the normal `mono' instead of the
4179         `mono-debugger-mini-wrapper' when executing managed code.
4180
4181         * debug-debugger.c: New file; previously known as
4182         debugger/wrapper/wrapper.c.
4183
4184         * debug-mini.c (mono_init_debugger): Removed.
4185
4186         * driver.c (mono_main): Added new `--inside-mdb' command line
4187         argument which is used when running inside the debugger.
4188
4189 2006-01-20  Zoltan Varga  <vargaz@gmail.com>
4190
4191         * liveness.c (mono_analyze_liveness): Remove some unused data
4192         structures.
4193
4194 2006-01-17  Zoltan Varga  <vargaz@gmail.com>
4195
4196         * mini.h: Move mono_bitset_test_fast macro to monobitset.h where it belongs.
4197
4198 2006-01-16  Zoltan Varga  <vargaz@gmail.com>
4199
4200         * mini.h (mono_bitset_test_fast): Disable the 'fast' implementation which
4201         depends on implementation details of monobitset.
4202
4203         * mini.c (mini_get_ldelema_ins): Fix handling of 1 dimensional arrays.
4204         Fixes #77271.
4205
4206 2006-01-15  Zoltan Varga  <vargaz@gmail.com>
4207
4208         * liveness.c: Update after monobitset changes.
4209
4210 2006-01-14  Zoltan Varga  <vargaz@gmail.com>
4211
4212         * mini-amd64.c (mono_arch_compute_omit_fp): Fix a leak.
4213
4214 2006-01-11 Neale Ferguson <neale@sinenomine.net>
4215
4216         * inssel-s390x.brg: Fix reg: OP_LDADDR(OP_S390_LOADARG) register setting.
4217
4218         * mini-s390x.c: Remove warning messages.
4219
4220 2006-01-11  Ben Maurer  <bmaurer@andrew.cmu.edu>
4221
4222         * mini.c: pass the jitinfo to mono_profiler_method_end_jit.
4223
4224 2006-01-10  Zoltan Varga  <vargaz@gmail.com>
4225
4226         * generics.2.cs: Add ldelem/stelem_any test.
4227
4228 2006-01-10 Neale Ferguson <neale@sinenomine.net>
4229
4230         * mini-s390.c: Fix ATOMIC_ADD_I4 operation.
4231
4232 2006-01-07  Zoltan Varga  <vargaz@gmail.com>
4233
4234         * inssel-long.brg: Fix int->long ovf conversion rules. Fixes #77172.
4235         
4236 2006-01-06  Zoltan Varga  <vargaz@gmail.com>
4237
4238         * generics.2.cs: Reenable vtype tests.
4239
4240         * inssel-x86.brg: Remove an icorrect valuetype rule.
4241
4242 2006-01-06 Neale Ferguson <neale@sinenomine.net>
4243
4244         * mini-s390x.c, inssel-s390x.brg, cpu-s390x.md: Fix ATOMIC_I8 operations. Provide
4245         initial support for OP_ABS.
4246
4247 2006-01-05 Neale Ferguson <neale@sinenomine.net>
4248
4249         * mini-s390x.c (emit_float_to_int): Correct r8 to unsigned int algorithm.
4250
4251 2006-01-05 Neale Ferguson <neale@sinenomine.net>
4252
4253         * mini-s390.c, mini-s390.h, inssel-s390.brg, cpu-s390.md: Fix r8 to unsigned int 
4254         conversion and implement LADD/LSUB.
4255
4256         * exceptions-s390.c: Standardize mono_arch_find_jit_info to match other
4257         architectures.
4258
4259 2006-01-05 Neale Ferguson <neale@sinenomine.net>
4260
4261         * mini-s390x.c, mini-s390x.h: Fix r8 to unsigned int conversion.
4262
4263         * exceptions-s390x.c: Standardize mono_arch_find_jit_info to match other
4264         architectures.
4265
4266 2006-01-05 Neale Ferguson <neale@sinenomine.net>
4267
4268         * mini-s390x.c, mini-s390x.h, mini-s390.c, mini-s390.h: Fix lmf handling when 
4269         localloc is encountered.  Fixes crash in test-183.cs when using gmcs 
4270         (stack walk problem).
4271
4272 2006-01-04  Zoltan Varga  <vargaz@gmail.com>
4273
4274         * aot.c (mono_aot_load_method): Fix a warning.
4275
4276 2006-01-03  Neale Ferguson <neale@sinenomine.net>
4277
4278         * mini-s390x.h, exceptions-s390x.c, inssel-s390x.brg: Fix compiler warnings
4279
4280 2006-01-03  Zoltan Varga  <vargaz@gmail.com>
4281
4282         * iltests.il: Add test for #77148.
4283
4284         * mini.c (mini_get_ldelema_ins): Handle arrays with rank 1 too. Fixes
4285         #77148.
4286
4287 2006-01-03  Neale Ferguson <neale@sinenomine.net>
4288
4289         * mini-s390x.c, inssel-s390x.brg: Remove debug statements
4290
4291 2006-01-03  Neale Ferguson <neale@sinenomine.net>
4292
4293         * mini-s390x.c, mini-s390x.h, exceptions-s390x.c, tramp-s390x.c, inssel-s390x.brg,
4294         cpu-s390x.md, mini-codegen.c, Makefile.am: add 64-bit s390 support to JIT.
4295
4296         * basic-long.cs: Add lconv-to-r4/r8 tests.
4297
4298 2006-01-03  Zoltan Varga  <vargaz@gmail.com>
4299
4300         * mini.c (mono_method_to_ir): Fix DynamicMethod support in some opcodes.
4301
4302         * mini-sparc.c (mono_arch_call_opcode): Use mono_class_value_size ()
4303         here as on other archs.
4304
4305 2005-12-29 Neale Ferguson <neale@sinenomine.net>
4306
4307         * mini-s390.c (mono_arch_get_inst_for_method): Add memory_barrier support.
4308
4309 2005-12-29 Neale Ferguson <neale@sinenomine.net>
4310
4311         * inssel-s390.brg: Correct register assignment; Rework L[ADD|SUB]_OVF[_UN] for s390.
4312         
4313         * cpu-s390.md: Fix lengths of a couple of long instructions; Add memory_barrier.
4314
4315         * mini-s390.c: Fix long add/sub overflow instructions; Fix displacement handling in
4316         instrument_prolog; Add memory_barrier instruction.
4317
4318 2005-12-26  Zoltan Varga  <vargaz@gmail.com>
4319
4320         * exceptions-x86.c mini-x86.h: Fix solaris/x86 exception handling.
4321
4322 2005-12-23  Zoltan Varga  <vargaz@gmail.com>
4323
4324         * tramp-ia64.c (mono_arch_get_unbox_trampoline): Flush icache.
4325
4326         * aliasing.c inssel.brg: Fix warnings.
4327
4328         * inssel-ia64.brg (OP_MEMSET): Fix an optimization which previously
4329         could skip initialization of some parts of memory.
4330
4331         * mini.c mini-ia64.c: Fix warnings.
4332
4333         * inssel-sparc.brg: Add an implementation of lneg which actually works.
4334
4335 2005-12-22  Zoltan Varga  <vargaz@gmail.com>
4336
4337         * aliasing.c (mono_build_aliasing_information): Add a workaround for
4338         a crash seen on sparc.
4339
4340         * mini-sparc.c: Add implementation of Thread.MemoryBarrier.
4341         
4342         * cpu-sparc.md: Add memory_barrier opcode. Remove unused opcodes.
4343
4344 2005-12-21 Neale Ferguson <neale@sinenomine.net>
4345
4346         * mini-ops.h: Add s390_backchain instruction
4347
4348         * inssel-s390.brg: Use backchaining instruction for LOADARG/STKARG operations.
4349
4350         * cpu-s390.md: Add s390_backchain instruction
4351
4352         * mini-s390.c: Significant ABI changes
4353
4354         * mini-s390.h: Cater for zero length structures
4355
4356 2005-12-20 Neale Ferguson <neale@sinenomine.net>
4357
4358         * mini-s390.c: ABI fixes
4359
4360         * inssel-s390.brg: Remove debug statements
4361
4362         * cpu-s390.md: Fix length of ATOMIC_xx operations
4363
4364 2005-12-19  Zoltan Varga  <vargaz@gmail.com>
4365
4366         * basic-float.cs: Add float<->long conversion tests.
4367
4368 2005-12-16 Neale Ferguson <neale@sinenomine.net>
4369
4370         * mini-s390.c: Fix LOCALLOC processing.
4371
4372         * tramp-s390.c (s390_magic_trampoline): Fix base calculation.
4373
4374 2005-12-15  Zoltan Varga  <vargaz@gmail.com>
4375
4376         * iltests.il: Add tests for some opcodes not covered by the other
4377         tests.
4378
4379 2005-12-15 Neale Ferguson <neale@sinenomine.net>
4380
4381         * mini-s390.c: Fix ADDCC/SBB bug revealed by test_0_ulong_regress; Correct 
4382         register loading for Tail processing; Correct trace output.
4383
4384         * inssel-s390.brg: Reimplement LSUB_OVF due to s390 implementation of signed math.
4385
4386         * cpu-s390.md: Correct size of jmp instruction. 
4387
4388 2005-12-13 Neale Ferguson <neale@sinenomine.net>
4389
4390         * mini-s390.c (mono_arch_emit_prolog): Remove some debugging bits.
4391
4392 2005-12-13 Neale Ferguson <neale@sinenomine.net>
4393
4394         * inssel-s390.brg tramp-s390.c cpu-s390.md mini-s390.c mini-s390.h:
4395           Bring s390 up to current level.
4396
4397 2005-12-12  Zltan Varga  <vargaz@gmail.com>
4398
4399         * generics.2.cs: Disable the newly added tests as they do not work yet.
4400         
4401         * generics.2.cs: Add valuetype tests.
4402
4403 2005-12-09  Zoltan Varga  <vargaz@gmail.com>
4404
4405         * basic-long.cs: Add i4->u8 test.
4406
4407         * objects.cs: Add tests for JIT intrinsic.
4408
4409         * mini.c (mini_get_inst_for_method): Resurrect the array Rank/Length
4410         optimizations lost by a mistake.
4411
4412 2005-12-07  Zoltan Varga  <vargaz@gmail.com>
4413
4414         * basic-long.cs: Remove a test moved to objects.cs.
4415
4416         * arrays.cs: Add more array tests.
4417
4418 2005-12-06  Zoltan Varga  <vargaz@gmail.com>
4419
4420         * arrays.cs: Add new tests for multi-dimensional arrays.
4421
4422 2005-12-06  Raja R Harinath  <rharinath@novell.com>
4423
4424         * Makefile.am (test_sources2): Add generics.2.cs.
4425         (EXTRA_DIST): Add test_sources2.
4426
4427 2005-12-05  Ben Maurer  <bmaurer@ximian.com>
4428
4429         Support for boxing and unboxing nullable types as well as the
4430         isinst operation on nullables, per the CLI ammendment.
4431
4432         * inssel.brg (CEE_ISINST): Special case for nullable
4433
4434         * mini.c (handle_unbox_nullable): new method
4435         (handle_box): Special case for nullable types
4436         (mono_method_to_ir): Call handle_unbox_nullable in correct
4437         places.
4438
4439         * generics.2.cs: New test suite
4440
4441         * Makefile.am: Support for regression tests with generics.
4442
4443 2005-12-03  Zoltan Varga  <vargaz@gmail.com>
4444
4445         * mini-amd64.c (emit_load_volatile_arguments): Add loading of arguments
4446         allocated to registers. Fixes #76800.
4447
4448 Thu Dec 1 12:59:40 EST 2005 Paolo Molaro <lupus@ximian.com>
4449
4450         * mini-ppc.c, inssel-ppc.brg: fix ABI issue (pinvoke3.cs).
4451
4452 2005-11-30  Zoltan Varga  <vargaz@gmail.com>
4453
4454         * exceptions.cs: Disable test_0_long_cast () test, since it fails on a lot 
4455         of platforms.
4456
4457 2005-11-29  Zoltan Varga  <vargaz@gmail.com>
4458
4459         * objects.cs basic-calls.cs: Move a test depending on valuetypes to
4460         objects.cs.
4461
4462         * inssel-long32.brg (CEE_CONV_I8): Remove unused labels.
4463         
4464         * inssel-long32.brg (CEE_CONV_I8): Convert this to a branchless version.
4465 Tue Nov 29 05:41:34 EST 2005 Paolo Molaro <lupus@ximian.com>
4466
4467         * mini-ppc.c, cpu-g4.md: ensure a fp register is converted to
4468         single precision before storing to a single precision location.
4469
4470 2005-11-28  Raja R Harinath  <rharinath@novell.com>
4471
4472         * Makefile.am (ILASM): Use profile-dependent location of ilasm.
4473
4474 2005-11-27  Zoltan Varga  <vargaz@gmail.com>
4475
4476         * basic-long.cs basic-calls.cs objects.cs: Move some tests to the
4477         correct files.
4478
4479         * basic.cs: Remove test_0_byte_compares test which was moved to
4480         objects.cs a long time ago.
4481
4482 2005-11-22  Massimiliano Mantione  <massi@ximian.com>
4483
4484         * aliasing.c: Fixed aliasing issue on 64 bit archs.
4485
4486 2005-11-20  Zoltan Varga  <vargaz@gmail.com>
4487
4488         * mini-ia64.c exceptions-ia64.c: Simplify the way filters/finally
4489         handlers are called.
4490
4491         * mini-ia64.c (mono_arch_emit_exceptions): Optimize size of exception
4492         throwing code.
4493
4494          * mini-ia64.c: Add support for the throw->branch exception 
4495         optimization.   
4496
4497         * driver.c (DEFAULT_OPTIMIZATIONS): Add MONO_OPT_EXCEPTION.
4498
4499 2005-11-18  Massimiliano Mantione  <massi@ximian.com>
4500
4501         * mini.c: Enabled "fastpath" deadce :-)
4502         
4503 2005-11-18  Massimiliano Mantione  <massi@ximian.com>
4504
4505         * mini.c: Added "fastpath" deadce (deadce without SSA), and a simple
4506         alias analysis pass to support it.
4507         * mini.h: Likewise.
4508         * ssa.c: Likewise.
4509         * liveness.c: Likewise (liveness computation can use aliasing
4510         information to be more accurate).
4511         * driver.c: Added an "ssa" option go tell the JIT to use SSA, and
4512         moreover made so that "--compile-all" uses the given optimization
4513         flags and not the default ones.
4514         * aliasing.c: Alias analysis (new file).
4515         * aliasing.h: Likewise.
4516         * Makefile.am: added "aliasing.c" and "aliasing.h".
4517         
4518 2005-11-17  Zoltan Varga  <vargaz@gmail.com>
4519
4520         * mini-ops.h: Add missing OP_I opcodes so it is in synch with the
4521         OP_L opcodes.
4522
4523 2005-11-13  Zoltan Varga  <vargaz@gmail.com>
4524
4525         * mini-exceptions.c (mono_handle_exception_internal): Remove the 
4526         fp >= end_of_stack exit condition, as it is not needed, and it might
4527         become true for fp eliminated frames.
4528
4529 2005-11-11  Zoltan Varga  <vargaz@gmail.com>
4530
4531         * mini-x86.c (mono_arch_emit_epilog): Use G_STRUCT_OFFSET instead of hard
4532         coded offsets.
4533
4534 Tue Nov 8 11:28:20 GMT 2005 Paolo Molaro <lupus@ximian.com>
4535
4536         * mini-arm.c: fixed alignment of doubles/longs to match
4537         the C ABI (bug #76635).
4538
4539 Mon Nov 7 16:13:21 CET 2005 Paolo Molaro <lupus@ximian.com>
4540
4541         * aot.c: fix compilation with --enable-minimal=aot.
4542
4543 Fri Nov 4 12:34:15 GMT 2005 Paolo Molaro <lupus@ximian.com>
4544
4545         * mini-arm.c: fixed compatibility with the new
4546         floating point emulator package for compares.
4547
4548 2005-11-03  Atsushi Enomoto  <atsushi@ximian.com?
4549
4550         * mini.c : reverted sig->pinvoke changes (r51396-51397).
4551
4552 2005-11-01  Zoltan Varga  <vargaz@freemail.hu>
4553
4554         * mini-exceptions.c (print_stack_frame): Output to stderr.
4555         (mono_handle_native_sigsegv): Ditto.
4556
4557 2005-10-30  Zoltan Varga  <vargaz@freemail.hu>
4558
4559         * mini-amd64.c (mono_arch_output_basic_block): Remove unused
4560         OP_LCONV_TO_OVF_I implementation.
4561
4562         * mini-amd64.c: Add support for the throw->branch exception 
4563         optimization.
4564
4565         * branch-opts.c (mono_branch_optimize_exception_target): Allow the case
4566         when the catch clause catches a more general exception, i.e. Object.
4567
4568 2005-10-30  Zoltan Varga  <vargaz@gmail.com>
4569
4570         * cpu-ia64.md: Remove unused opcodes.
4571
4572         * mini.c (GET_CONTEXT): Simplify this somewhat by removing arch
4573         specific defines for architectures defining USE_SIGACTION.
4574
4575         * mini-ia64.c: Fix some warnings.
4576
4577         * exceptions-ia64.c (mono_arch_ip_from_context): Fix this, the previous
4578         version seemed to skip a frame.
4579
4580 2005-10-30  Zoltan Varga  <vargaz@freemail.hu>
4581
4582         * mini.c: Clean up the usage of sig->pinvoke flag. Now
4583         only calls which are made to native code use this flag.
4584
4585 2005-10-29  Zoltan Varga  <vargaz@freemail.hu>
4586
4587         * mini-amd64.c (mono_arch_compute_omit_fp): Disable fp elimination for
4588         varargs methods as well.
4589         
4590         * mini-amd64.c exceptions-amd64.c: Allow fp elimination in methods
4591         which have save_lmf set. Reorganize methods prologs a bit.
4592
4593         * mini-amd64.c (mono_arch_compute_omit_fp): Move the check for the
4594         debugger to the proper place.
4595
4596 2005-10-29  Martin Baulig  <martin@ximian.com>
4597
4598         * mini-amd64.c (debug_omit_fp): Temporarily disable fp elimination
4599         when running inside the debugger until the debugger has support
4600         for it.
4601
4602 2005-10-26  Zoltan Varga  <vargaz@gmail.com>
4603
4604         * mini.h: Fix a warning.
4605
4606 2005-10-24  Miguel de Icaza  <miguel@novell.com>
4607
4608         * mini.c (mono_pmip): Just a wrapper for get_method_from_ip which
4609         we expose publicly, this returns the string.
4610
4611 2005-10-22  Zoltan Varga  <vargaz@freemail.hu>
4612
4613         * exceptions-amd64.c (mono_arch_find_jit_info): Fix some corner cases
4614         with fp elimination.
4615
4616 2005-10-21  Zoltan Varga  <vargaz@gmail.com>
4617
4618         * mini-exceptions.c (mono_handle_native_sigsegv): Try to print a
4619         native stacktrace using the glibc 'backtrace' function if available.
4620
4621 2005-10-20  Zoltan Varga  <vargaz@gmail.com>
4622
4623         * mini.h (MonoDebugOptions): Remove 'abort_on_sigsegv' option.
4624
4625         * mini-exceptions.c (mono_handle_native_sigsegv): New function to 
4626         handle SIGSEGVs received while in native code.
4627
4628         * mini.c (sigsegv_signal_handler): If the SIGSEGV happened in native
4629         code, call mono_handle_native_sigsegv which will abort the runtime
4630         after printing some diagnostics, instead of converting it into a
4631         confusing NullReferenceException.
4632
4633 2005-10-18  Zoltan Varga  <vargaz@gmail.com>
4634
4635         * cpu-pentium.md: Remove unused opcodes.
4636
4637 2005-10-18  Zoltan Varga  <vargaz@freemail.hu>
4638
4639         * mini-amd64.h (MonoLMF): Add rsp field.
4640
4641         * mini-amd64.c exceptions-amd64.c tramp-amd64.c: Save the sp reg into
4642         the lmf too.
4643
4644 2005-10-17  Zoltan Varga  <vargaz@gmail.com>
4645
4646         * mini-codegen.c (get_register_spilling): Fix some warnings.
4647
4648 2005-10-16  Zoltan Varga  <vargaz@freemail.hu>
4649
4650         * mini-amd64.h mini-amd64.c exceptions-amd64.c: Add support for fp
4651         elimination during exception handling. Enable fp elimination by
4652         default.
4653
4654         * mini-amd64.h mini-amd64.c: Add preliminary support for frame pointer
4655         elimination.
4656
4657 2005-10-16  Martin Baulig  <martin@ximian.com>
4658
4659         * mini-exceptions.c
4660         (mono_debugger_run_finally): New public method for the debugger.
4661
4662 2005-10-10  Zoltan Varga  <vargaz@gmail.com>
4663
4664         * debug-mini.c (mono_debug_init_method): Fix warning.
4665
4666         * mini.h branch-opts.c (mono_branch_optimize_exception_target): Make
4667         the 'exname' parameter const to fix some warnings.
4668
4669 2005-10-09  Zoltan Varga  <vargaz@freemail.hu>
4670
4671         * mini-exceptions.c (mono_handle_exception_internal): Fix another bug
4672         introduced by the previous patch.
4673
4674 2005-10-08  Zoltan Varga  <vargaz@gmail.com>
4675
4676         * basic-float.cs: Add test for precision of float arithmetic.
4677
4678         * mini-ia64.c (mono_arch_output_basic_block): Convert to/from doubles
4679         when loading/storing single values from/to memory.
4680
4681         * mini.c (mono_jit_compile_method_with_opt): Create the function
4682         pointers in the correct domain.
4683
4684 2005-10-08  Zoltan Varga  <vargaz@freemail.hu>
4685
4686         * mini-exceptions.c (mono_handle_exception_internal): Fix bug 
4687         introduced by previous patch.
4688         
4689         * mini-exceptions.c (mono_handle_exception_internal): Handle the case
4690         when out_filter_idx is NULL.
4691
4692         * mini-exceptions.c: Don't run filter clauses twice during exception
4693         handling. Fixes #75755.
4694
4695 2005-10-07  Zoltan Varga  <vargaz@gmail.com>
4696
4697         * aot.c: Add support for ldflda wrappers.
4698
4699         * mini.c (mono_method_to_ir): Use ldflda wrappers for CEE_LDFLDA. Fixes
4700         #75902.
4701
4702 Tue Oct 4 20:23:25 CEST 2005 Paolo Molaro <lupus@ximian.com>
4703
4704         * mini.c, mini.h: do not consider exception handlers blocks when
4705         setting up interface variables.
4706
4707 2005-10-04  Zoltan Varga  <vargaz@freemail.hu>
4708
4709         * aot.c (emit_section_change): Fix emitting of sections on win32. Fixes #76322.
4710
4711 2005-10-03  Zoltan Varga  <vargaz@gmail.com>
4712
4713         * liveness.c (mono_analyze_liveness): Revert parts of r51051 since it
4714         causes a regression.
4715
4716         * mini.c (mini_thread_cleanup): Fix reading of freed memory.
4717
4718 2005-10-02  Zoltan Varga  <vargaz@freemail.hu>
4719
4720         * mini.h (OP_PCONST): Move the definition of OP_PCONST into the rest
4721         of the OP_P definitions.
4722
4723         * TODO: Add a proposal for dealing with the CEE/OP mess.
4724
4725         * mini-amd64.c (mono_arch_output_basic_block): Merge mul_imm 
4726         optimizations from the x86 port.
4727
4728         * cpu-amd64.md: Ditto.
4729
4730         * basic.cs basic-long.cs: Add tests.
4731
4732 Fri Sep 30 20:07:20 CEST 2005 Paolo Molaro <lupus@ximian.com>
4733
4734         * Makefile.am, driver.c, mini-x86.c, mini.c, mini.h, branch-opts.c:
4735         Patrik Torstensson's implementation of my exception-handling
4736         optimization idea, when the exception object is not used
4737         (bug #62150).
4738
4739 Fri Sep 30 19:10:29 CEST 2005 Paolo Molaro <lupus@ximian.com>
4740
4741         * mini-x86.c, cpu-pentium.md: Patrik Torstensson's port
4742         of the mul_imm optimizations from the old jit.
4743
4744 Fri Sep 30 11:37:51 EDT 2005 Paolo Molaro <lupus@ximian.com>
4745
4746         * mini.c, liveness.c: patch by Patrik Torstensson and
4747         Zoltan Varga to improve performance in methods with
4748         exception clauses.
4749
4750 2005-09-30  Zoltan Varga  <vargaz@gmail.com>
4751
4752         * driver.c: Remove 'Globalization' entry from --version.
4753
4754 2005-09-28  Zoltan Varga  <vargaz@gmail.com>
4755
4756         * mini.c (mono_jit_compile_method_inner): Do not load AOT code when
4757         there is a profiler interested in JIT events.
4758
4759         * aot.c: Load profile files produced by the AOT profiling module, and
4760         reorder methods based on the profiling info. Add a 'method_order' table
4761         to the AOT file to make mono_aot_find_jit_info work with the reordered
4762         methods.
4763
4764         * mini.h: Bump AOT file version info.
4765
4766 Wed Sep 28 17:12:48 CEST 2005 Paolo Molaro <lupus@ximian.com>
4767
4768         * mini-arm.h: work around what looks like a gcc bug when optimizations
4769         are enabled.
4770
4771 2005-09-28  Raja R Harinath  <rharinath@novell.com>
4772
4773         * Makefile.am (AM_CFLAGS): Don't use += to append inside
4774         conditionals.  Use ...
4775         (PLATFORM_CFLAGS, ARCH_CFLAGS): ... these.
4776
4777 2005-09-27  Zoltan Varga  <vargaz@freemail.hu>
4778
4779         * mini-amd64.c (mono_arch_call_opcode): Use mono_class_value_size ()
4780         to determine the amount of memory to copy when passing valuetypes.
4781
4782         * inssel-amd64.brg: Remove PUSH(LDIND4) rules since they convert an
4783         4 byte load into a 8 byte load. Fix aligning of size in OP_OUTARG_VT.
4784
4785 2005-09-27  Zoltan Varga  <vargaz@gmail.com>
4786
4787         * mini.h mini.c aot.c: Add infrastructure to collect pagefault 
4788         information about aot.
4789
4790 2005-09-27  Ben Maurer  <bmaurer@ximian.com>
4791
4792         * *.c: Replace the use of {Enter,Leave}CriticalSection with
4793         macros. This will allow a deadlock debugger to easily be plugged
4794         in.
4795
4796 Tue Sep 27 09:32:11 EDT 2005 Paolo Molaro <lupus@ximian.com>
4797
4798         * mini-ppc.c, cpu-g4.md: added memory barrier instruction.
4799
4800 2005-09-27  Raja R Harinath  <rharinath@novell.com>
4801
4802         * Makefile.am (AM_CFLAGS): Rename from INCLUDES.
4803         (AM_CFLAGS) [PLATFORM_WIN32): Append to it, don't set it.
4804         (AM_CFLAGS) [ARM]: Add arch/arm directory from the build tree.
4805         ($(arch_built)) [CROSS_COMPILING]: Error out.
4806
4807 2005-09-26  Zoltan Varga  <vargaz@gmail.com>
4808
4809         * aot.c: Add support for the no_special_static flag for classes.
4810
4811 2005-09-24  Zoltan Varga  <vargaz@freemail.hu>
4812
4813         * Reapply reverted patches.
4814
4815         * *: Revert r50174 as well.
4816
4817         * mini-amd64.c cpu-amd64.md inssel-amd64.brg: Revert r50170 as well.
4818
4819 2005-09-24  Zoltan Varga  <vargaz@freemail.hu>
4820
4821         * mini-amd64.c: Revert r50342 to see if this fixed buildbot.
4822
4823 2005-09-23  Miguel de Icaza  <miguel@novell.com>
4824
4825         * mini.c (SIG_HANDLER_SIGNATURE): Only dereference info if it is
4826         part of the SIG_HANDLER_SIGNATURE.  
4827
4828 2005-09-23  Zoltan Varga  <vargaz@gmail.com>
4829
4830         * mini.h mini.c: Add a new MONO_DEBUG option to collect metadata pagefault
4831         statistics.
4832
4833         * mini-x86.c (mono_arch_call_opcode): Fix vararg calling convention 
4834         introduced by previous patch.
4835
4836 2005-09-21  Zoltan Varga  <vargaz@gmail.com>
4837
4838         * tramp-x86.c (mono_arch_create_trampoline_code): Restore caller
4839         saved registers too.
4840
4841         * mini-x86.c (mono_arch_allocate_vars): Rewrite this so it works based 
4842         upon the information returned by get_call_info ().
4843         
4844         * mini-x86.c (add_float): Fix stack size calculation.
4845         (mono_arch_call_opcode): Rewrite this so it works based up the
4846         information returned by get_call_info ().
4847         (mono_arch_get_this_vret_args): Ditto.
4848
4849 2005-09-21  Zoltan Varga  <vargaz@freemail.hu>
4850
4851         * mini-amd64.c (mono_arch_emit_this_vret_args): Use the information
4852         in cinfo to determine the registers which need to be used.
4853
4854 2005-09-20  Miguel de Icaza  <miguel@novell.com>
4855
4856         * driver.c (mono_main): Add --server and --desktop flags. 
4857
4858 2005-09-16  Zoltan Varga  <vargaz@gmail.com>
4859
4860         * mini-ia64.h: Make register masks 64 bit. Don't treat argument
4861         registers as global registers.
4862
4863         * inssel-ia64.brg (stmt): Remove OP_OUTARG_REG () rules which are no 
4864         longer needed with the new register allocator.
4865
4866         * mini-ia64.c: Use OP_MOVE instead of OP_SETREG for reg-reg moves.
4867
4868         * cpu-ia64.md: Remove unused opcodes.
4869         
4870         * regalloc.c mini-codegen.c: Make register masks 64 bit on ia64.
4871         
4872 2005-09-16  Zoltan Varga  <vargaz@freemail.hu>
4873
4874         * cpu-amd64.md: Remove unused opcodes.
4875
4876         * inssel-amd64.brg: Remove OP_OUTARG_REG () rules which are no longer
4877         needed with the new register allocator.
4878
4879         * inssel-amd64.brg mini-amd64.c: Use OP_MOVE instead of OP_SETREG for
4880         reg-reg moves.
4881
4882 2005-09-16  Raja R Harinath  <rharinath@novell.com>
4883
4884         * Makefile.am (check-local): Don't invoke semdel-wrapper.
4885
4886 2005-09-16  Martin Baulig  <martin@ximian.com>
4887
4888         * exceptions-amd64.c
4889         (throw_exception): Don't call mono_debugger_throw_exception() if
4890         we're a rethrow - see the FIXME in the code.
4891
4892 2005-09-15  Geoff Norton  <gnorton@customerdna.com>
4893
4894         * mini.c (mono_init_exceptions): This only works on some architectures.
4895         
4896 2005-09-15  Zoltan Varga  <vargaz@gmail.com>
4897
4898         * mini.c (mono_method_to_ir): Add OP_LMUL imm -> OP_LMUL_IMM conversion
4899         on ia64.
4900
4901         * inssel-long.brg mini-ia64.c: Add OP_LMUL_IMM rules.
4902
4903         * mini-ia64.h mini-ia64.c: Remove the altstack support code which is
4904         now in mini-exceptions.c.
4905
4906 2005-09-15  Zoltan Varga  <vargaz@freemail.hu>
4907
4908         * mini-amd64.h mini-am64.c: Remove the altstack support code which is
4909         now in mini-exceptions.c.
4910
4911 2005-09-15  Zoltan Varga  <vargaz@gmail.com>
4912
4913         * exceptions-x86.c: Applied patch from Patrik Torstensson 
4914         <patrik.torstensson@gmail.com>. Add stack overflow handling support for win32.
4915
4916         * mini-exceptions.c mini-x86.c mini.c: Move the altstack setup/teardown
4917         code into mini-exceptions.c. Add some assertions to it.
4918
4919 2005-09-12  Zoltan Varga  <vargaz@gmail.com>
4920
4921         * aot.c (emit_section_change): Applied patch from "The Software Team" 
4922         (<software@solmersa.com>). Fix as errors on windows.
4923
4924 2005-09-11  Zoltan Varga  <vargaz@freemail.hu>
4925
4926         * tramp-amd64.c (mono_arch_create_trampoline_code): Fix saving of
4927         method info into the LMF.
4928
4929 2005-09-11  Zoltan Varga  <vargaz@gmail.com>
4930         
4931         * mini-ia64.c: Add proper unwind info for method epilogs.
4932
4933         * exceptions-ia64.c: Add some code to help debugging.
4934         
4935         * mini-ia64.c mini-ia64.h: Add sigaltstack support.
4936
4937         * mini-exceptions.c: Fix warning.
4938
4939 2005-09-11  Zoltan Varga  <vargaz@freemail.hu>
4940
4941         * mini.c: Really fix build.
4942
4943         * mini-x86.c mini-amd64.c: Fix build.
4944
4945 2005-09-11  Zoltan Varga  <vargaz@gmail.com>
4946
4947         * mini-ia64.c inssel-ia64.brg: Add InterlockedExchange instrinsics.
4948
4949         * mini-ops.h cpu-ia64.md inssel-ia64.brg mini-ia64.c: Implement
4950         some Interlocked methods as intrinsics.
4951
4952         * mini.c (mini_get_inst_for_method): Call arch_get_inst_for_method
4953         for Thread methods as well.
4954
4955         * mini-ops.h: Add OP_MEMORY_BARRIER opcode.
4956
4957         * inssel.brg: Add rule for OP_MEMORY_BARRIER.
4958
4959         * mini-ia64.c mini-x86.c mini-amd64.c 
4960         cpu-ia64.md cpu-pentium.md cpu-amd64.md: Add implementation of 
4961         OP_MEMORY_BARRIER.
4962         
4963         * mini.c (mono_init_exceptions): Fix build breakage.
4964
4965 2005-09-10  Zoltan Varga  <vargaz@gmail.com>
4966
4967         * mini-ia64.c exceptions-ia64.c tramp-ia64.c: Remove 'manual' emitting
4968         of instructions. Use the new ia64_unw_op macros for emitting unwind
4969         info.
4970
4971         * mini.c (mono_init_exceptions): Initialize exception handling
4972         related trampolines at startup.
4973
4974 Fri Sep 9 19:30:37 BST 2005 Paolo Molaro <lupus@ximian.com>
4975
4976         * cpu-arm.md, mini-arm.c: fix for dynamic code (Gtk# apps).
4977
4978 2005-09-09  Zoltan Varga  <vargaz@gmail.com>
4979
4980         * mini.c: Handle type loading errors gracefully during compilation and
4981         throw the appropriate exception.
4982
4983 Fri Sep 9 09:49:14 CEST 2005 Paolo Molaro <lupus@ximian.com>
4984
4985         * ldscript.mono, Makefile.am: use anonymous versions in the ldscript
4986         for the mono binary.
4987
4988 2005-09-09  Martin Baulig  <martin@ximian.com>
4989
4990         * mini.c (mono_method_to_ir): Comment out the G_BREAKPOINT()'s for
4991         the release.
4992
4993 Thu Sep 8 14:53:45 BST 2005 Paolo Molaro <lupus@ximian.com>
4994
4995         * mini-arm.h: use emulation for conv.r.un for the release.
4996
4997 Thu Sep 8 11:28:45 BST 2005 Paolo Molaro <lupus@ximian.com>
4998
4999         * mini-arm.c, objects.cs: more fixes and tests for them.
5000
5001 Wed Sep 7 17:14:26 BST 2005 Paolo Molaro <lupus@ximian.com>
5002
5003         * mini-arm.c: align structures to at least 4 bytes to be able
5004         to keep our current optimized memcpy.
5005
5006 Tue Sep 6 22:51:08 BST 2005 Paolo Molaro <lupus@ximian.com>
5007
5008         * mini-arm.c, cpu-arm.md, inssel-arm.brg: bugfixes.
5009
5010 2005-09-05 Gonzalo Paniagua Javier <gonzalo@ximian.com>
5011
5012         * mini.c: ignore SIGPIPE.
5013
5014 2005-09-04  Zoltan Varga  <vargaz@gmail.com>
5015
5016         * mini-ia64.c (mono_arch_lowering_pass): Convert 'and_imm 255' to zext1.
5017
5018         * mini-ia64.h mini-ia64.c: Add some minor optimizations.
5019
5020 2005-09-02  Zoltan Varga  <vargaz@gmail.com>
5021
5022         * mini.h: Add prototype for mono_allocate_stack_slots_full.
5023
5024 Thu Sep 1 21:05:26 BST 2005 Paolo Molaro <lupus@ximian.com>
5025
5026         * exceptions-arm.c, mini.c, mini-arm.c, mini-arm.h:
5027         exception handling support.
5028         * mini-arm.c, mini-arm.h: bigendian fixes (partially from a
5029         patch by Brian Koropoff <briank@marakicorp.com>).
5030
5031 Thu Sep 1 10:22:44 EDT 2005 Paolo Molaro <lupus@ximian.com>
5032
5033         * mini.c: revert another 'optimization' which breaks when
5034         items on the eval stack need to be saved at a basic block end
5035         (bug #75940).
5036
5037 Wed Aug 31 17:29:32 CEST 2005 Paolo Molaro <lupus@ximian.com>
5038
5039         * jit-icalls.c: for arrays, ensure we always provide
5040         lower bounds.
5041
5042 2005-08-30  Zoltan Varga  <vargaz@gmail.com>
5043
5044         * mini.c (mono_allocate_stack_slots_full): Fix ia64 build.
5045         
5046         * mini.c (mini_get_inst_for_method): Special case Object:.ctor as well.
5047
5048 2005-08-29  Zoltan Varga  <vargaz@gmail.com>
5049
5050         * mini-ia64.h mini-ia64.c: Implement frame pointer elimination. Keep
5051         arguments in their original register.
5052
5053 2005-08-28  Zoltan Varga  <vargaz@gmail.com>
5054
5055         * mini-ops.h cpu-ia64.md inssel-ia64.brg mini-ia64.c: Optimize
5056         memset/memcpy.
5057
5058         * mini.c (mono_method_to_ir): Disable the MUL->MUL_IMM optimization
5059         when ssapre is enabled.
5060
5061         * inssel-long.brg: Fix bug in previous patch.
5062
5063         * mini-ia64.c mini-ia64.h mini.c inssel-long.brg: Optimize 
5064         multiplication by a constant.
5065
5066 2005-08-27  Zoltan Varga  <vargaz@gmail.com>
5067
5068         * mini-ia64.c (mono_arch_setup_jit_tls_data): Add support for intel
5069         icc.
5070
5071         * tramp-ia64.c (mono_arch_create_trampoline_code): Use st8.spill for
5072         saving registers.
5073
5074 Fri Aug 26 11:09:28 BST 2005 Paolo Molaro <lupus@ximian.com>
5075
5076         * inssel-arm.brg: apply changes tested by Brian Koropoff
5077         <briank@marakicorp.com>.
5078
5079 2005-08-25  Zoltan Varga  <vargaz@gmail.com>
5080
5081         * mini-x86.c (mono_arch_emit_prolog): Fix calling of mono_jit_thread_attach () under windows.
5082         
5083 2005-08-24  Zoltan Varga  <vargaz@gmail.com>
5084
5085         * mini-codegen.c (mono_local_regalloc): Avoid allocating dreg and sreg1/2
5086         to the same register if dreg is just a base register.
5087         (print_ins): Improve printing of membase opcodes.
5088
5089         * inssel-x86.brg: Add optimized ldind(reg) rules.
5090
5091         * mini-x86.c cpu-pentium.md: Changes required to support the new rules.
5092
5093 Wed Aug 24 19:39:36 CEST 2005 Paolo Molaro <lupus@ximian.com>
5094
5095         * mini.c: when running under valgrind, set the stack bottom for
5096         the GC at the actual approximate stack for the app (fixes running
5097         mono with valgrind).
5098
5099 Tue Aug 23 21:38:50 CEST 2005 Paolo Molaro <lupus@ximian.com>
5100
5101         * mini.c: do no break at the first valuetype to init found
5102         (fixes bug #75791).
5103
5104 Tue Aug 23 16:53:21 BST 2005 Paolo Molaro <lupus@ximian.com>
5105
5106         * cpu-arm.md, mini-arm.c: more fixes and LMF support.
5107
5108 Tue Aug 23 15:11:44 CEST 2005 Paolo Molaro <lupus@ximian.com>
5109
5110         * cpu-g4.md: fixed instruction length exposed by the nemerle compiler.
5111
5112 2005-08-23  Zoltan Varga  <vargaz@freemail.hu>
5113
5114         * inssel-amd64.brg inssel-x86.brg: Fix the fcall rules.
5115
5116 2005-08-22  Zoltan Varga  <vargaz@freemail.hu>
5117
5118         * inssel-x86.brg: Fix assert in patch_delegate_trampoline.
5119
5120         * tramp-x86.c (mono_arch_patch_delegate_trampoline): Add some debug
5121         code.
5122
5123         * tramp-amd64.c (mono_arch_patch_delegate_trampoline): Add some debug
5124         code.
5125
5126         * mini.c (optimize_branches): Don't quit after 1000 iterations on large
5127         methods.
5128
5129 Mon Aug 22 19:16:29 BST 2005 Paolo Molaro <lupus@ximian.com>
5130
5131         * tramp-arm.c: allocate less memory for the trampoline and fix typo.
5132
5133 2005-08-22  Zoltan Varga  <vargaz@freemail.hu>
5134
5135         * mini.c (mono_method_to_ir): Remove instructions inserted after a branch
5136         in the tail recursion optimization.
5137
5138         * mini.h helpers.c (mono_disassemble_code): Emit starts of basic blocks as 
5139         debug info into the assembly file.
5140
5141         * iltests.il: Add test for filter regions.
5142
5143         * mini.c (mono_method_to_ir): Fix handling of nested FILTER clauses. Fix
5144         initial stack of filter regions. Fixes #75755.
5145
5146 Mon Aug 22 17:49:16 BST 2005 Paolo Molaro <lupus@ximian.com>
5147
5148         * mini-arm.c, cpu-arm.c: fixes and support for methods with bigger
5149         stack requirements.
5150
5151 2005-08-22  Zoltan Varga  <vargaz@freemail.hu>
5152
5153         * mini.c (mono_create_delegate_trampoline): Fix memory leak. Put back
5154         the check for an already compiled method on non-ia64 platforms.
5155         (mono_create_jump_trampoline): Store the MonoJitInfo structure into the
5156         proper domain.
5157
5158         * mini-x86.h tramp-x86.c: Add support for delegate trampolines.
5159
5160         * inssel-x86.brg: Add some optimized call rules.
5161
5162 2005-08-21  Zoltan Varga  <vargaz@freemail.hu>
5163
5164         * mini.c (mono_create_delegate_trampoline): Do not return an already compiled
5165         method here.
5166
5167         * mini.h mini-trampolines.c: Pass the trampoline argument to 
5168         mono_arch_patch_delegate_trampoline.
5169
5170         * mini-ia64.h mini-ia64.c tramp-ia64.c: Add support for delegate trampolines.
5171
5172         * mini-trampolines.c: Fix build.
5173
5174         * mini-amd64.h: Add delegate trampolines.
5175
5176         * mini.h mini.c mini-trampolines.c tramp-amd64.c: Add delegate trampolines.
5177
5178         * inssel-amd64.brg: Add optimized call rules.
5179         
5180         * mini-ia64.c tramp-ia64.c: Improve instruction scheduling.
5181
5182         * inssel-ia64.brg: Add optimized ldind(reg) rules.
5183
5184 2005-08-20  Zoltan Varga  <vargaz@freemail.hu>
5185
5186         * mini.c (mono_create_class_init_trampoline): Fix bug caused by last
5187         change.
5188
5189         * mini-ia64.c: Remove LMF fixmes.
5190
5191         * mini-ia64.h: Remove most fields from LMF.
5192
5193         * inssel-ia64.brg (stmt): Fix unaligned access errors.
5194
5195         * mini-trampolines.c: Add support for IA64 function descriptors.
5196
5197         * mini.h mini.c jit-icalls.c exceptions-ia64.cdriver.c: Add support
5198         for IA64 function descriptors.
5199
5200 Sat Aug 20 16:51:44 BST 2005 Paolo Molaro <lupus@ximian.com>
5201
5202         * tramp-arm.c: patch the vtable for virtual calls. Added
5203         support code to register/unregister the LMF.
5204         * mini-arm.c, mini-arm.h: warning fixes, fixes, speedups,
5205         more LMF work.
5206
5207 2005-08-19  Dick Porter  <dick@ximian.com>
5208
5209         * mini.c: Use a gsize to store the thread ID, so it can hold a 64
5210         bit value if needed.
5211
5212 2005-08-19  Zoltan Varga  <vargaz@freemail.hu>
5213
5214         * mini.c (mini_get_method): Move handling of wrapper data here.
5215
5216         * mini.c (mono_method_to_ir): Add support for dynamic methods.
5217
5218         * mini.c (mono_method_to_ir): Convert nonvirtual calls to abstract methods into
5219         virtual.
5220
5221         * mini.c (mono_method_to_ir): Emit IR for CEE_NOP as well, so 
5222         bblock->code does not remain empty.
5223
5224 2005-08-17  Zoltan Varga  <vargaz@freemail.hu>
5225
5226         * arrays.cs: Add regression test for #75832.
5227
5228         * inssel-amd64.brg cpu-amd64.md mini-amd64.c: Fix LDELEMA optimization
5229         rules. Fixes #75832.
5230
5231         * mini-ia64.c tramp-ia64.c exceptions-ia64.c: Implement improved
5232         instruction scheduling.
5233
5234 2005-08-12  Zoltan Varga  <vargaz@freemail.hu>
5235
5236         * mini-exceptions.c (ves_icall_get_frame_info): Fix IA64 build.
5237
5238 2005-08-11  Zoltan Varga  <vargaz@freemail.hu>
5239
5240         * mini-exceptions.c mini-x86.h: Move VC stuff into macros in mini-x86.h.
5241
5242         * mini-codegen.c: Fix VC build.
5243
5244         * cpu-pentium.md: Increase length of atomic_exhange_i4.
5245
5246 2005-08-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
5247
5248         * mini.h: fix signature for mono_register_opcode_emulation.
5249
5250 2005-08-09  Zoltan Varga  <vargaz@freemail.hu>
5251
5252         * mini.c: Get rid of most of the helper_sig_... constants using
5253         mono_create_icall_signature ().
5254
5255 2005-08-08  Zoltan Varga  <vargaz@freemail.hu>
5256
5257         * jit-icalls.c (helper_ldstr): New helper function.
5258
5259         * mini.c (get_basic_blocks): Set out_of_line for bblocks containing a throw.
5260
5261         * mini.c (mono_method_to_ir): If an LDSTR instruction is in a bblock with a
5262         throw, load the string using a helper call instead of creating a string object.
5263
5264         * aot.c: Update after LDSTR changes.
5265
5266         * mini.h: Bump AOT file version.
5267         
5268         * aot.c: Save class size info into the AOT file. Print more statistics during
5269         compilation.
5270
5271         * mini.h: Bump AOT file version.
5272
5273         * tramp-amd64.c (mono_arch_nullify_class_init_trampoline): Fix
5274         ordering of disasm cases. Fixes #74957.
5275
5276 Thu Aug 4 19:47:24 BST 2005 Paolo Molaro <lupus@ximian.com>
5277
5278         * mini-ops.h, mini-arch.h, inssel.brg, mini.c, mini.h,
5279         jit-icalls.c, mini-codegen.c, Makefile.am: changes in
5280         the generic code needed for the ARM port.
5281
5282 Thu Aug 4 19:42:54 BST 2005 Paolo Molaro <lupus@ximian.com>
5283
5284         * exceptions-arm.c, tramp-arm.c, mini-arm.c, mini-arm.h, cpu-arm.md,
5285         inssel-arm.brg: more ARM features and fixes.
5286
5287 Mon Aug 1 18:37:38 BST 2005 Paolo Molaro <lupus@ximian.com>
5288
5289         * tramp-arm.c, mini-arm.c, cpu-arm.md, inssel-arm.brg: more
5290         ARM port work in progress.
5291
5292 2005-07-30  Zoltan Varga  <vargaz@freemail.hu>
5293
5294         * mini-ia64.c (mono_arch_call_opcode): Ongoing IA64 work.
5295
5296         * mini-exceptions.c mini-ia64.h: Ongoing IA64 work.
5297
5298         * mini-ia64.c (ia64_emit_bundle): Ongoing IA64 work.
5299
5300         * inssel.brg (mini_emit_memset): Add support for unaligned access.
5301
5302         * *-ia64.*: Ongoing IA64 work.
5303         
5304         * mini-ia64.c exceptions-ia64.c: Ongoing IA64 work.
5305
5306 2005-07-28  Zoltan Varga  <vargaz@freemail.hu>
5307
5308         * TODO: Remove out-of-data todo stuff.
5309
5310         * mini.h mini.c (mono_create_jit_trampoline_from_token): Remove some
5311         dead code.
5312
5313         * aot.c: Save/load MonoCachedClassInfo->has_nested_classes.
5314
5315         * mini.h: Bump corlib version.
5316
5317 2005-07-27  Martin Baulig  <martin@ximian.com>
5318
5319         * mini-codegen.c
5320         (create_copy_ins): Added `const unsigned char *ip' argument; set
5321         `copy->cil_code' from it.
5322
5323 2005-07-27  Martin Baulig  <martin@ximian.com>
5324
5325         * mini-exceptions.c (mono_handle_exception): Don't call
5326         mono_debugger_handle_exception() for filters.
5327
5328 2005-07-27  Zoltan Varga  <vargaz@freemail.hu>
5329
5330         * mini-trampolines.c (mono_aot_trampoline): Handle AppDomain:InvokeInDomain
5331         as well.
5332
5333 2005-07-26  Martin Baulig  <martin@ximian.com>
5334
5335         Committing a patch from Michal Moskal <michal.moskal@gmail.com>.
5336
5337         * mini.c (mono_method_to_ir): In `CEE_CALLI', only use
5338         helper_compile_generic_method() if the method is actually virtual
5339         and non-final.
5340
5341 2005-07-26  Martin Baulig  <martin@ximian.com>
5342
5343         * mini.c
5344         (trampoline_code): Renamed to `mono_trampoline_code' and made it
5345         public; this is now accessed directly by the debugger.
5346         (mono_generic_trampoline_code): Removed.
5347
5348         * debug-mini.c
5349         (mono_debug_init_method): Also add interncalls and wrappers.
5350
5351 2005-07-23  Zoltan Varga  <vargaz@freemail.hu>
5352
5353         * mini-ia64.c mini-ia64.h: Add support for tracing/profiling.
5354
5355 2005-07-22  Zoltan Varga  <vargaz@freemail.hu>
5356
5357         * aot.c (mono_aot_get_method_from_token): Fix a potential crash here.
5358
5359 2005-07-21  Zoltan Varga  <vargaz@freemail.hu>
5360
5361         * aot.c (load_patch_info): Fix handling of stfld_remote wrapper.
5362
5363 2005-07-20  Zoltan Varga  <vargaz@freemail.hu>
5364
5365         * mini-amd64.c (mono_arch_setup_jit_tls_data): Use the nice way of
5366         getting TLS offsets on AMD64 too.
5367
5368 2005-07-20  Kornél Pál <kornelpal@hotmail.com>
5369
5370         * driver.c: Detach console when executing IMAGE_SUBSYSTEM_WINDOWS_GUI on win32
5371
5372 Wed Jul 20 18:05:19 BST 2005 Paolo Molaro <lupus@ximian.com>
5373
5374         * exceptions-arm.c, mini-arm.c, tramp-arm.c, cpu-arm.md,
5375         inssel-arm.brg, mini-arm.h: ARM port work in progress.
5376
5377 2005-07-20  Zoltan Varga  <vargaz@freemail.hu>
5378
5379         * tramp-amd64.c (mono_arch_create_specific_trampoline): Fix build.
5380
5381         * mini.h mini.c mini-*.h tramp-*.c: Move more cross platform trampoline code
5382         to mini.c.
5383
5384         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Call 
5385         mono_sparc_is_virtual_call ().
5386         
5387         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Fix warning.
5388
5389         * tramp-sparc.c (mono_arch_create_trampoline_code): Fix order of
5390         trampoline parameters.
5391
5392         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Fix signature.
5393         
5394         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Rename this
5395         to mono_arch_get_vcall_slot_addr.
5396
5397         * Makefile.am tramp-sparc.c: Update the sparc port to use the generic
5398         trampoline code.
5399
5400         * *-sparc.*: Merge the mini-xp-regalloc branch for sparc.
5401
5402 2005-07-19  Zoltan Varga  <vargaz@freemail.hu>
5403
5404         * mini-ia64.h mini-ia64.c: Finish pinvoke support.
5405
5406 2005-07-19  Martin Baulig  <martin@ximian.com>
5407
5408         * exceptions-amd64.c (throw_exception): Call
5409         mono_debugger_throw_exception() here like we're doing it on i386.
5410
5411 2005-07-19  Zoltan Varga  <vargaz@freemail.hu>
5412
5413         * mini-ia64.c: Add optimized TLS access support.
5414
5415 2005-07-18  Zoltan Varga  <vargaz@freemail.hu>
5416
5417         * mini-exceptions.c: Ongoing IA64 work.
5418
5419         * mini-ia64.c inssel-long.brg: Ongoing IA64 work.
5420
5421         * mini.c: Use the default optimization set when embedding. Fixes
5422         #75194.
5423
5424 2005-07-11  Zoltan Varga  <vargaz@freemail.hu>
5425
5426         * tramp-amd64.c tramp-ia64.c Makefile.am: Move arch independent parts 
5427         of trampolines to a separate file.
5428
5429         * mini-trampolines.c: New file.
5430
5431         * mini.h tramp-x86.c: Move arch independent parts of trampolines to a 
5432         separate file.
5433         
5434         * tramp-x86.c: Reorganize the trampoline code to be similar to the 
5435         amd64/ia64 code.
5436
5437         * mini-codegen.c: Fix cygwin build.
5438
5439 2005-07-10  Zoltan Varga  <vargaz@freemail.hu>
5440
5441         * mini.c: Add some minor changes needed by the IA64 port.
5442
5443         * *-ia64.*: Ongoing IA64 work.
5444
5445 2005-07-09  Zoltan Varga  <vargaz@freemail.hu>
5446
5447         * tramp-amd64.c mini-amd64.c: Update after latest AOT changes. Split 
5448         trampolines into arch-independent and arch-dependent parts.
5449
5450         * mini-amd64.c (mono_arch_lowering_pass): Fix store_membase_imm -> store_membase_reg rule.
5451
5452 2005-07-08  Zoltan Varga  <vargaz@freemail.hu>
5453
5454         * cpu-amd64.md: Merge the xp-regalloc-branch for amd64.
5455
5456         * mini-ops.h mini-amd64.h mini-amd64.c inssel-amd64.brg Makefile.am: Merge
5457         the xp-regalloc-branch for amd64.
5458
5459         * mini-x86.h mini-x86.c cpu-pentium.md Makefile.am: Merge the
5460         xp-regalloc-branch for x86.
5461
5462 2005-07-07  Zoltan Varga  <vargaz@freemail.hu>
5463
5464         * inssel.brg (OP_THROW_OR_NULL): Allways rethrow the abort exception.
5465
5466 2005-07-06  Martin Baulig  <martin@ximian.com>
5467
5468         * mini.c
5469         (mono_jit_compile_method_inner): Call mono_get_inflated_method().
5470         (mono_jit_runtime_invoke): Likewise.
5471
5472 2005-07-05  Zoltan Varga  <vargaz@freemail.hu>
5473
5474         * aot.c (mono_compile_assembly): Allocate the GOT in the .bss segment
5475         on x86 too.
5476         
5477         * aot.c: Add new mono_aot_get_method_from_token () function to load AOT methods
5478         without loading their metadata. Reorganize the file format so exception handling+
5479         debug info is kept separate from normal method info. Create MonoJitInfo 
5480         structures for methods lazily.
5481
5482         * tramp-x86.c (x86_aot_trampoline): Use the new from_token method to avoid
5483         loading metadata.
5484         (x86_class_init_trampoline): Patch AOT class init trampolines too.
5485
5486         * mini.c (mini_init): Install the new mono_aot_find_jit_info hook.
5487
5488         * mini.c (mono_method_to_ir): Reduce the number of class init trampoline calls
5489         in AOT code.
5490
5491         * mini.h: Bump AOT file version.
5492
5493 2005-07-04  Zoltan Varga  <vargaz@freemail.hu>
5494
5495         * mini-x86.c (peephole_pass): Fix the loadi1/loadi2 rules.
5496
5497 2005-07-01  Raja R Harinath  <rharinath@novell.com>
5498
5499         * Makefile.am (check-local): Call semdel-wrapper.
5500
5501 2005-06-29  Zoltan Varga  <vargaz@freemail.hu>
5502
5503         * mini-x86.c: Revert the last change as it seems to break the build..
5504
5505 2005-06-28  Zoltan Varga  <vargaz@freemail.hu>
5506
5507         * mini-x86.c (peephole_pass): Fix the loadi1/loadi2 rules.
5508         
5509         * mini-x86.c (mono_arch_cpu_init): Fix setting of fp precision in the VC build.
5510
5511 2005-06-27  Ben Maurer  <bmaurer@ximian.com>
5512
5513         * mini.c (NEW_AOTCONST): make sure to call mono_get_got_var
5514         outside of the macro, so strange stuff doesn't happen with gcc4
5515         (NEW_AOTCONST_TOKEN): Likewise.
5516
5517 2005-06-28  Martin Baulig  <martin@ximian.com>
5518
5519         * mini.c (mini_class_is_system_array): New static method; use this
5520         instead of `klass->parent == mono_defaults.array_class' everywhere
5521         since this also works for the new generic array class.
5522
5523 2005-06-26  Ben Maurer  <bmaurer@ximian.com>
5524
5525         * inssel.brg: Remove warnings.
5526
5527 2005-06-24  Zoltan Varga  <vargaz@freemail.hu>
5528
5529         * mini-ia64.c: Ongoing IA64 work.
5530
5531         * basic-float.cs: Add float->i1 conversion test.
5532
5533         * iltests.il: Add conv.u4 test.
5534
5535 2005-06-23  Zoltan Varga  <vargaz@freemail.hu>
5536
5537         * inssel-long.brg: Fix bug caused by last change.
5538
5539 2005-06-23  Geoff Norton  <gnorton@customerdna.com>
5540
5541         * mini-x86.h: Add __APPLE__ to the SC_* redefines with the other 
5542         BSDs.  Allows the x86 JIT to work on OSX86
5543
5544 2005-06-22  Zoltan Varga  <vargaz@freemail.hu>
5545
5546         * inssel-long.brg: Use OP_LSHR_UN_IMM instead of OP_SHR_UN_IMM in
5547         u4->i8 conversion.
5548
5549         * mini-ia64.c: Ongoing IA64 work.
5550
5551 2005-06-19  Zoltan Varga  <vargaz@freemail.hu>
5552
5553         * mini-ia64.c: Ongoing IA64 work.
5554
5555         * driver.c: Clean up jit_code_hash as well when using --regression.
5556
5557         * inssel-long.brg: Fix long->i4/u4 conversion rules.
5558
5559         * basic-long.cs: Add tests for long->u4 conversion.
5560
5561 2005-06-18  Ben Maurer  <bmaurer@ximian.com>
5562
5563         * mini.c: Take mono_get_domainvar out of macros. This makes sure
5564         that we do not depend on undefined C behavior: the order stuff
5565         gets evaluated within an expression. Fixes mono when compiled on
5566         GCC 4.
5567
5568 2005-06-18  Zoltan Varga  <vargaz@freemail.hu>
5569
5570         * *-ia64.*: Ongoing IA64 work.
5571
5572         * aot.c: Lower memory usage while loading AOT methods.
5573
5574         * tramp-x86.c: Avoid allocating+freeing MonoJitInfo structures.
5575
5576         * mini.h: Bump AOT file format version.
5577
5578 2005-06-17  Zoltan Varga  <vargaz@freemail.hu>
5579
5580         * mini.c (mono_method_to_ir): Allow STACK_PTR as input to SWITCH.
5581
5582 2005-06-16  Sebastien Pouliot  <sebastien@ximian.com>
5583
5584         * declsec.c: Fixed APTC to check for FullTrust on caller assembly (and
5585         not on callee assembly). Fixed some comments.
5586
5587 2005-06-16  Zoltan Varga  <vargaz@freemail.hu>
5588
5589         * aot.c (mono_compile_assembly): Mark the "methods" symbol as a function so
5590         it gets proper disassembly.
5591         (emit_method_info): Remove some dead code.
5592
5593         * mini.c (mini_method_compile): Allways allocate the GOT var in
5594         mono_method_to_ir for emulating opcodes.
5595
5596 2005-06-13  Zoltan Varga  <vargaz@freemail.hu>
5597
5598         * mini.c (mono_jit_free_method): Remove the method from the JitInfo table
5599         before freeing the code memory. Fixes #74990.
5600
5601         * objects.cs: Add regression test for #74992.
5602
5603         * liveness.c: Extend live ranges of arguments to the beginning of the
5604         method. Fixes #74992.
5605
5606         * exceptions-ia64.c mini-ia64.h: Modify ip during exception handling
5607         so it points into the faulting instruction.
5608
5609 2005-06-12  Zoltan Varga  <vargaz@freemail.hu>
5610
5611         * jit-icalls.c (mono_imul_ovf): Add exception handling.
5612
5613         * *-ia64.*: Ongoing IA64 work.
5614
5615         * mini.c (mini_init): Fix signature of mono_delegate_ctor.
5616
5617 2005-06-11  Zoltan Varga  <vargaz@freemail.hu>
5618
5619         * mini-ia64.h exceptions-ia64.c: Ongoing IA64 work.
5620
5621         * *-ia64.*: Ongoing IA64 work.
5622
5623 2005-06-10  Zoltan Varga  <vargaz@freemail.hu>
5624
5625         * basic-long.cs: Add tests for add/sub.ovf.
5626
5627         * basic.cs: Add tests for sub.ovf.
5628
5629         * *-ia64.*: Ongoing IA64 work.
5630
5631 2005-06-09  Zoltan Varga  <vargaz@freemail.hu>
5632
5633         * *-ia64.*: Ongoing IA64 work.
5634
5635         * basic.cs: Add conv.ovf.i4.un test.
5636
5637 2005-06-09  Massimiliano Mantione  <massi@ximian.com>
5638
5639         * mini.c: (remove_block_if_useless) Fixed bug 75061.
5640         
5641 2005-06-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
5642
5643         * mini.c: no SIGUSR2 on windows. Remove it for PLATFORM_WIN32.
5644
5645 2005-06-07  Zoltan Varga  <vargaz@freemail.hu>
5646
5647         * *-ia64.*: Ongoing IA64 work.
5648
5649 2005-06-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
5650
5651         * trace.[ch]:
5652         * mini.c: added the ability to toggle trace on/off using SIGUSR2.
5653
5654 2005-06-04  Zoltan Varga  <vargaz@freemail.hu>
5655
5656         * mini-ia64.c mini-ia64.h: Fix cleanup of memory stack.
5657
5658 2005-06-03  Zoltan Varga  <vargaz@freemail.hu>
5659
5660         * mini-amd64.c (emit_call): Fix yet another bug in the near call optimization.
5661
5662         * mini-amd64.c (amd64_patch): Add an assert to check that the destination
5663         of a call is callable by a near call.
5664
5665 2005-05-31  Zoltan Varga  <vargaz@freemail.hu>
5666
5667         * mini-ia64.c: Ongoing IA64 work.
5668
5669 2005-05-29  Zoltan Varga  <vargaz@freemail.hu>
5670
5671         * genmdesc.c: Make the generated array non-static.
5672
5673         * inssel-long.brg: Fix LSHR_IMM rule.
5674
5675         * *-ia64.*: Ongoing IA64 work.
5676
5677         * *-ia64.*: Ongoing IA64 work.
5678
5679 2005-05-28  Zoltan Varga  <vargaz@freemail.hu>
5680
5681         * *-ia64.*: Ongoing IA64 work.
5682
5683         * *-ia64.*: Ongoing IA64 work.
5684         
5685         * mini-ia64.c: Ongoing IA64 work.
5686
5687         * *-ia64.* jit-icalls.c mini-codegen.c: Ongoing IA64 work.
5688
5689 2005-05-28  Zoltan Varga  <vargaz@freemail.hu>
5690
5691         * objects.cs basic-calls.cs: Move some tests to objects.cs.
5692         
5693         * objects.cs basic-long.cs: Move some tests to objects.cs.
5694
5695 2005-05-26  Zoltan Varga  <vargaz@freemail.hu>
5696
5697         * *-ia64.*: Ongoing IA64 work.
5698
5699         * iltests.il: Add a new test.
5700
5701         * mini.c (mono_method_to_ir): Initialize valuetypes when created using
5702         newobj. Fixes #75042.
5703
5704 2005-05-22  Zoltan Varga  <vargaz@freemail.hu>
5705
5706         * *-ia64.*: Ongoing IA64 work.
5707         
5708         * *-ia64.*: Ongoing IA64 work.
5709         
5710         * *-ia64.*: Ongoing IA64 work.
5711
5712         * basic.cs objects.cs: Move tests accessing static variables as well.
5713
5714         * basic.cs objects.cs: Move test_0_pin_string to objects.cs.
5715
5716 2005-05-21  Zoltan Varga  <vargaz@freemail.hu>
5717
5718         * mini.c (SIG_HANDLER_SIGNATURE): Fix warning.
5719
5720         * driver.c: Always print failed tests.
5721
5722         * mini-codegen.c: Use cfg->frame_reg instead of a macro for the
5723         frame pointer.
5724
5725         * *ia64*: Ongoing IA64 work.
5726
5727 2005-05-20  Zoltan Varga  <vargaz@freemail.hu>
5728
5729         * basic.cs: Add tests for add.ovf. Fix warnings.
5730
5731 2005-05-18  Miguel de Icaza  <miguel@novell.com>
5732
5733         * driver.c (mono_main): Avoid crash if no argument is passed to
5734         --break;  Do not use g_error, but f_printf.   And fix all other
5735         ocurrences of the same crash.
5736
5737 2005-05-17  Zoltan Varga  <vargaz@freemail.hu>
5738
5739         * mini.h mini.c: Generalize the existing uses of the MONO_DEBUG env variable
5740         and add a new one: aborting when a SIGSEGV is raised while in unmanaged code.
5741         Fixes #74742.
5742
5743 2005-05-14  Zoltan Varga  <vargaz@freemail.hu>
5744
5745         * *-ia64.*: Add beginnings of IA64 backend.
5746
5747         * Makefile.am mini-arch.h mini-codegen.c: Add IA64 support.     
5748
5749 2005-05-13  Zoltan Varga  <vargaz@freemail.hu>
5750
5751         * inssel-long.brg: Add missing ulong->{i1, i2} checked conversions.
5752         Fixes #74925.
5753
5754         * basic-long.cs exceptions.cs: Add new tests. Fix some warnings.
5755
5756         * mini-amd64.c: Fix a warning.
5757
5758 2005-05-10  Zoltan Varga  <vargaz@freemail.hu>
5759
5760         * mini-amd64.c (mono_arch_output_basic_block): Fix stack space leakage
5761         in float_neg. Fixes #74897.
5762
5763         * mini-amd64.c (emit_call): Fix another near call bug.
5764
5765 2005-05-06  Sebastien Pouliot  <sebastien@ximian.com>
5766
5767         * declsec.c: Keep the appdomain information in the structure. Added a 
5768         missing "return FALSE" for Unmanaged if FullTrust is set (or else the
5769         value gets overwritten).
5770         * declsec.h: Set the default MonoArray for the the stack to 6. Added
5771         an MonoAppDomain member to MonoSecurityFrame.
5772         * mini-exceptions.c: Do not use a glist to keep GC allocated objects
5773         used in the stack walk. Now use a MonoArray which grow (double) when
5774         it gets full.
5775
5776 2005-05-05  Lluis Sanchez Gual  <lluis@novell.com>
5777
5778         * mini.c: Re-enabled runtime cleanup, since running threads should
5779         now properly stop when exiting.
5780
5781 2005-05-05  Zoltan Varga  <vargaz@freemail.hu>
5782
5783         * mini-codegen.c: New file contaning the arch-independent local
5784         register allocator. Not used by any architectures yet.
5785
5786         * mini.h linear-scan.c: Merge some changes from the 
5787         mini-xp-local-regalloc branch.
5788
5789 2005-04-28  Zoltan Varga  <vargaz@freemail.hu>
5790
5791         * mini-amd64.c (emit_call): Fix calls to native functions when the
5792         runtime is compiled as a shared library. Fixes #74756.
5793
5794         * mini.c (mono_method_to_ir): Assert if ldsfld and friends are used
5795         on a literal field. Fixes #74751.
5796
5797 2005-04-25  Raja R Harinath  <rharinath@novell.com>
5798
5799         * Makefile.am (RUNTIME): Add MONO_CFG_DIR.
5800
5801 2005-04-23  Zoltan Varga  <vargaz@freemail.hu>
5802
5803         * objects.cs: Add missing null casting test.
5804
5805 2005-04-22  Zoltan Varga  <vargaz@freemail.hu>
5806
5807         * mini-exceptions.c (mono_find_jit_info): Fix native offset calculation
5808         in wrapper methods. Also rename 'address' variable to 'offset'.
5809
5810 2005-04-20  Zoltan Varga  <vargaz@freemail.hu>
5811
5812         * mini.c debug-mini.c aot.c tramp-x86.c driver.c: Fix some gcc 4.0
5813         warnings.
5814         
5815         * Makefile.am (MCS): Use -unsafe instead of --unsafe.
5816
5817         * aot.c: Applied patch from "The Software Team" <software@solmersa.com>. Make AOT compilation
5818         work on windows.
5819
5820 Mon Apr 18 16:20:32 CEST 2005 Paolo Molaro <lupus@ximian.com>
5821
5822         * exceptions-ppc.c: update code to handle stack traces (fixes bug #74452).
5823
5824 2005-04-17  Zoltan Varga  <vargaz@freemail.hu>
5825
5826         * mini-x86.c (mono_emit_stack_alloc): Initialize the whole allocated area not
5827         just the last bytes.
5828
5829 2005-04-17  Zoltan Varga  <vargaz@freemail.hu>
5830
5831         * aot.c (mono_compile_assembly): Fix warning.
5832
5833         * mini-exceptions.c (ves_icall_get_frame_info): Fix bug introduced
5834         by the _MSC_VER stuff.
5835
5836 2005-04-16  Zoltan Varga  <vargaz@freemail.hu>
5837
5838         * inssel-long.brg: Fix #74588.
5839
5840         * cpu-amd64.md: Fix #74591.
5841
5842         * iltests.il: Add new regression tests.
5843
5844 2005-04-13  Zoltan Varga  <vargaz@freemail.hu>
5845
5846         * trace.c (mono_trace_enter_method): Print enums as an int, not as a
5847         valuetype.
5848
5849 2005-04-11  Zoltan Varga  <vargaz@freemail.hu>
5850
5851         * mini-x86.c (setup_stack): Unconditionally call pthread_attr_init ().
5852
5853         * exceptions-x86.c mini-x86.h mini-x86.c: Applied some freebsd patches 
5854         from Bill Middleton <flashdict@gmail.com>.
5855
5856 2005-04-10  Zoltan Varga  <vargaz@freemail.hu>
5857
5858         * arrays.cs: Add new regression test. Fix warnings.
5859
5860 2005-04-09  Zoltan Varga  <vargaz@freemail.hu>
5861
5862         * mini-amd64.c (mono_arch_output_basic_block): Fix stack alignment
5863         and leakage in CKFINITE.
5864
5865         * exceptions-amd64.c (mono_arch_get_throw_exception_by_name): Change
5866         this to a null op since it is called on amd64 too.
5867
5868         * exceptions-amd64.c (get_throw_trampoline): Align stack.
5869
5870         * exceptions-amd64.c (mono_arch_get_throw_exception_by_name): Remove
5871         body since this is not used on amd64.
5872         
5873         * mini-amd64.h (MONO_ARCH_NO_EMULATE_LONG_SHIFT_OPS): Remove duplicate define.
5874
5875         * mini-amd64.c: Remove obsolete fixmes.
5876
5877         * mini.c (print_method_from_ip): Fix debugging support.
5878
5879 2005-2-1  Massimiliano Mantione  <massi@ximian.com>
5880
5881         * ssapre.c: Fix a subtle bug about availability, and limit SSAPRE
5882         so that expressions that don't give much gain are not reduced.
5883         * ssapre.h: Likewise.
5884
5885 2005-04-04  Zoltan Varga  <vargaz@freemail.hu>
5886
5887         * exceptions-x86.c (mono_arch_find_jit_info): Remove last SC_EBP reference.
5888
5889         * mini-x86.c (mono_emit_stack_alloc): Fix localloc under windows.
5890
5891         * mini-x86.h exceptions-x86.c: Hopefully fix compilation on *BSD.
5892
5893 2005-04-01  Zoltan Varga  <vargaz@freemail.hu>
5894
5895         * mini-sparc.c mini-sparc.h: Add asserts when running with sigaltstack.
5896
5897         * exceptions-x86.c (mono_arch_monoctx_to_sigctx): Fix cygwin build.
5898
5899 2005-03-31  Zoltan Varga  <vargaz@freemail.hu>
5900
5901         * mini-x86.c: If sigaltstack support is enabled, perform win32 style
5902         stack touching.
5903
5904         * mini.h (mono_arch_sigctx_to_monoctx): New arch-specific function.
5905
5906         * mini.h (mono_arch_monoctx_to_sigctx): New arch-specific function.
5907
5908         * mini.c: sigaltstack support requires MONO_ARCH_USE_SIGACTION.
5909
5910         * mini-x86.h mini-x86.c exceptions-x86.c: Add support for 
5911         MONO_ARCH_USE_SIGACTION. Fixes #74252.
5912
5913         * mini-x86.h: Enable MONO_ARCH_USE_SIGACTION on linux.
5914
5915         * mini-x86.c: Fix up stack overflow handling.   
5916
5917         * exceptions.cs: Add new regression test.
5918
5919 2005-03-30  Zoltan Varga  <vargaz@freemail.hu>
5920
5921         * mini-x86.c (mono_arch_emit_prolog): Adjust stack after calls to
5922         mono_jit_thread_attach.
5923
5924         * mini.c (mono_method_to_ir): Verify called method is not abstract.
5925
5926 2005-03-29  Zoltan Varga  <vargaz@freemail.hu>
5927
5928         * mini.c (mono_method_to_ir): Applied Ben's patch from bug #61441 to
5929         avoid calling constructors using callvirt.
5930
5931         * inssel.brg: Fix #74073.
5932
5933 2005-03-29  Sebastien Pouliot  <sebastien@ximian.com>
5934
5935         * aot.c, mini.h: Added mono-compiler.h header to allow/ease 
5936         compilation with non-GCC compilers.
5937         * mini-exceptions.c, mini-x86.c|h: Patches to make compilation of mono
5938         possible using VS.NET. Adapted from the work of J Lothian (for VC6).
5939
5940 Tue Mar 29 11:43:01 CEST 2005 Paolo Molaro <lupus@ximian.com>
5941
5942         * inssel.brg, arrays.cs: fix long standing 64 bit issue in access to
5943         klass->interface_offsets (will likely fix bug#74073).
5944
5945 2005-03-29  Zoltan Varga  <vargaz@freemail.hu>
5946
5947         * mini-amd64.c (mono_arch_is_int_overflow): Fix rex handling.
5948
5949 2005-03-28  Zoltan Varga  <vargaz@freemail.hu>
5950
5951         * mini-amd64.c (mono_arch_output_basic_block): Fix order of parameters
5952         to amd64_div_reg_size ().
5953         
5954         * mini-amd64.c (mono_arch_emit_exceptions): Emit a near call here too.
5955
5956 2005-03-27  Zoltan Varga  <vargaz@freemail.hu>
5957
5958         * cpu-amd64.md (store_membase_reg): Fix length of storer8 opcodes.
5959
5960 2005-03-24  Zoltan Varga  <vargaz@freemail.hu>
5961
5962         * driver.c: Turn off automatic command line globbing under windows. Fixes #73763.
5963
5964 2005-03-24  Zoltan Varga  <vargaz@freemail.hu>
5965
5966         * mini.c (mono_method_to_ir): Remove debugging stuff left in by mistake.
5967         
5968         * mini.c (mono_precompile_assembly): Load and precompile referenced
5969         assemblies as well. Fixes #74015.
5970
5971 2005-03-23  Zoltan Varga  <vargaz@freemail.hu>
5972
5973         * cpu-amd64.md (sin): Fix up maximum lengths of some opcodes.
5974
5975 2005-03-23  Sebastien Pouliot  <sebastien@ximian.com>
5976
5977         * declsec.c: Skip linkdemand checks for intra-corlib calls. This skips
5978         a lot of checks and (anyway) permissions cannot work until corlib is 
5979         loaded.
5980
5981 Wed Mar 23 14:29:49 CET 2005 Paolo Molaro <lupus@ximian.com>
5982
5983         * mini-ppc.c: fixed ABI issue on sysv/ppc.
5984
5985 Tue Mar 22 19:03:17 CET 2005 Paolo Molaro <lupus@ximian.com>
5986
5987         * tramp-ppc.c, exceptions-ppc.c: added missing icache flush
5988         calls (fixes bug#72824).
5989
5990 Tue Mar 22 16:28:48 CET 2005 Paolo Molaro <lupus@ximian.com>
5991
5992         * mini.c: fix tail recursion elimination (see test in bug#73936).
5993
5994 2005-03-21  Zoltan Varga  <vargaz@freemail.hu>
5995
5996         * mini-amd64.c (mono_arch_output_basic_block): Add inline versions of
5997         some fp functions in sse2 mode.
5998
5999 2005-03-20  Zoltan Varga  <vargaz@freemail.hu>
6000
6001         * mini-x86.c (emit_tls_get): Move tls handling into a separate helper function.
6002
6003 2005-03-19  Zoltan Varga  <vargaz@freemail.hu>
6004
6005         * mini.h mini.c: Add mono_get_jit_tls_key ().
6006
6007         * mini-x86.c: Enable fast TLS support on windows.
6008
6009 2005-03-17  Sebastien Pouliot  <sebastien@ximian.com>
6010
6011         * declsec.c: Renamed aptc to allowpartiallytrustedcallers.
6012         * mini.c: Check for p/invoke method when generating code. If a
6013         p/invoke method, or it's class, isn't decorated with [Suppress
6014         UnmanagedCodeSecurity] then generate code to call System.Security.
6015         UnmanagedDemand (only if the security manager is active).
6016
6017 2005-03-16  Zoltan Varga  <vargaz@freemail.hu>
6018
6019         * tramp-amd64.c (create_specific_trampoline): Revert parts of the 
6020         last change as it seems to cause strange crashes.
6021         
6022 Wed Mar 16 16:24:11 CET 2005 Paolo Molaro <lupus@ximian.com>
6023
6024         * *.c: handle unsafe function pointers where needed.
6025
6026 2005-03-16  Zoltan Varga  <vargaz@freemail.hu>
6027
6028         * mini.c (mono_jit_free_method): Remove the fixme too.
6029
6030 2005-03-15  Miguel de Icaza  <miguel@novell.com>
6031
6032         * mini.c: As discussed, make the code actually free the delegate
6033         thunk now, to enable the debugging of delegate problems, use
6034         MONO_DEBUG=1 when running Mono. 
6035
6036         This takes also care of parts of the leaks as seen by Joe.
6037
6038 2005-03-15  Zoltan Varga  <vargaz@freemail.hu>
6039
6040         * mini-amd64.c (mono_arch_setup_jit_tls_data): Enable 
6041         thread_tls_offset calculation.
6042
6043 2005-03-14  Sebastien Pouliot  <sebastien@ximian.com>
6044
6045         * declsec.c: Reworked linkdemand checks for icall. The previous code
6046         was using the declaration code (untrusted) and didn't work as expected
6047         with the CLR 2.0. We're now more compatible with 2.0 than 1.x for this
6048         specific case.
6049
6050 2005-03-13  Zoltan Varga  <vargaz@freemail.hu>
6051
6052         * iltests.il: Add new localloc test.
6053
6054         * mini-amd64.c: Handle large stack allocations the same way as on
6055         windows if stack overflow handling is working.
6056         
6057         * mini-amd64.c: Allocate the signal stack using mmap.
6058
6059         * mini.c (sigsegv_signal_handler): Fix reading of context.
6060
6061         * mini-exceptions.c: Fix up stack overflow handling.
6062
6063         * mini-amd64.h mini-amd64.c: Fix up stack overflow handling.
6064
6065         * tramp-amd64.c (create_specific_trampoline): Optimize trampoline size.
6066
6067         * exceptions-amd64.c (mono_amd64_exceptions_init): Remove this.
6068
6069         * mini.h mini.c tramp-*.c: Move common trampoline code to mini.c.
6070
6071         * mini-x86.h mini-x86.c mini-amd64.h mini-amd64.c: Get rid of the
6072         tramp_init functions as they are no longer needed.
6073
6074 2005-03-12  Zoltan Varga  <vargaz@freemail.hu>
6075
6076         * tramp-amd64.c (mono_amd64_tramp_init): Fix typo.
6077         
6078         * tramp-amd64.c (mono_amd64_tramp_init): Init AOT trampoline as well.
6079
6080         * mini-amd64.h mini-amd64.c (mono_amd64_exceptions_init): Remove this.
6081         
6082         * mini.c mini-*.h: Remove OUT_OF_LINE_BBLOCK defines since all arches
6083         support that now.
6084
6085         * mini-ops.h: Add OP_LMUL_IMM.
6086
6087         * mini.c jit-icalls.cmini-amd64.h mini-amd64.c cpu-amd64.md: Implement
6088         long mul/div opcodes as intrinsic.
6089
6090         * mini-amd64.c (emit_call): Handle the case when the callee might be
6091         an AOT method.
6092
6093 2005-03-11  Zoltan Varga  <vargaz@freemail.hu>
6094
6095         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Reorder cases to be
6096         extra safe.
6097         
6098         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Fix ordering of cases.
6099
6100         * aot.c (mono_aot_load_method): Get rid of bogus make_writable call.
6101
6102 2005-03-09  Ben Maurer  <bmaurer@ximian.com>
6103
6104         * mini.c (mono_codegen): Don't leak here, to help people running
6105         monogrind.
6106
6107 2005-03-08  Zoltan Varga  <vargaz@freemail.hu>
6108
6109         * mini-amd64.c (mono_arch_output_basic_block): Fix int->float 
6110         conversions in sse2 mode.
6111
6112         * basic-float.cs: Add regression test.
6113         
6114         * mini-amd64.c: Reenable sse2.
6115
6116 2005-03-07  Zoltan Varga  <vargaz@freemail.hu>
6117
6118         * mini-amd64.c: Disable sse2 until some regressions are fixed.
6119
6120 2005-03-07      Joerg Rosenkranz <joergr@voelcker.com>
6121
6122         * driver.c: Copyright text should include 2005.
6123         
6124 2005-03-07  Zoltan Varga  <vargaz@freemail.hu>
6125
6126         * cpu-amd64.md (load_membase): Fix more max lengths.
6127
6128 2005-03-06  Zoltan Varga  <vargaz@freemail.hu>
6129
6130         * cpu-amd64.md (load_membase): Fix max length.
6131
6132         * mini-ops.h: Add OP_F<xx>_MEMBASE opcodes.
6133
6134         * inssel.brg: Add MONO_EMIT_BIALU_MEMBASE macro.
6135
6136         * cpu-amd64.md inssel-amd64.brg mini-amd64.h mini-amd64.brg: Finish SSE2
6137         support and enable it by default. Also add OP_F<xxx>_MEMBASE opcodes.
6138
6139         * basic-float.cs: Add rounding regression test.
6140
6141         * mini-amd64.c (INST_IGNORES_CFLAGS): Add more instructions.
6142
6143 2005-03-04  Neale Ferguson <NealeFerguson@earthlink.net>
6144
6145         * inssel-s390.brg, mini-s390.c: Add support for passing/returning small
6146         structures in registers for pinvoke wrappers.
6147
6148 2005-03-04  Zoltan Varga  <vargaz@freemail.hu>
6149
6150         * mini-exceptions.c (ves_icall_get_trace): Return wrapper info as well.
6151
6152 2005-03-03  Zoltan Varga  <vargaz@freemail.hu>
6153
6154         * mini.h mini.c mini-x86.c: Pass the domain of the native->managed
6155         wrapper to mono_jit_thread_attach.
6156
6157         * mini.c (mini_jit_thread_attach): New jit icall.
6158
6159         * mini-x86.c (mono_arch_emit_prolog): Attach to the VM in 
6160         native->managed wrappers.
6161
6162         * exceptions.cs: Add new regression test.
6163
6164         * mini.c (optimize_branches): Check regions in the cbranch to throw
6165         block case as well. Fixes #73242.
6166
6167 Tue Mar 1 18:35:27 CET 2005 Paolo Molaro <lupus@ximian.com>
6168
6169         * mini.c: thread safety fixes.
6170
6171 2005-02-27  Zoltan Varga  <vargaz@freemail.hu>
6172
6173         * tramp-amd64.c (amd64_magic_trampoline): Disable the method_ptr
6174         patching stuff, since delegates use jump trampolines so there is
6175         no caller.
6176
6177         * tramp-amd64.c (create_trampoline_code): Pass NULL as 'code' in 
6178         jump trampolines.
6179         
6180         * tramp-amd64.c: Fix build.
6181
6182         * mini-x86.c tramp-x86.c: Moved get_vtable_slot_addr into mini-x86.c and rename
6183         it to mono_arch_.... Add get_delegate_method_ptr implementation for x86.
6184
6185         * mini-amd64.h mini.h mini-amd64.c tramp-amd64.c (mono_amd64_get_vcall_slot_addr):
6186         Rename this to mono_arch....
6187         (mono_amd64_get_delegate_method_ptr_addr): Ditto.
6188
6189         * mini-amd64.c (mono_amd64_get_delegate_method_ptr_addr): New helper function.
6190
6191         * mini-amd64.c (emit_call): If both the caller and the callee is
6192         guaranteed to have 32 bit addresses, emit a normal call.
6193
6194         * tramp-amd64.c: Adapt to changes in mini-amd64.c.
6195
6196         * tramp-amd64.c (amd64_magic_trampoline): Remove patching of trampolines. 
6197         * tramp-amd64.c (amd64_magic_trampoline): Add support for patching the
6198         method_ptr inside delegates.
6199
6200 2005-02-26  Zoltan Varga  <vargaz@freemail.hu>
6201
6202         * mini.c (mono_jit_free_method): Free the method info even if the native code is
6203         invalidated. Fixes #73001.
6204
6205         * mini.c: Add a proper icall wrapper for mono_delegate_ctor.
6206
6207         * mini-x86.c: Only use stdcall for pinvokes on windows.
6208
6209 Thu Feb 24 15:22:30 CET 2005 Paolo Molaro <lupus@ximian.com>
6210
6211         * mini.c, mini.h: make mono_lmf_addr a fast-access thread var.
6212         * mini-x86.c: remove unreliable __thread var offset detection,
6213         use the correct accessors and enable by default.
6214
6215 2005-02-23  Zoltan Varga  <vargaz@freemail.hu>
6216
6217         * mini.c (mono_jit_free_method): Fix memory leak.
6218
6219 2005-02-22  Zoltan Varga  <vargaz@freemail.hu>
6220
6221         * mini.c (mono_method_to_ir): Allocate a GOT var for THROW and RETHROW. 
6222
6223 2005-02-21  Zoltan Varga  <vargaz@freemail.hu>
6224
6225         * cpu-amd64.md: Fix lengths of atomic opcodes.
6226
6227 Mon Feb 21 16:52:20 CET 2005 Paolo Molaro <lupus@ximian.com>
6228
6229         * driver.c: try to not imply using ICU is any good.
6230
6231 2005-02-20  Zoltan Varga  <vargaz@freemail.hu>
6232
6233         * mini-amd64.c (mono_arch_get_inst_for_method): Implement more 
6234         functions as inline ops.
6235
6236         * mini-ops.h inssel-amd64.brg cpu-amd64.md mini-amd64.c: Implement
6237         some Interlocked functions as inline ops.
6238
6239         * mini.c (move_basic_block_to_end): Fix bug in last patch.
6240
6241         * mini.h (MonoBasicBlock): Reorganize fields a bit.
6242
6243         * mini-ops.h inssel.brg: Add OP_NOT_REACHED.
6244
6245         * mini.c: Add support for OP_NOT_TAKEN.
6246
6247         * mini-amd64.h mini-amd64.c: Add support for passing/returning small 
6248         structures in registers for pinvoke wrappers.
6249
6250         * mini-amd64.c: Fix warnings.
6251
6252 2005-02-19  Zoltan Varga  <vargaz@freemail.hu>
6253
6254         * mini.h (MonoCompile): Add 'ret_var_is_local' field.
6255
6256         * mini.h mini.c (mono_arch_create_vars): Add new arch specific hook.
6257
6258         * mini.c (NEW_RETLOADA): If the ret variable is a local, use its 
6259         address instead of loading the address from it.
6260
6261         * mini-x86.c: Add support for returning small structs in registers
6262         on Win32. Fixes part of #70864.
6263         
6264 2005-02-18  Zoltan Varga  <vargaz@freemail.hu>
6265
6266         * trace.c (get_token): Improve error checking.
6267
6268 2005-02-17  Zoltan Varga  <vargaz@freemail.hu>
6269
6270         * jit-icalls.c (mono_ldvirtfn): Explicitly check for a NULL obj here.
6271
6272 2005-02-17  Sebastien Pouliot  <sebastien@ximian.com> 
6273  
6274         * mini.h: Moved MONO_EXCEPTION_* enum to metadata/class-internals.h so
6275         it can be reused for MonoClass.
6276         * mini.c: Renamed MONO_EXCEPTION_SECURITY to MONO_EXCEPTION_SECURITY
6277         _LINKDEMAND.
6278
6279 2005-02-15  Sebastien Pouliot  <sebastien@ximian.com>
6280
6281         * mini.c: Fixed 2 cases where I sent a MonoMethod to managed code 
6282         instead of a MonoReflectionMethod. The method information wasn't used
6283         when displaying SecurityException details (but will be now).
6284
6285 2005-02-15  Atsushi Enomoto  <atsushi@ximian.com>
6286
6287         * Makefile.am : windows build fix.
6288
6289 2005-02-14  Zoltan Varga  <vargaz@freemail.hu>
6290
6291         * iltests.il: Add new regression test.
6292
6293         * mini.c (mono_method_to_ir): Allocate a GOT var in CEE_NEWOBJ. Fixes
6294         #72522.
6295
6296 2004-02-13  Sebastien Pouliot  <sebastien@ximian.com> 
6297  
6298         * mini.c: Moved linkdemand check into helper function check_linkdemand
6299         to allow reuse for all intructions (CALL, CALLVIRT, NEWOBJ, JMP, 
6300         LDFTN, LDVIRTFTN).
6301
6302 2004-02-13  Sebastien Pouliot  <sebastien@ximian.com>
6303
6304         * declsec.c: Added statistics counter for different kinds of 
6305         LinkDemands.
6306         * mini.h: Added CAS statistic counters to MonoJitStats. Removed unused
6307         (and commented) declaration.
6308         * mini.c: Added statistics counter for security Demand code 
6309         generation. Added display of security statistics.
6310
6311 2005-02-13  Zoltan Varga  <vargaz@freemail.hu>
6312
6313         * declsec.c (mono_declsec_linkdemand_aptc): Applied patch from Robert Jordan (robertj@gmx.net).
6314         Fix compilation errors under gcc-2.95.
6315
6316 2005-02-12  Ben Maurer  <bmaurer@ximian.com>
6317
6318         * mini.c, driver.c: Use the new jit trampoline hashtable
6319
6320 Fri Feb 11 18:47:11 CET 2005 Paolo Molaro <lupus@ximian.com>
6321
6322         * mini.c, jit-icalls.c: use the managed implementation of memcpy, too.
6323
6324 2005-02-11  Martin Baulig  <martin@ximian.com>
6325
6326         * debug-mini.c (mono_debug_close_method): Free the line number array.
6327
6328 2005-02-10  Zoltan Varga  <vargaz@freemail.hu>
6329
6330         * aot.c: Break up large methods into smaller ones. Share GOT slots for
6331         icalls.
6332
6333         * mini.h: Bump AOT file format version. 
6334
6335 2005-02-10  Sebastien Pouliot  <sebastien@ximian.com>
6336
6337         * declsec.c: Added LinkDemand support and it's special cases for ECMA,
6338         APTC and P/Invoke.
6339         * declsec.h: Added macros to get/set lazyly initialized security 
6340         informations about assemblies. Added new enum for different type of
6341         possible LinkDemand violation. Added function to check LinkDemands.
6342         * mini.h: Added a field to MonoCompile to hold any security violation
6343         detected when JITting a method (so it can be thrown later).
6344         * mini.c: Added LinkDemand checks in mono_method_to_ir for CEE_CALL 
6345         and CEE_CALLVIRT. Added code to throw exception at the end of
6346         mini_method_compile (note: the exception is unhandled right now).
6347
6348 Thu Feb 10 15:49:44 CET 2005 Paolo Molaro <lupus@ximian.com>
6349
6350         * mini.c, jit-icalls.c: use the managed implementation of
6351         memset for initobj and memset, to avoid managed <-> unmanaged
6352         transitions.
6353
6354 2005-02-10  Zoltan Varga  <vargaz@freemail.hu>
6355
6356         * inssel.brg (mini_emit_virtual_call): Disable the virtual->nonvirtual
6357         optimization if it would need a GOT var.
6358
6359         * basic.cs: Add tests for constant propagation and switch statements.
6360
6361         * ssa.c: Fix out-of-range constant propagation and switch statements.
6362
6363 2005-02-09    <vargaz@freemail.hu>
6364
6365         * inssel-x86.brg (reg): Align the allocation size in the localloc(imm) case too.
6366
6367 2005-02-08  Zoltan Varga  <vargaz@freemail.hu>
6368
6369         * cpu-amd64.md (load_membase): Fix max length of load_membase.
6370
6371 Tue Feb 8 18:21:11 CET 2005 Paolo Molaro <lupus@ximian.com>
6372
6373         * mini.c: update to new signature of mono_class_get_allocation_ftn().
6374
6375 2005-02-06  Neale Ferguson <NealeFerguson@earthlink.net>
6376
6377         * cpu-s390.md,  mini-s390.c: Correct bug with register usage on certain 
6378         arithmetic operations.
6379
6380 Sun Feb 6 07:10:12 EST 2005 Paolo Molaro <lupus@ximian.com>
6381
6382         * mini-ppc.c: add a workaround for broken user code that
6383         DllImports vararg functions with non-vararg signatures.
6384
6385 2005-02-05  Zoltan Varga  <vargaz@freemail.hu>
6386
6387         * mini.c (mono_jit_compile_method_inner): Add detection and a 
6388         meaningfull error message for assemblies written in Managed C++.
6389
6390         * tramp-amd64.c mini-amd64.h: Add support for 
6391         create_trampoline_from_token ().
6392
6393         * aot.c mini-x86.c abcremoval.c: Applied patch from
6394         Robert Jordan (robertj@gmx.net). Fix compilation errors under gcc-2.95.
6395
6396 2005-02-04  Zoltan Varga  <vargaz@freemail.hu>
6397
6398         * mini.h mini.c mini-x86.h tramp-x86.c: Add a new kind of trampoline 
6399         which takes a MonoImage/token as parameter instead of a MonoMethod.
6400
6401         * aot.c: Use the new trampoline for initializing vtables.
6402
6403         * aot.c: Add support for ldfld/stfld_remote wrappers.
6404
6405         * mini-ops.h cpu-pentium.md inssel-x86.brg mini-x86.c: Add optimized
6406         rules for compare <MEM>, IMM.
6407
6408         * mini.h (MONO_AOT_FILE_VERSION): Bump it.
6409
6410         * aot.c: Handle inherited finalizers correctly.
6411
6412 2005-02-03  Zoltan Varga  <vargaz@freemail.hu>
6413
6414         * inssel.brg (stmt): Add a missing _setup_... ().
6415
6416         * aot.c: Save some parts of the class state to the AOT file and use it
6417         to recompute that state when a class is initialized.
6418
6419         * mini.c: Install AOT hooks into the runtime.
6420
6421         * mini.h: Bump AOT file format version.
6422         
6423         * mini.c (mono_method_to_ir): Initialize pointer type locals correctly.
6424         Fixes #72148.
6425
6426         * iltests.il: Add new test.
6427
6428 Wed Feb 2 16:53:59 CET 2005 Paolo Molaro <lupus@ximian.com>
6429
6430         * mini.c: fix typo.
6431
6432 Wed Feb 2 16:37:13 CET 2005 Paolo Molaro <lupus@ximian.com>
6433
6434         * mini.c: setup the statistical profiler in the thread attach
6435         callback to cope with the new single thread code.
6436
6437 Wed Feb 2 15:43:58 CET 2005 Paolo Molaro <lupus@ximian.com>
6438
6439         * mini-ppc.c: ensure we have enough room for the profiler
6440         calls (fixed bug#72084).
6441
6442 2005-02-02  Zoltan Varga  <vargaz@freemail.hu>
6443
6444         * aot.c: Get rid of the MonoAotMethod structure and the hashtable holding 
6445         it.
6446
6447 2005-2-1  Massimiliano Mantione  <massi@ximian.com>
6448
6449         * driver.c: Re-enabled SSAPRE (two commits, I was just dumb).
6450
6451 2005-2-1  Massimiliano Mantione  <massi@ximian.com>
6452
6453         * ssapre.c: Fixed an issue with down safety (this allows IronPython
6454         to succesfully execute parrotbench).
6455         * ssapre.h: Likewise.
6456
6457 2005-2-1  Massimiliano Mantione  <massi@ximian.com>
6458
6459         * ssa.c: In mono_ssa_rename_vars, forced the creation of a new SSA
6460         variable for stores to method arguments (fixes a SSAPRE issue).
6461
6462 Tue Feb 1 15:52:26 CET 2005 Paolo Molaro <lupus@ximian.com>
6463
6464         * mini.c: handle value types in dup, fixes gen-112.cs.
6465
6466 Tue Feb 1 11:45:19 CET 2005 Paolo Molaro <lupus@ximian.com>
6467
6468         * mini-ppc.c, cpu-g4.md, tramp-ppc.c: use a slower code
6469         sequence for calls in dynamic methods to avoid thunks.
6470
6471 Tue Feb 1 11:44:01 CET 2005 Paolo Molaro <lupus@ximian.com>
6472
6473         * mini.c: correctly remove dynamic methods from the hashtable.
6474
6475 2005-1-20  Massimiliano Mantione  <massi@ximian.com>
6476
6477         * driver.c: Disabled SSAPRE until fix the bug that appears
6478         in IronPython's parrotbench.
6479
6480 2005-01-31  Zoltan Varga  <vargaz@freemail.hu>
6481
6482         * aot.c (mono_compile_assembly): Get rid of Skip (other) messages.
6483
6484         * mini.c (mono_method_to_ir): Revert the previous change.
6485         
6486         * mini.c (mono_method_to_ir): Do not inline ldfld and stfld wrappers
6487         when AOT compiling.
6488
6489         * tramp-x86.c (x86_magic_trampoline): Avoid calls to 
6490         mono_jit_info_table_find () etc. when running under valgrind.
6491
6492         * inssel.brg: Fix warnings.
6493
6494         * mini-exceptions.c: Fix warnings.
6495
6496 2005-01-31  Martin Baulig  <martin@ximian.com>
6497
6498         * driver.c (compile_all_methods_thread_main): Don't try to compile
6499         generic methods or anything which has type parameters.
6500
6501 2005-01-30  Zoltan Varga  <vargaz@freemail.hu>
6502
6503         * aot.c: Avoid costly calls to mono_method_full_name in tracing code and fix memory leaks.
6504
6505         * TestDriver.cs: Add --verbose flags.
6506
6507         * graph.c ssa.c: Fix 64 bit warnings.
6508         
6509         * abcremoval.h ssapre.h abcremoval.c ssapre.c mini.c tramp-amd64.c 
6510         trace.c mini-exceptions.c linear-scan.c inssel-amd64.brg inssel.brg:
6511         Fix 64 bit warnings.
6512
6513         * mini-amd64.c (mono_arch_output_basic_block): Fix uninitialized
6514         variable not spotted by gcc.
6515         
6516         * mini-amd64.c inssel-amd64.brg: Applied patch from  
6517         Willibald Krenn <Willibald.Krenn@gmx.at>. Clean up usage of 
6518         X86_COMPARE_MEMBASE opcodes.
6519
6520         * exceptions-amd64.c (mono_arch_find_jit_info): Fix AMD64 build.
6521
6522 2005-01-29  Ben Maurer  <bmaurer@ximian.com>
6523
6524         * *: MonoMethod->signature might be NULL now. You *MUST* use
6525         mono_method_signature.
6526
6527 2005-01-28  Zoltan Varga  <vargaz@freemail.hu>
6528
6529         * driver.c (compile_all_methods_thread_main): Compile the methods
6530         without invoking cctors.
6531
6532 Fri Jan 28 18:28:26 CET 2005 Paolo Molaro <lupus@ximian.com>
6533
6534         * mini.c: remove ben's "optimizations" to dup+stloc (bug #71905).
6535         * basic-calls.cs: test for the above.
6536
6537 2005-01-28  Zoltan Varga  <vargaz@freemail.hu>
6538
6539         * mini.c mini-exceptions.c aot.c exceptions-*.c: Update after 
6540         MonoJitInfo changes.
6541
6542 2005-01-27  Zoltan Varga  <vargaz@freemail.hu>
6543
6544         * mini-exceptions.c (mono_handle_exception): Compute the stack trace
6545         eagerly if it contains dynamic methods.
6546         
6547         * mini-exceptions.c (ves_icall_System_Exception_get_trace): New icall.
6548
6549         * mini-exceptions.c (mono_handle_exception): Avoid computing the stack
6550         trace, it is now computed by an icall from trace_ips.
6551         
6552         * mini-exceptions.c: Fix a warning.
6553
6554 Thu Jan 27 13:38:34 CET 2005 Paolo Molaro <lupus@ximian.com>
6555
6556         * mini-exceptions.c: don't bother getting stack trace info if
6557         it's not going to be used.
6558
6559 2005-01-27  Raja R Harinath  <rharinath@novell.com>
6560
6561         * Makefile.am (common_sources): Add ssapre-cee-ops.h and
6562         ssapre-mini-ops.h.
6563
6564 2005-01-26  Zoltan Varga  <vargaz@freemail.hu>
6565
6566         * mini.c (remove_block_if_useless): Only print debug stuff with -v -v.
6567
6568         * aot.c: Avoid calling mono_method_get_header () if not needed.
6569
6570         * mini.h: Bump AOT file format version.
6571         
6572         * mini.c (mono_emit_native_call): Allocate a GOT var here.
6573
6574         * mini.c (mono_print_tree): Print more info for calls.
6575
6576 2005-01-26  Sebastien Pouliot  <sebastien@ximian.com>
6577
6578         * declsec.h: Remove warning by adding missing include for marshal.h
6579
6580 2005-01-26  Martin Baulig  <martin@ximian.com>
6581
6582         * mini.c (mono_method_to_ir): In CEE_UNBOX_ANY, don't increase
6583         `ip' twice.
6584
6585 2005-01-25  Zoltan Varga  <vargaz@freemail.hu>
6586
6587         * mini-amd64.c (mono_arch_call_opcode): Add missing MONO_SSA_LOAD/STORE
6588         flags.
6589
6590         * ssa.c (mono_ssa_compute): Fix crashes when using AOT.
6591
6592         * aot.c (mono_compile_assembly): Fix a warning.
6593
6594 2005-01-25  Sebastien Pouliot  <sebastien@ximian.com>
6595
6596         * declsec.c: Look for security attributes on the original MonoMethod 
6597         (and not the wrapped one). This fix permissions on icalls.
6598
6599 2005-01-23  Zoltan Varga  <vargaz@freemail.hu>
6600
6601         * mini-amd64.c (mono_arch_allocate_vars): Use mono_allocate_stack_slots ().
6602
6603         * mini.c (mono_allocate_stack_slots): Add a fixme.
6604
6605         * mini-x86.c (mono_arch_allocate_vars): Use mono_allocate_stack_slots ().
6606
6607 Sun Jan 23 16:16:48 CET 2005 Paolo Molaro <lupus@ximian.com>
6608
6609         * inssel.brg: optimize casts of sealed types (more
6610         optimizations waiting for fixes in remoting).
6611
6612 2005-01-23  Zoltan Varga  <vargaz@freemail.hu>
6613
6614         * inssel.brg (stmt): Add another dummy rule.
6615
6616         * driver.c: Fix warnings.
6617
6618         * driver.c (mono_main): If running under valgrind, instruct glib to use
6619         the system allocation functions so valgrind can track the memory
6620         allocated by the g_... functions.
6621
6622         * inssel.brg (stmt): Add DUMMY rule for OP_DUMMY_STORE.
6623
6624         * mini-ops.h: Add OP_DUMMY_STORE opcode.
6625
6626         * mini.h (MONO_BBLOCK_IS_IN_REGION): New helper macro.
6627
6628         * liveness.c: Handle OP_DUMMY_STORE. Enable register allocation for
6629         variables in try regions.
6630
6631         * mini.c (mini_method_compile): Don't disable optimizations on large
6632         methods when AOT compiling.
6633
6634         * mini.c (mono_allocate_stack_slots): New arch independent method to 
6635         allocate stack slots. Not yet used.
6636
6637 2005-01-22  Ben Maurer  <bmaurer@ximian.com>
6638
6639         * debug-mini.c (mono_debug_close_method): Plug some leaks.
6640
6641 Sat Jan 22 13:41:51 EST 2005 Paolo Molaro <lupus@ximian.com>
6642
6643         * mini-ppc.c: make the branch info relative as the code
6644         buffer can be reallocated.
6645
6646 2005-01-22  Sebastien Pouliot  <sebastien@ximian.com>
6647
6648         * aot.c: Allow decoding of the new  MONO_PATCH_INFO_DECLSEC.
6649         * driver.c: Removed the AOT/security restriction. Now initialize the
6650         security manager (in metadata) if --security is used.
6651         * mini.c|h: Add the MONO_PATCH_INFO_DECLSEC code to use the index,
6652         rather than the pointer to declarative security, when AOT is used.
6653
6654 Sat Jan 22 09:35:19 EST 2005 Paolo Molaro <lupus@ximian.com>
6655
6656         * mini.h, mini-ppc.h, mini-ppc.c: updated to use out of line
6657         basic blocks, reduced intrinsic exception throwing code size.
6658
6659 2005-01-22  Miguel de Icaza  <miguel@ximian.com>
6660
6661         * driver.c (mini_usage): Reorder the usage screen.
6662
6663 2005-01-21  Zoltan Varga  <vargaz@freemail.hu>
6664
6665         * mini.c (mono_resolve_patch_target): Fix warning.
6666
6667 2005-01-20  Zoltan Varga  <vargaz@freemail.hu>
6668
6669         * mini-x86.c (mono_arch_local_regalloc): Fix bug introduced by
6670         previous patch.
6671
6672         * mini-amd64.c (mono_arch_local_regalloc): Ditto.       
6673
6674         * mini-amd64.c (mono_arch_local_regalloc): Revert last patch as it
6675         breaks the amd64 build.
6676
6677         * mini-x86.c (mono_arch_local_regalloc): Fix bug in div/rem 
6678         register allocation. Fixes #71454.
6679
6680         * mini-amd64.c (mono_arch_local_regalloc): Ditto.       
6681
6682         * arrays.cs: Add new regression test.   
6683
6684 2005-1-20  Massimiliano Mantione  <massi@ximian.com>
6685
6686         * ssapre.c: Turned usage of snprintf to GString.
6687         * ssapre.h: disabled MONO_APPLY_SSAPRE_TO_SINGLE_METHOD
6688         (I left it on by mistake in my previous commit).
6689
6690 Thu Jan 20 12:00:45 CET 2005 Paolo Molaro <lupus@ximian.com>
6691
6692         * mini.c, cfold.c, basic-calls.cs: preserve side effects
6693         on cond branch optimization (fixes bug# 71515).
6694
6695 2005-1-20  Massimiliano Mantione  <massi@ximian.com>
6696
6697         * abcremoval.c: Fixed bug 71062.
6698         * abcremoval.h: Likewise.
6699
6700 2005-1-20  Massimiliano Mantione  <massi@ximian.com>
6701
6702         * mini.c: Added a new functionality to optimize_branches, the removal
6703         of useless basic blocks, and fixed some problem in the removal of
6704         critical edges; some utility functions added for both purposes.
6705         * ssapre.c: Added complex expression support, and fixed bug 70637.
6706         * ssapre.h: Likewise.
6707         * ssapre-cee-ops.h: Added file with list of "CEE_*" opcodes
6708         enabled in SSAPRE.
6709         * ssapre-mini-ops.h: Likewise, but for "OP_*" opcodes.
6710         * driver.c: Re-enabled SSAPRE.
6711
6712 2005-01-19  Martin Baulig  <martin@ximian.com>
6713
6714         * mini.c (mono_method_to_ir): Call mono_get_inflated_method() on
6715         the result of mono_get_method_constrained().
6716
6717 2005-01-18  Neale Ferguson <NealeFerguson@earthlink.net>
6718
6719         * exceptions-s390.c tramp-s390.c: Allocate code using the global code
6720         manager.
6721
6722 2005-01-18  Geoff Norton  <gnorton@customerdna.com>
6723
6724         * jit-icalls.c (mono_llmult_ovf): Fix other overflow conditions to
6725         be detected.  Fixes #59296.
6726
6727 2005-01-18  Zoltan Varga  <vargaz@freemail.hu>
6728
6729         * mini-amd64.c (mono_arch_output_basic_block): Remove some assertions
6730         which can happen. Fixes #71361.
6731
6732 2005-01-18  Zoltan Varga  <vargaz@freemail.hu>
6733
6734         * exceptions-sparc.c tramp-sparc.c: Allocate code using the global code
6735         manager.
6736
6737 2005-01-17  Zoltan Varga  <vargaz@freemail.hu>
6738
6739         * mini.c (mono_create_jump_trampoline): Revert last change as it causes
6740         appdomain-unload.exe to fail.
6741         
6742         * mini.c: Fix some memory leaks.
6743
6744 Mon Jan 17 16:16:23 CET 2005 Paolo Molaro <lupus@ximian.com>
6745
6746         * inssel.brg: handle the new size of rank, idepth, max_interface_id.
6747         Fixed bug and sped up some codepaths.
6748
6749 2005-01-17  Zoltan Varga  <vargaz@freemail.hu>
6750
6751         * mini.c: Fix some memory leaks.
6752
6753         * exceptions.cs basic-long.cs: Add test for checked ulong->int 
6754         conversion.
6755
6756         * inssel-long.brg: Implement long_conv_to_ovf_i4_un. Fixes #71319.
6757
6758         * inssel-long.brg: Fix conv.ovf.i8 when run on an int32. Fixes
6759         #71320.
6760
6761         * iltests.il: Add regression test for #71320.
6762
6763 2005-01-16  Zoltan Varga  <vargaz@freemail.hu>
6764
6765         * mini.c (mono_codegen): Fix installation of profiler hooks.
6766
6767         * mini-sparc.c mini-amd64.c: Don't allocate stack space for dead vars.
6768
6769 Sun Jan 16 12:19:35 CET 2005 Paolo Molaro <lupus@ximian.com>
6770
6771         * mini.h, mini.c, cfold.c: optimize access to enum
6772         readonly fields, too. Eval conditional branches if possible
6773         to perform unreachable code removal in more cases.
6774
6775 2005-01-15  Zoltan Varga  <vargaz@freemail.hu>
6776
6777         * tramp-amd64.c exceptions-amd64.c: Use the new global code manager.
6778
6779         * mini.c (mono_global_codeman_reserve): New function to allocate code memory from a global
6780         code manager.
6781
6782         * tramp-x86.c mini-x86.c exceptions-x86.c: Allocate all code memory so mono works with
6783         WinXP DEP. Fixes #71244.
6784
6785 2005-01-14  Zoltan Varga  <vargaz@freemail.hu>
6786
6787         * inssel.brg: Allways convert CEE_CONV_OVF_I4 to a move on 64 bit platforms. Fixes #71236.
6788
6789 2005-01-13  Zoltan Varga  <vargaz@freemail.hu>
6790
6791         * mini-x86.c (mono_arch_output_basic_block): Fix OP_ATOMIC_ADD_NEW_I4.
6792
6793 2005-01-11  Zoltan Varga  <vargaz@freemail.hu>
6794
6795         * mini-exceptions.c exceptions-ppc.c aot.c: Cope with MonoJitInfo 
6796         changes.
6797
6798         * mini.h: Bump AOT version.
6799
6800         * mini.h (MonoCompile): Change exvar to a hash table.
6801
6802         * mini.c: Allocate a separate exvar for each handler block.
6803
6804         * mini.c: Get rid of the computation of filter_lengths, its not needed.
6805
6806         * mini.c inssel.brg: Change OP_THROW_OR_NULL to compare the current
6807         ex var with the pending exception and only throw if the two are equal.
6808         Fixes #68552.
6809         
6810         * exceptions.cs: Add tests for rethrow and nested catch clauses.
6811
6812         * mini-x86.c: Fix warnings.
6813
6814         * Makefile.am (common_sources): Move mini-exceptions.c here as it is
6815         used by all the ports now.
6816
6817         * aot.c: Add write-symbols and save-temps options.
6818
6819 2005-01-10  Zoltan Varga  <vargaz@freemail.hu>
6820
6821         * mini-x86.c: Add support for returning structs in registers from pinvoke functions on WIN32.
6822
6823 Mon Jan 10 16:11:16 EST 2005 Neale Ferguson <nealeferguson@earthlink.net>
6824
6825         * mini-ops.h, inssel-s390.brg, cpu-s390.md: Support OP_ATOMIC__xxx 
6826         operations.
6827
6828         * tramp-s390.c: Check vtable slot belongs to the domain.
6829
6830         * mini-exceptions.c, exceptions-s390.c: Standardize exception handling
6831         as per other platforms.
6832
6833         * mini-s390.c, mini-s390.h: Enable out-of-line bblock support.
6834
6835 Mon Jan 10 18:53:05 CET 2005 Paolo Molaro <lupus@ximian.com>
6836
6837         * driver.c: we don't run the Main() code in a subthread anymore.
6838
6839 Mon Jan 10 17:54:16 CET 2005 Paolo Molaro <lupus@ximian.com>
6840
6841         * mini.c: added experimental rtc support in the statistical
6842         profiler: if the user has the permission, more accurate statistics
6843         are gathered. Run with: MONO_RTC=4096 mono --profiler=default:stat ....
6844         The MONO_RTC value must be restricted to what the linux rtc allows:
6845         power of two from 64 to 8192 Hz.
6846
6847 2005-01-10  Zoltan Varga  <vargaz@freemail.hu>
6848
6849         * mini-x86.c (mono_arch_emit_exceptions): Fix #71121.
6850
6851 Mon Jan 10 05:20:49 EST 2005 Paolo Molaro <lupus@ximian.com>
6852
6853         * mini-ppc.c: better icache flush for smp.
6854
6855 2005-01-09  Zoltan Varga  <vargaz@freemail.hu>
6856
6857         * mini-amd64.c (emit_move_return_value): Fix memory leak.
6858
6859         * mini-x86.c (get_call_info): Add the get_call_info () code from the
6860         amd64 port, not yet used.
6861
6862 2005-01-07  Zoltan Varga  <vargaz@freemail.hu>
6863
6864         * mini.c (mono_method_to_ir): Disable inlining of ldfld wrappers with
6865         a struct type.
6866
6867 2005-01-07  Sebastien Pouliot  <sebastien@ximian.com>
6868
6869         * driver.c: Added --security option to activate the security manager.
6870         Right now this will allow code generation for declarative demands and
6871         is disabled when AOT is specified.
6872         * mini.c: Add code generation for declarative security demands.
6873         * mini.h: Add mono_use_security_manager as an extern gboolean.
6874
6875 2005-01-07  Zoltan Varga  <vargaz@freemail.hu>
6876
6877         * aot.c (mono_compile_assembly): Speed up compilation a bit by
6878         emitting more dense assembly code.
6879
6880         * mini-sparc.c mini-sparc.h exceptions-sparc.c: Enable optimized corlib
6881         exception throwing stuff.
6882
6883 2005-01-06  Zoltan Varga  <vargaz@freemail.hu>
6884
6885         * mini-sparc.c (mono_arch_emit_exceptions): Fix typo in previous patch. Remove
6886         dead code.
6887
6888         * mini-amd64.c (mono_arch_emit_exceptions): Remove duplicate epilog stuff
6889         left in by mistake.
6890
6891         * driver.c (EXCLUDED_FROM_ALL): Disable SSAPRE until bug #70637 is 
6892         fixed.
6893
6894         * mini-sparc.h mini-sparc.c: Enable out-of-line bblock support.
6895
6896         * tramp-*.c: Only patch vtable slots if the object is in the current
6897         domain. Fixes appdomain-unload.exe.
6898
6899         * mini-amd64.c mini-amd64.h: Enable out-of-line bblock support.
6900         
6901         * mini-amd64.c (mono_arch_local_regalloc): Port regalloc fix from
6902         x86 branch.
6903
6904 2005-01-05  Zoltan Varga  <vargaz@freemail.hu>
6905
6906         * mini.c (reverse_branch_op): New helper function.
6907
6908         * mini.c (optimize_branches): Run the new optimization only on 
6909         platforms which support it. Also reverse all kinds of branches.
6910
6911         * mini.h (MonoBasicBlock): Add 'out_of_line' field.
6912
6913         * mini.c (mono_method_to_ir): Set 'out_of_line' for bblocks which have
6914         a throw statement.
6915
6916         * mini.c (optimize_branches): Reverse not-equals branches if the false
6917         bblock is a throw. This happens a lot of time with argument checking in
6918         corlib.
6919
6920         * mini.c (mono_codegen): Add support for placing basic blocks after
6921         the function epilogue.
6922
6923         * mini-x86.c mini-x86.h: Add support for placing basic blocks after the
6924         function epilogue.
6925         
6926 2005-01-05  Miguel de Icaza  <miguel@ximian.com>
6927
6928         * mini.c (setup_stat_profiler): Only set this up if the platform
6929         supports ITIMER_PROF.
6930
6931 2005-01-05  Zoltan Varga  <vargaz@freemail.hu>
6932
6933         * mini-x86.c (mono_arch_local_regalloc): Fix a bug introduced by the
6934         previous patch.
6935
6936         * inssel.brg: Fix a warning.
6937
6938 Wed Jan 5 16:40:18 CET 2005 Paolo Molaro <lupus@ximian.com>
6939
6940         * mini.c: added support for statistical profiler 
6941         (run with: --profile=default:stat).
6942
6943 2005-01-04  Zoltan Varga  <vargaz@freemail.hu>
6944
6945         * mini-x86.h (MONO_ARCH_ENABLE_EMIT_STATE_OPT): Enable this on x86.
6946
6947         * mini-x86.c cpu-pentium.md: More fixes for usage of global registers.
6948
6949         * mini-amd64.c (mono_arch_local_regalloc): Port some regalloc fixes 
6950         related to global registers from the amd64 port.
6951
6952 2005-01-03  Zoltan Varga  <vargaz@freemail.hu>
6953
6954         * mini.c (mono_method_to_ir): Handle MONO_CLASSCONST.
6955
6956         * mini-amd64.c (mono_arch_local_regalloc): Fix some regalloc problems
6957         with global registers.
6958         (mono_arch_output_basic_block): Fix SWITCH in the AOT case.
6959
6960         * aot.c (emit_method_code): Fix the 'method emitted as' messages.
6961
6962 2004-12-31  Zoltan Varga  <vargaz@freemail.hu>
6963
6964         * debug-mini.c (encode_value): Fix off-by-one.
6965
6966         * aot.c (encode_value): Likewise.
6967
6968         * mini.c (mono_method_to_ir): Disable AOT for methods containing LDPTR.
6969
6970 2004-12-30  Zoltan Varga  <vargaz@freemail.hu>
6971
6972         * mini.c linear-scan.c: Add a workaround for the mcs crash when using 
6973         AOT.
6974
6975         * aot.c (mono_aot_load_method): Free up patch info if no longer needed.
6976         
6977         * aot.c (emit_method_info): Increase size of temp buffer.
6978
6979         * mini-x86.c cpu-pentium.md mini.c: Load fp constants differently in 
6980         the AOT case.
6981
6982 2004-12-28  Zoltan Varga  <vargaz@freemail.hu>
6983
6984         * aot.c (emit_method_info): Fix build.
6985         
6986         * aot.c: Further rework of the AOT file format to reduce the size of
6987         the method info data.
6988
6989         * mini.h: Bump AOT file format version.
6990
6991 2004-12-27  Martin Baulig  <martin@ximian.com>
6992
6993         * mini.c (mini_get_method): New static method; call
6994         mono_get_method_full() and mono_get_inflated_method().
6995         (mono_method_to_ir): Use mini_get_method() instead of
6996         mono_get_method_full(). 
6997
6998 2004-12-26  Patrik Torstensson  <patrik.torstensson@gmail.com>
6999
7000         * mini-x86.c (atomic ops): fixed bug interlocked bug #70784. 
7001
7002 2004-12-25  Zoltan Varga  <vargaz@freemail.hu>
7003
7004         * inssel.brg (ldind_to_load_membase): Handle CEE_LDIND_I8.
7005
7006         * inssel-amd64.brg: Add some optimization rules.
7007
7008 2004-12-24  Ben Maurer  <bmaurer@ximian.com>
7009
7010         * aot.c: Remove the use of MonoGHashTable and other GC stuff. The
7011         standard not GC'd stuff is fine.
7012
7013 2004-12-24  Zoltan Varga  <vargaz@freemail.hu>
7014
7015         * aot.c: Rework the AOT file format to get rid of most of the global
7016         symbols. This reduces the size of the mscorlib.dll.so by 1MB.
7017
7018         * mini.h: Bump AOT file format version.
7019         
7020 2004-12-23  Zoltan Varga  <vargaz@freemail.hu>
7021
7022         * mini.h: Bump AOT file format version.
7023
7024         * aot.c (mono_aot_is_got_entry): New function to determine if an 
7025         address is inside a GOT.
7026
7027         * aot.c mini-x86.c tramp-x86.c: Make all patches use the GOT.
7028
7029         * cpu-pentium.md: Increase the maximum size of some instructions which
7030         might involve a got access.
7031         
7032         * mini.c (get_method_from_ip): Another debug helper function.
7033
7034         * mini.c: Call mono_get_got_var () in a couple places. Handle the case
7035         when got var accesses are created during the decompose phase.
7036
7037         * mini-sparc.c: Change mono_compile_aot to cfg->compile_aot.
7038
7039         * mini.h mini.c mini-x86.c aot.c mini-sparc.c: Add a 'compile_corlib'
7040         argument mini_compile_method and to MonoCompile, and use this to
7041         determine whenever a given method is compiled for AOT. This allows the
7042         other methods compiled during AOT compilation to be free of AOT stuff,
7043         so the backends does not need to add special support for them by
7044         creating a fake GOT etc.
7045
7046         * mini-x86.c (mono_arch_patch_code): Remove fake got stuff as it is no
7047         longer needed.
7048
7049 2004-12-21  Ben Maurer  <bmaurer@ximian.com>
7050
7051         * mini.c (mono_method_to_ir): It turns out that some of the
7052         x-appdomain wrappers are lax with types, so just ignore this for
7053         all wrappers.
7054
7055         * inssel.brg (OP_CHECK_ARRAY_TYPE): Optimize this by only looking
7056         at the vtable->klass. If it is non-shared code we can just use the
7057         vtable.
7058
7059 Tue Dec 21 17:43:06 CET 2004 Paolo Molaro <lupus@ximian.com>
7060
7061         * mini-ppc.c: access MonoDomain from tls, too.
7062
7063 2004-12-21  Sebastien Pouliot  <sebastien@ximian.com>
7064
7065         * declsec.c: Removed unused variable (and related warning ;-)
7066
7067 2004-12-21  Ben Maurer  <bmaurer@ximian.com>
7068
7069         * iltests.il: New test for LDELEMA on an array of ref types.
7070
7071         * mini.c (CEE_LDELEMA): We need to emit OP_CHECK_ARRAY_TYPE for
7072         all ldelema's on reftypes.
7073         (check_call_signature): Remove the OP_CHECK_ARRAY_TYPE from here,
7074         it was the wrong place to put it.
7075
7076         * mini-x86.c (mono_arch_output_basic_block): Just use ecx as the
7077         register to pop to make this cleaner, at the request of Paolo.
7078
7079 2004-12-20  Ben Maurer  <bmaurer@ximian.com>
7080
7081         * mini-ops.h (OP_GETHASHCODE): New op.
7082
7083         * inssel.brg (OP_GETHASHCODE): Emit code for the new opcode
7084
7085         * mini.c (mini_get_inst_for_method): Create the intrinsic hash
7086         operation.
7087
7088         For a microbenchmark, this reduces the cost of Hashtable.get_Item
7089         by 25%.
7090         
7091         * mini-x86.c (mono_arch_output_basic_block): Rather than
7092
7093         add ebp, 4
7094
7095         Emit
7096
7097         pop edx
7098
7099         The first is 3 bytes while the second is 1. This saves 36 kb on
7100         mscorlib, quite a big saving. When bootstraping mcs, I was able to
7101         see a small boost because of icache locality.
7102
7103         * cfold.c (FOLD_BINOPCOMM): Kill add foo, 0
7104
7105 Mon Dec 20 12:19:40 EST 2004 Paolo Molaro <lupus@ximian.com>
7106
7107         * Makefile.am, mini-ppc.h, mini-exceptions.c, exceptions-ppc.c:
7108         started code sharing with the generic code.
7109
7110 Mon Dec 20 11:08:06 EST 2004 Paolo Molaro <lupus@ximian.com>
7111
7112         * mini-ppc.c, cpu-g4.md: added code for direct access to
7113         tls data slots.
7114
7115 Mon Dec 20 10:58:28 EST 2004 Paolo Molaro <lupus@ximian.com>
7116
7117         * mini-ops.h, inssel-x86.brg, cpu-amd64.md, inssel.brg, inssel-amd64.brg,
7118          mini-amd64.c, mini-x86.c, cpu-pentium.md: renamed OP_X86_TLS_GET
7119         to OP_TLS_GET.
7120
7121 2004-12-20  Sebastien Pouliot  <sebastien@ximian.com>
7122
7123         * declsec.c|h: Added functions to cache the declarative stack modifiers
7124         in MonoJitInfo and to create a security frame from a MonoJitInfo 
7125         structure.
7126         * mini.c: Initialize jinfo->cas_inited to FALSE when MonoJitInfo is
7127         created. Register internal calls for System.Security.SecurityFrame::
7128         _GetSecurityFrame and _GetSecurityStack.
7129         * mini.h: Added definition for new icalls (in mini-exceptions.c) and
7130         the definitions for the new stack walk/callback mechanism.
7131         * mini-exceptions.c: Added internal call GetSecurityFrame (to get the 
7132         first security frame for LinkDemands and InheritanceDemands) and
7133         GetSecurityStack for Demands. Both use the new mono_walk_stack code
7134         from lupus.
7135         * mini-x86.h, mini-amd64.h, mini-sparc.h: Architecture specific stack
7136         walk initialization (lupus).
7137
7138 2004-12-20  Ben Maurer  <bmaurer@ximian.com>
7139
7140         * mini.c (mono_method_to_ir): In CEE_DUP, handle the dup / stloc
7141         idiom.
7142         (handle_loaded_temps): Do not create a temporary variable for
7143         things that we know are temps. They will never be modified.
7144         (mono_spill_call): Set MONO_INST_IS_TEMP
7145         (mono_emulate_opcode): ditto
7146         (emit_tree): ditto
7147         (mono_method_to_ir.CEE_DUP): ditto
7148
7149 2004-12-19  Ben Maurer  <bmaurer@ximian.com>
7150
7151         * mini.c (type_to_eval_stack_type): Make this handle the void type
7152         (mono_emit_call_args): set the call->type with type_to_eval_stack_type
7153         (emit_tree): use ip_in_bb to special case some common idioms
7154         Update all callers to pass in the IP.
7155         (mono_method_to_ir): Make CEE_CALL* do the above as well.
7156
7157         This gives us a nice 2% speedup in mcs bootstrap.
7158
7159         * mini-x86.c (peephole_pass): Peephole pass to make
7160         mov  [foo], eax
7161         push [foo]
7162
7163         into
7164
7165         mov [foo], eax
7166         push eax
7167
7168         * mini.c (ip_in_bb): new method.
7169         (mono_method_to_ir): use this method rather than doing the hash
7170         lookup ourselves.
7171
7172         * linear-scan.c (mono_linear_scan): When expiring actives, you
7173         don't need to keep around variables that expire on this
7174         instruction. This makes it so that:
7175              a = b + 1
7176         will turn into:
7177              store (ebx add (ebx, 1))
7178         which will become
7179              add ebx, 1
7180
7181 2004-12-19  Zoltan Varga  <vargaz@freemail.hu>
7182
7183         * mini.c (mono_method_to_ir): Optimize the common ldobj+stloc 
7184         combination to avoid doing two copies. Fix up problems with previous
7185         patch.
7186
7187         * mini.c: Fix 64 bit warnings.
7188
7189         * mini-x86.c (INST_IGNORES_CFLAGS): Add OP_STOREI4_MEMBASE_REG.
7190
7191 2004-12-17  Zoltan Varga  <vargaz@freemail.hu>
7192
7193         * mini-amd64.h mini-amd64.c exceptions-amd64.c: Port exception handling
7194         changes from the x86 code.
7195
7196         * mini.h: Add prototype for mono_arch_get_throw_corlib_exception ().
7197
7198 2004-12-16  Zoltan Varga  <vargaz@freemail.hu>
7199
7200         * mini-x86.c (mono_arch_emit_epilog): Optimize the corlib exception
7201         throwing code to reduce its size, unify the AOT and non-aot code and 
7202         get rid of relocations in the AOT case.
7203
7204         * mini-x86.h mini.c exceptions-x86.c 
7205         (mono_arch_get_throw_corlib_exception): New arch specific function to 
7206         raise corlib exceptions which doesn't require relocations in the 
7207         caller.
7208
7209         * aot.c (emit_method): Handle PATCH_INFO_NONE as well.
7210
7211 2004-12-15  Zoltan Varga  <vargaz@freemail.hu>
7212
7213         * mini.c (mono_emit_method_call): Only allocate the got var when it is
7214         needed.
7215
7216         * mini-x86.c (mono_arch_patch_code): Add missing PATCH_INFO_METHOD_REL
7217         in the AOT case.
7218
7219 2004-12-14  Patrik Torstensson  <patrik.torstensson@gmail.com>
7220
7221         * mini-x86.c, cpu-pentium.md, inssel-x86.brg: Fixed bug
7222         with add function when used from Inc/dec atomic 
7223         functions. Re-enabled optimization on x86.
7224         * mini-ops.h: renamed atomic_add functions to
7225         allow _add to match the Interlocked::Add and
7226         _add_next to match Interlocked::Inc/Dec.
7227
7228 2004-12-15  Massimiliano Mantione  <massi@ximian.com>
7229
7230         * mini.c: Fixed a subtle bug in mono_method_to_ir, about the
7231         linking of BBs to the end BB, and enabled SSAPRE also with
7232         consprop and copyprop (which was prevented by that bug).
7233
7234 2004-12-14  Patrik Torstensson  <patrik.torstensson@gmail.com>
7235
7236         * mini-x86.c: disabling the Interlocked optimizing code. 
7237
7238 2004-12-14  Zoltan Varga  <vargaz@freemail.hu>
7239
7240         * aot.c (load_aot_module): Move reading of got_addr after the AOT
7241         file version check.
7242         
7243 2004-12-14  Patrik Torstensson  <patrik.torstensson@gmail.com>
7244
7245         * mini-x86.c, inssel-x86.brg, cpu-pentium.md: removed _imm 
7246         interlocked optimization due lack of support on x86, rewrote 
7247         exchange to take into account that base may be in eax.
7248         
7249         xsp works again; activated Interlocked optimizing code.
7250         
7251 2004-12-14  Zoltan Varga  <vargaz@freemail.hu>
7252
7253         * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file version.
7254
7255 2004-12-13  Zoltan Varga  <vargaz@freemail.hu>
7256
7257         * mini-ops.h: Add new opcodes.
7258
7259         * mini.h: Add new patch types. Add got_var to MonoCompile.
7260
7261         * mini.h mini-x86.c mini-amd64.c aot.c: Rename 
7262         mono_arch_get_aot_patch_offset () to mono_arch_get_patch_offset () and
7263         make it work with all kinds of patchable code.
7264
7265         * inssel.brg inssel-x86.brg: Add new rules dealing with computing the
7266         address of the GOT, and referencing entries in the GOT.
7267
7268         * mini.c: Add code to load the GOT address if needed by an opcode.
7269
7270         * aot.c mini-x86.h mini-x86.c cpu-pentium.md: Add support for position 
7271         independent AOT code on the x86 using an elf-style Global Offset Table.
7272
7273 2004-12-14  Raja R Harinath  <rharinath@novell.com>
7274
7275         * Makefile.am (RUNTIME): Set MONO_SHARED_DIR.
7276
7277 2004-12-13 Gonzalo Paniagua Javier <gonzalo@ximian.com>
7278
7279         * mini-x86.c: disabling the Interlocked optimizing code. It segfaults
7280         when running xsp.
7281
7282 2004-12-13  Patrik Torstensson  <patrik.torstensson@gmail.com>
7283
7284         * mini-x86.c,mini-ops.h,inssel-x86.brg,cpu-pentium.md: Implementation
7285         of Interlocked:Increment/Decrement/Add as inline ops.
7286         (mini-x86.c (mono_arch_get_inst_for_method and mono_arch_output_basic_block))
7287
7288 2004-12-12  Geoff Norton  <gnorton@customerdna.com>
7289
7290         * exceptions-ppc.c: Reorder code so gcc3.4 can compile it
7291         * mini-ppc.c: Unify mono_arch_patch_code with changes in r37636.
7292
7293 2004-12-12  Duncan Mak  <duncan@ximian.com>
7294
7295         * mini-ppc.c (mono_arch_patch_code): Hopefully made this build
7296         again. `patch_info->table_size' is no longer valid after Zoltan's
7297         commit #37636.
7298
7299 2004-12-12  Martin Baulig  <martin@ximian.com>
7300
7301         * mini.c (mono_method_to_ir): Only call mono_debug_init_method()
7302         if we are the "real" method, ie. not an inlined method inside it.
7303
7304 2004-12-11  Ben Maurer  <bmaurer@ximian.com>
7305
7306         * mini.c (CEE_LDSFLD): Make sure that the vtable has been init'd
7307         before we look in the special fields table. This fixes
7308         ../tests/thread-static-init.cs.
7309
7310 2004-12-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
7311
7312         * mini.c: return immediately after setting OP_ARRAY_RANK or CEE_LDLEN
7313         for Array get_Rank and get_Length. Fixes bug #70465.
7314
7315 2004-12-11  Zoltan Varga  <vargaz@freemail.hu>
7316
7317         * mini.h mini.c aot.c: Put the bblock table for a SWITCH patch into a
7318         separate structure to reduce the size of MonoJumpInfo.
7319
7320 Fri Dec 10 18:09:22 CET 2004 Paolo Molaro <lupus@ximian.com>
7321
7322         * mini.c, mini.h, aot.c, driver.c: allow disabling the aot code.
7323
7324 2004-12-10  Patrik Torstensson  <patrik.torstensson@gmail.com>
7325
7326         * mini.c (mini_get_inst_for_method): Changed to allow ports
7327         to return a MonoInst instead of opcode 
7328         (renamed mini_get_opcode_for_method to better reflect the new functionality)
7329         
7330         * mini-[x86|s390|s390x|ppc|sparc].c (mono_arch_get_inst_for_method): 
7331         Allow ports to return a created MonoInst instead of op-code, will enable
7332         new optimizations.
7333         (renamed mini_get_opcode_for_method to better reflected the functionality)
7334
7335 2004-12-09  Zoltan Varga  <vargaz@freemail.hu>
7336
7337         * mini.c (NEW_AOTCONST): Share some code between the different NEW_AOTCONST macros.
7338
7339 2004-12-08  Zoltan Varga  <vargaz@freemail.hu>
7340
7341         * mini.c jit-icalls.c: Pass generic_context to mono_ldtoken_wrapper.
7342         Fixes #69985.
7343
7344 2004-12-08  Martin Baulig  <martin@ximian.com>
7345
7346         * mini.c (mono_method_to_ir): In CEE_CALLVIRT, use `fsig->signature'
7347         if we're a CEE_CONSTRAINED call.  Fixes gen-118.cs.
7348
7349 2004-12-08  Zoltan Varga  <vargaz@freemail.hu>
7350
7351         * mini-sparc.c (mono_arch_output_basic_block): Implement OP_FCONV_TO_<X>
7352         correctly.
7353
7354         * exceptions.cs: Disable some tests which depend on properties of x86 fp
7355         arithmetic.
7356
7357 2004-12-08  Raja R Harinath  <rharinath@novell.com>
7358
7359         * Makefile.am (CLEANFILES): Add *.exe, *.dll.
7360
7361 2004-12-07  Zoltan Varga  <vargaz@freemail.hu>
7362
7363         * mini-sparc.c (mono_arch_output_basic_block): Fix LOCALLOC_IMM
7364         bug introduced by the previous patch.
7365
7366 Tue Dec 7 11:44:39 CET 2004 Paolo Molaro <lupus@ximian.com>
7367
7368         * mini-ppc.c, objectc.cs: handle large structs passed by value
7369         (fixes bug #69972).
7370
7371 Tue Dec 7 10:43:31 CET 2004 Paolo Molaro <lupus@ximian.com>
7372
7373         * mini-ppc.c: OP_ARGLIST implementation from
7374         Geoff Norton  <gnorton@customerdna.com>.
7375
7376 Tue Dec 7 10:14:25 CET 2004 Paolo Molaro <lupus@ximian.com>
7377
7378         * inssel-x86.brg, inssel-ppc.brg: fix reference to register
7379         in stmt: OP_OUTARG_VT (reg) (should fix bug #69785).
7380
7381 Tue Dec 7 10:06:39 CET 2004 Paolo Molaro <lupus@ximian.com>
7382
7383         * exceptions-ppc.c: avoid calling ppc_patch in exception trampolines.
7384
7385 2004-12-01  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
7386
7387         * inssel-s390.brgi, mini-ops.h, mini-s390.c : Add stubs for support of tls offset
7388         support.
7389
7390 2004-12-06  Zoltan Varga  <vargaz@freemail.hu>
7391
7392         * mini-sparc.c: Zero out localled-ed memory.
7393
7394         * iltests.il: Add tests for zeroing out localloc-ed memory.
7395
7396 2004-12-04  Martin Baulig  <martin@ximian.com>
7397
7398         * mini.c (mono_method_to_ir): In CEE_CALLVIRT, use the new
7399         mono_method_get_signature_full().       
7400
7401 2004-12-03  Massimiliano Mantione  <massi@ximian.com>
7402
7403         * mini.c: Added removal of critical edges (prerequisite for SSAPRE),
7404         and some utility functions (always for SSAPRE), integrated SSAPRE.
7405         * mini.h: Likewise.
7406         * driver.c: Added ssapre option.
7407         * ssa.c: Small fix on OP_ARG handling.
7408         * ssapre.c, ssapre.h: Added files containing SSAPRE implementation.
7409         * Makefile.am: Likewise.
7410
7411 2004-12-02  Zoltan Varga  <vargaz@freemail.hu>
7412
7413         * tramp-x86.c (mono_arch_create_jit_trampoline): Remove code which is
7414         now in the xp code.
7415
7416         * mini.c (mini_init): Register mono_thread_force_interruption_checkpoint
7417         icall.
7418
7419 2004-12-01  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
7420
7421         * inssel-s390.brg : Add OP_OUTARG_VT (OP_REFANYTYPE (reg)) rule.
7422         
7423         * cpu-s390.md : Increase instruction length of oparglist.
7424
7425         * mini-s390.c : Implement vararg and TYPEDEBYREF support.
7426
7427 2004-11-30  Martin Baulig  <martin@ximian.com>
7428
7429         * mini.c (mono_method_to_ir): In CEE_CALLVIRT, added support for
7430         virtual generic methods.  We call a special helper_compile_generic_method()
7431         icall to retrieve the method from the vtable, inflate and compile
7432         it and then do a CEE_CALLI.  Thanks a lot to Paolo for this idea.
7433
7434         * jit-icalls.c (helper_compile_generic_method): New JIT icall.
7435
7436 2004-11-30  Zoltan Varga  <vargaz@freemail.hu>
7437
7438         * mini-sparc.c: Fix up vararg corner cases. Fixes #70019.
7439
7440 2004-11-29  Zoltan Varga  <vargaz@freemail.hu>
7441
7442         * cpu-sparc.md mini-sparc.c (long_conv_to_ovf_i): Fill missing delay slot.
7443         Fixes #69929.
7444
7445 2004-11-27  Ben Maurer  <bmaurer@ximian.com>
7446
7447         * inssel.brg (CEE_SWITCH): The AOT stuff Zoltan added is only for
7448         platforms with PIC aot.
7449
7450 2004-11-28  Martin Baulig  <martin@ximian.com>
7451
7452         * mini.c (mono_method_to_ir): In CEE_DUP, added handle_stobj().
7453         Fixes gen-112.cs.
7454
7455 2004-11-28  Martin Baulig  <martin@ximian.com>
7456
7457         * mini-x86.c (mono_arch_call_opcode): Use the original type, not
7458         the result of mono_type_get_underlying_type() to check whether
7459         we're byref.
7460
7461 2004-11-26  Martin Baulig  <martin@ximian.com>
7462
7463         * mini.c
7464         (mono_method_to_ir): Use `!method->signature->has_type_parameters'
7465         in the g_assert().
7466
7467 2004-11-26  Zoltan Varga  <vargaz@freemail.hu>
7468
7469         * mini-amd64.c (mono_arch_emit_this_vret_args): Handle this and vret
7470         the same way as the other arguments so they won't get clobbered.
7471
7472         * mini-amd64.c (mono_arch_output_basic_block): Avoid doing virtual 
7473         calls through R11 since it is clobbered by the trampoline code.
7474
7475 2004-11-26  Raja R Harinath  <rharinath@novell.com>
7476
7477         * Makefile.am: Consistently use $(RUNTIME) rather than ./mono to
7478         pick up in-tree mscorlib.dll.
7479
7480 2004-11-25  Zoltan Varga  <vargaz@freemail.hu>
7481
7482         * aot.c: Rename MonoAOTModule->cleanup to out_of_date.
7483
7484         * mini-amd64.c aot.c: Switch to PIC relative AOT code. References to 
7485         runtime data/code are now stored in a table similar to the GOT in ELF. 
7486         This allows the code itself to be position independent.
7487
7488         * aot.c: Fix loading of referenced assemblies after the lazy assembly
7489         loading changes.
7490
7491         * aot.c: Attach ELF type (object/function) directives to all global
7492         symbols.
7493
7494         * tramp-amd64.c (amd64_magic_trampoline): Patch RIP relative calls too.
7495
7496         * inssel.brg (SWITCH): Emit an AOT_CONST in the aot case.
7497
7498         * mini-amd64.h: Turn on PIC AOT code.
7499
7500         * mini.h (mono_arch_get_aot_patch_offset): New arch specific function
7501         returning the offset within an OP_AOTCONST instruction where the GOT
7502         offset needs to be added.
7503
7504         * mini.h: Bump AOT file format version.
7505
7506 2004-11-25  Martin Baulig  <martin@ximian.com>
7507
7508         * mini.c (mono_method_to_ir): In CEE_CALL, don't allow calling any
7509         uninflated generic methods.
7510
7511 2004-11-25  Martin Baulig  <martin@ximian.com>
7512
7513         * mini.c (mono_method_to_ir): Don't allow any uninflated generic methods.
7514
7515 2004-11-24  Martin Baulig  <martin@ximian.com>
7516
7517         * minit.c (type_to_eval_stack_type): Set `inst->klass' to the
7518         original klass (this only applies for generic instances).
7519
7520 2004-11-24  Martin Baulig  <martin@ximian.com>
7521
7522         * mini.c (mono_method_to_ir): Use `STACK_OBJ' instead of
7523         `ldind_type [CEE_LDIND_REF]' (which would be beyond the end of
7524         that array).
7525
7526 2004-11-24  Zoltan Varga  <vargaz@freemail.hu>
7527
7528         * mini.c (mono_method_to_ir): Disable inlining for methods containing
7529         localloc. Fixes #69678.
7530
7531         * iltests.il (test_0_localloc_inline): Add regression test for #69678.
7532         
7533 2004-11-23  Zoltan Varga  <vargaz@freemail.hu>
7534
7535         * mini-amd64.c (mono_arch_output_basic_block): Set %al to the number of
7536         used SSE registers on pinvoke calls. Fixes #69774.
7537
7538 2004-11-23  Geoff Norton  <gnorton@customerdna.com>
7539
7540         * inssel-ppc.brg, mini-ppc.c: Use mono_class_from_mono_type instead of
7541         vt->inst_vtype->data.klass.  This fixes generic structs and bug #69766
7542
7543 2004-11-23  Raja R Harinath  <rharinath@novell.com>
7544
7545         * Makefile.am (MCS,ILASM): Don't refer to runtime/ directory.
7546         Refer directly to the mcs/ tree.
7547
7548 2004-11-19  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
7549
7550         * mini-s390.c, tramp-s390.c, mini-s390.h: Add LMF processing for trampolines.
7551         Check if a trampoline for a synchronized method is required. 
7552
7553 Fri Nov 19 17:34:21 CET 2004 Paolo Molaro <lupus@ximian.com>
7554
7555         * mini-ppc.c, cpu-g4.md: set to zero the memory allocated
7556         with localloc if needed. Throe arithmetric exception in
7557         div an rem if needed. Implement ovf checks in OP_LCONV_TO_OVF_I.
7558         Adapted from a patch by Geoff Norton  <gnorton@customerdna.com>.
7559
7560 2004-11-19  Geoff Norton  <gnorton@customerdna.com>
7561
7562         * mini-ppc.c: Call mono_type_get_underlying_type to unwrap generic
7563         types before switching on type.  Fixes #69622.
7564
7565 2004-11-19  Raja R Harinath  <rharinath@novell.com>
7566
7567         * Makefile.am (check-local): New.  Integrate into 'make check'.
7568         (MCS,RUNTIME): Define using in-tree mono and mcs.
7569         (ILASM): New.
7570         (%.exe): Use $(ILASM).
7571
7572 Fri Nov 19 14:54:07 CET 2004 Paolo Molaro <lupus@ximian.com>
7573
7574         * mini-ppc.c: adjust initial prolog size (bug #69691).
7575
7576 2004-11-18  Zoltan Varga  <vargaz@freemail.hu>
7577
7578         * cpu-pentium.md (localloc): Increase max instruction len. Fixes
7579         #69664.
7580
7581 2004-11-17  Raja R Harinath  <rharinath@novell.com>
7582
7583         * Makefile.am (clean-local): Rename from 'clean'.
7584
7585 2004-11-15  Nelae Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
7586
7587         * mini.c, mini-x86.c, mini-amd64.c, exceptions-s390.c: Add siginfo_t parameter
7588         to mono_arch_is_int_overflow. 
7589         * exceptions-s390.c: Add mono_arch_is_int_overflow routine to discern between
7590         SIGFPE events.
7591
7592 2004-11-15  Sebastien Pouliot  <sebastien@ximian.com>
7593
7594         * declsec.c|h: New files to support declarative security attributes.
7595         Added function to check if a method has (applicable) security.
7596         * mini.c|h: Add check for declarative security attributes in
7597         mono_method_check_inlining.
7598         * Makefile.am: Added declsec.c and declsec.h to the build.
7599
7600 Mon Nov 15 11:53:46 CET 2004 Paolo Molaro <lupus@ximian.com>
7601
7602         * mini.c, mini.h: update to keep dynamic code info per-domain.
7603
7604 2004-11-12  Zoltan Varga  <vargaz@freemail.hu>
7605
7606         * mini.c mini-*.h: Get rid of MONO_ARCH_HAVE_RETHROW since all architectures support it now.
7607         (mini_init): Get rid of it from here too.
7608
7609 Thu Nov 11 20:17:17 CET 2004 Paolo Molaro <lupus@ximian.com>
7610
7611         * mini-ppc.c, mini-ppc,h, cpu-g5.md, exceptions-ppc.c:
7612         implemented OP_RETHROW (patch by Geoff Norton
7613         <gnorton@customerdna.com>).
7614
7615 2004-11-10  Geoff Norton  <gnorton@customerdna.com>
7616
7617         * tramp-ppc.c (ppc_magic_trampoline): Don't trampoline methods
7618         between appdomains.  Fixes appdomain-unload on PPC.
7619
7620 2004-10-26  Lluis Sanchez Gual  <lluis@novell.com>
7621
7622         * exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
7623         mini-exceptions.c: handle the new wrapper types.
7624         * mini.c: The CEE_ISINST and CEE_CASTCLASS opcodes now take the
7625         token value as a MonoClass* when compiling a wrapper.
7626         mono_jit_create_remoting_trampoline now takes an additional
7627         MonoRemotingTarget parameter.
7628         
7629 2004-11-10  Martin Baulig  <martin@localhost>
7630
7631         * mini.c (mono_method_to_ir): Use `generic_container->context'
7632         rather than creating a new one.
7633
7634 2004-11-09  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
7635
7636         * exceptions-s390.c, mini-s390, cpu-s390.md: Add support for OP_RETHROW.
7637
7638         * inssel-390.md, mini-s390.c: Correct register allocation for globals.
7639
7640 2004-11-09  Zoltan Varga  <vargaz@freemail.hu>
7641
7642         * aot.c (mono_aot_init): Add MONO_AOT_CACHE env variable to turn on
7643         the experimental aot cache stuff.
7644
7645 Tue Nov 9 17:30:20 CET 2004 Paolo Molaro <lupus@ximian.com>
7646
7647         * aot.c, mini.c, exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
7648         mini-exceptions.c: update to exception clause structure changes.
7649
7650 2004-11-08  Zoltan Varga  <vargaz@freemail.hu>
7651
7652         * exceptions-x86.c (throw_exception): Fix warnings.
7653
7654         * mini-x86.h mini-x86.c cpu-pentium.md exceptions-x86.c: Add support 
7655         for OP_RETHROW.
7656
7657 2004-11-08  Zoltan Varga  <vargaz@freemail.hu>
7658
7659         * exceptions-sparc.c (get_throw_exception): Really fix this.
7660
7661 2004-11-07  Ben Maurer  <bmaurer@ximian.com>
7662
7663         * tramp-*.c: we no longer support icalls without wrappers, so
7664         a bit of code can be removed here
7665
7666 2004-11-07  Zoltan Varga  <vargaz@freemail.hu>
7667
7668         * exceptions-sparc.c (get_throw_exception): Fix more bugs in previous
7669         patch.
7670
7671         * cpu-sparc.md: Add op_rethrow.
7672
7673         * exceptions-sparc.c (get_throw_exception): Fix bug in previous patch.
7674
7675         * mini-sparc.h mini-sparc.c exceptions-sparc.c: Add support for OP_RETHROW.
7676
7677         * mini.h: Add mono_arch_get_rethrow_exception () arch specific function.
7678         * mini-ops.h: Add OP_RETHROW.
7679
7680         * mini.c inssel.brg: Distinguish between THROW and RETHROW.
7681
7682         * cpu-amd64.c mini-amd64.c exceptions-amd64.c: Add support for OP_RETHROW.
7683
7684 2004-11-05  Geoff Norton  <gnorton@customerdna.com>
7685         
7686         * helpers.c: Change otool arguments from -V -v -t to -v -t on Darwin
7687         Makes the output much easier to read
7688
7689 2004-11-05  Ben Maurer  <bmaurer@ximian.com>
7690
7691         * ssa.c: allocate MonoMethodVar.uses from the mempool. First, this
7692         prevents another huge leak when compiling with ssa. Secondly, the
7693         performance of doing this rather than freeing the lists is much
7694         better. GList does a lock every time you allocate a list link,
7695         so that it can use a memory pool. So, it is better to just use
7696         a memory pool of our own.
7697         
7698         * ssa.c, linear-scan.c: replace g_list_remove_link with
7699         g_list_delete.  The remove one does not free the GList, so we were
7700         leaking memory. On -O=all --compile-all with corlib, this cut down
7701         3 MB of allocations.
7702
7703 2004-11-05  Zoltan Varga  <vargaz@freemail.hu>
7704
7705         * tramp-sparc.c (mono_arch_create_jit_trampoline): Fix sparc build.
7706
7707         * tramp-amd64.c (mono_arch_create_jit_trampoline): Fix amd64 build.
7708
7709         * mini.h mini.c tramp-*.c: Moved xp parts of JIT trampoline creation
7710         into a new function mono_create_jit_trampoline ().
7711
7712 2004-11-02  Zoltan Varga  <vargaz@freemail.hu>
7713
7714         * trace.c (get_spec): Allow tracing of classes without a namespace.
7715
7716 2004-11-02  Sebastien Pouliot  <sebastien@ximian.com>
7717
7718         * mini.c: Fix pointer overwrite in mini_method_compile.
7719
7720 2004-11-2  Geoff Norton  <gnorton@customerdna.com>
7721
7722         * inssel-ppc.brg (OP_OUTARG_VT (CEE_LDOBJ (base))):
7723         The darwin ABI needs some special handling for 1 and 2 byte structs
7724         Lets use lbz/lhz instead of lwz everywhere.
7725         * mini-ppc.c (calculate_sizes):  The Darwin ABI needs from special handling
7726         for 1 and 2 byte structs and struct which are size >= 3 || size % 4 != 0.
7727         Use stb/sth for the former, and put the latter always on stack instead of in
7728         argument registers.
7729
7730 2004-10-30  Zoltan Varga  <vargaz@freemail.hu>
7731
7732         * trace.c (is_filenamechar): Add '_'.
7733
7734 2004-10-29  Neale Ferguson  <Neale.Ferguson@SoftwareAG-usa.com>
7735
7736         * mini-s390.c: Fix prolog length to allow for large trace requirements.
7737
7738         * exceptions-s390.c: Remove dwarf unwinding stuff that was unused.
7739
7740 2004-10-29  Zoltan Varga  <vargaz@freemail.hu>
7741
7742         * Makefile.am (libgc_libs): Do some automake magic so libmono/mono
7743         depends on libmonogc. Fixes #68805.
7744
7745 2004-10-26  Miguel de Icaza  <miguel@ximian.com>
7746
7747         * mini.c (mono_jit_free_method): Provide extra information for
7748         this error.  Currently this leaks, but will be turned into a
7749         developer option in the future.
7750
7751 2004-10-26  Zoltan Varga  <vargaz@freemail.hu>
7752
7753         * driver.c (mono_main): Applied patch from Willibald Krenn <willibald.krenn@gmx.at>. Make --graph work for icalls and pinvoke methods.
7754
7755 2004-10-25  Zoltan Varga  <vargaz@freemail.hu>
7756
7757         * aot.c (mono_aot_load_method): Align PATCH_INFO_R8 on an 8 byte 
7758         boundary. Fixes reading of PATCH_INFO_R4 and R8.
7759         (mono_aot_load_method): Do not allocate MonoAotMethod in the GC heap.
7760
7761 2004-10-24  Zoltan Varga  <vargaz@freemail.hu>
7762
7763         * mini-amd64.c (mono_arch_patch_code): Fix patching of class init
7764         trampolines for AOT code.
7765
7766 2004-10-22    <vargaz@freemail.hu>
7767
7768         * aot.c (mono_compile_assembly): Disable AOT for methods containing calls to methods of
7769         constructed types. Fixes #68136.
7770
7771 2004-10-21  Martin Baulig  <martin@ximian.com>
7772
7773         * exceptions-x86.c (throw_exception): Call mono_debugger_throw_exception();
7774         if it returns true, unwind the stack to the call instruction.
7775
7776 2004-10-21    <vargaz@freemail.hu>
7777
7778         * aot.c: Reorganize the AOT file format to avoid relocations. Fix warnings.
7779
7780         * mini.h: Bump AOT version number.
7781
7782         * objects.cs: Add another test for unbox trampolines.
7783
7784         * tramp-amd64.c (amd64_magic_trampoline): Disable patching of trampolines for 
7785         valuetype methods.
7786
7787 2004-10-20    <vargaz@freemail.hu>
7788
7789         * driver.c: Add SHARED to the set of optimizations tested.
7790
7791         * tramp-amd64.c (amd64_magic_trampoline): Patch trampoline code as well.
7792
7793         * mini.c (mono_method_to_ir): Mark the domainvar as volatile when it is implicitly
7794         used by CEE_NEWARR.
7795
7796         * ssa.c (mono_ssa_deadce): Do not optimize away accesses to volatile variables.
7797
7798 2004-10-20  Martin Baulig  <martin@ximian.com>
7799
7800         * mini-exceptions.c (mono_handle_exception): Call
7801         mono_debugger_handle_exception() to tell the debugger about
7802         catch/finally clauses.
7803
7804 2004-10-18  Zoltan Varga  <vargaz@freemail.hu>
7805
7806         * exceptions-amd64.c (mono_arch_find_jit_info): Pop arguments of the stack.
7807
7808         * mini-amd64.c (mono_amd64_get_vcall_slot_addr): Handle extended registers. Fixes
7809         #68447.
7810
7811 2004-10-15  Geoff Norton  <gnorton@customerdna.com>
7812
7813         * mini-ppc.c (calculate_sizes): Marshal valuetypes for pinvoke
7814         methods as their native size, fixed bug #57543, #57545.
7815         * mini-ppc.c (mono_arch_output_basic_block): Use mulli for imm16 types
7816         This saves a temporary register and mullw call down into 1 (minor perf
7817         increase for cases like sum = sum * 5;  This use to translate into:
7818             li r11,5
7819             mullw r28,r28,r11
7820         It now translates to
7821             mulli r28,r28,5
7822
7823 2004-10-15  Zoltan Varga  <vargaz@freemail.hu>
7824
7825         * trace.c (mono_trace_eval): Use mono_method_desc_full_match. Fixes
7826         #68388.
7827
7828 2004-10-11  Martin Baulig  <martin@ximian.com>
7829
7830         * mini.c (mono_method_to_ir): If we're a generic method, get the
7831         MonoGenericContainer from our MonoMethodNormal and create a
7832         MonoGenericContext from it.
7833
7834 2004-10-08  Zoltan Varga  <vargaz@freemail.hu>
7835
7836         * inssel-long32.brg (OP_LCONV_TO_OVF_I2): Fix CONV_I1 -> CONV_I2.
7837
7838         * basic-long.cs: Add test for checked i8->i2 cast.
7839
7840 Wed Oct 6 12:40:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
7841
7842         * inssel-ppc.brg: added a couple of speedup rules.
7843
7844 2004-10-05  Zoltan Varga  <vargaz@freemail.hu>
7845
7846         * Makefile.am (genmdesc_LDADD): Don't link this against libmetadata
7847         to speed up rebuilds.
7848
7849 2004-10-04  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
7850
7851         * mini-s390.c: Minor fix to OP_OR_IMM.
7852
7853 2004-10-03  Zoltan Varga  <vargaz@freemail.hu>
7854
7855         * tramp-sparc.c (sparc_magic_trampoline): Handle appdomain stuff
7856         better. Fixes appdomain-unload.exe on sparc.
7857
7858 2004-10-02  Massimiliano Mantione  <massi@ximian.com>
7859
7860         * ssa.c: Fixed casts to unsigned where the value was of 64 bits in
7861         simulate_long_compare, patch by will@exomi.com (Ville-Pertti Keinonen),
7862         see bug 67324.
7863
7864 2004-10-02  Zoltan Varga  <vargaz@freemail.hu>
7865
7866         * jit-icalls.c: Handle a nonexisting trunc function more correctly.
7867
7868 2004-09-30  Lluis Sanchez Gual  <lluis@novell.com>
7869
7870         * mini.c: Always generate a field read/write wrapper for members
7871         of the class MarshalByRefObject since the actual instance could
7872         be a CBO.
7873
7874 2004-09-28  Lluis Sanchez Gual  <lluis@novell.com>
7875
7876         * mini.c: Use mono_thread_exit() to stop threads, instead of ExitThread.
7877
7878 2004-09-28  Zoltan Varga  <vargaz@freemail.hu>
7879
7880         * driver.c mini.h trace.c: Move the setting of the main assembly into
7881         a separate function called mono_trace_set_assembly () and call it after
7882         actually loading the main assembly. Fixes #66872.
7883
7884 2004-09-25  Zoltan Varga  <vargaz@freemail.hu>
7885
7886         * mini-amd64.h mini-amd64.c tramp-amd64.c: Allocate trampoline memory
7887         using the code manager.
7888
7889 2004-09-24  Zoltan Varga  <vargaz@freemail.hu>
7890
7891         * tramp-amd64.c mini-amd64.h: Add support for MONO_ARCH_HAVE_INVALIDATE_METHOD.
7892
7893 2004-09-23  Zoltan Varga  <vargaz@freemail.hu>
7894
7895         * cpu-amd64.md: Fix bug in previous patch.
7896         
7897         * cpu-amd64.md: Fix instruction lengths of membase opcodes. Fixes
7898         #66650.
7899
7900 Wed Sep 22 19:03:20 CEST 2004 Paolo Molaro <lupus@ximian.com>
7901
7902         * mini.h, exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
7903         mini-exceptions.c: updates for changed stack walk interface.
7904
7905 2004-09-21  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
7906
7907         * mini-s390.c, cpu-s390.md: Minor changes to OP_ARGLIST handling
7908
7909 2004-09-17  Zoltan Varga  <vargaz@freemail.hu>
7910
7911         * mini.c (mono_method_to_ir): Fix LDSTR in dynamic methods. Fixes #66132.
7912
7913 2004-09-13  Zoltan Varga  <vargaz@freemail.hu>
7914
7915         * driver.c (mini_regression_list): Do not call mono_assembly_close 
7916         since assemblies can't be unloaded.
7917         
7918 2004-09-11  Zoltan Varga  <vargaz@freemail.hu>
7919
7920         * cpu-amd64.md: Fix more instruction lengths.
7921
7922         * cpu-amd64.md: Fix lengths of some instructions.
7923
7924 2004-09-11 Ben Maurer  <bmaurer@users.sourceforge.net>
7925
7926         * inssel.brg: Make the array ldelema check aot friendly.
7927
7928 2004-09-11  Zoltan Varga  <vargaz@freemail.hu>
7929
7930         * mini-amd64.c (mono_arch_get_argument_info): Fix stack_unwind test.
7931
7932         * cpu-amd64.md inssel-long.brg inssel-amd64.brg: Small optimizations.
7933
7934 2004-09-10  Zoltan Varga  <vargaz@freemail.hu>
7935
7936         * mini-x86.c: Fix build.
7937
7938         * mini-sparc.c mini-x86.c mini-amd64.c: Use the new 
7939         mono_type_get_underlying_type () helper function to simplify code.
7940         
7941 2004-09-09  Martin Baulig  <martin@ximian.com>
7942
7943         * mini-amd64.c: Don't access `type->data.klass' directly, call
7944         mono_class_from_mono_type() instead since the type may be a
7945         generic instance.
7946
7947 2004-09-09  Martin Baulig  <martin@ximian.com>
7948
7949         * mini-amd64.c (get_call_info): Fix support for generic instances.
7950         (add_valuetype): Use mono_class_from_mono_type() to get the class
7951         since we can be a generic instance.
7952
7953 Thu Sep 9 01:43:53 PDT 2004 Paolo Molaro <lupus@ximian.com>
7954
7955         * mini-ppc.c, mini.h, regalloc.c, regalloc.h: powerpc speedups.
7956
7957 2004-09-07 Ben Maurer  <bmaurer@users.sourceforge.net>
7958
7959         * liveness.c: reset spill costs on each scan: bug 62107
7960
7961 2004-09-07  Bernie Solomon  <bernard@ugsolutions.com>
7962
7963         * exceptions-sparc.c (mono_arch_find_jit_info): remove
7964         unnecessary line that doesn't compile
7965
7966 2004-09-07  Zoltan Varga  <vargaz@freemail.hu>
7967
7968         * mini.c mini.h mini-x86.h tramp-x86.c: Instead of freeing delegate
7969         trampolines, make them call an error function so people can fix their
7970         code.
7971
7972 2004-09-06  Martin Baulig  <martin@ximian.com>
7973
7974         * mini.c (mono_method_to_ir): When initializing locals, handle a
7975         generic instances like a valuetype if it's a valuetype and like a
7976         class if it's a class.
7977
7978 2004-09-06  Zoltan Varga  <vargaz@freemail.hu>
7979
7980         * exceptions-x86.c (mono_arch_find_jit_info): Pop arguments off the
7981         stack. Fixes #64674.
7982
7983         * exceptions.cs: Add test for unwinding of call arguments.
7984
7985 Mon Sep 6 05:50:02 PDT 2004 Paolo Molaro <lupus@ximian.com>
7986
7987         * mini-*.c, mini-ops.h, inssel-long32.brg: introduced
7988         OP_ADDCC_IMM and OP_SUBCC_IMM (add/sub immediate that will
7989         set the carry/borrow flag). The sparc and s390 implementations
7990         can now use optimized versions (and simplify the code). ppc bugfixes.
7991
7992 2004-09-06  Zoltan Varga  <vargaz@freemail.hu>
7993
7994         * exceptions-ppc.c (mono_arch_find_jit_info): Fix memory leak.
7995
7996 2004-09-05  Zoltan Varga  <vargaz@freemail.hu>
7997
7998         * inssel-amd64.brg: Remove leftover 32 bit rule.
7999
8000         * mini-amd64.c (mono_arch_instrument_prolog): Fix tracing support.
8001
8002 2004-09-04  Zoltan Varga  <vargaz@freemail.hu>
8003
8004         * mini-exceptions.c (mono_find_jit_info): Refactor common code from
8005         mono_arch_find_jit_info functions into a new function. Fix a memory
8006         leak.
8007
8008         * exceptions-x86.c exceptions-amd64.c exceptions-sparc.c: Remove
8009         refactored code.
8010         
8011 2004-09-02  Zoltan Varga  <vargaz@freemail.hu>
8012
8013         * exceptions.cs inssel-long32.brg: Handle the OP_LCONV_TO_OVF_I2 case
8014         as well.
8015         
8016         * exceptions.cs: Add array size tests.
8017
8018         * mini.c: Allocate a separate icall wrapper for each arity of 
8019         mono_array_new_va. Fixes #59509.
8020
8021         * exceptions.cs: Add testcase for 64578.
8022
8023         * inssel-long32.brg: Fix OP_LCONV_TO_OVF_I1 rule. Fixes #64578.
8024
8025         * trace.c (is_filenamechar): Allow 0..9 in strings. Fixes #65094.
8026         
8027 2004-09-02  Martin Baulig  <martin@ximian.com>
8028
8029         * mini.c (mono_method_to_ir): When initializing the locals, call
8030         handle_initobj() on the generic instance itself, not its
8031         underlying type.
8032
8033 2004-09-02  Zoltan Varga  <vargaz@freemail.hu>
8034
8035         * mini.h (MonoJitDynamicMethodInfo): New structure, extension of 
8036         MonoJitInfo for dynamic methods.
8037
8038         * mini.c: Rename trampoline_hash_mutex to jit_mutex.
8039
8040         * mini.c: Add support for freeing JIT data for dynamic methods.
8041         
8042 2004-09-01  Martin Baulig  <martin@ximian.com>
8043
8044         * mini-x86.c (is_regsize_var): Added support for generic
8045         instances.
8046         (mono_arch_emit_prolog): Make this compile again, use
8047         `x86_push_imm_template (code)'.
8048
8049 2004-08-30 Ben Maurer  <bmaurer@users.sourceforge.net>
8050
8051         * mini-x86.c: make all push_imm instructions that get
8052         patched always emit the long form
8053
8054 2004-08-30  Zoltan Varga  <vargaz@freemail.hu>
8055
8056         * mini.c (mono_create_jump_trampoline): Store the jump trampolines 
8057         in a per-domain hash.
8058
8059         * mini-amd64.c (merge_argument_class_from_type): Handle generic
8060         types.
8061
8062 2004-08-29  Zoltan Varga  <vargaz@freemail.hu>
8063
8064         * mini-amd64.c cpu-amd64.md inssel-amd64.brg mini-amd64.h: Ongoing SSE
8065         work.
8066         
8067         * mini-amd64.c cpu-amd64.md inssel-amd64.brg mini-amd64.h: More SSE
8068         work.
8069
8070         * mini-amd64.c cpu-amd64.md: Implement checked int<->uint casts.
8071         Beginnings of SSE2 support.
8072
8073         * exceptions.cs: Add more tests for checked int<->uint casts.
8074
8075 2004-08-28  Martin Baulig  <martin@ximian.com>
8076
8077         * mini-x86.c (mono_arch_instrument_epilog): Added support for
8078         generic instances.
8079
8080         * mini.c
8081         (mono_type_to_ldind, mono_type_to_stind, type_to_eval_stack_type):
8082         Handle generic instances recursively.
8083
8084 2004-08-27 Ben Maurer  <bmaurer@users.sourceforge.net>
8085
8086         * iltests.il: test for conv.u8 on a constant
8087
8088 2004-08-27 Ben Maurer  <bmaurer@users.sourceforge.net>
8089
8090         * inssel-long32.brg: c&p rules for LCONV_x4 (membase) and
8091         LCONV_x4 (shrun_32 (membase)).
8092
8093 2004-08-27 Ben Maurer  <bmaurer@users.sourceforge.net>
8094
8095         * inssel-x86.brg: c&p rules for push/setret of long
8096
8097 2004-08-26 Ben Maurer  <bmaurer@users.sourceforge.net>
8098
8099         * inssel-x86.brg: c&p rules for compare (base, regvar) and
8100         compare (regvar, base)
8101
8102         * inssel-x86.brg: more burg love
8103
8104         * inssel.brg: more cleanup
8105
8106         * inssel-x86.brg, inssel-long32.brg: burg cleanup.
8107
8108 2004-08-26 Ben Maurer  <bmaurer@users.sourceforge.net>
8109
8110         * basic-long.cs, basic-calls.cs: new tests for optimization.
8111
8112 2004-08-26  Zoltan Varga  <vargaz@freemail.hu>
8113
8114         * mini-amd64.c (read_tls_offset_from_method): Fix typo in previous
8115         patch.
8116
8117 2004-08-25  Zoltan Varga  <vargaz@freemail.hu>
8118
8119         * mini-amd64.c (read_tls_offset_from_method): Add another case.
8120         
8121 2004-08-25  Bernie Solomon  <bernard@ugsolutions.com>
8122
8123         * inssel.brg (mini_emit_memcpy): use 
8124         NO_UNALIGNED_ACCESS to disable memcpy optimization
8125
8126 2004-08-25  Zoltan Varga  <vargaz@freemail.hu>
8127
8128         * mini-amd64.c: Handle generic types in various places.
8129
8130         * mini.c (mono_method_to_ir): Handle generic types in init locals.
8131
8132 2004-08-24  Zoltan Varga  <vargaz@freemail.hu>
8133
8134         * mini.c (handle_box): Fix warning.
8135
8136         * mini-amd64.c (mono_arch_local_regalloc): Fix regalloc problem.
8137
8138         * mini-amd64.h: Enable the emit_state optimization.
8139
8140         * mini-ops.h cpu-amd64.md: Add new amd64_test_null opcode.
8141
8142         * mini-amd64.c: Add some new 64 bit peephole opts.
8143
8144         * inssel.brg (mini_emit_memcpy): Optimize for 64 bit architectures.
8145
8146         * cpu-amd64.md: sreg1 of div instructions must be %rax.
8147
8148         * mini-amd64.c: Register allocator fixes.
8149
8150         * mini.c: Add an optimization to emit_state to avoid allocation of new
8151         registers on some platforms.
8152
8153 2004-08-23  Zoltan Varga  <vargaz@freemail.hu>
8154
8155         * inssel-x86.brg inssel-amd64: Add yet another missing tree->dreg assignment.
8156
8157         * mini-x86.c (mono_arch_local_regalloc): Fix bug in long register
8158         allocation. Fixes #63085.
8159
8160         * basic-long.cs: Add new regression test.
8161
8162         * mini-amd64.c: Register allocator improvements.
8163
8164 2004-08-21  Zoltan Varga  <vargaz@freemail.hu>
8165
8166         * mini-amd64.c (read_tls_offset_from_method): Add another code
8167         sequence.
8168
8169         * tramp-amd64.c (amd64_class_init_trampoline): Use a more efficient
8170         instruction sequence for nullifying class init trampolines.
8171
8172         * objects.cs: Add new regalloc test.
8173
8174         * mini-amd64.c inssel-amd64.brg: Optimize parameter passing.
8175
8176 2004-08-20  Zoltan Varga  <vargaz@freemail.hu>
8177
8178         * mini-amd64.c (mono_arch_call_opcode): Refactor this a little.
8179         
8180         * mini-amd64.c (mono_arch_regalloc_cost): Adjust regalloc costs for
8181         arguments.
8182
8183         * driver.c: Fix profiling after TLS changes.
8184         
8185         * driver.c (mono_main): Set mono_stats.enabled if needed.
8186
8187         * mini.c (handle_alloc): New helper function used by CEE_NEWOBJ and
8188         CEE_BOX.
8189
8190 2004-08-20 Ben Maurer  <bmaurer@users.sourceforge.net>
8191
8192         * mini-x86.c: use a 1 op rather than a 2 op tls access
8193         instruction -> faster.
8194
8195 2004-08-20  Zoltan Varga  <vargaz@freemail.hu>
8196
8197         * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Merge changes from
8198         x86 backend.
8199
8200 2004-08-19 Bernie Solomon <bernard@ugsolutions.com>
8201
8202         * exceptions-sparc.c (throw_exception): fix typo
8203
8204 2004-08-19 Ben Maurer  <bmaurer@users.sourceforge.net>
8205
8206         * mini-x86.c, cpu-pentium.md, inssel-x86.brg:
8207         set tree->dreg correctly with tls. Allow any
8208         register to be used.
8209
8210         * mini-x86.c (read_tls_offset_from_method): add new code
8211         generation pattern seen with GCC.
8212
8213
8214 Thu Aug 19 17:26:55 CEST 2004 Paolo Molaro <lupus@ximian.com>
8215
8216         * mini-exceptions.c, exceptions-x86.c, exceptions-amd64.c,
8217         exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
8218         exceptions-sparc.c: fix some performance issues in exception
8219         handling and setting of the stack trace for exceptions that were
8220         already thrown.
8221
8222 2004-08-18  Zoltan Varga  <vargaz@freemail.hu>
8223
8224         * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Merge changes from 
8225         x86 backend.
8226         
8227         * mini-amd64.c (mono_arch_is_int_overflow): Handle all possible 
8228         registers.
8229
8230 2004-08-18 Ben Maurer  <bmaurer@users.sourceforge.net>
8231
8232         This patch inlines tls access, when possible.
8233         
8234         * mini.h: new arch functions for TLS intrinsics.
8235         All platforms updated with a stub.
8236
8237         * mini.c: use the new intrinsics
8238
8239         * mini-x86.c, cpu-pentium.md, inssel-x86.brg, mini-ops.h:
8240         arch specific intrinsic for tls variables
8241
8242 2004-08-18  Zoltan Varga  <vargaz@freemail.hu>
8243
8244         * Makefile.am (libmono_la_LDFLAGS): Enable creating of libmono dll
8245         under windows.
8246
8247 2004-08-17 Ben Maurer  <bmaurer@users.sourceforge.net>
8248
8249         * mini.c: thread local allocation
8250
8251 2004-08-16  Zoltan Varga  <vargaz@freemail.hu>
8252
8253         * mini-amd64.h (MONO_ARCH_NO_EMULATE_LONG_SHIFT_OPS): Enable.
8254
8255         * Makefile.am: Link against the static version of libmonogc.
8256         
8257         * Makefile.am: Link the static versions of the convenience libraries
8258         into the mono executable.
8259
8260         * mini-x86.h mini-x86.c: Throw the correct exception on integer overflow.
8261
8262 2004-08-15  Zoltan Varga  <vargaz@freemail.hu>
8263
8264         * mini.h mini.c mini-amd64.h mini-amd64.c: Throw the correct exception
8265         on integer overflow.
8266
8267         * mini-amd64.c: Reorganize function call code.
8268
8269         * mini-amd64.c (peephole_pass): Merge changes from mini-x86.c.
8270
8271 2004-08-14 Ben Maurer  <bmaurer@ximian.com>
8272
8273         * inssel-x86.brg: use xor eax,eax.
8274         
8275         * basic.cs: new tests
8276
8277 2004-08-14  Zoltan Varga  <vargaz@freemail.hu>
8278
8279         * mini-amd64.c (mono_arch_emit_epilog): Use RIP relative addressing
8280         in exception throwing code.
8281         
8282 2004-08-14 Ben Maurer  <bmaurer@ximian.com>
8283
8284         * inssel-x86.brg: use xor esi,esi.
8285
8286 2004-08-14  Zoltan Varga  <vargaz@freemail.hu>
8287
8288         * driver.c (mono_main): Call mono_trace_parse_options earlier so it
8289         can trace methods compiled during mini_init () too.
8290
8291         * cpu-amd64.md mini-amd64.c (mono_arch_output_basic_block): Handle 
8292         CEE_CONV_U4.
8293
8294 2004-08-14 Ben Maurer  <bmaurer@ximian.com>
8295
8296         * Makefile.am: static link on x86 (r=zoltan)
8297
8298 2004-08-14  Zoltan Varga  <vargaz@freemail.hu>
8299
8300         * tramp-amd64.c (amd64_magic_trampoline): Avoid patching the trampoline
8301         code since it causes some programs to fail.
8302
8303 2004-08-12  Zoltan Varga  <vargaz@freemail.hu>
8304
8305         * mini-amd64.c (bb_is_loop_start): Merge changes from mini-x86.c.
8306
8307 2004-08-11  Bernie Solomon <bernard@ugsolutions.com>
8308
8309         * mini.c: ovfops_op_map - add STACK_OBJ case for
8310         CONV_I 
8311         * basic.cs: add test_0_pin_string as test
8312         case for above.
8313
8314 2004-08-11  Bernie Solomon <bernard@ugsolutions.com>
8315
8316         * Makefile.am: build C# if srcdir != builddir
8317
8318 Tue Aug 10 19:23:47 CEST 2004 Paolo Molaro <lupus@ximian.com>
8319
8320         * dominators.c, mini.h, mini-x86.c: fix loop alignment with
8321         fall-through blocks.
8322
8323 Tue Aug 10 16:18:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
8324
8325         * driver.c: enable loop by default again and include abcrem in -O=all.
8326
8327 2004-08-08  Zoltan Varga  <vargaz@freemail.hu>
8328
8329         * iltests.il: Add some localloc tests.
8330
8331         * mini.c (mono_method_to_ir): Set stack type of LOCALLOC correctly.
8332
8333         * inssel-amd64.brg inssel-x86.brg: Set dreg of LOCALLOC correctly. 
8334         Fixes #62574.
8335
8336         * inssel-amd64.brg: Add some optimizations.
8337
8338         * mini-amd64.c (mono_arch_setup_jit_tls_data): Add tls offset detection
8339         for gcc-3.4.
8340
8341         * Makefile.am: Statically link mono against libmono on AMD64.
8342         
8343         * mini-amd64.c inssel-amd64.brg: Optimizations.
8344
8345 2004-08-07  Zoltan Varga  <vargaz@freemail.hu>
8346
8347         * mini-amd64.c (mono_arch_emit_prolog): Optimize lmf saving a bit.
8348
8349         * tramp-amd64.c: Patch calling code in trampolines.
8350
8351 2004-08-06  Zoltan Varga  <vargaz@freemail.hu>
8352
8353         * mini-amd64.c: pinvoke struct passing fixes.
8354
8355 2004-08-05  Bernie Solomon  <bernard@ugsolutions.com>
8356
8357         * mini-sparc.c: redo change, make mono_arch_cpu_init call
8358         mono_arch_cpu_optimizazions so sparcv9 is initialized when embedded
8359
8360 2004-08-05  Duncan Mak  <duncan@ximian.com>
8361
8362         * mini.c: Renamed CEE_STELEM to CEE_STELEM_ANY and CEE_LDELEM to
8363         CEE_LDELEM_ANY.
8364
8365 2004-08-05  Zoltan Varga  <vargaz@freemail.hu>
8366
8367         * mini-amd64.c (emit_move_return_value): Move return value for normal
8368         calls too.
8369
8370 2004-08-05  Martin Baulig  <martin@ximian.com>
8371
8372         * mini.c (ret_type_to_call_opcode): Don't use a `t' variable for
8373         `type->type'; just modify `type' itself when dealing with enums
8374         and generic instances.
8375         (check_call_signature): Make `simple_type' a `MonoType *'.
8376
8377 2004-08-05  Zoltan Varga  <vargaz@freemail.hu>
8378
8379         * mini.c: Use OP_PADD to add offsets to addresses.
8380
8381         * mini-amd64.h: Disable SIGSEGV_ON_ALTSTACK.
8382
8383 2004-08-04  Bernie Solomon  <bernard@ugsolutions.com>
8384
8385         * mini-sparc.c (mono_arch_emit_epilog): fix check
8386         for folding last op into restore instruction
8387
8388 2004-08-05  Zoltan Varga  <vargaz@freemail.hu>
8389
8390         * exceptions-amd64.c (mono_arch_get_throw_exception_by_name): Allocate
8391         helper methods using the code manager.
8392         
8393         * exceptions-amd64.c (mono_arch_get_throw_exception): Fix maximum length.
8394
8395         * mini-amd64.c (mono_arch_allocate_vars): Fix tls offset detection.
8396
8397 Tue Aug 3 23:50:00 EST 2004 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
8398         
8399         * mini-s390x.c mini-s390x.h tramp-s390x.c inssel-s390x.brg
8400           cpu-s390x.md exceptions-s390x.c Makefile.am: S/390 64-bit JIT
8401
8402         * mini-s390.c: fix tail processing
8403
8404 Tue Aug 3 01:35:44 PDT 2004 Paolo Molaro <lupus@ximian.com>
8405
8406         * mini-ppc.c: mul.ovf.un exception name fix.
8407
8408 2004-08-03  Martin Baulig  <martin@ximian.com>
8409
8410         * mini-x86.c (mono_arch_call_opcode): Correctly handle generic
8411         instances; before jumping to `handle_enum', also modify `ptype'.
8412
8413 2004-08-02  Bernie Solomon  <bernard@ugsolutions.com>
8414
8415         * cpu-sparc.md: fcall maximal length too small.
8416
8417 2004-08-02  Zoltan Varga  <vargaz@freemail.hu>
8418
8419         * mini-amd64.c mini.h: Add initial support for passing/returning 
8420         structures to/from pinvoked methods.
8421
8422 Mon Aug 2 11:59:35 PDT 2004 Paolo Molaro <lupus@ximian.com>
8423
8424         * mini-ppc.c: reg allocator fix.
8425
8426 2004-07-31  Zoltan Varga  <vargaz@freemail.hu>
8427
8428         * mini-amd64.c (mono_arch_output_basic_block): Fix OP_X86_PUSH_OBJ.
8429
8430         * inssel.brg: Optimize memset on 64 bit machines.
8431
8432         * mini-amd64.c: Fix some vararg cases.
8433
8434 2004-07-30  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
8435
8436         * mini-s390.c: Corrected macro in emit_float_to_int
8437
8438         * s390-abi.cs: Tests to exercise the s390 ABI
8439
8440 2004-07-30  Zoltan Varga  <vargaz@freemail.hu>
8441
8442         * exceptions-amd64.c (mono_arch_find_jit_info): Fix restoring of
8443         caller saved regs.
8444
8445         * basic.cs: Add a test for add.ovf.un.
8446
8447 2004-07-30  Bernie Solomon  <bernard@ugsolutions.com>
8448
8449         * mini-sparc.c: add case for OP_IDIV_UN
8450
8451 2004-07-30  Zoltan Varga  <vargaz@freemail.hu>
8452
8453         * mini-amd64.c mini-amd64.h mini.c: Add support for vararg pinvoke calls.
8454         
8455         * mini-amd64.c cpu-amd64.md: Ongoing JIT work.
8456
8457 2004-07-30  Ben Maurer  <bmaurer@ximian.com>
8458
8459         * basic.cs: regression tests.
8460
8461         * inssel-x86.brg: Disable cmp BYTE PTR [eax], imm, it causes various
8462         regressions.
8463
8464 2004-07-30  Zoltan Varga  <vargaz@freemail.hu>
8465
8466         * basic.cs: Add a new test.
8467
8468         * mini-amd64.c aot.c cpu-amd64.md: Add support for tracing, profiling 
8469         and AOT. Various fixes and optimizations.
8470
8471         * inssel.brg (CALL_REG): Add 64 bit versions of call_reg rules.
8472
8473 Fri Jul 30 15:49:26 CEST 2004 Paolo Molaro <lupus@ximian.com>
8474
8475         * mini-ppc.c: make sure temp regs are not used for global reg
8476         allocation.
8477
8478 2004-07-29  Bernie Solomon  <bernard@ugsolutions.com>
8479
8480         * cpu-sparc.md: conv_i8 fix for 64bits
8481
8482         * mini-sparc.c: add cases for OP_IXXX codes for 64bits
8483
8484 2004-07-29  Ben Maurer  <bmaurer@ximian.com>
8485         
8486         * cpu-pentium.md, mini-x86.c, inssel-x86.brg, mini-ops.h:
8487         add opcode for cmp BYTE PTR [eax], imm.
8488
8489         * inssel.brg: Make memcpy and memset takes bases.
8490
8491 2004-07-28  Zoltan Varga  <vargaz@freemail.hu>
8492
8493         * *-amd64.*: More AMD64 work.
8494         
8495 2004-07-28  Ben Maurer  <bmaurer@ximian.com>
8496
8497         * cpu-pentium.md, inssel-x86.brg, mini-ops.h, mini-x86.c:
8498         add a compare-not-equal opcode.
8499         
8500 2004-07-28  Lluis Sanchez Gual  <lluis@novell.com>
8501
8502         * mini.c: Use mono_init_from_assembly instead of mono_init.
8503         
8504 2004-07-28  Zoltan Varga  <vargaz@freemail.hu>
8505
8506         * mini.c: Fix opcode mapping for STACK_MP on 64 bit platforms.
8507
8508         * mini.c (CEE_NEWOBJ): Call mono_array_new_va using the correct signature.
8509
8510         * mini.c: Use MONO_ARCH_SIGACTION on AMD64 as well.
8511
8512         * inssel.brg: 64 bit fixes.
8513
8514         * mini.h (MonoCallInst): Add some AMD64 specific data.
8515
8516         * mini.h: Add some OP_P opcodes.
8517
8518 2004-07-28  Ben Maurer  <bmaurer@ximian.com>
8519
8520         * basic.cs: tests for 61797 and 61740
8521
8522 Tue Jul 27 16:05:19 CEST 2004 Paolo Molaro <lupus@ximian.com>
8523
8524         * mini-ppc.c, mini-sparc.c, mini-s390.c: keep track of line
8525         numbers in the debug info (spotted by Geoff Norton, <gnorton@customerdna.com>).
8526
8527 2004-07-24  Zoltan Varga  <vargaz@freemail.hu>
8528
8529         * mini-sparc.c (mono_arch_output_basic_block): Add CEE_CONV_U8/I8.
8530
8531         * *-amd64*.*: Ongoing AMD64 work.
8532
8533 2004-07-23 Zoltan Varga <vargaz@freemail.hu>
8534
8535         * inssel-long.brg: Implement CONV_I8/CONV_U8 in the backends.
8536
8537         * *-amd64*: Ongoing AMD64 work.
8538
8539         * mini-arch.h: Add AMD64 support.
8540
8541         * mini-sparc.c (mono_arch_is_inst_imm): New arch dependent function.
8542
8543         * mini.h: Add new arch dependent function mono_arch_is_inst_imm.
8544
8545         * mini-ops.h: Add new opcodes.
8546
8547         * Makefile.am: Add AMD64 support.
8548
8549         * inssel.brg inssel-long32.brg inssel-long.brg: Move mul/div and shift
8550         rules into the inssel-long*.brg files.
8551
8552         * *-amd64.*: Add beginnings of AMD64 backend.
8553
8554 2004-07-22  Ben Maurer  <bmaurer@ximian.com>
8555
8556         * mini.c (print_dfn): commenting out the code that prints
8557         the cil. With -O=deadce, this makes -v -v crash.
8558         
8559         * cpu-pentium.md: make checkthis have a length of 2
8560
8561 2004-04-21  Bernie Solomon  <bernard@ugsolutions.com>
8562
8563         * mini-sparc.h: fix implementations of __builtin
8564         functions for Sun compiler for V9.
8565
8566 2004-07-16  Ben Maurer  <bmaurer@ximain.com>
8567
8568         * mini.c: use the new stelem.ref wrapper
8569         * exceptions.cs, arrays.cs: new stelem.ref tests
8570
8571 Wed Jul 14 19:08:41 CEST 2004 Paolo Molaro <lupus@ximian.com>
8572
8573         * mini-ppc.c, exceptions-ppc.c: cleanups and fixes (the
8574         new XSP should work with these changes).
8575
8576 2004-07-14  Ben Maurer  <bmaurer@ximain.com>
8577         
8578         * inssel-{long32,x86,}.brg: trivial optimizations.
8579         
8580 Mon Jul 12 20:25:57 CEST 2004 Paolo Molaro <lupus@ximian.com>
8581
8582         * mini.c: load value when emitting box operation in
8583         constrained calls.
8584
8585 2004-07-12  Ben Maurer  <bmaurer@ximian.com>
8586
8587         * mini-x86.c (OP_CHECK_THIS): cmp DWORD PTR [eax], eax
8588         is one byte shorter than cmp DWORD PTR [eax], 0.
8589
8590 Mon Jul 12 17:47:00 CEST 2004 Paolo Molaro <lupus@ximian.com>
8591
8592         * inssel-ppc.brg: arguments on the stack are always
8593         relative to the stack pointer (spotted by Neale Ferguson).
8594
8595 2004-07-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
8596
8597         * exceptions-x86.c: delay appending the method name to the trace until
8598         after mono_jit_info_table_find is called, as this gets the real
8599         MonoMethod.
8600
8601 2004-07-09  Ben Maurer  <bmaurer@ximian.com>
8602
8603         * aot.c: register roots
8604
8605 2004-07-09  Atsushi Enomoto  <atsushi@ximian.com>
8606
8607         * aot.c : I could just use PLATFORM_WIN32 flag.
8608
8609 2004-07-09  Atsushi Enomoto  <atsushi@ximian.com>
8610
8611         * aot.c : Reverting the previous fix. This time it broke linux build.
8612
8613 2004-07-09  Atsushi Enomoto  <atsushi@ximian.com>
8614
8615         * aot.c : quick cygwin build fix. mkdir() with two args does not exist.
8616
8617 2004-07-08  Zoltan Varga  <vargaz@freemail.hu>
8618
8619         * mini.c (handle_stack_args): Remove some more debugging code.
8620         
8621         * mini.c (handle_stack_args): Remove debug output left in by mistake.
8622
8623         * driver.c mini.h aot.c: Allow additional options to be specified with
8624         --aot and pass them to mono_compile_assembly.
8625
8626         * aot.c: Add experimental code to AOT compile all loaded assemblies
8627         on demand and save the code into a cache in the filesystem.
8628
8629         * aot.c: Add support for more wrapper methods.
8630         
8631         * mini.c (handle_stack_args): Handle some corner cases. Fixes 
8632         58863.
8633
8634         * cpu-*.md: Remove removed opcodes.
8635
8636         * mini.h mini.c: Move JIT icall handling to icall.c. Replace usage of
8637         CEE_MONO_PROC<x> with CEE_MONO_ICALL. Move registration of marshalling
8638         related icalls to marshal.c.
8639
8640 2004-07-06  Zoltan Varga  <vargaz@freemail.hu>
8641
8642         * mini-ops.h: Add OP_SAVE_LMF and OP_RESTORE_LMF.
8643
8644         * Makefile.am (EXTRA_DIST): Add inssel-long[32].brg.
8645
8646         * inssel.brg: Fix warning. Add rules for SAVE_LMF and RESTORE_LMF.
8647
8648 2004-07-06  Ben Maurer  <bmaurer@ximian.com>
8649         * liveness.c: If liveness is recomputated we need to reset the information
8650         for each variable. This way, if the liveness range has been narrowed
8651         by optimizations that happened after the last computation, we can return
8652         a smaller range.
8653         
8654         For example, if you have
8655         
8656         {
8657                 int i = 0;
8658                 
8659                 // Tons of code that does not affect i
8660                 
8661                 i = foo ();
8662                 ...
8663         }
8664         
8665         i = 0 is dead code and will be removed by SSA. However, when
8666         linear scan gets to the code, i will still appear to be live
8667         throughout the entire block. This prevents good register allocation.
8668
8669 2004-07-06  Martin Baulig  <martin@ximian.com>
8670
8671         * debug-mini.c (mono_debug_init_method): Allow
8672         MONO_WRAPPER_MANAGED_TO_NATIVE wrappers.
8673         (mono_debug_add_icall_wrapper): New method.
8674
8675         * mini.c (mono_icall_get_wrapper): Call mono_debug_add_icall_wrapper().
8676
8677 2004-07-05  Zoltan Varga  <vargaz@freemail.hu>
8678
8679         * mini.c (optimize_branches): Fix linking of bblocks in branch->branch
8680         optimization.
8681
8682 2004-07-03  Zoltan Varga  <vargaz@freemail.hu>
8683
8684         * aot.c (mono_aot_load_method): Fix loading of debug info.
8685
8686 2004-07-02  Zoltan Varga  <vargaz@freemail.hu>
8687
8688         * aot.c: Add logging support.
8689
8690 2004-07-01  Zoltan Varga  <vargaz@freemail.hu>
8691
8692         * mini.h: Add prototype for mono_print_method_from_ip.
8693
8694         * mini.c: 64 bit fixes. Use LCOMPARE for comparing longs.
8695
8696         * inssel.brg: 64 bit fixes.
8697
8698         * inssel.brg inssel-long32.brg: Move 32 bit arithmetic rules to 
8699         inssel-long32.brg.
8700
8701         * Makefile.am: Add SPARC64 support.
8702
8703 2004-07-02  Zoltan Varga  <vargaz@freemail.hu>
8704
8705         * aot.c: Fix alignment problems on 32 bit platforms.
8706
8707 2004-07-01  Zoltan Varga  <vargaz@freemail.hu>
8708
8709         * helpers.c (mono_disassemble_code): Pass -xarch=v9 to assembler on
8710         SPARC64.
8711
8712         * aot.c: Add SPARC64 support. Reorganize patch table to fix alignment
8713         problems.
8714
8715         * mini.h: Bump AOT file version. Some 64 bit fixes.
8716
8717 2004-06-30  Zoltan Varga  <vargaz@freemail.hu>
8718
8719         * inssel-sparc.brg: Add new rule to avoid register moves.
8720
8721         * inssel.brg: Add ldind_to_load_membase helper function.
8722
8723 2004-06-30  Ben Maurer  <bmaurer@ximian.com>
8724
8725         * mini.c: OffsetToStringData intrinsic.
8726         
8727 2004-06-30  Zoltan Varga  <vargaz@freemail.hu>
8728
8729         * ssa.c: Handle OP_LCOMPARE the same as OP_COMPARE.
8730
8731         * objects.cs exceptions.cs basic.cs basic-long.cs basic-calls.cs: New
8732         regression tests.
8733
8734         * mini-ops.h cpu-sparc.md mini-sparc.h mini-sparc.c exceptions-sparc.c tramp-sparc.c inssel-long.brg: Add SPARC64 support.
8735 Mon Jun 28 18:05:09 CEST 2004 Paolo Molaro <lupus@ximian.com>
8736
8737         * mini.c: reinstated mono_compile_get_interface_var()
8738         on x86, too, since the change breaks the Gtk# build there as well.
8739
8740 Fri Jun 25 17:36:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
8741
8742         * driver.c: remove loop from the default optimizations: it seems to
8743         interact badly with some of the other options (see bug #60613).
8744
8745 2004-06-25  Zoltan Varga  <vargaz@freemail.hu>
8746
8747         * mini.c mini-x86.h mini-x86.c: Applied patch from Guenter Feldmann 
8748         (fld@informatik.uni-bremen.de): Add Solaris x86 support.
8749
8750 Tue Jun 22 21:29:11 CEST 2004 Paolo Molaro <lupus@ximian.com>
8751
8752         * mini-ppc.c, cpu-g4.md: small updates to be able to compile
8753         vararg-using methods.
8754
8755 2004-06-21  Martin Baulig  <martin@ximian.com>
8756
8757         * mini/mini-exceptions.c
8758         (mono_handle_exception): Added `gpointer original_ip' argument.
8759         After calling mono_unhandled_exception(), call
8760         mono_debugger_unhandled_exception() and if that returns true,
8761         restore the context and return.
8762
8763 Mon Jun 21 19:26:40 CEST 2004 Paolo Molaro <lupus@ximian.com>
8764
8765         * mini-ppc.c: prefer the use of relative branches so
8766         they won't need to be patched in aot code (patch from Patrick Beard).
8767
8768 Mon Jun 21 19:03:18 CEST 2004 Paolo Molaro <lupus@ximian.com>
8769
8770         * aot.c: patch from Patrick Beard to make the output assembly
8771         more correct for the MacOSX assembler. Small tweak to
8772         generate sane images on Linux/PPC, too.
8773
8774 Fri Jun 18 18:24:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
8775
8776         * mini.c, mini.h, mini-ppc.c: handle varargs methods with a special
8777         case until bug #59509 is fixed (shows up in #60332).
8778
8779 Tue Jun 15 16:36:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
8780
8781         * mini.c: make sure the needed wrappers are compiled, too, with
8782         precomp.
8783
8784 Mon Jun 14 18:36:08 CEST 2004 Paolo Molaro <lupus@ximian.com>
8785
8786         * driver.c: remove NPTL reference in --version output.
8787
8788 Sun Jun 13 17:25:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
8789
8790         * aot.c: patch from Patrick Beard (pcbeard@mac.com) to
8791         generate valid assembly for the Mach-O assembler.
8792
8793 Sun Jun 13 15:59:38 CEST 2004 Paolo Molaro <lupus@ximian.com>
8794
8795         * driver.c: don't include abcrem in the all optimization specifier
8796         since it slows down jit compilation too much for now.
8797
8798 2004-06-12 Ben Maurer  <bmaurer@users.sourceforge.net>
8799
8800         * mini.c: use BIGMUL only if both operands have the same signage.
8801         * iltests.il: Test for bug 60056. (errors related to signage in
8802         BIGMUL).
8803
8804         r=lupus.
8805
8806 Thu Jun 10 16:06:42 CEST 2004 Paolo Molaro <lupus@ximian.com>
8807
8808         * mini.c, aot.c: memory leak fixes.
8809
8810 Tue Jun 8 16:37:15 CEST 2004 Paolo Molaro <lupus@ximian.com>
8811
8812         * inssel-long32.brg: implemented a few missing ulong cast opcodes.
8813
8814 Tue Jun 8 15:36:30 CEST 2004 Paolo Molaro <lupus@ximian.com>
8815
8816         * Makefile.am: remove the -static hack completely, it links in
8817         statically glib as well.
8818
8819 Sat Jun 5 16:32:33 CEST 2004 Paolo Molaro <lupus@ximian.com>
8820
8821         * iltests.il, mini.c: fixed bug#59580 in branch optimization.
8822         * exceptions.cs: make it compile with new mcs/csc.
8823
8824 2004-06-03 Massimiliano Mantione <massi@ximian.com>
8825         * cpu-pentium.md basic-float.cs Fixed bug on fpu spills (see bug 54467),
8826         and added relevant test case.
8827
8828 Mon May 31 19:41:46 CEST 2004 Paolo Molaro <lupus@ximian.com>
8829
8830         * mini.c revert Zoltan's fix to bug#58863 on ppc, since it causes
8831         regressions in gtk-sharp.
8832
8833 2004-05-29  Zoltan Varga  <vargaz@freemail.hu>
8834
8835         * exceptions.cs: New regression tests.
8836
8837         * jit-icalls.c (mono_llmult_ovf): Fix some boundary conditions.
8838
8839 Sat May 29 10:45:58 CEST 2004 Paolo Molaro <lupus@ximian.com>
8840
8841         * mini.c: emit castclass/isinst in their own trees (bug #54209/59057).
8842
8843 2004-05-28  Zoltan Varga  <vargaz@freemail.hu>
8844
8845         * mini-sparc.h (MONO_ARCH_NEED_DIV_CHECK): Define this.
8846
8847         * cpu-sparc.md mini-sparc.c: Add overflow detection to div opcodes.
8848
8849 2004-05-28      Patrik Torstensson <totte@hiddenpeaks.com>
8850
8851         * mini.c (mono_jit_runtime_invoke): Init class in this
8852         method instead of trusting mono_jit_compile_method to
8853         do the work (because wrappers can be in object class)
8854
8855 2004-05-27  Zoltan Varga  <vargaz@freemail.hu>
8856
8857         * mini-sparc.c (mono_arch_output_basic_block): Fix sub.imm.
8858
8859         * basic-long.cs: New regression test.
8860
8861 Thu May 27 15:50:52 CEST 2004 Paolo Molaro <lupus@ximian.com>
8862
8863         * cpu-g4.md, mini-ppc.c: fixes to long add/sub ovf opcodes
8864         and div/rem checks.
8865
8866 Thu May 27 12:36:53 CEST 2004 Paolo Molaro <lupus@ximian.com>
8867
8868         * Makefile.am: fix miguel's change to build mono statically against
8869         libmono (track build dependencies).
8870
8871 2004-05-26  Zoltan Varga  <vargaz@freemail.hu>
8872
8873         * cfold.c: Some glib versions do not have G_MININT32.
8874
8875 2004-05-26  Massimiliano Mantione  <massi@ximian.com>
8876
8877         * mini-x86.c cpu-pentium.md Makefile.am basic-math.cs: Fixed problem
8878         with precision of tan, atan, sin and cos, and implemented related
8879         regressions tests (fixes bug 54467, but one new problem appeared and
8880         is not fixed yet).
8881
8882 2004-05-26  Zoltan Varga  <vargaz@freemail.hu>
8883
8884         * cfold.c (FOLD_BINOPZ): Avoid division by zero.
8885
8886         * exceptions.cs: Add test for constant folding && division by zero.
8887
8888         * driver.c mini.h mini.c mini-x86.c: Revert most of the previous patch
8889         since driver.c is in libmono too, so the optimization was useless.
8890
8891         * driver.c mini.h mini.c mini-x86.c: Moved the mono_lmf_addr TLS 
8892         variable to driver.c so the compiler can emit more efficient code to
8893         access them.
8894
8895 2004-05-26  Gonzalo Paniagua Javier <gonzalo@ximian.com>
8896
8897         * Makefile.am: don't distribute generated inssel.[ch] files.
8898
8899 2004-05-25  Zoltan Varga  <vargaz@freemail.hu>
8900
8901         * mini.c (mono_jit_compile_method_with_opt): Really emit icall wrappers
8902         into the default appdomain. Fixes #58707.
8903
8904         * jit-icalls.c: Remove the broken approximation for truncl, doing
8905         no conversion is better.
8906
8907         * mini.c (handle_stack_args): Avoid reusing variables for stack slots.
8908         Fixes #58863.
8909
8910 Tue May 25 14:33:56 CEST 2004 Paolo Molaro <lupus@ximian.com>
8911
8912         * mini-ops.h, mini-ppc.c, cpu-g4.md, inssel-ppc.brg: eliminate the use
8913         of the mcrxr instruction which is not available on some processors
8914         even if it's documented to be. Implement add and sub overflow correctly
8915         (still not complete for long unsigned). Speed up icalls a bit.
8916
8917 2004-05-25 13:01 CET Patrik Torstenson <totte@hiddenpeaks.com>
8918
8919         * mini.c (mono_jit_compile_method_with_opt): Make sure that
8920         we run .cctor in the current domain instead of target_domain.
8921         
8922         Fixes bug #58558, .cctor not being called in -O=shared.
8923
8924 Tue May 25 12:46:50 CEST 2004 Paolo Molaro <lupus@ximian.com>
8925
8926         * mini-ppc.h, jit-icalls.c: added explicit checks for divide by zero.
8927
8928 2004-05-24 Ben Maurer  <bmaurer@users.sourceforge.net>
8929
8930         * mini-x86.c (EMIT_COND_BRANCH): If an OP_LABEL has an offset
8931         which can be done with an imm8, do it that way.
8932         (mono_arch_output_basic_block): ditto for a jmp
8933         (mono_arch_emit_prolog): Computate maximum offset of a label.
8934
8935 2004-05-24 18:18 CET Patrik Torstenson <totte@hiddenpeaks.com>
8936
8937         * mini-x86.c (mono_arch_local_regalloc): the reg allocator
8938         now tries to allocate prefered physical reg's for virtual
8939         regs. This reduces the number of emited spills/loads with
8940         20-30% on our core assemblies.
8941
8942 Mon May 24 18:21:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
8943
8944         * jit-icalls.c: truncl() is not needed and trunc() is
8945         the correct thing to do anyway (bug #58287).
8946
8947 2004-05-24  Zoltan Varga  <vargaz@freemail.hu>
8948
8949         * mini-sparc.c (mono_arch_flush_icache): Call sync_instruction_memory
8950         if available.
8951
8952 Mon May 24 12:49:45 CEST 2004 Paolo Molaro <lupus@ximian.com>
8953
8954         * driver.c: enable loop optimizations by default.
8955
8956 Mon May 24 11:13:46 CEST 2004 Paolo Molaro <lupus@ximian.com>
8957
8958         * mini-x86.c: fix calc of max loop size when aligning loops start.
8959
8960 2004-05-23  Zoltan Varga  <vargaz@freemail.hu>
8961
8962         * ssa.c (mono_ssa_cprop): Allocate carray dynamically instead of on
8963         the stack.
8964
8965 2004-05-22  Zoltan Varga  <vargaz@freemail.hu>
8966
8967         * mini-sparc.c (mono_arch_output_basic_block): ADD_IMM and SUB_IMM
8968         should set carry.
8969
8970         * basic-long.cs: Add tests for add/subtract of immediates with carry.
8971
8972         * mini.c exceptions-x86.c: Remove MONO_USE_EXC_TABLES stuff.
8973         
8974         * mini.c (inline_method): Allways inline some wrappers even if the cost
8975         is too large. Fixes #58785.
8976
8977         * mini.c: Add support for MARSHAL_CONV_FTN_DEL.
8978         
8979 2004-05-21  Zoltan Varga  <vargaz@freemail.hu>
8980
8981         * mini-sparc.c exceptions-sparc.c: Applied patch from Mark Crichton
8982         (crichton@gimp.org). Beginning of support for sparc/linux.
8983
8984         * mini-sparc.c: Optimize retrieval of LMF address.
8985
8986 Fri May 21 08:00:12 EDT 2004 Paolo Molaro <lupus@ximian.com>
8987
8988         * exceptions-ppc.c:  handle alloca in methods with clauses.
8989
8990 Fri May 21 07:35:30 EDT 2004 Paolo Molaro <lupus@ximian.com>
8991
8992         * mini-ppc.c: cleanups, off-by-one fixes, avoid recursive thunks.
8993
8994 2004-05-20  Lluis Sanchez Gual  <lluis@ximian.com>
8995
8996         * mini.c: Delegate most of the abort signal work to 
8997           mono_thread_request_interruption, which also handles Stop and Suspend
8998           states.
8999
9000 2004-05-20  Zoltan Varga  <vargaz@freemail.hu>
9001
9002         * mini.c mini.h: Allow inlining of icall wrappers if the backend 
9003         supports the save/restore lmf opcodes.
9004
9005 2004-05-19  Zoltan Varga  <vargaz@freemail.hu>
9006
9007         * mini-x86.c (mono_arch_setup_jit_tls_data): Handle code generated
9008         by gcc-3.4 as well.
9009
9010         * mini-x86.h mini-x86.c tramp-x86.c: Optimize lmf restoring code.
9011
9012 2004-05-18  Zoltan Varga  <vargaz@freemail.hu>
9013
9014         * mini.h mini.c (mini_method_compile): Only run abc removal pass on 
9015         methods which contain array accesses.
9016
9017         * mini.c (CEE_LDTOKEN): Handle this instruction correctly on bb
9018         boundaries. Fixes #58537.
9019
9020         * iltests.il: Add regression test for #58537.
9021
9022 2004-05-18  Patrik Torstensson <totte@hiddenpeaks.com>
9023
9024         * mini-x86.c (mono_arch_local_regalloc): Last part of
9025         fix for bug #58633 (releasing register to early).
9026
9027 2004-05-18  Miguel de Icaza  <miguel@ximian.com>
9028
9029         * basic-long.cs: Add new regression test.
9030
9031 2004-05-18  Patrik Torstensson <totte@hiddenpeaks.com>
9032
9033         * mini-x86.c (mono_arch_local_regalloc): Avoid releasing a
9034         register too early on the chain.
9035
9036 2004-05-18  Zoltan Varga  <vargaz@freemail.hu>
9037
9038         * mini.c (create_helper_signature): Use a helper function to reduce
9039         the code which needs to be written. Also set the calling convention of
9040         icalls on windows. Fixes #57840.
9041
9042 Tue May 18 11:05:18 CEST 2004 Paolo Molaro <lupus@ximian.com>
9043
9044         * mini.h, exceptions-x86.c, exceptions-sparc.c, exceptions-s390.c,
9045         exceptions-ppc.c: added helper function to get the instruction address
9046         from a signal handler context.
9047
9048 2004-05-17 Ben Maurer  <bmaurer@users.sourceforge.net>
9049
9050         * helpers.c: use g_get_tmp_dir. Invokes happyness 
9051         from gonzalo.
9052
9053 2004-05-17 Ben Maurer  <bmaurer@users.sourceforge.net>
9054
9055         * helpers.c: Add new env variable to pass args to objdump.
9056         Specifically for those of us who love -Mintel. r=miguel, gonzalo.
9057
9058 2004-05-17  Radek Doulik  <rodo@ximian.com>
9059
9060         * Makefile.am (common_sources): added abcremoval.h so it get
9061         disted and daily mono packages on go-mono.com will build again
9062
9063 2004-05-17  Massimiliano Mantione  <massi@ximian.com>
9064
9065         * abcremoval.c: Fixed coding style, added copyright header.
9066
9067         * abcremoval.h: Fixed style and moved prototype to mini.h, added copyright header.
9068
9069         * mini.h: Added prototype for abc removal main function.
9070
9071         * build_relations_propagation_table.pl: Added copyright header.
9072
9073 2004-05-16      Patrik Torstensson <totte@hiddenpeaks.com>
9074
9075         * basic-long.cs: reg test for complex ceq_long bug.
9076
9077 2004-05-16      Patrik Torstensson <totte@hiddenpeaks.com>
9078
9079         * mini-x86.c (mono_arch_local_regalloc): Correctly free 
9080         reg in long and clob case (bug #58343). Fixed/added comments.
9081
9082 2004-05-14 Ben Maurer  <bmaurer@users.sourceforge.net>
9083
9084         * mini.c (mono_jit_runtime_invoke): Follow new convention
9085         of calling the invoke method with an function pointer.
9086
9087 2004-05-14  Zoltan Varga  <vargaz@freemail.hu>
9088
9089         * ChangeLog: Fix author of memory leak patch.
9090
9091 Fri May 14 15:13:06 CEST 2004 Paolo Molaro <lupus@ximian.com>
9092
9093         * Makefile.am: fix make dist as well...
9094
9095
9096 2004-05-14  Massimiliano Mantione  <massi@ximian.com>
9097
9098         * cfold.c: Made so that conversions from pointer to int4 are no-ops
9099         on archs where pointers are 4 bytes long.
9100
9101         * Makefile.am: Added abcremoval.c source file.
9102
9103         * abcremoval.c: Added abcremoval.c.
9104
9105         * abcremoval.h: Added abcremoval.h.
9106
9107         * build_relations_propagation_table.pl: Added build_relations_propagation_table.pl.
9108
9109         * inssel.brg: Enabled bounds check removal.
9110
9111         * mini.c: Added support for abcrem optimization.
9112
9113         * mini.h: Added abcrem optimization label.
9114
9115         * driver.c: Added support for abcrem optimization.
9116
9117         * propagated_relations_table.def: Added propagated_relations_table.def.
9118
9119 Fri May 14 14:30:13 CEST 2004 Paolo Molaro <lupus@ximian.com>
9120
9121         * mini.c, cfold.c: fix style.
9122
9123 Fri May 14 14:28:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
9124
9125         * mini.c: handle issue with the low-level implementation of
9126         some long opcodes (bug #54209).
9127
9128 2004-05-13 Ben Maurer  <bmaurer@users.sourceforge.net>
9129
9130         * basic.cs: test for my new cmov stuff.
9131
9132 2004-05-13      Patrik Torstensson
9133
9134         * mini-x86.c: added OP_X86_COMPARE_MEMBASE_IMM peephole
9135         opt and added peephole documentation.
9136
9137 Thu May 13 11:41:49 CEST 2004 Paolo Molaro <lupus@ximian.com>
9138
9139         * tramp-ppc.c: rewrote the generic trampoline code.
9140
9141 2004-05-11      Patrik Torstensson
9142
9143         * mini-x86.c: optimize long shl/shr asm code (one less branch)
9144
9145 2004-05-11  Zoltan Varga  <vargaz@freemail.hu>
9146
9147         * basic.cs basic-long.cs objects.cs: Make these compile under MS csc.
9148
9149         * mini.h mini.c dominators.c: Applied patch from Derek Woo
9150         (derek@eecg.toronto.edu): Fix memory leaks in loop optimizations.
9151
9152         * mini.c: Add new icalls for AsAny marshalling.
9153
9154 Tue May 11 16:00:38 CEST 2004 Paolo Molaro <lupus@ximian.com>
9155
9156         * tramp-ppc.c, mini-ppc.c: more cleanups.
9157
9158 2004-05-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
9159
9160         * mini.c: no warnings.
9161
9162 Tue May 11 13:59:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
9163
9164         * mini-ppc.c, mini.c: use mono_resolve_patch_target ().
9165
9166 2004-05-11  Lluis Sanchez Gual  <lluis@ximian.com>
9167
9168         * mini.c: In the thread abort signal handler, if the thread is in the
9169         process of being stoped, don't throw the Abort exception, just stop the
9170         thread.
9171
9172 Tue May 11 12:15:24 CEST 2004 Paolo Molaro <lupus@ximian.com>
9173
9174         * tramp-ppc.c: removed old code.
9175
9176 Tue May 11 12:02:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
9177
9178         * mini.h, mini-ppc.c, cfold.c: export mono_is_power_of_two().
9179         do some simple speed optimizations on ppc.
9180
9181 Mon May 10 17:21:00 CEST 2004 Paolo Molaro <lupus@ximian.com>
9182
9183         * mini-ppc.c, cpu-g4.md: fixes to handle large stack frames
9184         and large offsets in load/store.
9185
9186 2004-05-07  Zoltan Varga  <vargaz@freemail.hu>
9187
9188         * mini-x86.c (mono_arch_local_regalloc): Remove the previous fix, since
9189         it causes regressions.
9190
9191 2004-05-07  Zoltan Varga  <vargaz@freemail.hu>
9192
9193         * mini-sparc.c: Fix vararg support + add beginnings of sigaltstack
9194         support.
9195
9196 Fri May 7 13:25:50 CEST 2004 Paolo Molaro <lupus@ximian.com>
9197
9198         * jit-icalls.c: remove warnings.
9199         * inssel-x86.brg, inssel.brg, mini-x86.c, cfold.c: some simple
9200         speedups for unsafe code.
9201
9202 2004-05-07 Ben Maurer  <bmaurer@users.sourceforge.net>
9203
9204         * inssel.brg: Optimize Stind.[ui][12]. r=zoltan.
9205
9206 2004-05-06  Zoltan Varga  <vargaz@freemail.hu>
9207
9208         * basic-calls.cs: Add new regression test.
9209
9210         * mini.c (mono_runtime_install_handlers): Use SA_ONSTACK since it is
9211         more portable.
9212
9213         * mini.c (mono_method_to_ir): Handle opcode emulation for *_OVF opcodes.
9214
9215         * mini-x86.c (mono_arch_local_regalloc): Free new_dest register when it
9216         is no longer used.
9217
9218 2004-05-06      Patrik Torstensson
9219
9220         * mini-x86.[c|h], inssel-x86.brg, cpu-pentium.md, mini.c: enabled
9221         long reg allocation in any reg (not only eax:edx) and implemented 
9222         long shl/shr ops in asm instead of helpers.
9223
9224 2004-05-05  Zoltan Varga  <vargaz@freemail.hu>
9225
9226         * mini-sparc.h: Fix warnings.
9227
9228         * exceptions-sparc.c (mono_arch_find_jit_info): Pop unused lfm off the
9229         stack.
9230
9231         * mini-exceptions.c (mono_handle_exception): Call the filter in a
9232         separate statement for clarity.
9233
9234         * mini-sparc.c: Update status.
9235
9236 2004-05-04  Zoltan Varga  <vargaz@freemail.hu>
9237
9238         * mini-exceptions.c (ves_icall_get_frame_info): Flush register windows
9239         here.
9240
9241 Mon May 3 22:58:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
9242
9243         * inssel-ppc.brg: another small pre-release workaround:
9244         we don't do overflow detection for long_sub_un.
9245
9246 Sun May 2 20:12:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
9247
9248         * mini.c, mini-ops, inssel-long32.brg: speedup ulong >> 32
9249         (also works around a weird ppc bug: 57957).
9250
9251 Sat May 1 16:56:10 EDT 2004 Paolo Molaro <lupus@ximian.com>
9252
9253         * tramp-ppc.c: trampoline fixes.
9254
9255 Fri Apr 30 15:54:26 EDT 2004    Paolo Molaro <lupus@ximian.com>
9256
9257         * mini-ppc.c: fixed typos.
9258
9259 Thu Apr 29 20:15:41 CEST 2004 Paolo Molaro <lupus@ximian.com>
9260
9261         * mini-ppc.c, exceptions-ppc.c: more code saves registers
9262         at the top of the stack. Fixed typos. Use a frame registers
9263         for all the methods with exception clauses.
9264
9265 Thu Apr 29 18:52:09 CEST 2004 Paolo Molaro <lupus@ximian.com>
9266
9267         * exceptions-ppc.c: restore fp registers.
9268
9269 Thu Apr 29 18:26:56 CEST 2004 Paolo Molaro <lupus@ximian.com>
9270
9271         * mini-ppc.c, exceptions-ppc.c: save the registers in reverse
9272         order from the stack top (moved the stack room to save the
9273         return value for trace after the param area). Fixed corruption
9274         in restoring registers on unwind.
9275
9276 Thu Apr 29 16:47:15 CEST 2004 Paolo Molaro <lupus@ximian.com>
9277
9278         * mini-ppc.c, cpu-g4.md: fixed unisgned -> double conversion.
9279
9280 Thu Apr 29 13:50:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
9281
9282         * exceptions-ppc.c, mini-ppc.h, mini-ppc.c: fixed localloc
9283         and prolog/epilog for methods that use it. Allow
9284         enough param area room for varargs methods. Fix miguel's
9285         breakage in exception handling.
9286
9287 Thu Apr 29 12:06:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
9288
9289         * Makefile.am: run genmdesc only on current arch.
9290
9291 2004-04-29  Gonzalo Paniagua Javier <gonzalo@ximian.com>
9292
9293         * exceptions-x86.c:
9294         * mini-x86.h: fix the build on windows.
9295
9296 2004-04-28  Zoltan Varga  <vargaz@freemail.hu>
9297
9298         * Makefile.am mini.h mini-exceptions.c mini-x86.h mini-sparc.h exceptions-sparc.c: Move parts of the sparc exception handling code to XP code.
9299
9300         * exceptions-sparc.c exceptions-ppc.c exceptions-s390.c mini-ppc.h mini-s390.h mini-sparc.h: Fix up ports after changes.
9301
9302         * mini-exceptions.c: New file.
9303         
9304         * mini.c mini-exceptions.c mini-x86.h exceptions-x86.c Makefile.am:
9305         Move some parts of the x86 exception handling code to an 
9306         arch-independent file so it can be shared with other ports.
9307
9308 Tue Apr 27 12:15:59 CEST 2004 Paolo Molaro <lupus@ximian.com>
9309
9310         * trace.c, cpu-g4.md, inssel-ppc.brg, mini-ppc.c: some fixes for FP code.
9311
9312 2004-04-26  David Waite  <mass@akuma.org>
9313
9314         * driver.c: remove comma from end of enumeration declaration
9315
9316 2004-04-26  Jackson Harper  <jackson@ximian.com>
9317
9318         * driver.c: parse config file before loading first assembly. This
9319         allows the user gac to be enabled/disabled. 
9320         
9321 2004-04-23  Miguel de Icaza  <miguel@ximian.com>
9322
9323         * mini-ppc.c (ppc_patch): Replaced the branch code patching with a
9324         simpler mechanism: we do not care what is encoded initially
9325         (branch absolute or relative), we care about the code and its
9326         target.  I kept the old code for reference for now.
9327
9328         The new code tries first to determine if the jump is anywhere in
9329         the -/+32 absolute meg range, if it succeeds, it encodes using the
9330         absolute branch;  If not, it tried to find something in the
9331         relative range, if not, it uses the handle_thunk code. 
9332
9333 Fri Apr 23 14:20:40 EDT 2004 Paolo Molaro <lupus@ximian.com>
9334
9335         * exceptions-ppc.c: use the correct ip register on macosx.
9336
9337 Thu Apr 22 13:23:16 EDT 2004 Paolo Molaro <lupus@ximian.com>
9338
9339         * exceptions.c, mini.c, mini-ppc.h: adapt code to macosx.
9340
9341 Thu Apr 22 18:08:37 CEST 2004 Paolo Molaro <lupus@ximian.com>
9342
9343         * mini-ppc.c, cpu-g4.md: made the branch macros more flexible.
9344         Raise exception on integer divide by zero by hand since the hw
9345         doesn't support it. Handle NaNs in FP compares.
9346
9347 Thu Apr 22 16:10:31 CEST 2004 Paolo Molaro <lupus@ximian.com>
9348
9349         * exceptions-ppc.c, mini-ppc.h, mini.c: simplified some
9350         code reducing duplication between the platforms and enabled
9351         signal exception handling (on linux for now).
9352
9353 Wed Apr 21 12:27:48 EDT 2004 Paolo Molaro <lupus@ximian.com>
9354
9355         * exceptions-ppc.c: more macosx support.
9356
9357 Wed Apr 21 16:38:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
9358
9359         * mini-ppc.h, mini-ppc.c, cpu-g4.md: enable bigmul optimization.
9360
9361 Wed Apr 21 16:20:32 CEST 2004 Paolo Molaro <lupus@ximian.com>
9362
9363         * mini.h, mini-ppc.c, cpu-g4.md: support for implicit exceptions.
9364
9365 2004-04-19 Ben Maurer  <bmaurer@users.sourceforge.net>
9366
9367         * iltests.il: more tests.
9368
9369 2004-04-19  Zoltan Varga  <vargaz@freemail.hu>
9370
9371         * mini-*.c (mono_arch_get_allocatable_int_vars): Skip written-only
9372         vars as well.
9373
9374 Mon Apr 19 19:39:47 CEST 2004 Paolo Molaro <lupus@ximian.com>
9375
9376         * mini-ppc.c: some fixes to bootstrap mcs/corlib/etc.
9377
9378 2004-04-19  Zoltan Varga  <vargaz@freemail.hu>
9379
9380         * liveness.c: Mark variables as volatile in all basic blocks reachable
9381         from exception clauses.
9382
9383 2004-04-18  Zoltan Varga  <vargaz@freemail.hu>
9384
9385         * exceptions.cs (test_0_rethow_stacktrace): Make this work with
9386         inlining.
9387
9388 2004-04-18 Ben Maurer  <bmaurer@users.sourceforge.net>
9389
9390         * iltests.il, basic.cs: more tests for regalloc.
9391
9392 2004-04-17 Ben Maurer  <bmaurer@users.sourceforge.net>
9393
9394         * iltests.il: Some tests for register allocation modifications
9395         I have locally.
9396
9397 2004-04-16  Zoltan Varga  <vargaz@freemail.hu>
9398
9399         * exceptions.cs: Add regression test for bug #56782.
9400
9401         * exceptions-*.c (mono_arch_handle_exception): Do not overwrite the
9402         original stack trace if an exception is rethrown. Fixes #56782. Oh,
9403         the beauty of fixing the same thing in 5 different files...
9404
9405 2004-04-15  Zoltan Varga  <vargaz@freemail.hu>
9406
9407         * mini.c (mono_method_to_ir): Do not compute coverage for inlined
9408         methods.
9409
9410 2004-04-14  Zoltan Varga  <vargaz@freemail.hu>
9411
9412         * mini.c: Add support for STRWLPARRAY marshalling convention.
9413
9414 Wed Apr 14 18:15:55 CEST 2004 Paolo Molaro <lupus@ximian.com>
9415
9416         * exceptions-ppc.c: missing fixes in mono_jit_walk_stack (need
9417         to init the context to setup the regs pointer).
9418
9419 Wed Apr 14 17:59:09 CEST 2004 Paolo Molaro <lupus@ximian.com>
9420
9421         * exceptions-ppc.c: more exceptions work.
9422
9423 Wed Apr 14 17:46:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
9424
9425         * mini.c: avoid reusing the same MonoInst on multiple trees: this is
9426         not allowed.
9427
9428 2004-04-13  Miguel de Icaza  <miguel@ximian.com>
9429
9430         * inssel-x86.brg (reg): Add new rules for add, sub and mul that
9431         can use the memory directly.
9432
9433         * cpu-pentium.md: Update documentation from a post from Zoltan. 
9434
9435         add x86_add_membase, x86_sub_membase, x86_mul_membase
9436
9437 2004-04-13  Miguel de Icaza  <miguel@ximian.com>
9438
9439         * mini-ppc.c: Remove unused definitions FLOAT_REGS and
9440         GENERAL_REGS they were also hardcoded for all PPC ports.
9441
9442         (add_general): Use PPC_NUM_REG_ARGS instead of GENERAL_REGS.
9443
9444         Remove hard-coded limit for floating point registers, use
9445         PPC_LAST_FPARG_REG instead in MONO_TYPE_R4 and MONO_TYPE_R8.
9446
9447         Notice that in MacOS X calling conventions you can fit a lot more
9448         floating point values in registers, so I should update the PInvoke
9449         test to excercise the passing of floating point values on the
9450         stack (currently broken).
9451         
9452 2004-04-06  Miguel de Icaza  <miguel@ximian.com>
9453
9454         * tramp-ppc.c (create_trampoline_code): Added
9455         JUMP_TRAMPOLINE_SIZE. 
9456         (ppc_magic_trampoline): Follow the pattern from
9457         x86_magic_trampoline: if code is set to zero, return. 
9458         (create_trampoline_code): Always pass MonoMethod to the jump
9459         trampoline, before it was passing a null.
9460         (mono_arch_create_jump_trampoline): Implement the jump stub, could
9461         share the code with mono_arch_create_jit_trampoline. 
9462
9463         * mini-ppc.c (mono_arch_output_basic_block): CEE_JMP opcode
9464         implemented.
9465         (mono_arch_patch_code): MONO_PATCH_INFO_METHOD_JUMP patch type
9466         implemented.  
9467
9468         * cpu-g4.md: Added length for jmp instruction, the worst case
9469         scenario is 92 bytes (4 mandatory bytes, potential 19 registers
9470         for save_lmf).
9471
9472 2004-04-08  Zoltan Varga  <vargaz@freemail.hu>
9473
9474         * aot.c (mono_compile_assembly): Add back unlink removed by mistake.
9475
9476 2004-04-07  Zoltan Varga  <vargaz@freemail.hu>
9477
9478         * mini.c: Only set bblock->real_offset when adding a new bblock, and
9479         before each IL instruction.
9480
9481         * mini.c (CEE_BOX): Fix warnings.
9482
9483 2004-04-07  Gonzalo Paniagua Javier <gonzalo@ximian.com>
9484
9485         * mini.c: removed a few unused vars and extra whitespace.
9486
9487 2004-04-05 Ben Maurer  <bmaurer@users.sourceforge.net>
9488
9489         * inssel.brg (MONO_EMIT_BOUNDS_CHECK): a new macro to emit bounds
9490         checks.
9491         (MONO_EMIT_BOUNDS_CHECK_IMM): the above, but when you know the
9492         index.
9493         (OP_GETCHR): use the above
9494         (CEE_LDELEMA): use the above.
9495
9496         * inseel-x86.brg (MONO_EMIT_BOUNDS_CHECK): a faster and smaller
9497         version of the generic impl.
9498         (MONO_EMIT_BOUNDS_CHECK_IMM): the same
9499         (CEE_LDELEMA): use the above.
9500
9501 2004-04-05  Zoltan Varga  <vargaz@freemail.hu>
9502
9503         * inssel-long32.brg (CEE_CONV_OVF_I8): Sign extend the i4 value to i8.
9504         Fixes #56317.
9505
9506         * iltests.il: Added new regression test for #56317.
9507
9508 2004-04-05  Zoltan Varga  <vargaz@freemail.hu>
9509
9510         * mini-x86.c (mono_arch_setup_jit_tls_data): Use pthread_attr_get_np
9511         under NetBSD. Fixes #56450.
9512
9513         * liveness.c (update_gen_kill_set): Fix previous patch.
9514
9515 2004-04-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
9516
9517         * mini-x86.h: SA_STACK defined as SA_ONSTACK. Fixed build under NetBSD.
9518
9519 2004-04-02  Zoltan Varga  <vargaz@freemail.hu>
9520
9521         * mini.c (mono_method_to_ir): Avoid handle_loaded_temps in
9522         ldsfld and ldsflda.
9523
9524         * inssel-sparc.brg: Add more optimizations.
9525
9526         * mini-sparc.c: Replace multiply/divide with shifts if possible.
9527
9528 2004-04-01  Martin Baulig  <martin@ximian.com>
9529
9530         * mini.c (handle_box): New static function; moved the
9531         implementation of CEE_BOX here.
9532         (mono_method_to_ir): Added `constrained_call' variable.
9533         (mono_method_to_ir:CEE_CONSTRAINED_): Set it.
9534         (mono_method_to_ir:CEE_CALL): If `constrained_call' is set, use
9535         mono_method_get_constrained() to get the method.
9536
9537 2004-04-01  Martin Baulig  <martin@ximian.com>
9538
9539         * mini.c (TYPE_PARAM_TO_TYPE, TYPE_PARAM_TO_CLASS): Removed.
9540         (MTYPE_PARAM_TO_TYPE, MTYPE_PARAM_TO_CLASS): Removed.
9541         (mono_method_to_ir): We don't need these macros anymore since
9542         mono_class_get_full() already takes care of it. 
9543
9544 2004-03-31  Gonzalo Paniagua Javier <gonzalo@ximian.com>
9545
9546         * aot.c: set aot_verbose to 0, fixed format string that caused sigsegv,
9547         use @function (as doesn't accept #function here) and check the return
9548         value of system and stop if fails.
9549
9550 2004-03-31  Gonzalo Paniagua Javier <gonzalo@ximian.com>
9551
9552         * mini.c: set the timeout to 2s when calling mono_domain_finalize.
9553
9554 2004-03-31  Zoltan Varga  <vargaz@freemail.hu>
9555
9556         * mini-ppc.c (mono_arch_patch_code): Fix ppc build.
9557
9558         * inssel-sparc.brg mini-sparc.c aot.c: Implement AOT support.
9559
9560         * inssel-long32.brg (OP_LNEG): Use ADC instead of ADD here. Fixes
9561         #56223.
9562
9563         * basic-long.cs: Add test for negation of Int64.MinValue.
9564
9565 2004-03-30  Zoltan Varga  <vargaz@freemail.hu>
9566
9567         * mini-sparc.c: Update status.
9568
9569         * mini-sparc.c tramp-sparc.c: Save lmf in trampolines.
9570
9571         * exceptions-sparc.c: Fix return value in filters.
9572
9573         * inssel-sparc.brg: Fix register allocation in some rules.
9574
9575 2004-03-28  Martin Baulig  <martin@ximian.com>
9576
9577         * mini.c (mmono_method_to_ir): In CEE_STELEM, do a handle_stobj()
9578         if neccessary.  
9579
9580 2004-03-28  Zoltan Varga  <vargaz@freemail.hu>
9581
9582         * mini-x86.c (mono_arch_patch_code): Fix warnings.
9583         
9584         * mini-x86.c (mono_arch_output_basic_block): Fix CEE_MUL_OVF_UN if 
9585         dreg is not EAX. Thanks to Willibard Krenn for spotting this. Also
9586         remove unused conv_u4 opcode.
9587
9588         * mini-x86.c: Remove valgrind workaround since it slows down things
9589         even when mono is not run under valgrind.
9590
9591 2004-03-26  Zoltan Varga  <vargaz@freemail.hu>
9592
9593         * mini-sparc.c: Update status.
9594
9595         * inssel-sparc.brg: Add some optimizations.
9596
9597         * inssel-sparc.brg mini-sparc.c: Rework branch instructions to allow
9598         future delay slot filling. Add support for varargs, tail calls and JMP.
9599
9600         * inssel.brg mini-ops.h mini.c: Use OP_REFANYTYPE instead of 
9601         CEE_REFANYTYPE, since CEE_REFANYTYPE needs a prefix to be unique.
9602
9603         * inssel.brg: Fix register allocation in OP_ARGLIST.
9604
9605         * inssel.brg: Fix warnings.
9606
9607 2004-03-25  Martin Baulig  <martin@ximian.com>
9608
9609         * mini.c (inflate_generic_field): Removed.
9610         (mini_get_method): Removed, use mono_get_method_full(),
9611         (mini_get_class): Removed, use mono_class_get_full().
9612         (mono_method_to_ir): Pass our generic context to
9613         mono_field_from_token().        
9614
9615 2004-03-25  Martin Baulig  <martin@ximian.com>
9616
9617         * mini.c (mini_get_class): Take a `MonoGenericContext *' instead
9618         of a `MonoMethod *'.
9619         (mini_get_method): Take a `MonoGenericContext *' instead
9620         of a `MonoMethod *'.
9621         (TYPE_PARAM_TO_TYPE, MTYPE_PARAM_TO_TYPE): mono_method_to_ir() has
9622         a new local variable called `generic_context' which holds the
9623         current `MonoGenericContext *'; use it to lookup things.
9624
9625 2004-03-24  Martin Baulig  <martin@ximian.com>
9626
9627         * mini.c (mini_get_class): New static method; if we're inside a
9628         generic instance, inflate the class if neccessary.
9629         (mono_method_to_ir): Use mini_get_class() instead of mono_class_get().
9630
9631 2004-03-24  Zoltan Varga  <vargaz@freemail.hu>
9632
9633         * iltests.il: New regression test for #55976.
9634
9635         * mini.c (mono_method_to_ir): Empty the stack in endfinally. Fixes
9636         #55976.
9637
9638 2004-03-23  Zoltan Varga  <vargaz@freemail.hu>
9639
9640         * exceptions-sparc.c (mono_sparc_handle_exception): Remove debugging
9641         output.
9642
9643 2004-03-23  Zoltan Varga  <vargaz@freemail.hu>
9644
9645         * liveness.c: Consider SSA stores as well as loads when making vars
9646         volatile.
9647
9648         * exceptions.cs: New regression tests for register allocation.
9649         
9650 2004-03-22  Lluis Sanchez Gual  <lluis@ximian.com>
9651
9652         * mini-ppc.c, tramp-ppc.c: Added lock for accessing the domain code manager.
9653         * mini.c: Removed domain lock from mono_jit_compile_method_with_opt. Use
9654           domain lock only to protect puntual access to data structures.
9655           Added access lock for sighash, jit_icall_hash_name, 
9656           jit_icall_hash_addr and domain->code_mp.
9657
9658 2004-03-20  Zoltan Varga  <vargaz@freemail.hu>
9659
9660         * driver.c: Print SIGSEGV handling method.
9661
9662         * mini-x86.c (mono_arch_free_jit_tls_data): Add missing ifdef.
9663
9664         * mini.c (setup_jit_tls_data): Handle case when this is called
9665         multiple times for a thread.
9666
9667         * mini-x86.c cpu-pentium.md: Fix floating point branch opcodes so fbxx 
9668         is different from fbxx_un. Fixes #54303. Also use constants instead of
9669         magic numbers in a lot of places.
9670
9671 2004-03-19  Zoltan Varga  <vargaz@freemail.hu>
9672
9673         * exceptions.cs: Fix cctor test when --regression is used.
9674
9675 Thu Mar 18 19:57:56 CET 2004 Paolo Molaro <lupus@ximian.com>
9676
9677         * mini-ppc.c, exceptions-ppc.c: basic exceptions support 
9678         for Linux/ppc.
9679
9680 Thu Mar 18 19:56:19 CET 2004 Paolo Molaro <lupus@ximian.com>
9681
9682         * inssel-ppc.brg: fixed register assignments for some rules.
9683
9684 2004-03-17  Zoltan Varga  <vargaz@freemail.hu>
9685
9686         * exceptions.cs: Add test for exceptions in static constructors.
9687
9688         * mini.c (mono_jit_compile_method_with_out): Move the calling of
9689         static constructors outside the domain lock. Fixes #55720.
9690
9691 2004-03-17  Martin Baulig  <martin@ximian.com>
9692
9693         * mini.c (get_generic_field_inst): Removed, this'll never happen.
9694         (inflate_generic_field): Take the `MonoMethod *' instead of the
9695         `MonoClass *' and added support for generic method.
9696         (mono_method_to_ir): In CEE_LDSFLD and CEE_STSFLD, assert we never
9697         have a `field->parent->gen_params', only inflate the field if it's
9698         an open constructed type.
9699
9700 2004-03-17  Zoltan Varga  <vargaz@freemail.hu>
9701
9702         * exceptions-x86.c (mono_arch_handle_exception): Allocate a new
9703         exception object instead of the preconstructed ones.
9704
9705 2004-03-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
9706
9707         * mini.c: reverted changed to sigsegv_signal_handler commited
9708         accidentally in the previous patch.
9709
9710 2004-03-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
9711
9712         * mini.c:
9713         (mono_method_to_ir): CEE_CALLVIRT, abort if no method. It hanged when
9714         running --aot with an old assembly.
9715
9716 2004-03-16  Zoltan Varga  <vargaz@freemail.hu>
9717
9718         * mini-sparc.c (mono_arch_instrument_epilog): Fix handling of floating
9719         point values.
9720
9721         * mini-sparc.c: Add support for v9 branches with prediction.
9722
9723 2004-03-15  Bernie Solomon  <bernard@ugsolutions.com>
9724
9725         * mini.c (mini_init): #warning is GNUC only
9726
9727         * mini-sparc.h: implement __builtin_frame_address
9728         and __builtin_return_address for Sun C compiler
9729
9730 2004-03-15  Zoltan Varga  <vargaz@freemail.hu>
9731
9732         * exceptions-sparc.c (mono_arch_has_unwind_info): Add missing function.
9733
9734 2004-03-14  Zoltan Varga  <vargaz@freemail.hu>
9735
9736         * basic-calls.cs: Add test for unaligned byref long argument passing.
9737
9738         * mini-ops.h: Add sparcv9 compare and branch instructions.
9739
9740         * inssel-sparc.brg mini-sparc.h mini-sparc.c cpu-sparc.md: Use some
9741         v9 instructions if we have a v9 cpu.
9742
9743         * mini-sparc.c (mono_arch_get_global_int_regs): Use unused input
9744         registers for global allocation.
9745
9746         * exceptions-sparc.c: Fixes.
9747         
9748 2004-03-11  Zoltan Varga  <vargaz@freemail.hu>
9749
9750         * liveness.c (mono_analyze_liveness): Optimized version.
9751
9752         * inssel-sparc.brg cpu-sparc.md: Ongoing sparc work.
9753
9754         * mini-sparc.h mini-sparc.c tramp-sparc.c exceptions-sparc.c: Ongoing
9755         sparc work.
9756
9757         * basic-float.cs basic-calls.cs: New regression tests.
9758
9759 2004-03-10  Zoltan Varga  <vargaz@freemail.hu>
9760
9761         * mini-x86.h: Define SIGSEGV_ON_ALTSTACK only if we have a working
9762         sigaltstack implementation.
9763
9764         * mini-x86.c (mono_arch_setup_jit_tls_data): Fix previous patch.
9765         
9766         * mini-x86.c (mono_arch_setup_jit_tls_data): Turn off the sigaltstack
9767         stuff if SIGSEGV_ON_ALTSTACK is not defined.
9768
9769 2004-03-09  Zoltan Varga  <vargaz@freemail.hu>
9770
9771         * mini.c: Fix warnings.
9772         
9773         * mini.c (mono_resolve_patch_target): New function which contains the
9774         arch independent part of the patching process.
9775
9776         * mini-x86.c (mono_arch_patch_code): Move arch independent parts of the
9777         patching code to a separate function.
9778
9779 2004-03-09  Bernie Solomon  <bernard@ugsolutions.com>
9780
9781         * mini.c (add_signal_handler): ifdef out on Windows
9782
9783 2004-03-08  Zoltan Varga  <vargaz@freemail.hu>
9784
9785         * mini-sparc.h mini-sparc.c inssel-sparc.brg exceptions-sparc.c 
9786         cpu-sparc.md: Add exception handling support + other fixes.
9787
9788         * driver.c: Print --help output to stdout. Fixes #55261. Also fix
9789         typed GC detection in --version.
9790
9791         * basic.cs exceptions.cs: New regression tests.
9792
9793         * mini.h mini-x86.h mini-ppc.h: Add MonoCompileArch structure where
9794         the arch specific code can store data during a compilation.
9795
9796         * mini-ops.h: Add OP_SETFRET.
9797
9798         * mini.c (mini_get_ldelema_ins): Instead of allways calling the same
9799         function, register a separate icall for each arity, so the icalls can
9800         get a wrapper.
9801         
9802         * mini.c (mono_print_tree): Print negative offsets in a more readable
9803         form.
9804         
9805         * mini.c: Make signal handling work on sparc.
9806         
9807         * mini.c (mini_init): Add emulation for lconv_to_r8_un.
9808
9809         * inssel-long32.brg: Fix OP_LSUB_OVF_UN rule.
9810
9811         * jit-icalls.c: Emulate truncl by aintl on solaris.
9812
9813         * jit-icalls.c (mono_lconv_to_r8_un): New icall emulation function.
9814
9815 2004-03-05  Zoltan Varga  <vargaz@freemail.hu>
9816
9817         * mini.c (mini_init): fconv_to_ovf can raise exceptions.
9818
9819 2004-03-04  Lluis Sanchez Gual  <lluis@ximian.com>
9820
9821         * mini.c: In CEE_ISINST and CEE_CASTCLASS, if the type is an interface or
9822         a MarshalByRef type, inline a method that performs the check, taking into
9823         account that the object can be a proxy. Also implemented tow new opcodes:
9824         CEE_MONO_CISINST and CEE_MONO_CCASTCLASS.
9825         * inssel.brg: Implemented two new opcodes, mini-ops.h: OP_CISINST and 
9826         OP_CCASTCLASS, which implement CEE_MONO_CISINST and CEE_MONO_CCASTCLASS.
9827
9828 Tue Mar 2 17:23:48 CET 2004 Paolo Molaro <lupus@ximian.com>
9829
9830         * mini-ppc.c: if a relative branch displacement is too big
9831         but it points to and area reachable with an absolute branch, 
9832         avoid the thunks.
9833
9834 Tue Mar 2 16:59:40 CET 2004 Paolo Molaro <lupus@ximian.com>
9835
9836         * mini.c: optimize small copies in cpblk.
9837
9838 2004-03-01  Zoltan Varga  <vargaz@freemail.hu>
9839
9840         * basic-calls.cs basic-float.cs: New regression tests.
9841
9842         * mini-sparc.c inssel-sparc.brg mini-ops.h: Access local variables at 
9843         negative offsets from %fp. Implement localloc. Fix local register 
9844         allocation. Fix the case when the this argument needs to be saved to
9845         the stack. Implement some missing opcodes.
9846
9847 2004-02-26  Zoltan Varga  <vargaz@freemail.hu>
9848
9849         * mini.c (mini_method_compile): Reenable global regalloc in methods
9850         with exception handlers.
9851
9852         * linear-scan.c (mono_varlist_sort): Fix warning.
9853
9854         * linear-scan.c (mono_linear_scan): Fix computation of used_regs.
9855
9856         * mini-x86.c (mono_arch_regalloc_cost): Reenable precise computation of
9857         regalloc costs.
9858
9859         * liveness.c: Make all variables uses in exception clauses volatile, to
9860         prevent them from being allocated to registers. Fixes #42136.
9861
9862 2004-02-25  Zoltan Varga  <vargaz@freemail.hu>
9863
9864         * mini-x86.c (mono_arch_regalloc_cost): Revert this change since it
9865         causes regressions.
9866
9867         * mini.h linear-scan.c mini-x86.c mini-sparc.c mini-ppc.c: Add 'cfg'
9868         argument to mono_arch_regalloc_cost.
9869
9870         * mini-x86.c (mono_arch_regalloc_cost): Compute regalloc costs 
9871         precisely.
9872
9873 2004-02-24  Zoltan Varga  <vargaz@freemail.hu>
9874
9875         * mini.h mini-x86.c mini-ppc.c mini-sparc.c linear-scan.c: 
9876         Make the cost of allocating a variable to a register arch dependent.
9877
9878         * basic-calls.cs: Fix compilation of tests.
9879         
9880         * mini.h mini.c tramp-x86.c mini-x86.c: Add mono_running_on_valgrind ()
9881         helper function to cut back on the number of #ifdefs needed.
9882
9883         * mini-ppc.c: Fix compilation.
9884
9885         * basic-calls.cs: New regression tests.
9886
9887         * mini-sparc.c (mono_sparc_is_virtual_call): New helper function.
9888
9889         * tramp-sparc.c (create_specific_trampoline): Use g5 register instead
9890         of l0 since that is callee saved.
9891
9892         * tramp-sparc.c (sparc_magic_trampoline): Apply unbox trampoline only
9893         to virtual calls.
9894
9895         * mini-sparc.c: Ongoing work + flag virtual calls with a special kind 
9896         of delay instruction.
9897
9898         * inssel.brg (OP_CHECK_THIS): Set tree->sreg1 and dreg correctly.
9899
9900         * mini.h (MonoCallInst): Add 'virtual' flag.
9901
9902         * inssel.brg (mini_emit_virtual_call): Set 'virtual' flag.
9903
9904 2004-02-23  Zoltan Varga  <vargaz@freemail.hu>
9905
9906         * *.cs: New regression tests.
9907
9908         * mini-sparc.c inssel-sparc.brg: Update after latest changes. Ongoing sparc 
9909         work.
9910
9911         * mini.c (mono_runtime_install_handlers): Fix build.
9912
9913         * mini.h (MonoJitTlsData): Add 'stack_size', 'signal_stack' and
9914         'signal_stack_size' members.
9915
9916         * mini.h mini.c mini-x86.h mini-x86.c: Run sigsegv handlers on an 
9917         alternate signal stack.
9918
9919         * exceptions-x86.c: Add stack overflow handling.
9920
9921         * mini.h mini.c mini-x86.c mini-ppc.c trace.h trace.c: Move tracing 
9922         functions to arch independent code.
9923
9924         * mini.c (mono_print_tree): Print more detailed info for load_membase
9925         opcodes.
9926         
9927 2004-02-23  Martin Baulig  <martin@ximian.com>
9928
9929         * mini.c (mini_get_method): Set `gmethod->generic_inst'.
9930
9931 Sun Feb 22 22:25:19 CET 2004 Paolo Molaro <lupus@ximian.com>
9932
9933         * mini-x86.c: fixed reg allocation for div/rem.
9934
9935 2004-02-22  Miguel de Icaza  <miguel@ximian.com>
9936
9937         * driver.c (mono_main): Report some configuratio options on --version.
9938
9939 Fri Feb 20 11:01:44 PST 2004 Paolo Molaro <lupus@ximian.com>
9940
9941         * mini-ppc.c: fixed clt.un, cgt.un. Optimized calls to functions
9942         low in the address space. Correctly flush memory in thunks where we
9943         output native code.
9944
9945 2004-02-20  Martin Baulig  <martin@ximian.com>
9946
9947         * mini.c (mini_get_method): New static method; inflate all generic
9948         methods and methods in open generic instances.
9949         (mono_method_to_ir): Use mini_get_method() instead of mono_get_method().
9950         (ret_type_to_call_opcode): Added support for MONO_TYPE_GENERICINST.
9951
9952 2004-02-19  Zoltan Varga  <vargaz@freemail.hu>
9953
9954         * mini-sparc.c (mono_arch_patch_code): Update after domain->code_mp changes.
9955
9956         * tramp-sparc.c (mono_arch_create_jump_trampoline): Set ji->method.
9957
9958 2004-02-19  Bernie Solomon  <bernard@ugsolutions.com>
9959
9960         * helpers.c (mono_disassemble_code): use Sun's dis if not using gcc
9961
9962         * mini-sparc.c (flushi mono_arch_output_basic_block): make
9963         it compile using Sun's compiler.
9964
9965 2004-02-19  Zoltan Varga  <vargaz@freemail.hu>
9966
9967         * mini-ops.h inssel-sparc.brg cpu-sparc.md mini-sparc.h mini-sparc.c tramp-sparc.c exceptions-sparc.c: Sparc port, part I.
9968
9969         * basic-calls.cs basic-float.cs basic-long.cs objects.cs: New regression tests.
9970
9971 Tue Feb 17 21:41:20 CET 2004 Paolo Molaro <lupus@ximian.com>
9972
9973         * aot.c, mini-x86.c, mini.c: use the code manager instead of a mempool to hold native
9974         code.
9975         * mini-ppc.c: handle calls outside of the allowed range with thunks
9976         allocated using the code manager.
9977         * tramp-ppc.c: use the code manager to hold generated native code.
9978         Fixed the magic trampoline to just patch vtable entries.
9979
9980 2004-02-17  Zoltan Varga  <vargaz@freemail.hu>
9981
9982         * inssel.brg inssel-x86.brg: Move call(immediate) rules to the platform
9983         independent file.
9984
9985 2004-02-16  Zoltan Varga  <vargaz@freemail.hu>
9986
9987         * tramp-ppc.c (mono_arch_create_jump_trampoline): Fix compilation on
9988         PPC.
9989
9990         * mini-x86.c: Call mono_arch_get_lmf_addr instead of mono_get_lmf_addr
9991         if we have a working __thread implementation.
9992
9993         * mini-ops.h cpu-pentium.md mini-x86.c inssel-x86.brg: Remove 
9994         OP_CALL_IMM opcodes, since the CALL opcodes handles immediates as well.
9995
9996 2004-02-15  Zoltan Varga  <vargaz@freemail.hu>
9997
9998         * mini-x86.c: Fix compilation under gcc 2.
9999         
10000 2004-02-14  Zoltan Varga  <vargaz@freemail.hu>
10001
10002         * mini.c (mono_codegen): Avoid infinite loop when an icall wrapper
10003         contains a call to the wrapped function.
10004
10005         * mini-ops.h cpu-pentium.md mini-x86.c inssel-x86.brg: Add 
10006         OP_<CALL>_IMM opcodes, and use them under X86.
10007         
10008         * mini.c (mono_jit_find_compiled_method): Fix warning.
10009
10010         * cpu-pentium.md: Fix length of opcodes which use x86_alu_membase_imm.
10011
10012         * jit-icalls.c (mono_ldftn_nosync): New JIT icall.
10013
10014         * tramp-x86.c (mono_arch_create_jump_trampoline): Move arch independent
10015         functionality to mini.c.
10016
10017         * mini.c (mono_create_jump_trampoline): New function to create a jump
10018         trampoline. Return a compiled method instead of a trampoline if it
10019         exists. Add a cache for jump trampolines.
10020
10021         * mini.c (mono_jit_find_compiled_method): New function to return a
10022         compiled method if it exists.
10023
10024         * mini-x86.c: Call mono_create_jump_trampoline instead of 
10025         mono_arch_create_jit_trampoline.
10026
10027         * jit-icalls.c (mono_ldftn): Do not compile the method. Instead, return
10028         a jump trampoline. Fixes #52092.
10029         
10030 2004-02-11  Zoltan Varga  <vargaz@freemail.hu>
10031
10032         * debug-mini.c (mono_init_debugger): Remove call to mono_verify_corlib,
10033         which is not up-to-date. Add check_corlib_version () instead.
10034
10035         * mini.c (mini_init): Call mono_thread_attach () so embedders do not 
10036         have to call it.
10037         
10038         * mini.c (mono_runtime_install_handlers): Remove check for valgrind
10039         since newer valgrind versions do not need it.
10040
10041         * mini.c (mono_jit_compile_method_with_opt): New helper function to
10042         compile a method with a given set of optimizations.
10043
10044         * mini.c: Compile icall wrappers on-demand instead of at startup.
10045
10046         * mini-sparc.c mini-ppc.c: Call mono_icall_get_wrapper to obtain the
10047         wrapper for an icall.
10048
10049 2004-02-10  Zoltan Varga  <vargaz@freemail.hu>
10050
10051         * mini.c (mono_method_to_ir): Handle switch with non-empty stack. Fixes
10052         #54063.
10053
10054         * iltests.il: Add test for non-empty stack before switch instruction.
10055
10056 2004-02-02  Zoltan Varga  <vargaz@freemail.hu>
10057
10058         * mini.c: Add support for new stringbuilder marshalling conventions.
10059
10060         * mini.c (mono_method_to_ir): Fix stack management of generic CEE_BOX.
10061
10062 2004-02-01  Martin Baulig  <martin@ximian.com>
10063
10064         * mini.c (MTYPE_PARAM_TO_TYPE): Method type arguments are stored
10065         in `ginst->mtype_argv'.
10066
10067 2004-01-31  Miguel de Icaza  <miguel@ximian.com>
10068
10069         * mini.c: Add comments, replace CEE_XXX+128 with OP_XXX to
10070         facilitate grepping.
10071
10072 Wed Jan 28 14:04:58 CET 2004 Paolo Molaro <lupus@ximian.com>
10073
10074         * mini.c: fixed buglet in initobj generic implementation for references.
10075
10076 Fri Jan 23 16:10:44 EST 2004 Paolo Molaro <lupus@ximian.com>
10077
10078         * Makefile.am: make the version script conditional.
10079         * jit-icalls.c: handle missing truncl().
10080
10081 2004-01-23  Zoltan Varga  <vargaz@freemail.hu>
10082
10083         * exceptions.cs: Add more tests for double->int conversion.
10084
10085         * jit-icalls.c (mono_fconv_ovf_i8): Call truncl before comparison, so
10086         we don't throw exceptions when converting 1.1 to a long. Fixes #53250.
10087
10088 Fri Jan 23 17:12:08 CET 2004 Paolo Molaro <lupus@ximian.com>
10089
10090         * driver.c: make --verbose --version emit an error
10091         if the loaded corlib doesn't match the runtime version.
10092
10093 Mon Jan 19 17:44:50 CET 2004 Paolo Molaro <lupus@ximian.com>
10094
10095         * mini-ppc.h: export ppc_patch().
10096         * mini-ppc.c: call convention fixes. Added assert in ppc_patch().
10097         * tramp-ppc.c: call convention fixes: Linux/PPC support should be
10098         on par or better than on MacOSX.
10099
10100 2004-01-19  Zoltan Varga  <vargaz@freemail.hu>
10101
10102         * mini.c tramp-x86.c tramp-sparc.c: Updated after changes to
10103         mono_lookup_pinvoke_call.
10104
10105         * mini-x86.c: Under windows, the default pinvoke calling convention is
10106         stdcall. Fixes #52834.
10107
10108         * mini.c (optimize_branches): Add an upper bound to the number of
10109         iterations to prevent infinite loops on strange loops. Fixes #53003.
10110
10111 2004-01-16  Zoltan Varga  <vargaz@freemail.hu>
10112
10113         * inssel.brg: Add vectors<->one dimensional array checking to CASTCLASS
10114         and ISINST. Fixes #52093.
10115
10116         * objects.cs (test_0_vector_array_cast): New tests.
10117         
10118 2004-01-15  Zoltan Varga  <vargaz@freemail.hu>
10119
10120         * jit-icalls.c (helper_stelem_ref_check): New jit icall for array type
10121         checking in Array.Set ().
10122
10123         * mini.c (method_to_ir): Add array type checking in Array.Set (). Fixes
10124         #52590.
10125
10126         * object.cs (test_0_multi_array_cast): New regression test.
10127
10128 Thu Jan 15 16:30:24 CET 2004 Paolo Molaro <lupus@ximian.com>
10129
10130         * exceptions-ppc.c: fix build on Linux/PPC.
10131
10132 2004-01-14  Zoltan Varga  <vargaz@freemail.hu>
10133
10134         * tramp-x86.c (x86_magic_trampoline): Disable code patching when
10135         running under valgrind.
10136         (x86_magic_trampoline): Fix build bustage.
10137
10138         * debug-mini.c: Modify the debug info serialize/deserialize code so it handles
10139         negative values as well. This is needed for the encoding of the line number
10140         info, since sometimes the line numbers are not in increasing order.
10141
10142 2004-01-13  Zoltan Varga  <vargaz@freemail.hu>
10143
10144         * cpu-pentium.md (localloc): Increase the size of the localloc 
10145         instruction since it is a loop under Win32.
10146
10147         * debug-mini.c (record_line_number): Get rid of unneccesary memory
10148         allocation.
10149
10150 2004-01-09  Zoltan Varga  <vargaz@freemail.hu>
10151
10152         * exceptions-ppc.c exceptions-x86.c exceptions-sparc.c 
10153         tramp-x86.c tramp-ppc.c tramp-sparc.c: Applied patch from 
10154         Max Horn (max@quendi.de). Fix file names in comments.
10155
10156 2004-01-03  Zoltan Varga  <vargaz@freemail.hu>
10157
10158         * ssa.c (mono_ssa_rename_vars): Allocate new_stack on the heap to
10159         avoid stack overflow.
10160         (replace_usage): Avoid uninitialized variable warnings.
10161
10162         * mini.c (mono_method_to_ir): Avoid disabling SSA for array operations
10163         and taking the address of valuetype variables.
10164
10165 2004-01-03  Patrik Torstensson
10166
10167         * mini-x86.c: renamed fpflags to flags in RegTrack, going to be used
10168         for other purposes than FP later on.
10169
10170 2004-01-02  Zoltan Varga  <vargaz@freemail.hu>
10171
10172         * mini.c (mono_method_to_ir): Prevent register allocation for arguments
10173         of tail calls.
10174
10175 Fri Jan 2 13:37:25 CET 2004 Paolo Molaro <lupus@ximian.com>
10176
10177         * mini-ops.h, mini.c, inssel.brg: Object.GetType () speedup.
10178
10179 2003-12-30  Patrik Torstensson <p@rxc.se>
10180
10181         * mini-x86.h: Decreased number of availiable fp regs.
10182         Solves corner cases with FP spilling.
10183
10184 2003-12-23  Patrik Torstensson <p@rxc.se>
10185
10186         * mini-x86.c, mini-ops.h, cpu-pentium.md: Added support
10187         for floating point stack tracking / spilling on x86. 
10188         Fixes bug #49012.
10189         
10190         * basic-float.cs: added float mul overflow test.
10191
10192 2003-12-23  Zoltan Varga  <vargaz@freemail.hu>
10193
10194         * mini.c (mono_method_to_ir): Add workaround for bug #51126.
10195
10196 Sun Dec 21 19:53:16 CET 2003 Paolo Molaro <lupus@ximian.com>
10197
10198         * mini.h, mini-ppc.c, mini-ppc.h: small cleanups and
10199         supports for cond branches that overflow the immediate
10200         overflow offset. mcs can compile simple programs.
10201
10202 Fri Dec 19 21:17:16 CET 2003 Paolo Molaro <lupus@ximian.com>
10203
10204         * exceptions-ppc.c: exception handling support wip:
10205         finally handlers get run on exception.
10206
10207 2003-12-19  Zoltan Varga  <vargaz@freemail.hu>
10208
10209         * aot.c (mono_aot_get_method_inner): Avoid loading AOT code while 
10210         profiling.
10211
10212 Fri Dec 19 17:58:28 CET 2003 Paolo Molaro <lupus@ximian.com>
10213
10214         * cpu-g4.md, mini-ppc.c, exceptions-ppc.c, mini-ppc.h:
10215         initial support for stack walking and unwinding.
10216
10217 2003-12-18  Zoltan Varga  <vargaz@freemail.hu>
10218
10219         * driver.c (mono_main): Make corlib-out-of-sync message more 
10220         descriptive. Also remove verify_corlib call.
10221
10222 Wed Dec 17 15:31:41 CET 2003 Paolo Molaro <lupus@ximian.com>
10223
10224         * mini.c: make CEE_NEWARR calls and other emulated opcodes 
10225         not overlap with other call's arguments, too.
10226
10227 Wed Dec 17 12:49:23 CET 2003 Paolo Molaro <lupus@ximian.com>
10228
10229         * mini.h, mini.c, mini-ppc.c, mini-sparc.c, mini-x86.c: 
10230         move to arch-specific code the choice of arch-specific
10231         intrinsics (from Laurent Morichetti (l_m@pacbell.net)).
10232         * mini.c: ensure emulation calls will not interleave
10233         with other calls.
10234
10235 Wed Dec 17 12:27:26 CET 2003 Paolo Molaro <lupus@ximian.com>
10236
10237         * tramp-ppc.c, basic-calls.cs: rework trampolines so that
10238         the magic trampoline stack frame is dropped before executing
10239         the new method.
10240
10241 Mon Dec 15 18:13:57 CET 2003 Paolo Molaro <lupus@ximian.com>
10242
10243         * mini-ppc.c, cpu-g4.md, inssel-ppc.brg: fixed some opcode lengths
10244         and integer to fp conversions. Added support for overflowing
10245         arguments on the stack. Reserve a couple more registers as temps.
10246         Added support for aot compilation (as output still needs to be
10247         tweaked, though).
10248
10249 Sat Dec 13 17:49:10 CET 2003 Paolo Molaro <lupus@ximian.com>
10250
10251         * mini-ppc.c, basic-long.cs: fix jumps to known labels.
10252         Don't overwrite return register in some corner cases.
10253
10254 2003-12-13  Zoltan Varga  <vargaz@freemail.hu>
10255
10256         * mini.h mini.c driver.c mini-x86.c mini-ppc.c aot.c: Do not run
10257         static constructors when AOT compiling.
10258
10259         * driver.c (mono_main): Call mono_check_corlib_version.
10260
10261 Sat Dec 13 10:31:12 CET 2003 Paolo Molaro <lupus@ximian.com>
10262
10263         * cpu-g4.md, basic.cs: fixed div target register.
10264
10265 Sat Dec 13 09:45:56 CET 2003 Paolo Molaro <lupus@ximian.com>
10266
10267         * mini-ppc.c, basic.cs: shl_imm fix with test.
10268
10269 Fri Dec 12 21:25:14 CET 2003 Paolo Molaro <lupus@ximian.com>
10270
10271         * inssel-ppc.brg, mini-ppc.h, mini-ppc.c: support for passing 
10272         structures by value. Misc fixes.
10273         * objects.cs: more tests.
10274
10275 Fri Dec 12 10:11:49 CET 2003 Paolo Molaro <lupus@ximian.com>
10276
10277         * mini-ppc.c: lconv.ovf.i implemented.
10278
10279 2003-12-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
10280
10281         * mini.c:
10282         (mini_init): don't error out if someone already called g_thread_init.
10283
10284 Tue Dec 9 17:27:14 CET 2003 Paolo Molaro <lupus@ximian.com>
10285
10286         * exceptions-x86.c, exceptions-ppc.c: allow the exception object
10287         to be any type per the spec. Fix abnormal memory usage when
10288         the same object is repeatedly thrown.
10289
10290 Tue Dec 9 15:39:54 CET 2003 Paolo Molaro <lupus@ximian.com>
10291
10292         * mini.c: check for overruns in IL code.
10293
10294 2003-12-09  Zoltan Varga  <vargaz@freemail.hu>
10295
10296         * TODO: Add/remove some todo entries.
10297
10298 2003-12-08  Zoltan Varga  <vargaz@freemail.hu>
10299
10300         * driver.c (mono_main): Call mono_verify_corlib.
10301
10302 2003-12-07  Lluis Sanchez Gual  <lluis@ximian.com>
10303
10304         * inssel.brg: In CEE_ISINST and CEE_CASTCLASS, removed check for proxy. 
10305         This has been moved to mini.c
10306         * mini.c: in mono_method_to_ir, CEE_ISINST and CEE_CASTCLASS cases, if the
10307         type being casted is marshalbyref it could be a proxy, so instead of
10308         emitting the type check code, emit a call to a runtime method that will
10309         perform the check by calling CanCastTo if needed.
10310
10311 2003-12-06  Zoltan Varga  <vargaz@freemail.hu>
10312
10313         * mini-x86.c (mono_arch_emit_prolog): Fix stack space allocation for
10314         methods with large stack frames under Win32.
10315
10316 2003-12-04  Zoltan Varga  <vargaz@freemail.hu>
10317
10318         * Makefile.am: Distribute regression tests.
10319
10320         * mini-x86.c (mono_arch_get_allocatable_int_vars): Sort the var list
10321         at the end instead of inserting each variable into the sorted list.
10322
10323         * linear-scan.c (mono_varlist_sort): New helper function.
10324         
10325 Wed Dec 3 20:46:28 CET 2003 Paolo Molaro <lupus@ximian.com>
10326
10327         * mini.c: ensure arguments and locals are within bounds.
10328
10329 Wed Dec 3 17:59:10 CET 2003 Paolo Molaro <lupus@ximian.com>
10330
10331         * mini-ppc.c, cpu-g4.md, basic.cs, basic-long.cs: more tests and 
10332         related fixes.
10333
10334 2003-12-03  Zoltan Varga  <vargaz@freemail.hu>
10335
10336         * mini.c (mono_cprop_copy_values): Fix crash.
10337
10338         * aot.c: Set verbosity back to 0.
10339         
10340 Wed Dec 3 15:42:27 CET 2003 Paolo Molaro <lupus@ximian.com>
10341
10342         * regalloc.c: complete memory leak fix by Laurent Morichetti
10343         (l_m@pacbell.net).
10344
10345 2003-12-03  Zoltan Varga  <vargaz@freemail.hu>
10346
10347         * driver.c (main_thread_handler): Revert the previous patch.
10348
10349         * tramp-x86.c (x86_class_init_trampoline): Avoid patching when running
10350         under valgrind.
10351
10352         * mini-x86.c (mono_arch_local_regalloc): Do not allocate transient
10353         memory from the memory pool.
10354
10355         * driver.c (main_thread_handler): Turn on all optimizations when
10356         --aot is used.
10357
10358         * mini.c (mono_find_jit_opcode_emulation): Turn emul_opcode_hash into
10359         an array for better performance.
10360
10361         * regalloc.c (mono_regstate_assign): Fix memory leak.
10362
10363         * debug-mini.c (mono_debug_serialize_debug_info): New function to
10364         serialize the debug info.
10365
10366         * debug-mini.c (mono_debug_add_aot_method): New function to load the
10367         debug info from the serialized representation.
10368
10369         * aot.c: Save debug info into the generated file and load it when 
10370         loading a method.
10371
10372         * mini.h (MONO_AOT_FILE_VERSION): Bump version number.
10373
10374 Mon Dec 1 16:54:05 CET 2003 Paolo Molaro <lupus@ximian.com>
10375
10376         * mini-ppc.c, tramp-ppc.c: save FP arguments in the trampoline.
10377         More FP-related fixes.
10378
10379 Sun Nov 30 19:13:52 CET 2003 Paolo Molaro <lupus@ximian.com>
10380
10381         * mini-ppc.c, cpu-g4.md, inssel-ppc.brg: fixed finally handlers
10382         and register allocation buglet. Hello world now runs.
10383
10384 Fri Nov 28 23:03:05 CET 2003 Paolo Molaro <lupus@ximian.com>
10385
10386         * cpu-g4.md, inssel-ppc.brg, mini-ppc.c: better long return support.
10387         * tramp-ppc.c: fixed class init trampoline.
10388         * inssel-ppc.brg, mini.c, jit-icalls.c, mini-ppc.h: more emulation.
10389
10390 Fri Nov 28 16:36:29 CET 2003 Paolo Molaro <lupus@ximian.com>
10391
10392         * cpu-g4.md, inssel-ppc.brg, jit-icalls.c, mini-ppc.c, mini-ppc.h,
10393         mini.c: more ppc changes/fixes.
10394
10395 2003-11-27  Zoltan Varga  <vargaz@freemail.hu>
10396
10397         * mini.c (mono_method_to_ir): Fix tail calls with valuetype arguments.
10398         Also optimize the case when the arguments are the same in the caller 
10399         and in the callee.
10400
10401         * iltests.il: Add tests for tail calls with valuetype arguments.
10402
10403 Thu Nov 27 21:06:37 CET 2003 Paolo Molaro <lupus@ximian.com>
10404
10405         * mini-ppc.c: fixes for struct return type.
10406
10407 Thu Nov 27 19:02:07 CET 2003 Paolo Molaro <lupus@ximian.com>
10408
10409         * mini.h, mini.c, mini-x86.c, mini-ppc.c, mini-sparc.c: move 
10410         mono_spillvar_offset() to arch-specific code.
10411
10412 Thu Nov 27 18:30:42 CET 2003 Paolo Molaro <lupus@ximian.com>
10413
10414         * mini-ppc.h, mini-ppc.c: handle some different ABI call convention issues.
10415
10416 2003-11-27  Zoltan Varga  <vargaz@freemail.hu>
10417
10418         * exceptions-x86.c: Fix stack space leaks.
10419         
10420         * exceptions-x86.c (mono_arch_find_jit_info): Restore callee saved
10421         registers from the lmf if the method has save_lmf set.
10422
10423 2003-11-26  Zoltan Varga  <vargaz@freemail.hu>
10424
10425         * tramp-x86.c (x86_magic_trampoline): Avoid patching in the addresses
10426         of icall wrappers into InvokeInDomain, since these are now per-domain.
10427
10428 Wed Nov 26 20:15:04 CET 2003 Paolo Molaro <lupus@ximian.com>
10429
10430         * mini-ppc.h, mini-x86.h, mini.c, inssel-ppc.brg, jit-icalls.c:
10431         make some opcode emulation and intrinsic ops enabled/disabled 
10432         according to the architecture. More fixes.
10433
10434 Wed Nov 26 19:59:09 CET 2003 Paolo Molaro <lupus@ximian.com>
10435
10436         * mini-ppc.c, mini-sparc.c, cpu-g4.md: more bug fixes.
10437
10438 Wed Nov 26 19:18:29 CET 2003 Paolo Molaro <lupus@ximian.com>
10439
10440         * mini.h, inssel.brg, mini-x86.c, mini-ppc.c, mini-sparc.c: move
10441         arch-specific handling for 'this' and struct return type to
10442         arch-specific code.
10443
10444 2003-11-26  Gonzalo Paniagua Javier <gonzalo@ximian.com>
10445
10446         * aot.c: prevent divide by zero error when reporting (it happened with
10447         Accessibility.dll).
10448
10449 2003-11-25  Zoltan Varga  <vargaz@freemail.hu>
10450
10451         * mini.h (inst_switch): Remove unused macro.
10452
10453 2003-11-25  Gonzalo Paniagua Javier <gonzalo@ximian.com>
10454
10455         * aot.c:
10456         (load_aot_module): free 'info->methods' and 'info' properly. No more
10457         "free(): invalid pointer blah" messages when you have an old aot
10458         compiled assembly.
10459
10460 2003-11-21  Lluis Sanchez Gual <lluis@ximian.com>
10461
10462         * jit-icalls.c, mini.c: Added support for context static fields.
10463
10464 2003-11-18  Zoltan Varga  <vargaz@freemail.hu>
10465
10466         * mini.c (mono_method_blittable): Methods which set LastError are not 
10467         blittable either. Fixes #51108.
10468         
10469 Tue Nov 18 16:41:37 CET 2003 Paolo Molaro <lupus@ximian.com>
10470
10471         * mini.c: flush icache.
10472         * cpu-g4.md, mini-ppc.c, inssel.brg: more fixes. Trace support.
10473
10474 2003-11-18  Zoltan Varga  <vargaz@freemail.hu>
10475
10476         * mini.c (mono_type_blittable): OBJECT is not blittable. Fixes #47842.
10477
10478 2003-11-17  Zoltan Varga  <vargaz@freemail.hu>
10479
10480         * tramp-x86.c (x86_class_init_trampoline): Make code patching thread
10481         safe on IA32.
10482
10483         * mini-x86.c (mono_arch_call_opcode): Disable AOT for methods with 
10484         vararg calls.
10485
10486         * inssel.brg (CEE_MKREFANY): Fix AOT case.
10487
10488 2003-11-16  Zoltan Varga  <vargaz@freemail.hu>
10489
10490         * mini-x86.c (mono_arch_local_regalloc): Fix regalloc for div 
10491         instruction when the result is discarded.
10492
10493         * iltests.il (test_0_div_regalloc): New regression test.
10494
10495         * arrays.cs: Fix compilation error.
10496
10497 Fri Nov 14 21:34:06 CET 2003 Paolo Molaro <lupus@ximian.com>
10498
10499         * inssel-x86.brg, inssel-float.brg, mini-ops.h: move x86-specific
10500         float rules to inssel-x86.brg: sane architectures with FP registers
10501         don't need to implement these rules.
10502
10503 Fri Nov 14 20:52:12 CET 2003 Paolo Molaro <lupus@ximian.com>
10504
10505         * mini-ppc.c, cpu-g4.md, inssel-ppc.brg: updates and fixes to the ppc port.
10506
10507 Fri Nov 14 17:58:27 CET 2003 Paolo Molaro <lupus@ximian.com>
10508
10509         * mini.h, inssel-long32.brg: fixed endianess issues in int64
10510         implementation of 32 bit systems.
10511
10512 Thu Nov 13 16:14:41 CET 2003 Paolo Molaro <lupus@ximian.com>
10513
10514         * exceptions-ppc.c: fix build on Linux/ppc from Jeroen@xs4all.nl
10515         (Jeroen Zwartepoorte).
10516
10517 2003-11-12  Zoltan Varga  <vargaz@freemail.hu>
10518
10519         * mini.c (mono_method_to_ir): Use CEE_JMP only if the signature of
10520         the caller and the callee matches.
10521         
10522         * mini.c (mono_method_to_ir): Add comment.
10523
10524         * mini-x86.c (mono_arch_output_basic_block): Use mono_signbit, since
10525         signbit is missing on some platforms.
10526
10527 2003-11-06  Zoltan Varga  <vargaz@freemail.hu>
10528
10529         * mini.h (mono_arch_setup_jit_tls_data): New arch specific function.
10530
10531         * mini.c (setup_jit_tls_data): Call the new function.
10532         
10533         * mini-x86.c mini-ppc.c mini-sparc.c: Define the new function.
10534
10535         * mini-x86.c: Add experimental support for fast access to the lmf
10536         structure under NPTL/Linux 2.6.x.
10537
10538 2003-11-06  Martin Baulig  <martin@ximian.com>
10539
10540         * ldscript: Make `GC_push_all_stack', `GC_start_blocking',
10541         `GC_end_blocking' and 'gc_thread_vtable' public; they're used by
10542         the debugger.
10543
10544 2003-11-02  Martin Baulig  <martin@ximian.com>
10545
10546         * mini.c (inflate_generic_field): New static method.
10547         (mono_method_to_ir): In CEE_LDFLD and CEE_LDSFLD: if we're a
10548         generic instance and the field is declared in a generic type, call
10549         inflate_generic_field() to inflate it.  Fixes gen-28.cs.
10550
10551 2003-10-31  Zoltan Varga  <vargaz@freemail.hu>
10552
10553         * mini.h mini.c (mono_method_same_domain): New function to return
10554         whenever the caller and the callee are in the same domain.
10555
10556         * tramp-x86.c (x86_magic_trampoline): Use the new function.     
10557
10558 2003-10-30  Martin Baulig  <martin@ximian.com>
10559
10560         * mini.c (MTYPE_PARAM_TO_TYPE, MTYPE_PARAM_TO_CLASS): New macros;
10561         similar to TYPE_PARAM_TO_TYPE and TYPE_PARAM_TO_CLASS, but for
10562         method parameters.
10563         (mono_method_to_ir): Added support for MONO_TYPE_MVAR; similar to
10564         MONO_TYPE_VAR, we the actual types from MTYPE_PARAM_TO_CLASS(). 
10565
10566 2003-10-29  Zoltan Varga  <vargaz@freemail.hu>
10567
10568         * mini.c mini-ops.h inssel.brg: Implement undeniable exception 
10569         propagation.
10570
10571         * mini.c (sigusr1_signal_handler): Move creation of the thread abort
10572         object here, so it is in the correct appdomain etc.
10573
10574 2003-10-27  Zoltan Varga  <vargaz@freemail.hu>
10575
10576         * mini.c (mono_jit_compile_method_inner): Lookup icalls here if not
10577         already done.
10578         (mono_method_to_ir): Avoid freeing the type created returned from
10579         mono_type_create_from_typespec, since it is put into an internal cache
10580         by the function. Fixes pointer.exe.
10581
10582         * mini.c tramp-x86.c tramp-sparc.c tramp-ppc.c: Use the normal 
10583         trampolines for icalls and pinvokes as well. Fixes #33569.
10584
10585 2003-10-24  Zoltan Varga  <vargaz@freemail.hu>
10586
10587         * mini.c: Update after appdomain changes.
10588
10589         * mini.c (mono_jit_compile_method_inner): Allways compile native
10590         method wrappers in the root domain, since there can only be one
10591         instance of them, whose address is stored in method->info.
10592
10593 2003-10-16  Zoltan Varga  <vargaz@freemail.hu>
10594
10595         * mini.c (mono_runtime_install_handlers): Get rid of the MONO_VALGRIND
10596         environment variable. Instead detect automatically whenever running
10597         under valgrind using the magic macro RUNNING_ON_VALGRIND from
10598         valgrind.h.
10599
10600 2003-10-16  Miguel de Icaza  <miguel@ximian.com>
10601
10602         * trace.c, trace.h: New files that implement the new trace option
10603         parsing. 
10604
10605         * driver.c: Document new --trace options.
10606
10607         * exceptions-ppc.c, exceptions-x86.c, mini-ppc.c, mini-sparc.c,
10608         mini-x86.c: Apply:
10609
10610         -       if (mono_jit_trace_calls)
10611         +       if (mono_jit_trace_calls != NULL && mono_trace_eval (method))
10612
10613         * mini.h: prototypes.
10614         
10615 2003-10-15  Zoltan Varga  <vargaz@freemail.hu>
10616
10617         * mini.c (mono_method_to_ir): Fix initialization of typedbyref locals.
10618
10619         * mini.c inssel.brg: Implement typedefbyref opcodes.
10620
10621         * mini.c (mono_jit_compile_method): Remove unused local variable.
10622
10623         * mini.c (mono_jit_compile_method_inner): Ditto.
10624         
10625 2003-10-12  Zoltan Varga  <vargaz@freemail.hu>
10626
10627         * tramp-x86.c (x86_class_init_trampoline): Fix build.
10628         
10629         * tramp-x86.c (x86_class_init_trampoline): Thread safety fixes.
10630
10631 2003-10-10  Zoltan Varga  <vargaz@freemail.hu>
10632
10633         * mini.c (mono_no_aot): Remove unused global variable.
10634
10635         * mini.c: Thread safety fixes.
10636
10637 2003-10-09  Zoltan Varga  <vargaz@freemail.hu>
10638
10639         * mini.c (mono_create_class_init_trampoline): Add a lock around
10640         class_init_hash_addr.
10641
10642         * arrays.cs (test_0_newarr_emulation): Add new regression test for
10643         #30073.
10644
10645         * mini.c: Decompose the NEWARR instruction before decomposing its
10646         arguments. Fixes #30073.
10647
10648 2003-10-08  Zoltan Varga  <vargaz@freemail.hu>
10649
10650         * mini-x86.c (mono_arch_emit_epilog): Add support for stdcall calling
10651         convention.
10652
10653 2003-10-06  Zoltan Varga  <vargaz@freemail.hu>
10654
10655         * mini.c (mono_method_to_ir): Allow wrapper data for CEE_LDELEMA.
10656
10657         * inssel-x86.brg (OP_LOCALLOC): Fix register assignment for localloc.
10658
10659         * driver.c: Add support for compiling icall wrappers to --compile.
10660
10661 2003-10-05  Zoltan Varga  <vargaz@freemail.hu>
10662
10663         * inssel.brg: The empty value in class->interface_offsets is -1, not
10664         0. Fixes #49287.
10665
10666 2003-10-03  Zoltan Varga  <vargaz@freemail.hu>
10667
10668         * objects.cs: New test for 'is' operator on an array of interfaces.
10669
10670 Wed Oct 1 19:40:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
10671
10672         * tramp-ppc.c: update trampoline code to support jumps
10673         and class initialization.
10674
10675 2003-09-30  Zoltan Varga  <vargaz@freemail.hu>
10676
10677         * mini.c (mono_jit_compile_method): Fix reading of freed memory.
10678
10679         * inssel.brg (OP_UNBOXCAST): Fix #46027.
10680
10681         * inssel.brg (OP_UNBOX): Remove unused rule.
10682
10683         * mini.h mini.c inssel-x86.brg: Allocate one SP variable for each
10684         region instead of one for each method. Fixes #47813.
10685
10686 2003-09-29  Zoltan Varga  <vargaz@freemail.hu>
10687
10688         * exceptions.cs (test_0_nested_finally): New regression test for
10689         nested exception handlers.
10690
10691         * mini.c (mono_jit_runtime_invoke): Fix for the previous fix.
10692
10693         * mini.c (mono_method_to_ir): Avoid inlining tail calls.
10694
10695         * mini.c (mono_method_to_ir): Fix tail recursion in the presence of 
10696         inlining.
10697
10698         * mini.c (mono_method_check_inlining): Make the inlining limit 
10699         configurable by an environment variable.
10700         
10701         * mini.c (mono_jit_runtime_invoke): Add Gonzalo's fix for #36545.
10702
10703         * mini.h: Bump AOT file version.
10704
10705         * mini.h mini.c aot.c mini-x86.c: For relocations which refer to a 
10706         token, store the image along with the token, since the token might not 
10707         refer to the same image as the method containing the relocation, 
10708         because of inlining.
10709
10710 2003-09-27  Zoltan Varga  <vargaz@freemail.hu>
10711
10712         * mini.c (mono_precompile_assemblies): New function to compile
10713         all methods in all loaded assemblies.
10714
10715         * mini.h driver.c: Added new optimization flag MONO_OPT_PRECOMP.
10716
10717         * regalloc.h regalloc.c (MonoRegState): Change the type of 
10718         iassign and fassign to int*, since they can contain large negative
10719         values if the register is spilled. Also added some comments. Fixes
10720         #45817.
10721
10722         * exceptions-x86.c (seh_handler): Fix handling of system exceptions
10723         under Win32. Fixes #42964.
10724
10725 2003-09-26  Zoltan Varga  <vargaz@freemail.hu>
10726
10727         * mini.h (MONO_PATCH_INFO_WRAPPER): New patch type.
10728
10729         * aot.c: Added support for AOT compiling methods which contain calls
10730         to wrappers. Currently, only remoting-invoke-with-check wrappers are
10731         handled.
10732         
10733         * driver.c (compile_all_methods): Run the compilation in a thread
10734         managed by mono. Fixes #44023.
10735
10736         * mini.c (mono_codegen): Print full method name in verbose output.
10737
10738         * mini-x86.c (mono_arch_patch_code): Fix warning.
10739         
10740         * mini-x86.c (mono_arch_patch_code): Allways create a trampoline for
10741         jumps, since the method we are jumping to might be domain-specific.
10742
10743         * aot.c: Added support for MONO_PATCH_INFO_METHOD_JUMP.
10744
10745 Tue Sep 23 10:50:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
10746
10747         * inssel.brg: string chars are unsigned.
10748
10749 2003-09-15  Zoltan Varga  <vargaz@freemail.hu>
10750
10751         * TODO: New todo item.
10752
10753         * tramp-x86.c (x86_class_init_trampoline): New trampoline function
10754         which calls mono_runtime_class_init and patches the call site to
10755         avoid further calls.
10756         (mono_arch_create_class_init_trampoline): New arch specific function 
10757         to create a class init trampoline.
10758         (create_trampoline_code): Generalized so it can create
10759         class init trampolines as well.
10760
10761         * mini.c (helper_sig_class_init_trampoline): New helper variable.
10762         (mono_create_class_init_trampoline): New function to create and cache
10763         class init trampolines.
10764         (mono_find_class_init_trampoline_by_addr): New function to lookup the
10765         vtable given the address of a class init trampoline. Used by the
10766         patching process.
10767         (mono_codegen): Generate a call to a trampoline instead of
10768         mono_runtime_class_init in LDSFLD[A].
10769         (mono_codegen): Add relocations for the new trampoline.
10770         
10771         * mini.h mini-x86.c aot.c: Added a new relocation type: 
10772         MONO_PATCH_INFO_CLASS_INIT.
10773
10774         * mini.h: Bump AOT version number.
10775
10776         * aot.c: Create a copy of the loaded code instead of using the original
10777         so methods which call each other will be close in memory, improving
10778         cache behaviour.
10779         
10780         * exceptions-x86.c (mono_arch_has_unwind_info): Back out the previous
10781         patch since it breaks the regression tests.
10782         
10783         * exceptions-x86.c (mono_arch_has_unwind_info): Added explicit check
10784         for the register saving instruction sequence since the 
10785         frame_state_for function in glibc 2.3.2 don't seem to detect it.
10786
10787 2003-09-14  Zoltan Varga  <vargaz@freemail.hu>
10788
10789         * TODO: Fix todo item && remove another.
10790
10791 2003-09-12  Zoltan Varga  <vargaz@freemail.hu>
10792
10793         * mini-x86.c (mono_arch_patch_code): Fix tail calls broken by a
10794         previous checkin.
10795
10796         * aot.c: Moved the check for MONO_LASTAOT into the initialization
10797         function of the module.
10798
10799         * mini.h mini.c aot.c: Added a new optimization flag OPT_AOT for
10800         turning on/off the usage of AOT code. Got rid of mono_no_aot and the
10801         --no-aot command line option.
10802
10803 2003-09-11  Zoltan Varga  <vargaz@freemail.hu>
10804
10805         * helpers.c (mono_disassemble_code): Make this work under cygwin. Patch
10806         by Bernie Solomon (bernard@ugsolutions.com).
10807
10808         * inssel.brg: Refactor the interface offset table related code into
10809         its separate functions and add support for the AOT case.
10810
10811 2003-09-10  Zoltan Varga  <vargaz@freemail.hu>
10812
10813         * aot.c (mono_aot_get_method_inner): Fix memory leak.
10814         
10815         * aot.c: Added mono_aot_verbose variable and made all debugging
10816         output depend on the value of this variable.
10817
10818         * aot.c (mono_aot_get_method_inner): Avoid dynamic allocation of
10819         method_label and info_label.
10820
10821         * mini.h mini-x86.c aot.c: Added a new relocation type 
10822         MONO_PATCH_INFO_IID for klass->interface_id.
10823
10824         * mini.h mini.c driver.c aot.c: Changed mono_aot_get_method to return
10825         the MonoJitInfo structure.
10826
10827         * mini.c (mono_jit_compile_method): Avoid using non-shared AOT in
10828         a non-root appdomain in shared mode.
10829
10830 Tue Sep 9 16:33:07 CEST 2003 Paolo Molaro <lupus@ximian.com>
10831
10832         * aot.c: make aot loader less verbose. Remove free of unused variable.
10833
10834 2003-09-08  Zoltan Varga  <vargaz@freemail.hu>
10835
10836         * aot.c (mono_aot_get_method_inner): Fix MONO_PATCH_INFO_IMAGE.
10837
10838         * .cvsignore: Added *.dll.
10839
10840         * mini.c (mono_print_tree_nl): New function callable while debugging.
10841
10842         * mini.c (mono_print_code): Export this.
10843
10844         * tramp-x86.c (x86_magic_trampoline): Tell valgrind to recompile the
10845         patched code.
10846
10847 2003-09-05  Zoltan Varga  <vargaz@freemail.hu>
10848
10849         * mini.h (MonoCompile): Added 'jit_info' field.
10850
10851         * mini.c (mini_method_compile): Save the generated MonoJitInfo into
10852         the cfg structure, since it is needed by the AOT compiler.
10853
10854         * mini.h (MONO_AOT_FILE_VERSION): Bump version number.
10855
10856         * aot.c: A major rewrite. Changes include:
10857         - save exception tables for methods which have them.
10858         - cache failed lookups in aot_get_method () to avoid the (slow) calls 
10859         to g_module_symbol.
10860         - reworked the file format so it is now much smaller and needs
10861         fewer relocation entries.
10862         
10863 2003-09-04  Zoltan Varga  <vargaz@freemail.hu>
10864
10865         * aot.c (load_aot_module): Fix build bustage on platforms without
10866         Boehm GC.
10867
10868 2003-09-04  Martin Baulig  <martin@ximian.com>
10869
10870         * Makefile.am (INCLUDES): Added $(LIBGC_CFLAGS).
10871
10872 2003-09-04  Zoltan Varga  <vargaz@freemail.hu>
10873
10874         * TODO: Some new optimization ideas.
10875
10876         * aot.c: Move AOT module loading logic here from mono_assembly_open.
10877
10878         * aot.c: Save the optimization flags used to compile the code into
10879         the AOT module.
10880
10881         * mini.h mini-x86.c mini.c aot.c: Added new types of relocations to
10882         support emitting domain specific code.
10883         
10884         * mini.h mini.c aot.c: Modified the JIT so the generated AOT code is 
10885         no longer domain neutral. It can be made domain neutral by compiling 
10886         with --optimize=shared.
10887
10888         * aot.c (mono_aot_get_method_inner): Allow sharing of AOT methods
10889         between appdomains.
10890
10891         * driver.c mini.h mini.c: New --no-aot debugging option which disables
10892         loading of AOT code.
10893
10894         * inssel-x86.brg: Added missing AOTCONST -> OUTARG_VT rule.
10895         
10896         * tramp-x86.c (x86_magic_trampoline): Avoid patching the calling method
10897         if there is no domain neutrality information.
10898
10899 2003-09-01  Zoltan Varga  <vargaz@freemail.hu>
10900
10901         * aot.c (mono_compile_assembly): Emit a symbol containing the file 
10902         format version into the generated library.
10903
10904         * mini-x86.c (mono_arch_patch_code): Do not emit the address of the
10905         callee method into the caller since one of them could be shared.
10906
10907         * mini.h mini-x86.c aot.c: Added two new relocations so throwing
10908         system exceptions from AOT code now works.
10909
10910         * tramp-x86.c (x86_magic_trampoline): Avoid patching the calling 
10911         method if it is domain neutral and the callee is not.
10912
10913         * graph.c (cfg_emit_one_loop_level): Fix warning.
10914
10915 2003-08-30  Zoltan Varga  <vargaz@freemail.hu>
10916
10917         * aot.c (mono_compile_assembly): Oops. Remove debugging cruft from
10918         last checkin.
10919
10920 2003-08-29  Zoltan Varga  <vargaz@freemail.hu>
10921
10922         * mini.c (mini_init): Call mono_marshal_init () explicitly since it
10923         is needed  by code which is executed before mono_runtime_init ().
10924         Thanks to Bernie Solomon (bernard@ugsolutions.com) for noticing this.
10925         
10926         * mini.c (mono_thread_abort): Fix warning.
10927         (mono_jit_compile_method): Call static constructor in the AOT case too.
10928
10929         * aot.c (mono_compile_assembly): Fix warning.
10930
10931 2003-08-28  Gonzalo Paniagua Javier <gonzalo@ximian.com>
10932
10933         * mini.c: register a SIGINT handler if MONO_DEBUG is defined.
10934
10935 2003-08-28  Zoltan Varga  <vargaz@freemail.hu>
10936
10937         * inssel.brg (OP_UNBOXCAST): Add support for the AOT case.
10938
10939         * cpu-pentium.md: Fix the length of call opcodes so they include the
10940         ESP restoring instruction. Fixes #47968.
10941
10942 2003-08-28  Martin Baulig  <martin@ximian.com>
10943
10944         * mini-x86.c (mono_arch_call_opcode): Added support for
10945         MONO_TYPE_GENERICINST.
10946
10947         * mini.c (check_call_signature): Added support for MONO_TYPE_GENERICINST.       
10948
10949 2003-08-27  Zoltan Varga  <vargaz@freemail.hu>
10950
10951         * Makefile.am (BUILT_SOURCES): Fix compilation on platforms without
10952         a JIT. Patch by Bernie Solomon (bernard@ugsolutions.com).
10953
10954         * mini.c jit-icalls.c tramp-x86.c tramp-ppc.c tramp-sparc.c: Get rid of
10955         metadata_section.
10956
10957 2003-08-26  Martin Baulig  <martin@ximian.com>
10958
10959         * mini.c (get_basic_blocks): Added `unsigned char **pos' argument;
10960         when reporting an error, set this to the actual error location.
10961         (mono_method_to_ir): Report the correct error location if
10962         get_basic_blocks() returned an error.
10963
10964 2003-08-25  Zoltan Varga  <vargaz@freemail.hu>
10965
10966         * mini.c (mono_type_blittable): OBJECT is not blittable.
10967         (mono_method_blittable): Methods which have marshalling descriptors
10968         are not blittable either. Fixes #47842.
10969
10970 2003-08-22  Zoltan Varga  <vargaz@freemail.hu>
10971
10972         * driver.c mini.c: Use an environment variable instead of a global 
10973         variable. Also fix the build.
10974
10975         * mini.c (mini_init): Call g_thread_init () to make glib thread-safe. 
10976         Fixes #47682. Thanks to Laurent Morichetti (l_m@pacbell.net) for 
10977         reporting this. 
10978
10979         * driver.c mini.c: Added --with-valgrind option to turn off some
10980         code which prevents mono from running under valgrind.
10981
10982         * mini.c (mono_emit_call_args): Fixed warning.
10983
10984         * mini.c (mono_emulate_opcode): Fixed warning.
10985
10986 Thu Aug 21 19:10:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
10987
10988         * inssel.brg: 64bit fixes from Laurent Morichetti <l_m@pacbell.net>.
10989         * linear-scan.c, mini-ppc.h, mini-sparc.h, mini-x86.h, mini.h,
10990         regalloc.c, regalloc.h: specify available registers in arch-specific
10991         code and support floats in the regallocator (patch by Laurent Morichetti 
10992         <l_m@pacbell.net>)
10993
10994 Wed Aug 20 19:02:22 CEST 2003 Paolo Molaro <lupus@ximian.com>
10995
10996         * mini.c: mono_thread_current() can be called only after
10997         mono_runtime_init(): rearrange code to not call it early on.
10998
10999 Wed Aug 20 13:14:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
11000
11001         * mini.c: allocate jump tables in the code mempools.
11002
11003 Wed Aug 20 13:04:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
11004
11005         * mini.c, mini.h: make sure per-thread data allocated by the jit is
11006         freed.
11007
11008 2003-08-10  Miguel de Icaza  <miguel@ximian.com>
11009
11010         * cpu-pentium.md (ldtoken): Change the length for mul.ovf.un from
11011         12 to 16.  This fixes bug #47453.
11012
11013
11014 Thu Aug 7 15:59:35 CEST 2003 Paolo Molaro <lupus@ximian.com>
11015
11016         * mini-ppc.c: fixed indexed load and unsigned compares.
11017
11018 2003-08-06  Lluis Sanchez Gual  <lluis@ximian.com>
11019
11020         * mini.c: reenabled installation of handler for
11021           thread abort signal.
11022
11023 Tue Aug 5 12:21:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
11024
11025         * cprop.c, mini-x86.c, cpu-pentium.md: fix buglets spotted
11026         by Laurent Morichetti <l_m@pacbell.net>. Disabled local cprop
11027         until it's fixed and actually useful.
11028
11029 Mon Aug 4 12:12:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
11030
11031         * inssel-long32.brg: couple more opcodes implemented.
11032
11033 Thu Jul 31 22:43:02 EDT 2003 Mark Crichton <crichton@gimp.org>
11034         
11035         * mini-sparc.c: Even more opcodes implemeted.
11036
11037 Thu Jul 31 19:36:03 EDT 2003 Mark Crichton <crichton@gimp.org>
11038
11039         * mini-sparc.c: More opcodes implemented.
11040
11041 Thu Jul 31 15:16:26 EDT 2003 Mark Crichton <crichton@gimp.org>
11042
11043         * mini-sparc.c: More opcodes implemented.
11044
11045 Wed Jul 30 22:31:02 EDT 2003 Mark Crichton <crichton@gimp.org>
11046
11047         * inssel-sparc.brg: Add some needed rules.  Direct
11048         copy from PPC.
11049         * Makefile.am: Use inssel-sparc.brg
11050         * exceptions-sparc.c: 0xdeadbeef/0xdecafbad to keep
11051         an assert happy for now.
11052
11053 Wed Jul 30 20:44:07 EDT 2003 Mark Crichton <crichton@gimp.org>
11054
11055         * mini-sparc.c: Fixed compile errors.
11056         * exceptions-sparc.c: Same.  We now produce a mono binary 
11057         on sparc-linux.  Yea.
11058
11059 Wed Jul 30 14:10:12 EDT 2003 Mark Crichton <crichton@gimp.org>
11060
11061         * mini-sparc.c: Renamed registers.  Also some macro cleanups.
11062         * exceptions-sparc.c, tramp-sparc.c: Various compile fixes.
11063         They compile, but do not work.
11064
11065 Wed Jul 30 17:52:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
11066
11067         * Makefile.am, cpu-sparc.md, exceptions-sparc.c, mini-sparc.c,
11068         mini-sparc.h, tramp-sparc.c: Beginning of sparc support
11069         from Mark Crichton <crichton@gimp.org> and Christopher Taylor
11070         (ct@gentoo.org).
11071
11072 Tue Jul 29 12:43:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
11073
11074         * mini.c: more opcodes implemented and better support for generics.
11075
11076 Fri Jul 25 18:51:45 CEST 2003 Paolo Molaro <lupus@ximian.com>
11077
11078         * cpu-g4.md, cpu-pentium.md: updates for new instructions.
11079         * mini.c, mini.h: first cut at generics support: some new instructions 
11080         added and changed the behaviour of some of the existing ones.
11081
11082 2003-07-21  Miguel de Icaza  <miguel@ximian.com>
11083
11084         * mini.c: Removed definition of metadata_shared mutex here.
11085
11086 Tue Jul 22 15:21:24 CEST 2003 Paolo Molaro <lupus@ximian.com>
11087
11088         * mini-x86.c: make vararg calls work for instance methods.
11089
11090 Fri Jul 18 19:26:20 CEST 2003 Paolo Molaro <lupus@ximian.com>
11091
11092         * mini.c, mini.h, mini-x86.c, mini-ppc.c: mono_arch_call_opcode()
11093         returns the arguments in a separte list, now.
11094
11095 Fri Jul 18 13:16:18 CEST 2003 Paolo Molaro <lupus@ximian.com>
11096
11097         * aot.c, mini.c: updates for array type representation changes.
11098
11099 Fri Jul 18 11:28:28 CEST 2003 Paolo Molaro <lupus@ximian.com>
11100
11101         * mini.c: register function to perform jit shutdown.
11102
11103 Thu Jul 17 16:02:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
11104
11105         * mini.c: use a faster allocator if possible.
11106
11107 Thu Jul 17 16:00:39 CEST 2003 Paolo Molaro <lupus@ximian.com>
11108
11109         * aot.c: some cleanups and portability changes.
11110
11111 Wed Jul 2 11:08:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
11112
11113         * mini.c: use faster allocation for CEE_BOX if possible.
11114
11115 Mon Jun 30 19:16:33 CEST 2003 Paolo Molaro <lupus@ximian.com>
11116
11117         * mini.c, mini-ops.h, inssel.brg, mini-x86.c: optimized access to fields.
11118         Moved inlined mempcy code to its own function so that is can be
11119         reused. Added an inline memset function as well (optimized initobj).
11120         * cpu-pentium.md, inssel-x86.brg: add and use lea_membase.
11121
11122 Fri Jun 27 11:19:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
11123
11124         * mini.c, mini-ops.h, inssel.brg: optimized a couple of Array methods.
11125
11126 Wed Jun 25 13:19:25 CEST 2003 Paolo Molaro <lupus@ximian.com>
11127
11128         * mini.c, mini.h, mini.x86.c, mini-ppc.c: added facility so that
11129         arch code can setup the cpu for CLR execution, if needed.
11130         We use it on x86 to set the precision of FP operations.
11131
11132 Tue Jun 17 19:02:55 CEST 2003 Paolo Molaro <lupus@ximian.com>
11133
11134         * mini.c: disable some optimizations if we can guess they'll cost too
11135         much for a given method.
11136
11137 2003-06-17  Zoltan Varga  <vargaz@freemail.hu>
11138
11139         * mini.h mini.c: Rework last patch based on suggestions by Paolo.
11140         
11141 2003-06-17  Zoltan Varga  <vargaz@freemail.hu>
11142         * mini.h mini.c mini-x86.c: Added instruction level coverage 
11143         info collection support.
11144
11145 Mon Jun 16 18:13:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
11146
11147         * driver.c, mini-ppc.c, mini-x86.c, mini.c, mini.h: the coverage stuff
11148         is now implemented in the profiling API. Get rid of a couple of
11149         unnecessary global variables.
11150
11151 2003-06-15  Nick Drochak <ndrochak@gol.com>
11152
11153         * basic-long.cs: tests for negative values for bigmul, and unsigned.
11154         * cpu-g4.md: add op_bigmul and op_bigmul_un
11155         * cpu_pentium.md: add op_bigmul_un
11156         * inssel-long32.brg: add rule for unsigned bigmul
11157         * mini-ops.h: define OP_BIGMUL_UN
11158         * mini-x86.c: THE BUG: handle (un)signed properly
11159         * mini.c: choose unsigned opcode if needed.
11160         This set of patches fixes bug #44291
11161
11162 2003-06-13  Dietmar Maurer  <dietmar@ximian.com>
11163
11164         * mini.c (optimize_branches): improved to handle all kinds of
11165         conditional branches.
11166
11167 Wed Jun 11 18:01:06 CEST 2003 Paolo Molaro <lupus@ximian.com>
11168
11169         * mini.c, mini.h, jit-icalls.c: speedup emulation of opcodes that
11170         don't raise exceptions.
11171
11172 Tue Jun 10 19:00:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
11173
11174         * tramp-x86.c, tramp-ppc.c, debug-mini.c: move arch-specific code
11175         to arch-specific files.
11176
11177 2003-06-09  Martin Baulig  <martin@ximian.com>
11178
11179         * Makefile.am (libs): Added $(LIBGC_LIBS).
11180
11181 Mon Jun 9 20:21:47 CEST 2003 Paolo Molaro <lupus@ximian.com>
11182
11183         * cpu-pentium.md, mini-x86.c: fix (well, actually implement) OP_TAN
11184         and OP_ATAN (fixes bug#44293).
11185
11186 Mon Jun 9 19:00:56 CEST 2003 Paolo Molaro <lupus@ximian.com>
11187
11188         * Makefile.am, mini-x86.c: rename cpu description array to
11189         pentium_desc, since some compilers define the 'pentium' preprocessor
11190         symbol.
11191
11192 2003-05-28  Dietmar Maurer  <dietmar@ximian.com>
11193
11194         * mini.c (mini_select_instructions): add explicit branch if the
11195         following block is not the false target of a conditional branch -
11196         we need this with any optimization that reorder or remove bblocks
11197
11198         * mini.c (optimize_branches): bug fixes
11199
11200 2003-06-06  Dietmar Maurer  <dietmar@ximian.com>
11201
11202         * mini.c (mono_method_to_ir): inline static readonly fields
11203
11204         * ssa.c (fold_tree): start cfold support for long (very simple
11205         cases only)
11206
11207         * cfold.c (mono_constant_fold_inst): opt. CEE_CONV_I8 (OP_ICONST)
11208
11209 Fri Jun 6 11:41:18 CEST 2003 Paolo Molaro <lupus@ximian.com>
11210
11211         * inssel.brg: fixed memcpy (bug #44219).
11212
11213 2003-06-05  Dick Porter  <dick@ximian.com>
11214
11215         * driver.c: Set the glib log levels to not abort if g_message
11216         recurses.
11217
11218         g_set_prgname() has to happen before mini_init() so that the
11219         process handle gets the info.
11220         
11221 Thu Jun 5 20:11:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
11222
11223         * driver.c: add intrins to the default optimizations to get wider
11224         exposure.
11225
11226 Wed Jun 4 19:47:57 CEST 2003 Paolo Molaro <lupus@ximian.com>
11227
11228         * mini.h: some large basic blocks will overflow a 16-bit
11229         integers for symbolic registers.
11230
11231 2003-06-04  Dietmar Maurer  <dietmar@ximian.com>
11232
11233         * mini-x86.c (mono_arch_output_basic_block): revert previous fprem changes.
11234         (mono_arch_output_basic_block): fix bug 43499 
11235
11236 Wed Jun 4 13:13:52 CEST 2003 Paolo Molaro <lupus@ximian.com>
11237
11238         * mini.c: kill duplicated definition of mono_debug_format.
11239
11240 Wed Jun 4 13:09:51 CEST 2003 Paolo Molaro <lupus@ximian.com>
11241
11242         * mini-x86.c, arrays.cs: fixed register allocation bug.
11243
11244 2003-06-04  Dietmar Maurer  <dietmar@ximian.com>
11245
11246         * mini-x86.c (mono_arch_output_basic_block): use IEEE compatible fprem1
11247
11248         * mini.c (mini_get_opcode_for_method): inline IEEERemainder
11249
11250 2003-06-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
11251
11252         * mini.c:
11253         (print_method_from_ip): also print source location information if
11254         available.
11255
11256 2003-06-02  Dietmar Maurer  <dietmar@ximian.com>
11257
11258         * mini.c (mono_find_block_region): bug fix in region code
11259         (mini_method_compile): enable removing unreachable code again, but
11260         only in methods without exception clauses.
11261
11262 Fri May 30 18:40:24 CEST 2003 Paolo Molaro <lupus@ximian.com>
11263
11264         * mini.c, mini-ops.h, cpu-pentium.md, inssel.brg, mini-x86.c, mini.h:
11265         Implemented arglist opcode and handling of TypedReference type.
11266         Fixed x86 call convention when a structure is returned.
11267         Minimal support for calling static vararg methods.
11268
11269 2003-05-30  Dietmar Maurer  <dietmar@ximian.com>
11270
11271         * mini.c (mini_method_compile):  always remove unreachable code,
11272         because the code in them may be inconsistent  (access to dead
11273         variables for example).
11274
11275 Thu May 29 11:44:49 CEST 2003 Paolo Molaro <lupus@ximian.com>
11276
11277         * driver.c, debug-mini.c: warning fixes.
11278
11279 Wed May 28 11:19:15 CEST 2003 Paolo Molaro <lupus@ximian.com>
11280
11281         * Makefile.am, jit.h, mini.h: install header for embedding mono.
11282
11283 Tue May 27 17:56:12 CEST 2003 Paolo Molaro <lupus@ximian.com>
11284
11285         * mini.c: thread-static fields are registered in mono_class_vtable(),
11286         so ensure the function is called before checking for them.
11287
11288 2003-05-27  Dietmar Maurer  <dietmar@ximian.com>
11289
11290         * mini.c (optimize_branches): fix for bug 43586
11291
11292         * jit-icalls.c (mono_llmult_ovf): added an additional check for
11293         overflow (fixes Bug #43639)
11294
11295 Tue May 27 11:33:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
11296
11297         * mini.c, objects.cs: allow the use of stobj for primitive types.
11298
11299 Tue May 27 10:33:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
11300
11301         * mini.c: be less strict about argument checking until we support
11302         running the verifier.
11303
11304 2003-05-27  Nick Drochak <ndrochak@gol.com>
11305
11306         * basic-long.cs: tests for (ulong)int * (ulong)int also
11307         * mini.c: use the same trick for (ulong)int * (ulong)int
11308
11309 2003-05-27  Nick Drochak <ndrochak@gol.com>
11310
11311         * basic-long.cs: add regression test for (long)int * (long)int
11312         * cpu-pentium.md: add op_bigmul specification
11313         * inssel-long32.brg: add OP_BIGMUL rule
11314         * mini-ops.h: add OP_BIGMUL
11315         * mini-x86.c: register allocator: handle case where src1 needs to be
11316         in EAX.
11317         * mini.c: substitute special BIGMUL opcode in the tree for 
11318         (long)int * (long)int
11319
11320 Mon May 26 20:20:13 CEST 2003 Paolo Molaro <lupus@ximian.com>
11321
11322         * jit-icalls.c: call the type ctor on field access if needed.
11323
11324 Mon May 26 15:21:21 CEST 2003 Paolo Molaro <lupus@ximian.com>
11325
11326         * mini-ops.h, mini.c, inssel.brg, exceptions.cs: validate arguments passed
11327         to a method (including results of ldelema, bug#43207).
11328
11329 2003-05-26  Dietmar Maurer  <dietmar@ximian.com>
11330
11331         * graph.c (cfg_emit_one_loop_level): loop over all blocks. use
11332         colors to show exception handler blocks.
11333
11334         * inssel-x86.brg (OP_OUTARG_VT): dont push zero sized structures
11335         (fix for pinvoke7.cs).
11336
11337 Mon May 26 12:11:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
11338
11339         * mini.h, mini.c: ensure correct initialization order for types that
11340         require it. Prepare for lazy compilation of jit icall wrappers.
11341         Provide a name for opcode emulation to reduce unneeded mallocing.
11342
11343 Fri May 23 16:08:54 CEST 2003 Paolo Molaro <lupus@ximian.com>
11344
11345         * mini-x86.c: better register restoring code and profiling
11346         support for tail calls.
11347
11348 Fri May 23 15:30:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
11349
11350         * mini.h, driver.c: prepare for leaf methods optimization.
11351
11352 Fri May 23 15:28:32 CEST 2003 Paolo Molaro <lupus@ximian.com>
11353
11354         * mini.c: get targets of branches before converting a method.
11355
11356 2003-05-23  Dietmar Maurer  <dietmar@ximian.com>
11357
11358         * mini.c (optimize_branches): added some experimental code (disbaled) 
11359
11360 2003-05-22  Dietmar Maurer  <dietmar@ximian.com>
11361
11362         * mini.c (optimize_branches): fix branch to branch optimization 
11363
11364         * exceptions-x86.c (mono_arch_handle_exception): bug fix.
11365
11366         * mini-x86.c (mono_arch_output_basic_block): cleanup up exception code
11367
11368         * inssel-x86.brg: added OP_START_HANDLER, CEE_ENDFINALLY, OP_ENDFILTER
11369
11370         * mini-x86.c (mono_arch_allocate_vars): only reserve space for lmf
11371         if needed.
11372
11373 2003-05-21  Dietmar Maurer  <dietmar@ximian.com>
11374
11375         * mini.c (mono_method_to_ir): call handle_loaded_temps before inlining.
11376         enable use of interface variables again.
11377
11378         * mini-x86.c (mono_arch_get_allocatable_int_vars): dont allocate
11379         I1 to registers because there is no simply way to sign extend 8bit
11380         quantities in caller saved registers on x86.
11381
11382         * inssel-float.brg: set costs of some rules to 2 so
11383         that monobure always select the arch. specific ones if supplied,
11384         regardless of the order we pass the files to monoburg.
11385
11386 Tue May 20 17:19:14 CEST 2003 Paolo Molaro <lupus@ximian.com>
11387
11388         * mini.c, mini-x86.c: since the magic trampoline for jumps
11389         can't patch the code directly, we do it as soon as the
11390         method gets compiled.
11391
11392 Tue May 20 16:02:52 CEST 2003 Paolo Molaro <lupus@ximian.com>
11393
11394         * mini-x86.c, mini.h: introduce a new patching method
11395         to support CEE_JMP and tail calls.
11396         * mini.c: obey tail.call. Don't precompile methods target
11397         of CEE_JMP.
11398         * tramp-x86.c: new trampoline code to handle methods
11399         reached through a jump.
11400
11401 2003-05-20  Dietmar Maurer  <dietmar@ximian.com>
11402
11403         * mini-x86.c (mono_arch_get_allocatable_int_vars): allocate 8/16
11404         bit values to registers
11405
11406 2003-05-19  Dietmar Maurer  <dietmar@ximian.com>
11407
11408         * mini.c (mono_compile_get_interface_var): share interface
11409         variables if possible.
11410
11411 2003-05-16  Martin Baulig  <martin@ximian.com>
11412
11413         * debug-mini.c (mono_init_debugger): New function to initialize
11414         the debugger.  This is not in the debugger since it needs to
11415         access some of mini's internals.
11416
11417 2003-05-16  Dietmar Maurer  <dietmar@ximian.com>
11418
11419         * mini.c (mono_method_to_ir): inlining fixes/cleanups
11420
11421 Fri May 16 13:27:23 CEST 2003 Paolo Molaro <lupus@ximian.com>
11422
11423         * mini.c, mini-opts.h, inssel.brg: inline small memcpy
11424         for value type handling.
11425
11426 2003-05-16  Dietmar Maurer  <dietmar@ximian.com>
11427
11428         * mini.c (mono_method_to_ir): inline LDFLD/STFLD wrappers
11429         (mono_method_check_inlining): enable inlining of all kinds of wrappers
11430
11431 2003-05-15  Lluis Sanchez Gual  <lluis@ideary.com>
11432
11433         * mini.c: fixed little bug in CEE_NEWOBJ case when calling
11434           the constructor through a proxy.
11435
11436 Thu May 15 17:17:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
11437
11438         * jit-icalls.c, inssel.brg: fixes to array element address
11439         calculations.
11440
11441 2003-05-15  Dietmar Maurer  <dietmar@ximian.com>
11442
11443         * mini-x86.c (is_regsize_var): allocate pointer to registers
11444
11445 Thu May 15 13:04:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
11446
11447         * driver.c: fixed typo, added intrins to the set of optimizations
11448         tested with regressions.
11449
11450 Thu May 15 11:57:42 CEST 2003 Paolo Molaro <lupus@ximian.com>
11451
11452         * mini-ops.h, mini.c, inssel.brg: optimize access to 2D arrays.
11453         * jit-icalls.c, exceptions.cs: fixed index out of range checks, added
11454         test case.
11455
11456 2003-05-14  Dietmar Maurer  <dietmar@ximian.com>
11457
11458         * inssel.brg: remove some common pop instructions without side effects
11459
11460 Wed May 14 12:40:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
11461
11462         * inssel-x86.brg: fixed thinko in int to double conversions.
11463
11464 Wed May 14 12:01:58 CEST 2003 Paolo Molaro <lupus@ximian.com>
11465
11466         * mini.c, jit-icalls.c: added runtime thread-static variable support.
11467
11468 Tue May 13 22:02:06 CEST 2003 Paolo Molaro <lupus@ximian.com>
11469
11470         * inssel-long32.brg: two more missing instructions.
11471
11472 2003-05-13  Dietmar Maurer  <dietmar@ximian.com>
11473
11474         * mini.c (mono_emit_call_args): set the cil_code for all arguments
11475         if not already set.
11476
11477 2003-05-12  Zoltan Varga  <vargaz@freemail.hu>
11478
11479         * mini-x86.c (mono_arch_output_basic_block): Handle negative zero
11480         correctly.
11481
11482         * basic-float.cs: Added tests for negative zero.
11483
11484 Sun May 11 14:56:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
11485
11486         * inssel-long32.brg, basic-long.cs, exceptions.cs: handle
11487         a couple of missing operations for long casts, with test cases.
11488
11489 2003-05-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
11490
11491         * exceptions-x86.c: fixed small leaks in mono_arch_handle_exception.
11492
11493 2003-05-09  Dietmar Maurer  <dietmar@ximian.com>
11494
11495         * mini-x86.c (mono_arch_emit_prolog): avoid reallocs with better
11496         code size estimation.
11497
11498 2003-05-08  Dietmar Maurer  <dietmar@ximian.com>
11499
11500         * mini.c (mono_jit_create_remoting_trampoline): make it work with
11501         abstract methods (fix bug 42542)
11502
11503         * aot.c: add ability to handle array types
11504         
11505 2003-05-08  Zoltan Varga  <vargaz@freemail.hu>
11506
11507         * mini.c: Call the _specific versions of the object allocation
11508         functions if possible.
11509
11510 Tue May 6 17:18:33 CEST 2003 Paolo Molaro <lupus@ximian.com>
11511
11512         * driver.c: call setlocale ().
11513
11514 Tue May 6 14:38:22 CEST 2003 Paolo Molaro <lupus@ximian.com>
11515
11516         * mini.h, mini.c, aot.c, debug-mini.c, exceptions.c: build fixes for
11517         windows build.
11518
11519 2003-05-05  Dietmar Maurer  <dietmar@ximian.com>
11520
11521         * mini.c (optimize_branches): dont touch code inside exception clauses (fix bug 38136)
11522
11523         * exceptions-x86.c (ves_icall_get_frame_info): also skip remoting
11524         wrappers (fix bug 42122)
11525
11526 2003-05-04  Martin Baulig  <martin@ximian.com>
11527
11528         * mini.h (mono_jit_init, mono_jit_cleanup): Added prototypes.
11529
11530         * driver.c: s/MONO_OPT_SAHRED/MONO_OPT_SHARED/g.
11531         s/mini_set_defaults/mono_set_defaults/g.
11532
11533 2003-05-04  Martin Baulig  <martin@ximian.com>
11534
11535         * driver.c: s/mini_parse_default_optimizations/mono_parse_default_optimizations/g.
11536
11537 Sun May 4 11:48:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
11538
11539         * inssel-long32.brg: add missing lreg: OP_LCONV_TO_U8 (lreg) rule
11540         (reported by Don Roberts).
11541
11542 Fri May 2 18:36:45 CEST 2003 Paolo Molaro <lupus@ximian.com>
11543
11544         * mini.c: temporarily work around two bugs for this release.
11545
11546 Fri May 2 17:37:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
11547
11548         * Makefile.am: avoid linking libmono with GMODULE_LIBS, because
11549         that contains -export-dynamic and it makes using the ld script
11550         useless.
11551         * mini.h, main.c, driver.c: s/mini_main/mono_main/g.
11552
11553 Fri May 2 12:52:32 CEST 2003 Paolo Molaro <lupus@ximian.com>
11554
11555         * mini.h, mini-x86.c, driver.c: disable optimizations not available on a
11556         specific cpu.
11557
11558 Thu May 1 15:28:21 CEST 2003 Paolo Molaro <lupus@ximian.com>
11559
11560         * mini.c: make sure leave calls all the needed finally blocks,
11561         even when the target jumps out of multiple exception clauses.
11562
11563 Thu May 1 15:18:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
11564
11565         * ldscript, Makefile.am: add linker script to reduce the number of
11566         exported symbols (should also fix the issues with libwine defining
11567         some of the same symbols in io-layer).
11568
11569 2003-05-01  Zoltan Varga  <vargaz@freemail.hu>
11570
11571         * driver.c (mini_main): Avoid assertion when no file name is given on 
11572         the command line.
11573
11574 Wed Apr 30 15:33:11 CEST 2003 Paolo Molaro <lupus@ximian.com>
11575
11576         * driver.c: added --version/-V command line option.
11577         Added the inline optimization in the regression tests.
11578
11579 Wed Apr 30 15:16:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
11580
11581         * mini.c, basic-calls.cs: when inlining, save arguments to locals according 
11582         to the type in the method signature (fixes bug#42134).
11583
11584 Wed Apr 30 12:38:44 CEST 2003 Paolo Molaro <lupus@ximian.com>
11585
11586         * mini.c: when inlining, check this is not null only when needed (bug #42135).
11587
11588 Wed Apr 30 11:44:36 CEST 2003 Paolo Molaro <lupus@ximian.com>
11589
11590         * mini-ppc.h, tramp-pcc.c: type fixes from Max Horn <max@quendi.de>.
11591
11592 2003-04-30  Gonzalo Paniagua Javier <gonzalo@ximian.com>
11593
11594         * driver.c: fixed bug #42100.
11595
11596 2003-04-29  Dietmar Maurer  <dietmar@ximian.com>
11597
11598         * mini.c (mono_method_to_ir): UNBOX need to CAST objects first
11599
11600 Mon Apr 28 17:03:14 CEST 2003 Paolo Molaro <lupus@ximian.com>
11601
11602         * mini.c: moved most of the code required to do inlining to its own
11603         function so it can be reused. Inline also ctors if appropriate.
11604
11605 2003-04-28  Zoltan Varga  <vargaz@freemail.hu>
11606
11607         * Makefile.am: Link with -export-dynamic so shared libs loaded by
11608         the runtime can call mono API functions.
11609
11610 2003-04-27  Martin Baulig  <martin@ximian.com>
11611
11612         * debug-mini.c (mono_debug_init_method): Added
11613         `guint32 breakpoint_id' argument; if the method has a breakpoint,
11614         send a notification to the debugger.
11615
11616         * mini.c (mono_method_to_ir): Don't insert a breakpoint if we're
11617         running in the Mono Debugger, just pass the breakpoint number to
11618         mono_debug_init_method().
11619
11620         * tramp-x86.c, tramp-ppc.c: Removed the breakpoint trampolines.
11621
11622 Sun Apr 27 13:18:04 CEST 2003 Paolo Molaro <lupus@ximian.com>
11623
11624         * mini.c: allow some more unsafe compares.
11625
11626 Sat Apr 26 11:55:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
11627
11628         * mini-x86.c, Makefile.am: make distcheck works (partially from
11629         a patch by Richard Lee <r.h.lee@attbi.com>).
11630         * regset.c, regset.h: removed, they are unused.
11631
11632 2003-04-25  Dick Porter  <dick@ximian.com>
11633
11634         * driver.c: Usage reports the name as 'mono' not 'mini'
11635         * exceptions-x86.c: Build and run on freebsd
11636
11637 Thu Apr 24 17:09:03 CEST 2003 Paolo Molaro <lupus@ximian.com>
11638
11639         * Makefile.am: install the program with the 'mono' name and
11640         the library as libmono instead of mini and libmini.
11641
11642 Thu Apr 24 17:08:07 CEST 2003 Paolo Molaro <lupus@ximian.com>
11643
11644         * driver.c: provide the APIs for the embedding interface of the old jit.
11645
11646 2003-04-23  Dietmar Maurer  <dietmar@ximian.com>
11647
11648         * jit-icalls.c (helper_stelem_ref): impl. (fix bug 41775)
11649
11650 2003-04-23  Martin Baulig  <martin@ximian.com>
11651
11652         * tramp-x86.c, tramp-ppc.c: Reenable the debugger breakpoint interface.
11653
11654         * driver.c: Added `--debug' command line argument to enable
11655         debugging support.
11656
11657 2003-04-23  Martin Baulig  <martin@ximian.com>
11658
11659         * debug.[ch]: Removed.  The code is now in
11660         ../metadata/mono-debug.[ch] and mono-debug-debugger.[ch].
11661
11662         * debug-stabs.c, debug-dwarf2.c: Removed; nobody used this for the
11663         last six months.
11664
11665 2003-04-22  Dietmar Maurer  <dietmar@ximian.com>
11666
11667         * mini.c (mono_method_to_ir): set the cil_code address (fix bug 41525)
11668
11669 2003-04-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
11670
11671         * mini.c:
11672         (mini_cleanup): moved mono_runtime_cleanup call after the call to
11673         mono_domain_finalize.
11674         (mini_method_compile): use mono_method_profile* if the the option is
11675         enabled.
11676
11677 2003-04-17  Zoltan Varga  <vargaz@freemail.hu>
11678
11679         * tramp-x86.c (mono_arch_create_jit_trampoline): Subsitute synchronized
11680         methods with their wrapper.
11681
11682         * tramp-ppc.c (mono_arch_create_jit_trampoline): Subsitute synchronized
11683         methods with their wrapper.
11684
11685         * jit-icalls.c (mono_ldvirtfn): Subsitute synchronized methods with
11686         their wrapper.
11687
11688         * mini.c (mono_method_to_ir): Subsitute synchronized methods with their
11689         wrapper.
11690
11691         * mini.c (mono_method_check_inlining): Avoid inlining synchronized
11692         methods.
11693
11694 2003-04-17  Dietmar Maurer  <dietmar@ximian.com>
11695
11696         * exceptions-x86.c (mono_arch_handle_exception): fix for bug 36252
11697
11698 2003-04-16  Dietmar Maurer  <dietmar@ximian.com>
11699
11700         * mini.c (mono_compile_create_var): use g_malloc/g_realloc instead
11701         of the mempool. This is slightly faster and uses less memory
11702
11703 Wed Apr 16 12:53:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
11704
11705         * mini.c: avoid O(n) allocation for variables.
11706
11707 Tue Apr 15 19:13:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
11708
11709         * mini.c: handle items on the stack after inlining methods.
11710
11711 Tue Apr 15 14:17:57 CEST 2003 Paolo Molaro <lupus@ximian.com>
11712
11713         * mini.c: make the method->opcode optimization dependent
11714         on MONO_OPT_INSTRINS and do it lazily.
11715
11716 Tue Apr 15 14:15:39 CEST 2003 Paolo Molaro <lupus@ximian.com>
11717
11718         * driver.c: print overall results at the end of regression run.
11719
11720 Tue Apr 15 11:18:46 CEST 2003 Paolo Molaro <lupus@ximian.com>
11721
11722         * inssel.brg: don't overwrite symbolic registers.
11723
11724 Mon Apr 14 17:41:34 CEST 2003 Paolo Molaro <lupus@ximian.com>
11725
11726         * inssel-x86.brg: fix conversion from long to float.
11727
11728 2003-04-11  Dietmar Maurer  <dietmar@ximian.com>
11729
11730         * mini.c (mini_init): use an opcode for get_Chars (OP_GETCHR)
11731
11732 2003-04-10  Zoltan Varga  <vargaz@freemail.hu>
11733
11734         * mini.c (mono_type_blittable): MONO_TYPE_OBJECT is blittable.
11735
11736         * driver.c: Added --print-vtable option as in the old JIT.
11737
11738 Thu Apr 10 17:43:49 CEST 2003 Paolo Molaro <lupus@ximian.com>
11739
11740         * inssel-long32.brg, exceptions.cs: fix conversions from long, too.
11741
11742 Thu Apr 10 16:27:43 CEST 2003 Paolo Molaro <lupus@ximian.com>
11743
11744         * inssel.brg, basic.cs: fixed checked conversions to byte and short.
11745
11746 2003-04-09  Zoltan Varga  <vargaz@freemail.hu>
11747
11748         * mini.c regalloc.c regalloc.h: Fix memory leak.
11749
11750 2003-04-09  Dietmar Maurer  <dietmar@ximian.com>
11751
11752         * aot.c (mono_aot_get_method): register all used strings
11753
11754 Wed Apr 9 15:22:18 CEST 2003 Paolo Molaro <lupus@ximian.com>
11755
11756         * mini.c: always intern strings references with ldstr at compile time.
11757
11758 Tue Apr 8 11:41:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
11759
11760         * Makefile.am: add BUILT_SOURCES.
11761
11762 Mon Apr 7 16:31:34 CEST 2003 Paolo Molaro <lupus@ximian.com>
11763
11764         * driver.c: give a better error message when the assembly to execute
11765         doesn't have an entry point.
11766
11767 2003-04-07  Dietmar Maurer  <dietmar@ximian.com>
11768
11769         * Makefile.am: added hack for automake
11770
11771         * mono/mini/mini.c (mono_save_args): always copy arguments to keep
11772         correct sematics.
11773
11774         * mono/mini/ssa.c (mono_ssa_avoid_copies): don't optimize calls
11775
11776 22003-04-07  Martin Baulig  <martin@ximian.com>
11777
11778         * Makefile.am: Added Makefile.am.
11779
11780         * debugger-main.c: Removed, this is now in the debugger where it
11781         belongs.
11782
11783         * mini.pc.in: Call this package `mini' for the moment.
11784
11785
11786
11787
11788
11789
11790
11791