2008-10-27 Rodrigo Kumpera <rkumpera@novell.com>
[mono.git] / mono / mini / ChangeLog
1 2008-10-27  Rodrigo Kumpera  <rkumpera@novell.com>
2
3         * basic-simd.cs: Test for packing with signed saturation.
4
5 2008-10-28  Zoltan Varga  <vargaz@gmail.com>
6
7         * aot-compiler.c (add_generic_instances): Add all methods of generic instances
8         found in the TYPESPEC table.
9
10 2008-10-26  Zoltan Varga  <vargaz@gmail.com>
11
12         * aot-runtime.c (mono_aot_get_method): Log not found methods for extra methods
13         too.
14
15         * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file format version.
16
17         * mini.c (mono_method_to_ir): For MONO_PATCH_INFO_RVA, save field the token
18         instead of the RVA, since the RVA can be changed by tools like the cil 
19         stripper.
20
21         * method-to-ir.c (mono_method_to_ir2): Ditto.
22
23         * debug-mini.c (serialize_variable): Handle ADDRESS_MODE_DEAD.
24         (deserialize_variable): Ditto.
25
26 2008-10-25  Martin Baulig  <martin@ximian.com>
27
28         * debug-mini.c (write_variable): Use
29         `MONO_DEBUG_VAR_ADDRESS_MODE_DEAD' for dead variables.
30
31 2008-10-24  Rodrigo Kumpera  <rkumpera@novell.com>
32
33         * cpu-x86.md: Add unsigned variants of packd and packw.
34
35         * mini-ops.h: Same.
36
37         * mini-x86.h: Emit the right instruction for packd and packw.
38         Add unsigned variants of packd and packw.
39
40         * simd-intrinsics.c: Packd and packw were used in place of their
41         unsigned variants. Change that.
42         Add intrinsics for (Signed)PackWithSignedSaturation.
43
44         * simd-methods.h: Add (Signed)PackWithSignedSaturation.
45
46 2008-10-24  Rodrigo Kumpera  <rkumpera@novell.com>
47
48         * simd-intrinsics.c (vector4i_intrinsics): New table of intrinsic type.
49
50 2008-10-24  Rodrigo Kumpera  <rkumpera@novell.com>
51
52         * mini-ops.h: Remove dword packed add/sub with saturation ops.
53
54         * cpu-x86.md: Remove dword packed add/sub with saturation ops.
55
56         * simd-intrinsics.c (vector4ui_intrinsics): Remove methods without
57         sse instructions.
58
59         * simd-intrinsics.c (vector8s_intrinsics): Fix ordering.
60
61 2008-10-24  Mark Probst  <mark.probst@gmail.com>
62
63         * method-to-ir.c, mini.c: Special casing for the synchronized
64         wrapper for the ldtoken+GetTypeFromHandle case.
65
66 2008-10-24  Zoltan Varga  <vargaz@gmail.com>
67
68         * mini.c (mono_replace_ins): Move this to branch-opts.c.
69
70         * mini.c (mono_replace_ins): Propagate has_array_access flag to the newly
71         created/split bblocks.
72
73 2008-10-24  Rodrigo Kumpera  <rkumpera@novell.com>
74
75         * mini-ops.h: Add packed signed mul high.
76         
77         * cpu-x86.md: Same.
78
79         * mini-x86.c (mono_arch_output_basic_block): Same.
80
81         * simd-methods.h: Add PackWithUnsignedSaturation and ShiftRightLogic.
82
83         * simd-intrinsics.c (vector8s_intrinsics): New table of intrinsic type.
84
85 2008-10-24  Rodrigo Kumpera  <rkumpera@novell.com>
86
87         * basic-simd.cs: Tests for Vector16sb.
88
89 2008-10-24  Zoltan Varga  <vargaz@gmail.com>
90
91         * inssel.brg (stmt): Fix OP_HARD_NOP rule.
92
93 2008-10-23  Rodrigo Kumpera  <rkumpera@novell.com>
94
95         * mini-ops.h: Add packed signed min, max and compare greater.
96         
97         * cpu-x86.md: Same.
98
99         * mini-x86.c (mono_arch_output_basic_block): Same. Add packed add/sub with
100         saturation.
101
102         * simd-methods.h: Add CompareGreaterThan.
103
104         * simd-methods.h: Remove CompareEquals.
105
106         * simd-intrinsics.c: Add new TODO entry and some cosmetic changes.
107
108         * simd-intrinsics.c (vector16sb_intrinsics): New table of intrinsic type.
109
110         * simd-intrinsics.c (vector4f_intrinsics): Rename CompareEquals to
111         CompareEqual.
112
113 2008-10-23  Rodrigo Kumpera  <rkumpera@novell.com>
114
115         * basic-simd.cs: Fix tests due to change in the API.
116
117 2008-10-21  Zoltan Varga  <vargaz@gmail.com>
118
119         * mini.c method-to-ir.c: Use mono_field_get_name () for accessing field->name.
120
121 2008-10-21  Rodrigo Kumpera  <rkumpera@novell.com>
122
123         * basic-simd.cs: Fix name change in Vector4f::CompareEqual.
124
125         * simd-intrinsics.c (simd_intrinsic_emit_store_aligned): Don't use
126         inst_offset as this has invalid values for LDADDR.
127
128 2008-10-21  Rodrigo Kumpera  <rkumpera@novell.com>
129
130         * basic-simd.cs: Test for SignedPackWithUnsignedSaturation.
131
132         * simd-intrinsics.c (vector4ui_intrinsics): Add SignedPackWithUnsignedSaturation.
133
134 2008-10-21  Zoltan Varga  <vargaz@gmail.com>
135
136         * method-to-ir.c (initialize_array_data): Use mono_field_get_data ()
137         for accessing field->data.
138
139 2008-10-21  Rodrigo Kumpera  <rkumpera@novell.com>
140
141         * basic-simd.cs: Test for SignedPackWithUnsignedSaturation.
142
143 2008-10-21  Rodrigo Kumpera  <rkumpera@novell.com>
144
145         * simd-methods.h: Add SignedPackWithUnsignedSaturation.
146
147         * simd-intrinsics.c (vector8us_intrinsics): Add SignedPackWithUnsignedSaturation.
148
149 2008-10-21  Zoltan Varga  <vargaz@gmail.com>
150
151         * dominators.c (mono_compute_natural_loops): Allocate GList enties
152         from the cfg mempool.
153
154 2008-10-20  Rodrigo Kumpera  <rkumpera@novell.com>
155
156         * basic-simd.cs: Tests for new methods in Vector8us.
157
158 2008-10-20  Rodrigo Kumpera  <rkumpera@novell.com>
159
160         * mini-ops.h: Add multiply and store high.
161         
162         * cpu-x86.md: Same.
163
164         * mini-x86.c (mono_arch_output_basic_block): Same.
165
166         * simd-methods.h: Same.
167
168         * simd-intrinsics.c (vector8us_intrinsics): Add MultiplyStoreHigh
169         and CompareEqual.
170
171 2008-10-19  Zoltan Varga  <vargaz@gmail.com>
172
173         * method-to-ir.c (mono_emit_method_call_full): Remove a needless call to
174         mono_class_setup_vtable ().
175
176         * mini-trampolines.c (mono_convert_imt_slot_to_vtable_slot): Use
177         mono_class_get_vtable_entry () for accessing klass->vtable.
178
179         * aot-runtime.c (load_method): Avoid a crash when using MONO_LOG_LEVEL.
180
181         * aot-compiler.c (add_generic_instances): Avoid a crash if a class is not
182         found.
183
184         * method-to-ir.c (mono_save_token_info): Don't save references made from
185         wrappers.
186
187         * aot-compiler.c (add_generic_instances): Add static rgctx wrappers for cctors
188         of generic instances.
189
190         * aot-runtime.c (find_extra_method): Search in all loaded AOT images.
191
192 2008-10-19  Mark Probst  <mark.probst@gmail.com>
193
194         * cpu-ppc.md, mini-ppc.c: The length of the code generated for
195         OP_JMP depends on the method signature.  Calculate it properly.
196
197 2008-10-19  Zoltan Varga  <vargaz@gmail.com>
198         
199         * aot-runtime.c (mono_aot_find_jit_info): Handle extra methods which are
200         called directly.
201
202         * aot-compiler.c (emit_and_reloc_code): Allow direct calling of generic
203         instances.
204         (emit_extra_methods): Add another table mapping method indexes to 
205         offsets in the extra_method_info table.
206
207         * mini.h: Bump AOT file format version.
208         
209         * aot-runtime.c: Merge most of the code from mono_aot_get_method
210         and mono_aot_get_method_from_token () into one function.
211
212 2008-10-19  Mark Probst  <mark.probst@gmail.com>
213
214         * mini-ppc.c (emit_load_volatile_arguments): Inner loop needs a
215         separate counter.
216
217 2008-10-18  Zoltan Varga  <vargaz@gmail.com>
218
219         * aot-compiler.c aot-runtime.c: Fix the hash function used for the extra
220         methods.
221
222         * method-to-ir.c (mono_method_to_ir2): Change a !compile_aot assert to
223         disable_aot.
224
225         * mini.c (mono_patch_info_equal): Compare the generic context as well.
226
227         * mini.h: Bump aot file format version.
228
229         * aot-compiler.c aot-runtime.c: Generalize the wrapper handling code so the
230         AOT file can contain native code for methods which are not in the METHOD
231         table. Generate code for non-sharable generic instances of generic methods
232         found in the METHODSPEC table.
233         
234         * method-to-ir.c (mono_method_to_ir2): Remove the aot restriction when
235         encoding generic type handles.
236
237         * ir-emit.h (NEW_AOTCONST_TOKEN): Add a generic_context argument.
238         (NEW_TYPE_FROM_HANDLE_CONST): Add a generic_context argument.
239
240         * ir-emit.h: Rewrite the EMIT_NEW_XXXCONST macros to use the NEW_XXXCONST
241         macros + MONO_ADD_INS.
242
243         * mini.c (mono_jump_info_token_new2): New function which takes a generic
244         context as well.
245
246         * mini.h (MonoJumpInfoToken): Include fields for a generic context.
247
248         * mini.h: Bump aot file format version.
249
250         * aot-compiler.c aot-runtime.c: Update after changes to MonoJumpInfoToken.
251
252 2008-10-17  Mark Probst  <mark.probst@gmail.com>
253
254         * mini-x86.h, mini-x86.c, exceptions-x86.c: Align stack on all
255         platforms, with definable stack alignment value.  Set to 16 now
256         for all platforms.
257
258         * mini.c, mini.h, driver.c: Command line option for disabling
259         stack alignment.
260
261 2008-10-17  Rodrigo Kumpera  <rkumpera@novell.com>
262
263         * basic-simd.cs: Tests for new methods in Vector4ui.
264
265 2008-10-17  Rodrigo Kumpera  <rkumpera@novell.com>
266
267         * mini-ops.h: Add packed int shuffle.
268         
269         * cpu-x86.md: Same.
270
271         * mini-x86.c (mono_arch_output_basic_block): Same.
272
273         * simd-intrinsics.c (vector4ui_intrinsics): Add compare equal,
274         extract mask, max, min, shuffle.
275
276         * simd-intrinsics.c (vector8us_intrinsics): Add max and min.
277
278 2008-10-17  Rodrigo Kumpera  <rkumpera@novell.com>
279
280         * basic-simd.cs: Tests for new methods in Vector8us.
281
282 2008-10-17  Mark Probst  <mark.probst@gmail.com>
283
284         * method-to-ir.c (mono_method_to_ir2): "refanytype" produces a
285         RuntimeTypeHandle, not a TypedReference.
286
287 Fri Oct 17 14:40:50 CEST 2008 Paolo Molaro <lupus@ximian.com>
288
289         * simd-intrinsics.c: remove relocations.
290
291 2008-10-17  Zoltan Varga  <vargaz@gmail.com>
292
293         * mini-amd64.c (mono_arch_output_basic_block): Port the IREM_IMM 
294         optimizations from the x86 backend.
295
296 Fri Oct 17 12:00:51 CEST 2008 Paolo Molaro <lupus@ximian.com>
297
298         * simd-methods.h, simd-intrinsics.c: debloat method names and
299         prepare for no relocations.
300
301 2008-10-16  Rodrigo Kumpera  <rkumpera@novell.com>
302
303         * mini-ops.h: Add packed min/equal and sum of absolute differences.
304         
305         * cpu-x86.md: Same.
306
307         * mini-x86.c (mono_arch_output_basic_block): Same.
308
309         * simd-intrinsics.c (vector16b_intrinsics): Add average, compare equal,
310         extract mask, max, min and sum of absolute differences.
311
312         * simd-intrinsics.c: Increase SIMD_INTRINSIC_NAME_MAX due to new huge
313         method name.
314
315 2008-10-16  Rodrigo Kumpera  <rkumpera@novell.com>
316
317         * basic-simd.cs: Test for the other mono_simd_simplify_indirection bug.
318         Renamed one test for consistency.
319
320 2008-10-16  Rodrigo Kumpera  <rkumpera@novell.com>
321
322         * simd-intrinsics.c (mono_simd_simplify_indirection): Apply the previous
323         fix to the code that deal with other blocks.
324
325 2008-10-16  Rodrigo Kumpera  <rkumpera@novell.com>
326
327         * basic-simd.cs: Test for the mono_simd_simplify_indirection bug.
328
329 2008-10-16  Rodrigo Kumpera  <rkumpera@novell.com>
330
331         * simd-intrinsics.c (mono_simd_simplify_indirection): Simplify the code
332         that deals with vreg interference. Explicitly check for OP_LDADDR to be
333         able to process the source reg.
334
335 2008-10-16  Martin Baulig  <martin@ximian.com>
336
337         * mini-ops.h, cpu-amd64.md, cpu-x86.md: Added new `hard_nop' opcode.
338
339         * inssel.brg: Add `OP_HARD_NOP'.
340
341         * mini.h (MonoCompile): Added `keep_cil_nops' flag.
342
343         * mini.c (mono_method_to_ir): In `CEE_NOP': generate a
344         `OP_HARD_NOP' instruction when running inside the debugger.
345
346         * method-to-ir.c (mono_method_to_ir2): In `CEE_NOP': generate a
347         `OP_HARD_NOP' instruction when running inside the debugger.
348
349 2008-10-15  Rodrigo Kumpera  <rkumpera@novell.com>
350
351         * simd-intrinsics.c (get_simd_vreg): Using sreg1 of OP_XMOVE
352         now works. The issue with the regalloc tripping up no longer
353         happens.
354
355         * simd-intrinsics.c (load_simd_vreg): Same.
356
357 2008-10-15  Rodrigo Kumpera  <rkumpera@novell.com>
358         
359         * basic-simd.cs: Tests for new Vector8ui methods.
360
361 2008-10-15  Rodrigo Kumpera  <rkumpera@novell.com>
362
363         * simd-intrinsics.c (get_simd_vreg): Simplify code and test
364         only for type. This fixes crashes where MonoInst::klass is checked
365         for ops of type != VTYPE or OBJ.
366
367         * simd-intrinsics.c (load_simd_vreg): Same.
368
369 2008-10-15  Rodrigo Kumpera  <rkumpera@novell.com>
370
371         * mini-ops.h: Add ops for packed shuffle/max/avg and
372         extract mask.
373         
374         * cpu-x86.md: Same.
375
376         * mini-x86.c (mono_arch_output_basic_block): Same.
377
378         * simd-intrinsics.c (vector8us_intrinsics): Add avg, shuffle and
379         extract mask.
380
381         * simd-intrinsics.c (simd_intrinsic_emit_extract_mask): New function
382         to emit extract mask op.
383
384         * simd-intrinsics.c (simd_intrinsic_emit_shuffle): Retrofic this function
385         to emit word shuffles.
386
387 2008-10-15  Mark Probst  <mark.probst@gmail.com>
388
389         * mini.c (mono_allocate_stack_slots_full): Align stack frame to
390         the largest alignment needed by a variable, but at least
391         sizeof(gpointer).
392
393 2008-10-14  Rodrigo Kumpera  <rkumpera@novell.com>
394
395         * basic-simd.cs: Tests for the fixes in the last commit.
396
397 2008-10-14  Rodrigo Kumpera  <rkumpera@novell.com>
398
399         * simd-intrinsics.c (get_simd_vreg): Drop the is_this_ptr, this function
400         no longer handles STACK_PTR input.
401
402         * simd-intrinsics.c (get_simd_vreg): Don't crash when MonoInst::klass == -1.
403
404         * simd-intrinsics.c (load_simd_vreg): New function that works like 
405         get_simd_vreg   but handles STACK_PTR input.
406
407         * simd-intrinsics.c (simd_intrinsic_emit_getter): Use load_simd_vreg
408         as the input can be an arbitrary pointer.
409
410         * simd-intrinsics.c (simd_intrinsic_emit_ctor): Try the
411         LDADDR local optimization directly otherwise use a store op.
412
413 2008-10-14  Rodrigo Kumpera  <rkumpera@novell.com>
414
415         * basic-simd.cs: Tests for dup low and dup high.
416
417 2008-10-14  Rodrigo Kumpera  <rkumpera@novell.com>
418
419         * mini-ops.h: Add dup low and dup high ops.
420         
421         * cpu-x86.md: Same.
422
423         * mini-x86.c (mono_arch_output_basic_block): Same.
424
425         * simd-intrinsics.c (vector4f_intrinsics): Same.
426
427 2008-10-13  Rodrigo Kumpera  <rkumpera@novell.com>
428
429         * basic-simd.cs: Tests for recently added functionality.
430
431 2008-10-13  Rodrigo Kumpera  <rkumpera@novell.com>
432
433         * mini-ops.h: Add remaining sse1 fp ops.
434         
435         * cpu-x86.md: Add remaining sse1 fp ops.
436
437         * mini-x86.c (mono_arch_output_basic_block): Same.
438
439         * mini.h: Add enum for simd FP compare conditions.
440
441         * simd-intrinsics.c (vector4f_intrinsics): Add all new ops.
442
443         * simd-intrinsics.c (simd_intrinsic_emit_binary): Set inst_c0 to flags
444         so the backed can generate the appropriate op.
445
446 2008-10-13  Rodrigo Kumpera  <rkumpera@novell.com>
447         This patch squeese one more byte from the SimdIntrinsc struct.
448
449         * mini-x86.c (mono_arch_cpu_enumerate_simd_versions: Use the version number
450         a a shift amount intead of simply or'ing it.
451
452         * mini.h: Change SIMD_VERSION_* values to be sequential intead of masks.
453
454         * simd-intrinsics.c (struct SimdIntrinsc): Squeese simd_version and simd_emit_mode into a single
455         byte so we can have an aditional flags field without increasing struct size.
456
457         * simd-intrinsics.c (emit_intrinsics): Use the value of simd_version as a shift amount before checking
458         against the simd_supported_versions bitmask.
459
460         * simd-intrinsics.c: Set SIMD_INTRINSIC_NAME_MAX to an appropriate value.
461
462 Mon Oct 13 10:58:10 CEST 2008 Paolo Molaro <lupus@ximian.com>
463
464         * mini.c: remove rawbuffer code (the only use here is unsafe because
465         it takes locks during signal handling and the kernel now provides much
466         better info in proc/pid/smaps these days).
467
468 2008-10-13  Zoltan Varga  <vargaz@gmail.com>
469
470         * mini-amd64.c (mono_arch_output_basic_block): Fix the changes to
471         OP_X86_PUSH_OBJ. Fixes #434620.
472
473         * objects.cs: Add a test.
474         
475 2008-10-12  Rodrigo Kumpera  <rkumpera@novell.com>
476
477         * basic-simd.cs: Remove PackWithUnsignedSaturation tests as it turns out
478         that the packuswb/packusdw don't work with unsigned numbers for what
479         would be negative numbers in signed format.
480
481         * cpu-x86.md: Add doubleword forms of many ops and packing ones.
482         Fix the len of fconv_to_r8_x and xconv_r8_to_i4.
483
484         * mini-ops.h: Add doubleword forms of many ops and packing ones.
485
486         * mini-x86.c: Emit doubleword forms of many ops and packing ones.
487
488         * simd-intrinsics.c (SimdIntrinsc): Rename the flags field to simd_version.
489
490         * simd-intrinsics.c (vector4f_intrinsics): Use simd_version field for sse3 ops.
491
492         * simd-intrinsics.c (vector4u_intrinsics): Rename to vector4ui_intrinsics and
493         add more ops.
494
495         * simd-intrinsics.c (simd_version_name): New function, returns the name of the
496         version as the enum in mini.h.
497
498         * simd-intrinsics.c (emit_intrinsics): Instead of having a special emit mode
499         for sse3 ops, check the simd_version field if present. This way the code
500         works with all versions of sse.
501
502 2008-10-10  Rodrigo Kumpera  <rkumpera@novell.com>
503
504         * simd-intrinsics.c: Fixed intrinsic name typo.
505
506         * mini.h: Added missing simd exported function.
507
508         * basic-simd.cs: Added tests for Vector4ui.
509         Fixed broken test for Vector16b.
510
511 2008-10-10  Zoltan Varga  <vargaz@gmail.com>
512
513         * tramp-amd64.c (mono_arch_create_rgctx_lazy_fetch_trampoline_full): Increase
514         the max length to 64.
515
516 2008-10-10  Mark Probst  <mark.probst@gmail.com>
517
518         * method-to-ir.c: Only do the fast virtual generic method call for
519         non-wrapper methods.
520
521         * mini.h, mini-trampolines.c: The new generic virtual remoting
522         trampoline handles virtual method calls via the vtable (as done by
523         the fast virtual generic method calls) to remoting proxies.
524
525         * mini.c (mono_jit_create_remoting_trampoline): For generic
526         methods reate a generic virtual remoting trampoline.
527
528         * mini-amd64.h: Enable fast virtual generic method calls again.
529
530 2008-10-10  Mark Probst  <mark.probst@gmail.com>
531
532         * mini-ppc.c: Use SP (r1), not frame_reg (which might be r31) to
533         restore registers when doing tail calls.
534
535 2008-10-10  Rodrigo Kumpera  <rkumpera@novell.com>
536
537         * simd-intrinsics.c (emit_intrinsics): Vector4u was renamed to
538         Vector4ui.
539
540 2008-10-10  Rodrigo Kumpera  <rkumpera@novell.com>
541
542         * basic-simd.cs: Add test for Vecto16b.PackWithUnsignedSaturation.
543
544 2008-10-10  Rodrigo Kumpera  <rkumpera@novell.com>
545
546         * simd-intrinsics.c (emit_intrinsics): Retrofit to new type names.
547
548 2008-10-10  Rodrigo Kumpera  <rkumpera@novell.com>
549
550         * basic-simd.cs: Retrofit for API changes.
551
552 2008-10-10  Mark Probst  <mark.probst@gmail.com>
553
554         * mini-ppc.c: Handle integer stack arguments for tail calls.
555
556 2008-10-10  Rodrigo Kumpera  <rkumpera@novell.com>
557
558         * optflags-def.h: Removed sse3 optimization.
559
560         * driver.c: Same.
561
562         * mini-x86.c (mono_arch_cpu_optimizazions): Remove detection of
563         sse3.
564
565         * mini-x86.c: Added mono_arch_cpu_enumerate_simd_versions.
566
567         * mini.h: Added enumeration with simd versions.
568
569         * simd-intrinsics.c (emit_intrinsics): Use the new static var
570         for detecting SSE3.
571
572         * simd-intrinsics.c: Added mono_simd_intrinsics_init.
573
574         * mini.c (mini_init): Call mono_simd_intrinsics_init.
575
576 2008-10-09  Rodrigo Kumpera  <rkumpera@novell.com>
577
578         * basic-simd.cs: Added tests for Vector8u and Vector16u.
579
580         * basic-simd.cs: Fixed test naming.
581
582 2008-10-09  Rodrigo Kumpera  <rkumpera@novell.com>
583
584         * mini-ops.h: Added ops for packed and saturated math, shifts
585         and packing/unpacking.
586
587         * cpu-x86.md: Added descriptors for the above ops.
588
589         * mini-x86.c: Added code to emmit the above ops.
590
591         * simd-intrinsics.c: Added support for Vector16u and Vector8u.
592
593 2008-10-08  Zoltan Varga  <vargaz@gmail.com>
594
595         * aot-compiler.c (compile_method): Enable AOT for generic code.
596
597         * ir-emit.h (NEW_DOMAINCONST): Use domainvars in AOT code as well.
598
599 Wed Oct 8 16:35:43 CEST 2008 Paolo Molaro <lupus@ximian.com>
600
601         * mini.c: add a workaround for a common screwup that ends up blamed
602         to mono (other processes blocking signal delivery).
603
604 2008-10-07  Zoltan Varga  <vargaz@gmail.com>
605
606         * method-to-ir.c (mono_method_to_ir2): Clear ins_flag on all code paths
607         in the LDFLD/STFLD opcodes. Fixes #432673.
608
609         * iltests.il.in: Add a new test.
610
611 Tue Oct 7 19:59:07 CEST 2008 Paolo Molaro <lupus@ximian.com>
612
613         * mini-arm.c: attach the thread in unmanaged->managed transitions
614         using delegates (bug #433148).
615
616 2008-10-07  Rodrigo Kumpera  <rkumpera@novell.com>
617
618        * basic-simd.cs: Use new ShuffleSel constants.
619
620 2008-10-07  Rodrigo Kumpera  <rkumpera@novell.com>
621
622         * driver.c (opt_sets): Added combinations of simd, sse2 and sse3.
623
624         * mini-x86.c (mono_arch_cpu_optimizazions): Detect sse3 and now
625         only disable simd intrinsics if no sse2 is detected.
626
627         * optflags-def.h: Added sse3.
628
629         * simd-intrinsics.c: Avoid generated sse3 intrinsics if the optimization
630         is disabled.
631
632 2008-10-07  Zoltan Varga  <vargaz@gmail.com>
633
634         * aot-compiler.c (add_wrappers): Fix Delegate/MulticastDelegate classes
635         when adding delegate-invoke wrappers.
636
637 2008-10-07  Zoltan Varga  <vargaz@gmail.com>
638
639         * Makefile.am: Reenable the simd tests.
640
641 2008-10-07  Bill Holmes  <billholmes54@gmail.com>
642
643         * mini-amd64.c (mono_arch_emit_outarg_vt) : In the ArgValuetypeAddrInIReg case,
644           add a call to mono_call_inst_add_outarg_reg for the arg->dreg to make sure that no
645           other vreg is allocated to that hreg.
646
647         Contributed under MIT/X11 license.
648
649 2008-10-07  Zoltan Varga  <vargaz@gmail.com>
650
651         * Makefile.am: Disable the simd tests for now as Mono.Simd is not
652         yet checked in.
653
654 2008-10-06  Rodrigo Kumpera  <rkumpera@novell.com>
655
656         * basic-simd.cs: New test suite for SIMD intrinsics.
657
658         * Makefile.am: Added new tests.
659
660 2008-10-06  Rodrigo Kumpera  <rkumpera@novell.com>
661
662         * cpu-x86.md: Added new instructions to handle float to int using SSE regs.
663
664         * mini-ops.h: Same.
665
666         * mini-x86.h: Enable mono_arch_decompose_opts if simd intrinsics are enabled.
667
668         * mini-x86.c (mono_arch_decompose_opts): Decompose float to int conversion
669         using SSE2 aware opcodes.
670
671         * mini-x86.c (emit_float_to_int): Disable the SSE2 optimization if OPT_SIMD
672         is enabled, this code path is only reachable if conversion ops are emmited after
673         mono_method_to_ir.
674
675         * mini.h: Added MonoCompile::fconv_to_r8_x_var to hold the float to int var.
676
677         This optimization saves 6 bytes per conversion against the old version.
678
679 2008-10-06  Zoltan Varga  <vargaz@gmail.com>
680
681         * aot-compiler.c (compile_method): Don't skip methods referencing 
682         generic methods without a corresponding entry in token_info_hash, since
683         encode_method_ref () can handle all generic methods now.
684
685         * method-to-ir.c (mono_save_token_info): Don't save the token info if a 
686         generic context is set.
687         
688         * method-to-ir.c (mono_method_to_ir2): Put back a disable_aot for
689         generic sharing of LDTOKEN.
690
691 2008-10-06  Mark Probst  <mark.probst@gmail.com>
692
693         * mini-amd64.h: Temporarily disabled fast virtual generic method
694         calls because it breaks the System.Runtime.Remoting tests.
695
696 2008-10-06  Zoltan Varga  <vargaz@gmail.com>
697
698         * aot-compiler.c (add_wrappers): Add delegate-invoke wrappers.
699
700         * method-to-ir.c (check_inline_called_method_name_limit): Return TRUE
701         so inlining actually works.
702         (check_inline_caller_method_name_limit): Ditto.
703
704 Mon Oct 6 11:04:38 CEST 2008 Paolo Molaro <lupus@ximian.com>
705
706         * mini-ppc.c: mono_arch_flush_icache () cast pointer using gsize for
707         64 bit safety (from Olaf Hering and Andreas Färber).
708
709 2008-10-06  Zoltan Varga  <vargaz@gmail.com>
710         
711         * mini-trampolines.c (mono_aot_trampoline): Delegate processing to
712         mono_magic_trampoline () if aot_get_method_from_token () fails. Remove
713         unused virtual call support code.
714
715         * aot-runtime.c (decode_method_ref): Add a 'no_aot_trampoline' out argument.
716         
717         * aot-runtime.c (mono_aot_get_method_from_vt_slot): Return NULL for methods
718         which can't use aot trampolines.
719         (decode_patch): Don't create aot trampolines for methods which can't use
720         them.
721
722         * aot-compiler.c (encode_method_ref): Add a marker for methods which can't
723         use aot trampolines.
724
725         * mini.h: Bump AOT image format version.
726         
727 2008-10-05  Zoltan Varga  <vargaz@gmail.com>
728
729         * method-to-ir.c (mono_method_to_ir2): Pass cil_method instead of cmethod
730         to save_token_info () since cmethod is inflated for constrained calls.
731
732         * mini-<ARCH>.h mini-x86.c: Remove some unused defines.
733
734 2008-10-04  Andreas Färber  <andreas.faerber@web.de>
735
736         * Makefile.am: Add build rules for ppc64.
737         This avoids the build failing at pedump with unresolved symbols
738         due to lack of arch_sources. Instead it will now fail earlier
739         due to lack of cpu-ppc64.md.
740
741         Contributed under MIT/X11 license.
742
743 2008-10-04  Mark Probst  <mark.probst@gmail.com>
744
745         * mini-amd64.c (mono_arch_emit_call): Support stack arguments for
746         tail calls.
747
748         * iltests.il.in: Add test case for tail call with many arguments.
749
750 2008-10-03  Zoltan Varga  <vargaz@gmail.com>
751
752         * method-to-ir.c (mono_method_to_ir2): Add an !cfg->compile_aot assert
753         to the fast virtual generic method code until the aot case is fixed.
754
755 2008-10-03  Mark Probst  <mark.probst@gmail.com>
756
757         * mini-ppc.c, mini-ppc.h: Implement generic virtual method thunks.
758
759 2008-10-03  Mark Probst  <mark.probst@gmail.com>
760
761         * mini-amd64.c, mini-amd64.h: Implement generic virtual method
762         thunks.
763
764 2008-10-03  Rodrigo Kumpera  <rkumpera@novell.com>
765         
766         * simd-intrinsics.c: Forgot to add this one.
767
768         * mini-codegen.c: Fix macro in case SIMD is not supported.
769
770 2008-10-03  Rodrigo Kumpera  <rkumpera@novell.com>
771         
772         This patch land initial JIT support for simd intrinsics.
773
774         * mini-x86.h: Added new define to make --enable_minimal work on x86.
775
776         * Makefile.am: Added simd-intrinsics.c
777
778         * simd-intrinsics.c: New file with simd instrinsic related
779         code.
780
781         * cfold.c (mono_constant_fold_ins2): Fold XZERO.
782
783         * cpu-x86.md: Add simd related instructions.
784
785         * driver.c: Added MONO_OPT_SIMD to the default set of optimizations.
786
787         * driver.c: Added two new --regression variants.
788
789         * ir-emit.h (MONO_EMIT_NEW_VZERO): Emit XZERO if the type is a simd intrinsic.
790
791         * local-propagation.c (mono_local_cprop2): Eliminate useless XMOVE.
792
793         * local-propagation.c (mono_local_deadce): Use new macro MONO_IS_NON_FP_MOVE and
794         extract some complicated logic to helper functions.
795
796         * method-to-ir.c (mono_type_to_regmove): Handle simd intrinsics.
797
798         * method-to-ir.c (mini_emit_inst_for_method): Emit simd intrinsics.
799
800         * method-to-ir.c (mono_handle_global_vregs): If a simd intrinsic was found, apply
801         the specialized simplification pass.
802
803         * method-to-ir.c (mono_spill_global_vars): Use new macro.
804
805         * mini-codegen.c: Added SIMD constants to all regbanks arrays.
806
807         * mini-codegen.c: Added reg_bank_table_init to initialize the reg desc -> bank
808         table.
809
810         * mini-codegen.c: Define a version of the reg_bank macro that uses desc_to_reg_type
811         if MONO_ARCH_NEED_SIMD_BANK is defined.
812
813         * mini-ops.h: Added the new simd ops.
814
815         * mini-x86.c: Added mono_arch_xregname.
816
817         * mini-x86.c (mono_arch_cpu_optimizazions): Disable MONO_OPT_SIMD if SSE3 is not detected.
818
819         * mini-x86.c (mono_arch_output_basic_block): Add simd related opcodes.
820
821         * mini-x86.h: Define simd related MONO_ARCH macros.
822
823         * mini.c (mono_type_to_load_membase): Handle simd intrinsics.
824
825         * mini.c (mono_type_to_store_membase): Handle simd intrinsics.
826
827         * mini.h: Added new macros MONO_IS_NON_FP_MOVE, MONO_IS_REAL_MOVE, MONO_IS_ZERO and
828         MONO_CLASS_IS_SIMD to deal with simd related IR.
829
830         * mini.h (MonoInst): Added spill_var to the backend union.
831
832         * mini.h (MonoCompile): Added uses_simd_intrinsics and iconv_raw_var.
833
834         * mini.h: Added forward declarations of the new simd fuctions.
835
836         * optflags-def.h: Added new optimization names SIMD.
837
838         * regalloc.c (mono_regstate_reset): Set next vreg to be the max value of the 3 reg banks.
839
840         * regalloc.h: Added support for working with 3 register banks.
841
842         * regalloc.h (MonoRegState): Added xsymbolic field if a third regbank is required.
843
844         * ssa2.c (mono_ssa_deadce2): Use new MONO_IS_ZERO macro.
845
846 Fri Oct 3 16:03:22 CEST 2008 Paolo Molaro <lupus@ximian.com>
847
848         * mini-exceptions.c: remove 64 bit related ifdef clutter.
849
850 2008-10-03  Zoltan Varga  <vargaz@gmail.com>
851
852         * mini-exceptions.c (mono_handle_soft_stack_ovf): Unprotect two pages
853         instead of one on 64 bit systems.
854
855         * method-to-ir.c: Remove unused includes.
856
857 2008-10-02  Zoltan Varga  <vargaz@gmail.com>
858
859         * aot-compiler.c (emit_exception_debug_info): Use jinfo->used_regs instead of
860         cfg->used_int_regs, since the two are different on arm.
861
862 2008-10-02  Mark Probst  <mark.probst@gmail.com>
863
864         * method-to-ir.c, inssel.brg, mini-trampolines.c: Use
865         mono_method_get_vtable_index() to get the vtable index.
866
867 2008-10-02  Mark Probst  <mark.probst@gmail.com>
868
869         * method-to-ir.c (mono_method_to_ir2): Don't create native
870         wrappers for array methods, because they're never called (and if
871         they were called they wouldn't work).
872
873 2008-10-02  Mark Probst  <mark.probst@gmail.com>
874
875         * method-to-ir.c (mono_method_to_ir2): Array methods are
876         special-cased and must not be invoked indirectly via the (M)RGCTX
877         when generic sharing is turned on.  Fixes #431413.
878
879 2008-10-01  Mark Probst  <mark.probst@gmail.com>
880
881         * method-to-ir.c: When generic sharing is active, call
882         non-interface virtual generic methods via the standard trampoline.
883
884         * mini-trampolines.c: Handle virtual generic shared methods.
885
886         * mini.h, mini-x86.c, mini-x86.h: New argument for
887         mono_arch_build_imt_thunk() which is non-NULL for virtual generic
888         method thunks and which is the trampoline to call if the lookup
889         fails.  Enable the virtual generic method thunk for x86.
890
891         * mini-amd64.c, mini-arm.c, mini-ia64.c, mini-sparc.c,
892         mini-ppc.c (mono_arch_build_imt_thunk): Add the additional
893         argument but assert that it's NULL, because these archs don't yet
894         implement the virtual generic method thunk.  Changes in the IMT
895         thunk data structures.
896
897 2008-10-01  Zoltan Varga  <vargaz@gmail.com>
898
899         * aot-compiler.c (emit_globals): Avoid invalid characters in
900         the static linking symbol.
901
902         * objects.cs: Add a test for the range check optimization. Fix warnings.
903
904         * branch-opts.c (mono_if_conversion): Add back the 'optimize range checks'
905         optimization from the current JIT.
906
907         * method-to-ir.c (mini_emit_inst_for_method): Decompose String.Length
908         later in decompose_array_access_opts () to allow more optimizations.
909
910         * method-to-ir.c (mono_handle_soft_float): Rename this to 
911         mono_decompose_soft_float () for consistency.
912
913         * mini-ops.h: Fix arguments of OP_STRLEN.
914
915         * method-to-ir.c (save_cast_details): Extract the cast details saving code
916         into a separate function.
917         (reset_cast_details): Ditto.
918         (handle_unbox): Save cast details. Fixes #431254.
919
920         * method-to-ir.c: Remove some obsolete FIXMEs.
921
922 2008-09-30  Rodrigo Kumpera  <rkumpera@novell.com>
923
924         * ir-emit.h (alloc_dreg): Write a warning before crashing.
925
926 2008-09-30  Rodrigo Kumpera  <rkumpera@novell.com>
927
928         * mini-codegen.c: More work on macros to make them
929         ready for multiple regbanks.
930
931 2008-09-30  Rodrigo Kumpera  <rkumpera@novell.com>
932
933         * method-to.ir.c (mono_type_to_regmove): Remove static modifier.
934
935         * mini.h: Export mono_type_to_regmove. Fix signature of mono_regname_full.
936
937 2008-09-30  Rodrigo Kumpera  <rkumpera@novell.com>
938
939         * mini-codegen.c (mono_spillvar_offset): Proper support for
940         multiple regbanks.
941
942 2008-09-30  Zoltan Varga  <vargaz@gmail.com>
943
944         * mini-amd64.c (mono_arch_emit_epilog): Remove some duplicated code from
945         the stack overflow changes.
946
947 2008-09-30  Rodrigo Kumpera  <rkumpera@novell.com>
948
949         * mini-codegen.c: Make all bank macros depend on reg_bank.
950
951         * mini-codegen.c (mono_local_regalloc): Make free mask
952         initialization regbank aware.
953
954 2008-09-30  Rodrigo Kumpera  <rkumpera@novell.com>
955
956         * mini-codegen.c (mono_local_regalloc): Extract callee
957         mask selection to a function and make it regbank aware.
958
959 2008-09-30  Rodrigo Kumpera  <rkumpera@novell.com>
960
961         * mini-codegen.c (mono_local_regalloc): Changed the cloberring
962         code to deal with many regbanks.
963
964 2008-09-30  Zoltan Varga  <vargaz@gmail.com>
965
966         * mini-codegen.c: More fp->regbank changes.
967
968 2008-09-29  Rodrigo Kumpera  <rkumpera@novell.com>
969
970         * mini-codegen.c: Change asserts to use MONO_NUM_REGBANKS instead
971         of a hardcoded constant.
972
973 2008-09-29  Rodrigo Kumpera  <rkumpera@novell.com>
974
975         * method-to-ir.c (type_from_stack_type): Fix typo.
976
977 2008-09-29  Zoltan Varga  <vargaz@gmail.com>
978
979         * mini-ia64.c (emit_move_return_value): Convert float return values to
980         double.
981
982         * objects.cs: Add a new test.
983         
984         * mini-ia64.c (mono_arch_allocate_vars): Disable fp elimination for
985         VARARG methods to fix an assert later.
986
987         * mini-mips.h mini-mips.c mini-ops.h cpu-mips.md: Update the mips back
988         end so it at least compiles.
989
990 2008-09-28  Zoltan Varga  <vargaz@gmail.com>
991
992         * method-to-ir.c (emit_optimized_ldloca_ir): Fix this.
993
994 2008-09-28  Rodrigo Kumpera  <rkumpera@novell.com>
995
996         * method-to-ir.c (mono_method_to_ir2): Extract the ldloca + initobj
997         optimization to a new function (emit_optimized_ldloca_ir) and enable
998         it for both ldloca and ldloca_s.
999
1000 2008-09-28  Zoltan Varga  <vargaz@gmail.com>
1001
1002         * method-to-ir.c (mono_method_to_ir2): Remove an unnecessary assert in the
1003         gshared CASTCLASS code.
1004
1005         * driver.c (mono_main): Add a workaround for shutdown crashes seen on
1006         amd64, where the libc stack unwinder encounters stack frames referring to
1007         native code in unmapped memory.
1008
1009         * method-to-ir.c (mini_emit_check_array_type): Add support for generic
1010         sharing.
1011
1012         * generics.cs: Add new test.
1013
1014 2008-09-27  Zoltan Varga  <vargaz@gmail.com>
1015
1016         * mini-arm.h driver.c: Print the fp model when using --version on arm. Also,
1017         add a check that one of the ARM_FPU_ constants is defined.
1018
1019         * mini-exceptions.c (mono_handle_soft_stack_ovf): Really fix the build.
1020         
1021         * mini-exceptions.c: Fix build on non-altstack platforms.
1022
1023         * method-to-ir.c (mono_method_to_ir2): Fix aot support for the
1024         sharing of vtypes.
1025
1026         * ir-emit.h: Add a comment to NEW_PCONST.
1027
1028         * mini-exceptions.c (mono_altstack_restore_prot): Fix a warning.
1029
1030         * mini.h (MonoJitDomainInfo): Move some fields here from MonoDomain.
1031
1032         * mini.c aot-runtime.c method-to-ir.c driver.c mini-trampolines.c: Update
1033         after the changes to MonoJitDomainInfo.
1034
1035 2008-09-27  Mark Probst  <mark.probst@gmail.com>
1036
1037         * mini-ppc.c, tramp-ppc.c, mini-ppc.h: Implement generic code sharing.
1038
1039 2008-09-27  Mark Probst  <mark.probst@gmail.com>
1040
1041         * mini-ppc.c: Compiler warning fixes.
1042
1043 2008-09-27  Mark Probst  <mark.probst@gmail.com>
1044
1045         * mini-ppc.c: Special handling for 1/2 byte structs on Darwin only
1046         for pinvokes.
1047
1048 2008-09-27  Mark Probst  <mark.probst@gmail.com>
1049
1050         * exceptions-ppc.c, mini-ppc.h: Compile
1051         mono_arch_handle_altstack_exception() on Darwin, too.
1052
1053 2008-09-27  Mark Probst  <mark.probst@gmail.com>
1054
1055         * method-to-ir.c (mono_emit_rgctx_method_call_full): Must also
1056         work on archs which don't have generic sharing implemented, only
1057         without the vtable_arg.
1058
1059 2008-09-26  Mark Probst  <mark.probst@gmail.com>
1060
1061         * mini.c: Added comment explaining why delegate ctor icall
1062         wrappers are compiled.
1063
1064 2008-09-26  Mark Probst  <mark.probst@gmail.com>
1065
1066         * mini.c: Don't produce trampolines to delegate ctor icall
1067         wrappers but compile them upfront.
1068
1069 Fri Sep 26 17:00:46 CEST 2008 Paolo Molaro <lupus@ximian.com>
1070
1071         * mini-amd64.c, mini-amd64.h, tramp-amd64.c: amd64 support code for calling a
1072         runtime-set function when going back to managed code. Currently this
1073         is used to set back the protection on the soft ovf pages and/or to
1074         throw the stack overflow exception that happened in unmanaged code.
1075
1076 Fri Sep 26 16:46:23 CEST 2008 Paolo Molaro <lupus@ximian.com>
1077
1078         * tramp-x86.c, mini-x86.h, mini-x86.c: x86 support code for calling a
1079         runtime-set function when going back to managed code. Currently this
1080         is used to set back the protection on the soft ovf pages and/or to
1081         throw the stack overflow exception that happened in unmanaged code.
1082
1083 Fri Sep 26 16:34:37 CEST 2008 Paolo Molaro <lupus@ximian.com>
1084
1085         * mini.h, mini.c, mini-trampolines.c, mini-exceptions.c: added
1086         the support code for restoring stack protection after stack overflows
1087         that happen in unmanaged code. Don't set the exec permission on the
1088         soft overflow area.
1089
1090 2008-09-26  Zoltan Varga  <vargaz@gmail.com>
1091
1092         * mini-trampolines.c (mono_delegate_trampoline): Add wrappers even if
1093         delegate->method_ptr is set. Fixes #428054.
1094
1095 2008-09-25  Zoltan Varga  <vargaz@gmail.com>
1096
1097         * tests.cs: Rename to ratests.cs.
1098
1099         * method-to-ir.c: Merge the emit_get_rgctx () calls into the 
1100         emit_get_rgctx_... functions.
1101
1102 2008-09-25  Mark Probst  <mark.probst@gmail.com>
1103
1104         * method-to-ir.c: Eliminated macro EMIT_GET_RGCTX.
1105
1106 2008-09-25  Mark Probst  <mark.probst@gmail.com>
1107
1108         * mini-trampolines.c (mono_magic_trampoline): Unwrap wrappers
1109         before asserting that method is sharable.
1110
1111 2008-09-25  Mark Probst  <mark.probst@gmail.com>
1112
1113         * method-to-ir.c, mini.c, jit-icalls.c: New function for checking
1114         whether method needs a static RGCTX wrapper used instead of
1115         complex conditions.
1116
1117         * generic-sharing.c, mini.h: A few functions moved to
1118         metadata/generic-sharing.c.
1119
1120 2008-09-25  Mark Probst  <mark.probst@gmail.com>
1121
1122         * method-to-ir.c, mini.c, mini-exceptions.c, mini-trampolines.c:
1123         Generic code sharing for value types, which essentially means
1124         treating value type methods like static methods.  The RGCTX is
1125         passed in the same way.
1126
1127 2008-09-25  Zoltan Varga  <vargaz@gmail.com>
1128
1129         * method-to-ir.c (mono_method_to_ir2): Avoid an assert in the NEWOBJ
1130         opcode when creating multi-dimensional arrays of open types.
1131
1132         * generic-sharing.c (mono_method_check_context_used): Handle arrays of
1133         open generic types.
1134
1135         * generics.cs: Add a test.
1136
1137         * mini-codegen.c: Use macros everywhere for checking floats instead of == 'f'.
1138
1139 2008-09-24  Zoltan Varga  <vargaz@gmail.com>
1140
1141         * mini.h (MonoCompile): Add 'disable_vreg_to_lvreg' flag.
1142
1143         * mini.c (mini_method_compile): Set it when running under the debugger. 
1144
1145         * method-to-ir.c (mono_handle_global_vregs): Disable global->local
1146         vreg optimization if the flag is set.
1147
1148         * driver.c (mono_main): Add --attach= option to pass options to
1149         the attach agent.
1150
1151         * mini.c (sigquit_signal_handler): Start the attach agent.
1152
1153         * ssapre.c: Disable this to save space since it is not yet ported to
1154         linear IR.
1155
1156         * regalloc2.c: Disable this to save space.
1157
1158         * mini.h (MonoJitStats): Remove unused analyze_stack_repeat.
1159
1160 Wed Sep 24 16:01:49 CEST 2008 Paolo Molaro <lupus@ximian.com>
1161
1162         * decompose.c, method-to-ir.c, mini-codegen.c, regalloc2.c: make
1163         the -v option useful again.
1164
1165 2008-09-24  Zoltan Varga  <vargaz@gmail.com>
1166
1167         * mini-amd64.c (mono_arch_output_basic_block): Add support for
1168         --break-at-bb.
1169
1170         * inssel.brg (mini_emit_castclass): Avoid the szarray!=array checks for
1171         arrays of arrays. Fixes #428406.
1172
1173         * method-to-ir.c (mini_emit_castclass): Ditto.
1174
1175         * objects.cs: Add new test.
1176         
1177 2008-09-23  Rodrigo Kumpera  <rkumpera@novell.com>
1178
1179         * method-to-ir.c (type_to_eval_stack_type): The code path for the new JIT
1180         was wrong at it choked against target_type_is_incompatible for byref types.
1181
1182 2008-09-23  Zoltan Varga  <vargaz@gmail.com>
1183
1184         * mini-codegen.c: Use 'bank' macros instead of 'is_fp' macros in most 
1185         places.
1186
1187 Tue Sep 23 15:31:45 CEST 2008 Paolo Molaro <lupus@ximian.com>
1188
1189         * mini-exceptions.c: update a few more exceptions-related counters.
1190
1191 Tue Sep 23 15:28:29 CEST 2008 Paolo Molaro <lupus@ximian.com>
1192
1193         * aot-runtime.c, method-to-ir.c, mini.c, mini-trampolines.c: use the
1194         new functions to allocate from persistent mempools.
1195
1196 2008-09-23  Zoltan Varga  <vargaz@gmail.com>
1197
1198         * mini.h regalloc.h mini-codegen.c: Generalize the regalloc code to allow 
1199         multiple register banks in the future.
1200
1201         * mini-codegen.c (mono_local_regalloc): Fix a warning.
1202
1203 2008-09-22  Rodrigo Kumpera  <rkumpera@novell.com>
1204
1205         * mini.c (type_to_eval_stack_type): Remove duplicated function.
1206
1207         * method-to-ir.c (type_to_eval_stack_type): Make this version compatible with both JIT.
1208
1209         * mini.h: Export type_to_eval_stack_type.
1210
1211         This function was nearly duplicated in method-to-ir.c and mini.c. The difference
1212         is only ins->klass of byref types.
1213
1214 2008-09-22  Zoltan Varga  <vargaz@gmail.com>
1215
1216         * method-to-ir.c (mini_emit_memset): Use a default alignment of 4.
1217         (mini_emit_memcpy2): Ditto.
1218
1219         * mini-amd64.c: Fix a warning.
1220
1221 2008-09-21  Mark Probst  <mark.probst@gmail.com>
1222
1223         * exceptions-ppc.c (mono_arch_get_call_filter): Fixed stack frame
1224         linking.
1225
1226 2008-09-19  Rodrigo Kumpera  <rkumpera@novell.com>
1227
1228         * method-to-ir.c: Extract stloc micro-optimization to a
1229         function and apply it to all cases.
1230
1231 2008-09-19  Mark Probst  <mark.probst@gmail.com>
1232
1233         * method-to-ir.c: Don't fail generic code sharing in cases we
1234         already support.
1235
1236 2008-09-18  Mark Probst  <mark.probst@gmail.com>
1237
1238         * mini-ppc.c: Handle structs in tailcalls on Darwin.
1239
1240 Tue Sep 16 21:07:11 CEST 2008 Paolo Molaro <lupus@ximian.com>
1241
1242         * *.c, *.md, mini-ops.h: introduced relaxed_nop opcode for spin wait
1243         implementation.
1244
1245 Tue Sep 16 16:39:16 CEST 2008 Paolo Molaro <lupus@ximian.com>
1246
1247         * trace.c: make tracing more useful and correct, with per-thread
1248         id and indent info.
1249
1250 2008-09-15  Mark Probst  <mark.probst@gmail.com>
1251
1252         * mini-ppc.c (mono_arch_emit_call): Convert floats to R4 when
1253         doing a method call and the argument is an R4.
1254
1255 2008-09-14  Zoltan Varga  <vargaz@gmail.com>
1256
1257         * aot-compiler.c (add_wrappers): Do not generate runtime invoke wrappers for
1258         generic methods.
1259
1260 2008-09-13  Mark Probst  <mark.probst@gmail.com>
1261
1262         * mini-ppc.c: Convert result to single for OP_ICONV_TO_R4.
1263
1264 2008-09-12  Zoltan Varga  <vargaz@gmail.com>
1265
1266         * mini.h (MONO_IS_JUMP_TABLE): Handle GOT_ENTRY.
1267         (MONO_JUMP_TABLE_FROM_INS): Ditto.
1268
1269 2008-09-11  Zoltan Varga  <vargaz@gmail.com>
1270
1271         * driver.c: Add a --agent argument (not supported yet) to load managed
1272         agent assemblies before loading the main assembly, similarly to how the
1273         Java VM handles agents.
1274
1275 2008-09-11  Mark Probst  <mark.probst@gmail.com>
1276
1277         * mini-ppc.c (mono_arch_allocate_vars): Use arch-independent
1278         function to do stack layout of local variables.
1279
1280 2008-09-11  Mark Probst  <mark.probst@gmail.com>
1281
1282         * mini-ppc.c (calculate_sizes): Bugfix in sigcookie position
1283         calculation.
1284
1285 2008-09-11  Zoltan Varga  <vargaz@gmail.com>
1286
1287         * method-to-ir.c ssa2.c mini.c mini-amd64.c decompose.c ssa.c abcremoval.c
1288         abcremoval2.c branch-opts.c driver.c dominators.c: Disable parts of the
1289         JIT if DISABLE_JIT is defined.
1290
1291         * Makefile.am: Avoid compiling/linking in inssel.c if DISABLE_JIT is
1292         defined.
1293
1294 2008-09-10  Mark Probst  <mark.probst@gmail.com>
1295
1296         * iltests.il.in: Disable the fconv test on PPC (the result is
1297         undefined according to ECMA).
1298
1299 2008-09-10  Mark Probst  <mark.probst@gmail.com>
1300
1301         * iltests.il.in: Enable tail call tests for PPC.
1302
1303         * mini.h: Add variable for storing incoming valuetype argument
1304         addresses for tail calls.
1305
1306         * mini-ppc.c: Implement valuetype arguments and return values for
1307         tailcalls on Linux.
1308
1309 2008-09-09  Mark Probst  <mark.probst@gmail.com>
1310
1311         * mini-ppc.c: Partially implement tail calls (struct arguments and
1312         return values not supported).
1313
1314         * method-to-ir.c: Enable tail calls on PPC.
1315
1316 2008-09-08  Zoltan Varga  <vargaz@gmail.com>
1317
1318         * aot-compiler.c (emit_wrapper_info): Omit the klass name from
1319         runtime-invoke wrappers to work around the problem of them getting
1320         assigned to a random class.
1321
1322         * aot-runtime.c (mono_aot_get_method): Ditto.
1323         
1324 2008-09-07  Zoltan Varga  <vargaz@gmail.com>
1325
1326         * mini-exceptions.c mini-mips.h mini-s390.h exceptions-mips.c: Kill
1327         the CUSTOM_EXCEPTION_HANDLING and CUSTOM_STACK_WALK defines.
1328
1329 2008-09-07  Mark Probst  <mark.probst@gmail.com>
1330
1331         * method-to-ir.c (mono_method_to_ir2): Disable tail calls for PPC
1332         until they're implemented properly.
1333
1334         * exceptions-ppc.c: Use arch-independent exception-handling code
1335         instead of custom one.
1336
1337         * exceptions-ppc.c, mini-ppc.c, mini-ppc.h: Bug fixes and changes
1338         for Linear IR.
1339
1340         * tramp-ppc.c, mini-ppc.c: Fixed warnings.
1341
1342         * decompose.c, aot-runtime.c, aot-compiler.c: PPC code also
1343         applies when __powerpc__ is defined.
1344
1345 2008-09-06  Zoltan Varga  <vargaz@gmail.com>
1346
1347         * aot-runtime.c (mono_aot_get_method): Add another cache mapping wrapper
1348         methods to their code to avoid computing the full name of wrappers and
1349         doing a lookup in a string hash table.
1350
1351 2008-09-05  Zoltan Varga  <vargaz@gmail.com>
1352
1353         * method-to-ir.c: Remove the CHECK_BBLOCK () stuff it is not needed since
1354         we identify bblocks before method_to_ir () is ran.
1355
1356         * branch-opts.c (mono_optimize_branches): Avoid nullifying the exit bblock.
1357         Also avoid optimizing branches pointing to themselves.
1358
1359         * mini.c (mini_method_compile): Ditto. Fixes #422947.
1360
1361 2008-09-05  Rodrigo Kumpera  <rkumpera@novell.com>
1362
1363         * driver.c (mono_main): Enable the new verifier under core-clr and cas.
1364
1365 2008-09-05  Zoltan Varga  <vargaz@gmail.com>
1366
1367         * tramp-arm.c (mono_arch_nullify_class_init_trampoline): Implement this.
1368         (mono_arch_patch_plt_entry): Fix the calculation of the jump_entry.
1369         (mono_arch_get_nullified_class_init_trampoline): Return 'code' instead of
1370         'buf'.
1371
1372         * aot-compiler.c (emit_plt): Fix the arm plt entries, previously they all 
1373         jumped to the same entry in plt_jump_table.
1374
1375 2008-09-02  Rodrigo Kumpera  <rkumpera@novell.com>
1376
1377         * method-to-ir.c (initialize_array_data): Handle field with RVA from
1378         dynamic images.
1379
1380 2008-08-31  Zoltan Varga  <vargaz@gmail.com>
1381
1382         * method-to-ir.c (handle_isinst): Do the assignment at the beginning, so the
1383         other assignment can be if converted. Saves 1.5% on corlib size and fixes
1384         #421807.
1385
1386 2008-08-29  Geoff Norton  <gnorton@novell.com>
1387
1388         * aot-compiler.c: The Mach/ARM compiler doesn't understand the bss
1389         segment, and doesn't properly handle .space as .text.  Fixes
1390         AOT Mach/ARM
1391
1392 2008-08-29  Geoff Norton  <gnorton@novell.com>
1393
1394         * mini.c: Disable the mach exception handler when running on 
1395         ARM
1396
1397 2008-08-29  Geoff Norton  <gnorton@novell.com>
1398
1399         * aot-compiler.c: Patch from Renaldas Zioma to properly register 
1400         globals on Darwin/ARM
1401
1402 2008-08-28  Zoltan Varga  <vargaz@gmail.com>
1403
1404         * mini.c: Avoid not initializing the runtime when doing AOT compilation, 
1405         since too many things depend on it. Instead, call 
1406         mono_runtime_set_no_exec ().
1407         
1408         * mini.c (mono_create_tls_get): Call mono_alloc_preg (cfg) when running with
1409         the new JIT.
1410
1411         * aot-compiler.c: Add an 'asm-only' AOT option.
1412
1413         * mini.c: Avoid initializing the runtime when doing AOT compilation.
1414                 
1415         * aot-compiler.c (compile_method): Disable gshared support for now as it
1416         doesn't yet work.
1417
1418 2008-08-27  Bill Holmes  <billholmes54@gmail.com>
1419
1420         * mini-amd64.h : Fix a compiler warning.
1421
1422         * exceptions-amd64.c (mono_arch_unwindinfo_install_unwind_info) :
1423           Changed to use a callback function to retrieve the unwind info.
1424           This avoids problems observed when code blocks were removed by
1425           unloading an app domain.
1426
1427         * mini-amd64.c (mono_arch_cpu_optimizazions) : Removing the peephole 
1428           and branch excludes for Winx64.  The fix in exceptions-amd64.c allows them
1429           to work properly.
1430
1431         Contributed under MIT/X11 license.
1432
1433 2008-08-27  Bill Holmes  <billholmes54@gmail.com>
1434
1435         * mini-amd64.c (mono_arch_output_basic_block) : Fix the OP_X86_PUSH_OBJ
1436           case to keep the stack aligned to 8.
1437
1438         Contributed under MIT/X11 license.
1439
1440 2008-08-26  Zoltan Varga  <vargaz@gmail.com>
1441
1442         * aot-runtime.c (mono_aot_get_method): Add a cache for wrapper names to
1443         avoid repeated linear searches.
1444
1445 2008-08-25  Zoltan Varga  <vargaz@gmail.com>
1446
1447         * aot-compiler.c (add_wrappers): Avoid calling get_runtime_invoke with
1448         methods it can't handle.
1449         
1450         * aot-compiler.c (add_method): Avoid adding a method twice.
1451         (add_wrappers): Add runtime invoke wrappers for all methods.
1452
1453         * tramp-amd64.c (mono_arch_create_rgctx_lazy_fetch_trampoline_full): New
1454         function to create an aot-compatible version of this trampoline.
1455
1456         * aot-compiler.c aot-runtime.c: Add support for AOT rgctx fetch trampolines.
1457
1458 2008-08-24  Zoltan Varga  <vargaz@gmail.com>
1459
1460         * aot-compiler.c (compile_method): Skip wrappers of generic icalls.
1461
1462         * method-to-ir.c (mono_method_to_ir2): Replace an assert in UNBOX_ANY
1463         with a generic sharing failure.
1464
1465         * aot-compiler.c (emit_klass_info): Call mono_class_get_nested_types ().
1466
1467         * method-to-ir.c (mono_method_to_ir2): Rethrow the correct exception in
1468         CEE_RETHROW. Fixes #419634.
1469
1470         * mini.c (mono_method_to_ir): Ditto.
1471
1472         * exceptions.cs: Add a new test.
1473         
1474         * generic-sharing.c (mini_type_stack_size): Always pass TRUE as allow_open
1475         to mono_type_stack_size_internal () since some callers might not pass in
1476         an rgctx.
1477
1478         * mini-x86.c (mono_arch_emit_prolog): Store the rgctx before calling
1479         instrument_prolog. Fixes #419878.
1480
1481         * mini.c (mono_compile_create_var_for_vreg): Make the lvars representing
1482         doubles in soft float mode volatile.
1483
1484 2008-08-23  Zoltan Varga  <vargaz@gmail.com>
1485
1486         * ir-emit.h (NEW_ARGSTORE): Use cfg->args and cfg->arg_types to fix the build.
1487
1488         * method-to-ir.c (mono_save_args): Use ARGSTORE instead of TEMPSTORE
1489         to handle soft float correctly.
1490
1491         * tramp-arm.c (mono_arch_create_rgctx_lazy_fetch_trampoline): Implement
1492         the fast path.
1493
1494         * mini.h (struct MonoCallInst): Add dynamic_imt_arg boolean field.
1495
1496         * exceptions-arm.c (mono_arch_find_jit_info): Set ctx->regs [ARMREG_R11]
1497         to sp, since the generics catch code requires it.
1498
1499         * mini-arm.h (MONO_ARCH_VTABLE_REG): Use R0 for this to avoid needless
1500         copying.
1501
1502         * method-to-ir.c (emit_imt_argument): Pass imt_arg to 
1503         mono_arch_emit_imt_argument ().
1504
1505         * mini-<ARCH>.c (mono_arch_emit_imt_argument): Add an 'imt_arg' argument.
1506
1507         * mini-arm.c tramp-arm.c: Generic sharing updates.
1508
1509 2008-08-22  Zoltan Varga  <vargaz@gmail.com>
1510
1511         * mini-arm.c: Fix the arm build.
1512
1513         * generic-sharing.c (mini_type_get_underlying_type): New helper function
1514         handling enums, generic instances and generic sharing.
1515         (mini_type_stack_size_full): Ditto.
1516
1517         * mini-amd64.c mini-x86.c mini-arm.c: Use the new functions.
1518         
1519         * mini.h (struct): Add 'uses_rgctx_reg' and 'uses_vtable_reg' fields.
1520
1521         * method-to-ir.c: Set the new fields when using RGCTX_REG/VTABLE_REG.
1522
1523         * tramp-arm.c: Implement the rgctx fetch and the generic class init 
1524         trampolines.
1525
1526         * mini-arm.c: Various small generic sharing changes.
1527
1528         * tramp-x86.c (mono_arch_create_generic_class_init_trampoline): Implement
1529         this for x86.
1530         (mono_arch_create_trampoline_code): Remove most of the GENERIC_CLASS_INIT
1531         custom code.
1532
1533         * mini-trampolines.c (mono_create_generic_class_init_trampoline): New
1534         helper function to return a generic class init trampoline.
1535
1536         * method-to-ir.c mini.c: Use it.
1537         
1538         * tramp-amd64.c (mono_arch_create_generic_class_init_trampoline): New
1539         arch-specfic function to return a generic class init trampoline.
1540
1541         * tramp-amd64.c (mono_arch_create_trampoline_code_full): Remove most of
1542         the GENERIC_CLASS_INIT custom code.
1543
1544         * method-to-ir.c (mono_method_to_ir2): If RGCTX_REG is not defined, that is
1545         a fatal error, not a sharing failure.
1546
1547         * tramp-<ARCH>.c (mono_arch_get_rgctx_lazy_fetch_offset): Removed, no longer
1548         needed.
1549
1550         * mini-trampolines.c (mono_rgctx_lazy_fetch_trampoline): Get the additional
1551         trampoline argument from MONO_ARCH_VTABLE_REG.
1552
1553         * tramp-x86.c (mono_arch_create_rgctx_lazy_fetch_trampoline): Change the
1554         order of the arguments to the C trampoline: pass 'slot' as the trampoline
1555         argument, and pass the vtable in VTABLE_REG.
1556
1557         * tramp-amd64.c (mono_arch_create_rgctx_lazy_fetch_trampoline): Change the
1558         order of the arguments to the C trampoline: pass 'slot' as the trampoline
1559         argument, and pass the vtable in VTABLE_REG.
1560         (mono_arch_create_trampoline_code_full): Remove some special casing for
1561         the rgctx fetch trampoline.
1562
1563         * mini.c (mono_method_to_ir): Fix the STELEM_ANY+null value optimization.
1564         Fixes #419273.
1565
1566         * iltests.il: Add a test for it.
1567
1568 2008-08-21  Zoltan Varga  <vargaz@gmail.com>
1569
1570         * aot-compiler.c (compile_method): Enable AOT support for generics sharing.
1571
1572         * method-to-ir.c (mono_method_to_ir2): Remove an aot restriction which is
1573         no longer needed.
1574
1575         * mini-trampolines.c (mono_magic_trampoline): Add a sync wrapper here,
1576         use mono_jit_info_table_find () to avoid recursion.
1577         (mono_delegate_trampoline): Add a sync wrapper here.
1578
1579         * method-to-ir.c (mono_method_to_ir2): Don't call mono_ldftn_nosyc
1580         here.
1581
1582         * mini.c (mono_method_to_ir): Ditto.
1583         
1584         * mini-trampolines.c (mono_create_jit_trampoline_in_domain): Remove
1585         add_sync_wrapper argument. Don't add a sync wrapper here.
1586         (mono_create_jump_trampoline): Don't add a sync wrapper here.
1587
1588         * jit-icalls.c (mono_ldftn_nosync): Removed, no longer needed.
1589         
1590 2008-08-20  Bill Holmes  <billholmes54@gmail.com>
1591
1592         * exceptions-amd64.c (seh_handler):  For Winx64 adding missing copy 
1593           of nonvolatile registers back from MonoContext to CONTEXT.
1594
1595         Contributed under MIT/X11 license.
1596
1597 2008-08-20  Bill Holmes  <billholmes54@gmail.com>
1598
1599         * mini-amd64.c (mono_arch_get_delegate_invoke_impl):  When shifting the
1600           arguments on Winx64 there are only 4 argument registers.  For this
1601           logic to work the last argument must be pulled from the stack.  
1602
1603         Contributed under MIT/X11 license.
1604
1605 2008-08-20  Zoltan Varga  <vargaz@gmail.com>
1606
1607         * mini.h (MONO_AOT_FILE_VERSION): Bump aot file format version.
1608
1609         * aot-runtime.c aot-compiler.c patch-info.h mini.c: Get rid of
1610         MONO_PATCH_INFO_WRAPPER, encode/decode wrapper methods like the others in
1611         encode/decode_method_ref ().
1612
1613         * aot-compiler.c (encode_patch): Handle STATIC_RGCTX_INVOKE wrappers.
1614
1615         * aot-runtime.c (decode_patch): Ditto.  
1616
1617         * mini.c (mono_resolve_patch_target): Handle RGCTX_FETCH sub-patches of type
1618         MONO_PATCH_INFO_METHOD.
1619
1620         * aot-runtime.c (decode_exception_debug_info): Decode the contents of
1621         MonoGenericJitInfo.
1622
1623         * aot-compiler.c (emit_exception_debug_info): Emit the contents of
1624         MonoGenericJitInfo.
1625
1626         * method-to-ir.c (emit_imt_argument): Fix AOT+gshared support.
1627
1628         * mini-amd64.c (add_valuetype): Use a dummy gsctx if we didn't receive
1629         one from the caller.
1630
1631         * aot-runtime.c (decode_generic_inst): New function to decode and
1632         return a interned generic inst.
1633         (decode_klass_ref): Use it.
1634         (decode_method_ref): Ditto.
1635
1636         * aot-compiler.c (emit_exception_debug_info): Save 
1637         jinfo->has_generic_jit_info too.
1638
1639 2008-08-19  Zoltan Varga  <vargaz@gmail.com>
1640
1641         * mini-ia64.c (mono_arch_output_basic_block): Add OP_FCONV_TO_I.
1642
1643         * iltests.il.in: Add a test for fconv_to_i.
1644
1645         * liveness.c: Disable the liveness2 pass for now to save space.
1646
1647         * regalloc2.c: Include mempool-internals.h to fix warnings.
1648
1649         * aot-compiler.c (encode_method_ref): Encode the context of generic
1650         instance methods.
1651
1652         * aot-runtime.c (decode_method_ref): Inflate generic methods using
1653         the context saved in the aot file.
1654
1655         * mini.h (MONO_AOT_FILE_VERSION): Bump aot file format version.
1656
1657         * mini-x86.c (mono_arch_output_basic_block): Disable AOT for OP_JMP.
1658
1659         * method-to-ir.c (mono_method_to_ir2): When using CEE_JMP, make arguments
1660         volatile so they won't be optimized away.
1661
1662 2008-08-19  Rodrigo Kumpera  <rkumpera@novell.com>
1663
1664         * ssa.c:
1665         * ssa2.c:
1666         * mini.c:
1667         * regalloc2.c:
1668         * dominators.c: Remove duplicated functions that now are in
1669         mempool-internals.h.
1670
1671 2008-08-19  Zoltan Varga  <vargaz@gmail.com>
1672
1673         * aot-compiler.c: Fix warnings.
1674
1675         * aot-runtime.c (decode_klass_ref): Add support for VARs/MVARs.
1676
1677         * aot-compiler.c (encode_klass_ref): Encode is_method too for VARs/MVARs.
1678
1679         * method-to-ir.c (emit_get_rgctx_method): Use MONO_PATCH_INFO_METHODCONST
1680         as the patch type.
1681
1682         * mini.c (mono_resolve_patch_target): Ditto.
1683         
1684         * aot-compiler.c (encode_patch): Add support for RGCTX_FETCH.
1685         (encode_klass_ref): Add support for encoding VARs/MVARs.
1686
1687         * mini.c (mono_patch_info_dup_mp): Handle RGCTX_FETCH.
1688
1689         * aot-runtime.c (decode_patch_info): Rename to 'decode_patch'. Split out
1690         the handling of the got entries into a separate 'decode_got_entry' function.
1691         Add support for RGCTX_FETCH.
1692
1693         * tramp-amd64.c mini-amd64.h: Change the VTABLE_REG to RDI since RAX is
1694         clobbered by the trampoline code.
1695
1696         * tramp-amd64.c mini-amd64.h: Change the VTABLE_REG to RAX since that is
1697         not clobbered by the indirect calling code.
1698
1699 2008-08-18  Zoltan Varga  <vargaz@gmail.com>
1700
1701         * mini-x86.c (mono_arch_patch_code): Handle RGCTX_FETCH/GENERIC_CLASS_INIT
1702         to fix the build.
1703
1704 2008-08-18  Rodrigo Kumpera  <rkumpera@novell.com>
1705
1706         * method-to-ir.c (mono_emit_method_call_full): Alloc the constructor
1707         signature using the compilation mempool otherwise we would leak it.
1708
1709 2008-08-18  Zoltan Varga  <vargaz@gmail.com>
1710
1711         * method-to-ir.c (mono_method_to_ir2): Emit the generic class inits using
1712         mono_emit_abs_call ().
1713
1714         * patch-info.h: Add GENERIC_CLASS_INIT.
1715
1716         * mini.c (mono_resolve_patch_target): Handle GENERIC_CLASS_INIT.
1717
1718         * mini-amd64.c (emit_call_body): Treat abs calls which have a patch info
1719         as their target as a near call.
1720
1721         * mini.c (mono_codegen): Handle patches stored in cfg->abs_patches in the
1722         ABS handling code.
1723         (mono_resolve_patch_target): Add support for MONO_PATCH_INFO_RGCTX_FETCH.
1724
1725         * method-to-ir.c (mono_emit_abs_call): New helper function which emits a
1726         call to a runtime function described by a patch.
1727
1728         * method-to-ir.c: Emit rgctx entry fetches and class init trampolines using
1729         mono_emit_abs_call, this has the advantage that the ABS handling code in
1730         mono_codegen () can handle them both, and can handle other stuff in the
1731         future without additional code.
1732
1733         * mini.h (struct MonoJumpInfoRgctxEntry): New structure describing an rgctx
1734         entry.
1735         (MonoCompile): Add 'abs_patches' hashtable, which contains patches describing
1736         abs addresses.
1737
1738         * mini.h: Add missing bblock related prototypes.
1739
1740         * mini.h (MonoCompile): Remove unused reverse_inst_list and
1741         reverse_inst_list_len fields.
1742
1743         * mini.c: Refactor this file a bit by moving branch optimizations to 
1744         branch-opts.c.
1745
1746         * method-to-ir.c: Merge generic sharing changes missed earlier.
1747
1748         * aot-compiler.c (is_shared_got_patch): Add MONO_PATCH_INFO_METHODCONST.
1749
1750         * aot-runtime.c (decode_patch_info): Refactor the code dealing with the
1751         shared patches. Process METHODCONST as a shared patch.
1752
1753         * liveness.c (mono_analyze_liveness): Disable the liveness2 code for now
1754         as it crashes on the 2.0 mscorlib.
1755
1756         * aot-compiler.c (is_shared_got_patch): Revert the last change as it seems
1757         to cause crashes.
1758         
1759         * aot-compiler.c: Use is_plt_patch () in a few additional places.
1760         (is_shared_got_patch): Add MONO_PATCH_INFO_METHODCONST, which is generated
1761         by IMT.
1762
1763         * aot-compiler.c: Reorganize the got handling code to be a bit more
1764         understandable.
1765
1766 2008-08-17  Zoltan Varga  <vargaz@gmail.com>
1767
1768         * aot-compiler.c: Make the patch_to_plt_offset hash table use 
1769         mono_patch_info_equals/hash, and use it to massively simplify
1770         get_plt_index ().
1771
1772         * mini.c (mono_patch_info_hash): Simplify this and add support for
1773         more patch types.
1774
1775         * patch-info.h: Rename RGCTX_LAZY_FETCH_TRAMPOLINE to just RGCTX_FETCH.
1776
1777         * mini.c aot-compiler.c aot-runtime.c: Revert the LAZY_FETCH_TRAMPOLINE
1778         handling code, since an offset is not enough to identify a trampoline.
1779
1780         * method-to-ir.c: Remove some g_assert (!cfg->compile_aot) lines.
1781
1782 2008-08-17  Mark Probst  <mark.probst@gmail.com>
1783
1784         * mini.c (mono_op_imm_to_op): Add case for OP_IMUL_IMM.
1785
1786         * method-to-ir.c (mono_method_to_ir2): Decompose OP_CKFINITE.
1787
1788         * mini-ops.h: Argument and result types for OVF_CARRY ops.
1789
1790         * decompose.c: PPC decompositions for various ops.
1791
1792         * cpu-ppc.md, inssel-ppc.brg, mini-ppc.c: PPC changes for Linear IL.
1793
1794 2008-08-17  Zoltan Varga  <vargaz@gmail.com>
1795
1796         * tramp-amd64.c (mono_arch_create_rgctx_lazy_fetch_trampoline): Make this
1797         call the generic trampoline code using a call, instead of a jump, to
1798         remove some special casing from the generic trampoline code.
1799
1800         * mini.c (mono_resolve_patch_target): Handle LAZY_FETCH_TRAMPOLINE.
1801         (mono_codegen): Ditto.
1802
1803         * aot-compiler.c aot-runtime.c: Ditto.
1804
1805         * patch-info.h: Add MONO_PATCH_INFO_RGCTX_LAZY_FETCH_TRAMPOLINE.
1806
1807         * mini-trampolines.c (mono_find_rgctx_lazy_fetch_trampoline_by_addr): New
1808         helper function to find the offset corresponding to a lazy fetch trampoline.
1809
1810         * mini.h (MonoCompile): Add 'orig_method' field to hold the original method
1811         when doing generic sharing.
1812
1813         * aot-compiler.c: Use cfg->orig_method instead of cfg->method in a lot of
1814         places.
1815         
1816         * mini.c (mono_create_rgctx_lazy_fetch_trampoline): Move this to
1817         mini-trampolines.c to be with the other trampoline creation functions.
1818
1819         * method-to-ir.c (mono_emit_method_call): Remove the 'signature' argument
1820         as it is equal to method->signature in most cases, add a 
1821         mono_emit_method_call_full variant which takes a signature and an imt
1822         argument as well.
1823
1824 2008-08-16  Zoltan Varga  <vargaz@gmail.com>
1825
1826         * jit-icalls.c (mono_helper_compile_generic_method): Don't pass the context
1827         to this function, since it could be computed easily from the method 
1828         argument.
1829         (mono_helper_compile_generic_method_wo_context): Removed, not needed any
1830         more.
1831
1832         * method-to-ir.c mini.c: Remove references to 
1833         compile_generic_method_wo_context.
1834
1835         * method-to-ir.c (mono_method_to_ir2): Enable AOT for virtual
1836         generic method calls.
1837         
1838         * method-to-ir.c (mono_method_to_ir2): Use mono_array_new_1 for 1
1839         dimensional non-szarrays.
1840
1841         * mini.c (mini_init): Register mono_array_new_1.
1842
1843         * jit-icalls.c (mono_array_new_1): New jit icall.
1844
1845         * mini-trampolines.c (mono_magic_trampoline): For jumps, patch the GOT entries
1846         pointing to the method.
1847
1848         * aot-runtime.c (mono_aot_get_method_from_token): Register GOT slots holding
1849         method addresses belonging to METHOD_JUMP patches in the 
1850         jump_target_got_slot_hash.
1851         (mono_aot_load_method): Ditto.
1852
1853         * aot-compiler.c (compile_method): Allow AOT compilation of methods with
1854         METHOD_JUMP patches.
1855
1856         * mini.c (mini_create_jit_domain_info): New helper function which 
1857         initializes/frees domain->runtime_info.
1858         (mini_free_jit_domain_info): Ditto.
1859         (mini_init): Install the domain hook functions with the runtime.
1860
1861         * mini.h (MonoJitDomainInfo): New structure which stores the domain specific
1862         information maintained by the JIT.
1863
1864         * mini.c (mono_resolve_patch_target): For PATCH_INFO_METHOD_JUMP, move the
1865         insertion into jump_table_hash into mono_codegen (), also implement proper
1866         locking.
1867
1868         * method-to-ir.c (mono_method_to_ir2): Don't disable AOT for CEE_JMP and
1869         tail calls, it is already done by the aot code.
1870         
1871         * method-to-ir.c (mono_method_to_ir2): Handle CEE_JMP using the tail call
1872         mechanism on amd64.
1873
1874         * iltests.il.in: Make the jmp test a bit more complex.
1875
1876         * aot-compiler.c (encode_method_ref): Handle references to normal methods of
1877         generic instances which doesn't have a token.
1878
1879         * aot-runtime.c (decode_method_ref): Ditto.
1880         
1881         * method-to-ir.c (handle_unbox_nullable): Don't disable AOT, the aot code
1882         can handle this case now.
1883         (handle_box): Ditto.
1884
1885 2008-08-15  Geoff Norton  <gnorton@novell.com>
1886
1887         * mini-x86.c: Fix alignment on Apple x86, and re-disable the alignment
1888         debugging check.
1889
1890 2008-08-15  Zoltan Varga  <vargaz@gmail.com>
1891
1892         * method-to-ir.c (mono_method_to_ir2): Allow AOT compilation of methods
1893         calling generic methods.
1894
1895         * aot-compiler.c (encode_patch): Handle MONO_PATCH_INFO_METHOD_RGCTX.
1896
1897         * aot-runtime.c (decode_patch_info): Ditto.
1898
1899         * mini.c (mono_resolve_patch_target): Ditto.
1900         
1901         * patch-info.h: Add METHOD_RGCTX.
1902
1903         * mini-amd64.c (mono_arch_output_basic_block): Optimize LOCALLOC_IMM.
1904
1905 2008-08-14  Zoltan Varga  <vargaz@gmail.com>
1906
1907         * mini-amd64.c (mono_arch_emit_call): Nullify call->vret_var if returning
1908         arguments in registers.
1909
1910         * decompose.c (mono_decompose_vtype_opts): Create a var for the vreg in
1911         OP_VCALL too, don't depend on OP_OUTARG_VTRETADDR doing it.
1912
1913         * mini.c (mini_method_compile): Abort aot compilation for generic
1914         methods if generic sharing is disabled.
1915         
1916         * mini.c (mono_method_to_ir): Disable AOT for virtual calls requiring
1917         an mrgctx.
1918
1919         * method-to-ir.c (mono_method_to_ir2): Disable AOT for virtual calls 
1920         requiring an mrgctx.
1921
1922         * decompose.c (mono_decompose_vtype_opts): Emit the correct sized
1923         store instructions when converting a vcall to a normal call.
1924
1925         * mini.c (sigprof_signal_handler): Call mono_find_jit_info instead of
1926         mono_arch_find_jit_info.
1927
1928 2008-08-13  Zoltan Varga  <vargaz@gmail.com>
1929
1930         * method-to-ir.c (check_inline_called_method_name_limit): Optimize this to
1931         avoid calling mono_method_full_name () for every method even if the
1932         env var is not set.
1933         (check_inline_caller_method_name_limit): Ditto.
1934
1935 2008-08-12  Zoltan Varga  <vargaz@gmail.com>
1936
1937         * driver.c (main_thread_handler): Allow AOT compilation of multiple 
1938         assemblies in one run.
1939
1940         * aot-compiler.c (mono_compile_assembly): Only print out a count of
1941         skipped methods if it is not 0.
1942
1943         * Makefile.am (aotcheck): AOT compile all test assemblies in one run.
1944
1945 2008-08-12  Bill Holmes  <billholmes54@gmail.com>
1946
1947         * mini.c (mono_codegen):  Changing a preprocessor check from WIN64 to
1948           MONO_ARCH_HAVE_UNWIND_TABLE.
1949
1950         Contributed under MIT/X11 license.
1951
1952 2008-08-12  Bill Holmes  <billholmes54@gmail.com>
1953
1954         * mini-amd64.c (mono_arch_cpu_optimizazions):  Remove peephole and branch
1955           from default optimizaton list on Winx64.
1956
1957         * mini-amd64.c (emit_tls_get):  Added Winx64 specific implementation for GetTLS.
1958
1959         * mini-amd64.c (mono_arch_emit_prolog):  Adding an offset on Winx64 to get
1960           the LMF from the MonoJitTlsData structure.
1961
1962         * mini-amd64.c (mono_arch_setup_jit_tls_data):  Added Winx64 implementation.
1963
1964         Contributed under MIT/X11 license.
1965
1966 2008-08-12  Zoltan Varga  <vargaz@gmail.com>
1967
1968         * mini.c (sigsegv_signal_handler): Fix the build.
1969
1970         * mini-amd64.c (emit_call_body): Use image->aot_module instead of 
1971         assembly->aot_module.
1972
1973         * aot-runtime.c: Use image->aot_module instead of searching in the aot_modules
1974         hash table. This simplifies and speeds up a lot of code, and fixes support
1975         for .netmodules.
1976
1977         * mini.c (SIG_HANDLER_SIGNATURE): Avoid crashes if the thread is not registered
1978         with the runtime.
1979
1980         * mini-exceptions.c: Ditto.
1981         
1982         * exceptions-*c.c (mono_arch_find_jit_info): Remove unused 'trace' and
1983         'native_offset' argument, since these are computed in the 
1984         mono_find_jit_info () function.
1985
1986         * mini-exceptions.c (mono_find_jit_info): Make this non-static, as it
1987         is used by exceptions-ppc.c.
1988
1989         * exceptions-ppc.c: Call mono_find_jit_info () instead of 
1990         mono_arch_find_jit_info ().
1991         
1992         * mini-ppc.h exceptions-ppc.c mini-mips.h mini-mips.c exceptions-mips.c
1993         mini-exceptions.c: Get rid of the CUSTOM_STACK_WALK stuff, use the
1994         generic code in mini-exceptions.c.
1995
1996 2008-08-11  Zoltan Varga  <vargaz@gmail.com>
1997
1998         * mini-ppc.c (mono_arch_flush_register_windows): Add this for ppc.
1999
2000         * aot-runtime.c (mono_aot_get_plt_info_offset): Fix a warning.
2001         
2002         * aot-runtime.c (mono_aot_get_method): Avoid doing all the loading inside
2003         the aot lock, to avoid deadlocks when mono_aot_get_class_from_name () is
2004         called while holding the loader lock. Fixes #415608.
2005         (mono_aot_get_method_from_token_inner): Ditto.
2006
2007 2008-08-09  Zoltan Varga  <vargaz@gmail.com>
2008
2009         * exceptions-ppc.c (mono_jit_walk_stack): Use MONO_INIT_CONTEXT_FROM_CURRENT
2010         to reduce differences between this and the generic implementation in
2011         mini-exceptions.c.
2012         (ves_icall_get_frame_info): Ditto.
2013
2014         * mini-ppc.h (MONO_INIT_CONTEXT_FROM_CURRENT): Define this for ppc too.
2015
2016         * mini-exceptions.c (mono_exceptions_init): Remove an #ifdef which is no
2017         longer neccesarry.
2018
2019         * exceptions-ppc.c (arch_get_call_filter): Rename this to 
2020         mono_arch_get_call_filter () and make it non-static, for consistency with the
2021         other architectures.
2022
2023 2008-08-09  Rodrigo Kumpera  <rkumpera@novell.com>
2024
2025         * mini.c:
2026         * local-propagation.c:
2027         * mini-x86.c: Correct the name of arch defines.
2028
2029 2008-08-09  Zoltan Varga  <vargaz@gmail.com>
2030
2031         * method-to-ir.c (mono_op_to_op_imm_noemul): Correct name of
2032         NO_EMULATE_LONG_SHIFT_OPS define.
2033
2034 2008-08-08  Zoltan Varga  <vargaz@gmail.com>
2035
2036         * method-to-ir.c (mono_method_to_ir2): Remove some code from CEE_MONO_LDPTR
2037         now that aot-ed icall wrappers use CEE_MONO_ICALL_ADDR.
2038
2039         * aot-compiler.c aot-runtime.c: Add support for static aot compilation.
2040         MACH fixes. Merged from the 2.0 branch.
2041
2042         * method-to-ir.c (mono_method_to_ir2): Handle CEE_MONO_ICALL_ADDR.
2043
2044         * mini.c (mono_resolve_patch_target): Error out if an icall is not found.
2045         (mono_method_to_ir): Handle CEE_MONO_ICALL_ADDR.
2046
2047         * exceptions-arm.c (mono_arch_get_throw_exception_generic): Add AOT support.
2048
2049         * method-to-ir.c mini.c driver.c aot-compiler.c: Update after
2050         mono_marshal_get_native_wrapper () signature changes.
2051
2052 2008-08-07  Rodrigo Kumpera  <rkumpera@novell.com>
2053
2054         * jit-icalls.c (mono_fconv_ovf_u8): Work around soft-float double to long
2055         conversion bug under arm.
2056
2057 2008-08-06  Rodrigo Kumpera  <rkumpera@novell.com>
2058
2059         * cpu-arm.md: Increase long_conv_to_ovf_i4_2 max length to 36.
2060
2061         * mini-arm.c (mono_arch_output_basic_block): Implement long to int conversion
2062         with overflow checking.
2063
2064 2008-08-05  Marek Habersack  <mhabersack@novell.com>
2065
2066         * Makefile.am (GENMDESC_PRG): when cross-compiling use full path
2067         to the genmdesc.pl file
2068
2069 2008-08-05  Zoltan Varga  <vargaz@gmail.com>
2070
2071         * ir-emit.h (EMIT_NEW_ARGSTORE): Fix the usage of param_types and
2072         arg_array in the soft-float versions of the LOAD/STORE macros.
2073
2074         * method-to-ir.c (mono_method_to_ir2): Fix a warning in the arm switch
2075         implementation.
2076
2077         * ir-emit.h (NEW_VARLOADA): Handle SOFT_FLOAT correctly.
2078
2079 2008-08-02  Zoltan Varga  <vargaz@gmail.com>
2080
2081         * mini-ia64.c (add_valuetype): Only reserve half parameter slot for each member of
2082         a float HFA. Fixes #413621.
2083
2084 2008-08-02  Gert Driesen  <drieseng@users.sourceforge.net>
2085
2086         * mini-x86.c (mono_arg_get_argument_info): Rename last occurrence of
2087         frame_size to args_size. Fixes build.
2088
2089 2008-08-02  Zoltan Varga  <vargaz@gmail.com>
2090
2091         * mini-x86.c (mono_arch_get_argument_info): Rename frame_size to args_size,
2092         and don't align it to MONO_ARCH_FRAME_ALIGNMENT.
2093
2094         * mini-x86.h: Change MONO_ARCH_FRAME_ALIGNMENT to 8 so doubles stored on
2095         the stack are not unaligned. Fixes #413247.
2096         
2097 Fri Aug 1 18:46:42 CEST 2008 Paolo Molaro <lupus@ximian.com>
2098
2099         * mini.c: update jitted methods performance counters.
2100
2101 Fri Aug 1 16:30:37 CEST 2008 Paolo Molaro <lupus@ximian.com>
2102
2103         * mini-exceptions.c: increase the exceptions thrown performance
2104         counter in mono_handle_exception ().
2105
2106 2008-07-29  Zoltan Varga  <vargaz@gmail.com>
2107
2108         * aot-runtime.c: Use MonoImage's as keys in the aot_modules hash so the aot
2109         can work with netmodules.
2110
2111 2008-07-28  Geoff Norton  <gnorton@novell.com>
2112
2113         * mini-x86.h: Correct the frame alignment on OSX.  Fixes the jit 
2114         regression tests.
2115
2116 2008-07-28  Zoltan Varga  <vargaz@gmail.com>
2117
2118         * mini-x86.c (mono_arch_emit_call): Emi the osx stack alignment at the
2119         correct place.
2120
2121 2008-07-28  Bill Holmes  <billholmes54@gmail.com>
2122
2123         * mini-amd64.c (get_call_info): Winx64 fix for passing floats.
2124           The float param registers and other param registers must be the 
2125           same index on Windows x64.
2126
2127         * mini-amd64.c (mono_arch_allocate_vars) : Implementing the 
2128           ArgValuetypeAddrInIReg argument case.  Setting the argument
2129           op to OP_VTARG_ADDR (OP_REGOFFSET)).
2130
2131         * mini-amd64.c (mono_arch_call_opcode) : Winx64 fix.  Use the size
2132           variable computed above as the copy length for arguments of storage
2133           type ArgValuetypeAddrInIReg.
2134
2135         * mini-amd64.c (mono_arch_emit_call) :  Implementing the 
2136           ArgValuetypeAddrInIReg argument case.  This case will rely on
2137           mono_arch_emit_outarg_vt to emit the correct code later in the process.
2138
2139         * mini-amd64.c (mono_arch_emit_call) :  On Winx64 there always needs to be
2140           a 32 byte stack allocation for all calls.  We will omit the adjustment for
2141           jump and tail call instructoins as they do not follow the typical call behavior.
2142
2143         * mini-amd64.c (mono_arch_emit_outarg_vt) :  Implementing the case for
2144           ArgValuetypeAddrInIReg.  The code emitted will copy the argument to a 
2145           local variable and pass the local variable by reference to the called method.
2146
2147         * mini-amd64.c (mono_arch_emit_prolog, emit_load_volatile_arguments) :
2148           Implementing the ArgValuetypeAddrInIReg argument case.  When the address
2149           of a struct is passed in a register it must be saved with the other
2150           volatile argument on the stack.
2151
2152         * mini-amd64.c (mono_arch_emit_prolog) : Winx64 fix.  When omitting the
2153           frame pointer the stack adjustment value must be saved to the unwind 
2154           info structure.
2155
2156         Contributed under MIT/X11 license.
2157
2158 2008-07-28  Zoltan Varga  <vargaz@gmail.com>
2159
2160         * inssel-x86.brg (stmt): Add missing OP_X86_OUTARG_ALIGN_STACK rule
2161         which got lost in the merge.
2162
2163 2008-07-27  Zoltan Varga  <vargaz@gmail.com>
2164
2165         * method-to-ir.c: Make the helper_sig variables extern to fix the ppc
2166         build.
2167
2168         * mini-amd64.c (emit_call_body): Add a no_patch case missed earlier.
2169         
2170         * mini-amd64.c (emit_call_body): Avoid aligning the call instruction on
2171         icalls, since they won't be patched.
2172
2173         * exceptions-amd64.c (mono_arch_get_restore_context_full): Use a slightly
2174         different code sequence when running under valgrind to prevent some valgrind
2175         errors.
2176
2177         * iltests.il.in: Add new regression test.
2178
2179         * method-to-ir.c (mono_method_to_ir2): Fix handling of inlined methods which
2180         end with a throw.
2181
2182         * method-to-ir.c (mono_method_to_ir2): Use get_vreg_to_inst () instead of
2183         accessing cfg->vreg_to_inst directly to prevent a crash in LDFLD.
2184
2185         * iltests.il.in: Add new test.
2186
2187         * aot-compiler.c: Fix some warnings.
2188
2189         * decompose.c (mono_decompose_long_opts): Implement OP_ICONV_TO_OVF_I8_UN.
2190         Fixes #412494.
2191
2192 2008-07-27  Zoltan Varga  <vargaz@gmail.com>
2193
2194         * driver.c (mono_main): Fix the --gc=none build. Fixes #412482.
2195         (mini_usage_jitdeveloper): Add a missing --wapi option.
2196
2197 2008-07-25  Zoltan Varga  <vargaz@gmail.com>
2198
2199         * mini-codegen.c: Simplify the is_fp macros.
2200         (free_up_ireg): Remove, use free_up_reg instead.
2201         (free_up_reg): Fix the fp case.
2202
2203 2008-07-26  Zoltan Varga  <vargaz@gmail.com>
2204
2205         * cpu-arm.md (loadr8_membase): Increase the length of this as this is not
2206         lowered earlier.
2207
2208         * exceptions-x86.c: Merge some changes which seemed to have got lost
2209         in the linear-ir merge.
2210
2211         * liveness.c: Disable the liveness2 pass on 32 bit platforms.
2212
2213         * method-to-ir.c (mono_handle_global_vregs): Make the component vregs of a
2214         long vreg volatile even if the variable was already created.
2215
2216         * liveness.c (update_liveness2): Avoid eliminating dead definitions of
2217         volatile variables.
2218
2219 2008-07-26  Zoltan Varga  <vargaz@gmail.com>
2220
2221         * cpu-x86.md (fcall_membase): Increase the size of the fcall opcodes.
2222
2223         * mini.c (mono_jit_compile_method_inner): Add support for 
2224         MONO_EXCEPTION_BAD_IMAGE.
2225
2226         * method-to-ir.c (mono_method_to_ir2): Avoid a crash if 
2227         mini_method_get_context () returns NULL. Fixes #356531.
2228
2229         * mini.c (mono_method_to_ir): Ditto.
2230         
2231         * method-to-ir.c (mono_method_to_ir2): Create a variable if needed when
2232         accessing a field of a valuetype in LDFLD/STFLD. Fixes #412399.
2233
2234 2008-07-25  Zoltan Varga  <vargaz@gmail.com>
2235
2236         * method-to-ir.c (mono_method_to_ir2): Initialize an uninitialized variable
2237         in the LDFTN implementation.
2238
2239 2008-07-25  Mark Probst  <mark.probst@gmail.com>
2240
2241         * mini-trampolines.c (mono_magic_trampoline): When sharing generic
2242         code, patch calls to icalls, too, even if they're not in the
2243         shared generic code hash.  Fixes #411962.
2244
2245 2008-07-25  Zoltan Varga  <vargaz@gmail.com>
2246
2247         * cpu-x86.md: Increase the length of the fcall opcodes.
2248
2249         * mini-x86.c (emit_move_return_value): Avoid some precision issues for
2250         calls returning floats.
2251
2252         * method-to-ir.c (mono_method_to_ir2): Remove the generic sharing restrictions
2253         on NEWARR.
2254         
2255         * method-to-ir.c (mono_method_to_ir2): Merge some LDFTN gsharing changes
2256         missed earlier.
2257
2258         * method-to-ir.c (handle_delegate_ctor): Avoid putting dynamic methods
2259         into the domain->method_code_hash.
2260
2261         * aot-compiler.c: Fix win32 build.
2262
2263         * method-to-ir.c (EMIT_GET_RGCTX): Call EMIT_NEW_LDARG in emit_get_rgctx ().
2264         
2265         * method-to-ir.c (mono_method_to_ir2): Use mono_array_new_specific in the
2266         gshared NEWARR implementation.
2267
2268         * cpu-sparc.md: Remove duplicate localloc_imm opcode.
2269
2270         * ir-emit.h (NEW_ARGLOAD): Use cfg->args and cfg->arg_types so this macro
2271         can be used outside of method_to_ir.
2272
2273         * mini.h (MonoCompile): Add arg_types field.
2274
2275         * method-to-ir.c (inline_method): Save/Restore cfg->args and cfg->arg_types.
2276         
2277         * method-to-ir.c (mono_method_to_ir2): Set cfg->args and cfg->arg_types to
2278         the values of the local arg_array and param_types array.
2279
2280 2008-07-24  Zoltan Varga  <vargaz@gmail.com>
2281
2282         * method-to-ir.c (mono_method_to_ir2): Allocate a GOT var for NEWOBJ, since
2283         got accesses might only get generated later when NEWOBJ is decomposed.
2284         
2285         * method-to-ir.c (handle_delegate_ctor): Add an optimization to avoid
2286         looking up the native code of the target method when a delegate is called
2287         for the first time.
2288
2289         * mini-trampolines.c (mono_delegate_trampoline): Add the other half of the
2290         optimization.
2291
2292         * debug-debugger.c (MONO_DEBUGGER__debugger_info): Fix a warning.
2293
2294         * aot-runtime.c aot-compiler.c: Add a new option 'no-dlsym' which makes
2295         AOT work on platforms without a working dlsym implementation.
2296
2297         * mini.h: Bump AOT image format version.
2298         
2299 2008-07-24  Mark Probst  <mark.probst@gmail.com>
2300
2301         * mini-exceptions.c: Free a MonoType with
2302         mono_metadata_free_type() instead of g_free().
2303
2304         * aot-runtime.c: Free a MonoType.
2305
2306 2008-07-24  Zoltan Varga  <vargaz@gmail.com>
2307
2308         * method-to-ir.c (mono_method_to_ir2): Add a comment for the box+brtrue
2309         optimization.
2310
2311         * mini-codegen.c (mono_local_regalloc): Remove the remaining items from the
2312         fp stack on x86.
2313
2314 2008-07-23  Massimiliano Mantione  <massi@ximian.com>
2315         * mini.c (sigprof_signal_handler): call the new "runtime initialized"
2316         profiler hook.
2317
2318 2008-07-23  Zoltan Varga  <vargaz@gmail.com>
2319
2320         * method-to-ir.c (mono_method_to_ir2): Set the stack type properly for
2321         NEWOBJ calls on valuetypes.
2322
2323         * iltests.il.in: Add new test.
2324
2325         * mini-x86.c (mono_arch_emit_call): Use mini_type_stack_size ().
2326
2327 2008-07-22  Zoltan Varga  <vargaz@gmail.com>
2328
2329         * mini-exceptions.c: Fix some warnings. Remove one ia64 special case as it
2330         is no longer needed.
2331
2332         * mini-ia64.c (mono_arch_emit_prolog): In native-to-managed wrappers, widen
2333         non register sized integer arguments.
2334         (mono_arch_call_opcode): Add support for ArgInFloatRegR4.
2335         (mono_arch_emit_outarg_vt): Pass a more reasonable alignment to 
2336         emit_memcpy2 ().
2337
2338         * method-to-ir.c (mono_method_to_ir2): Handle the ret_var_is_local case in
2339         CEE_MONO_RETOBJ.
2340         
2341         * method-to-ir.c (ADD_WIDEN_OP): New macro to insert a widening op when
2342         two a binop with different sized arguments is emitted.
2343
2344         * mini.c (mono_bblock_insert_after_ins): Properly link up with the next
2345         instruction in the ins==NULL case.
2346
2347 2008-07-23  Zoltan Varga  <vargaz@gmail.com>
2348
2349         * mini-ops.h: Add OP_X86_OUTARG_ALIGN_STACK.
2350
2351         * mini-x86.c: Fix osx build.
2352
2353         * mini-amd64.c (mono_arch_output_basic_block): Handle varargs in the CALL_REG
2354         opcodes as well.
2355
2356         * method-to-ir.c (mono_spill_global_vars): Avoid fusing a load+store into the
2357         instruction for non int sized variables.
2358
2359         * method-to-ir.c (mono_method_to_ir2): Fix an assert in the LDFLD
2360         implementation.
2361
2362 2008-07-23  Robert Jordan  <robertj@gmx.net>
2363
2364         * method-to-ir.c: Fix MSVC build.
2365
2366 2008-07-22  Zoltan Varga  <vargaz@gmail.com>
2367
2368         * method-to-ir.c (mono_method_to_ir2): When calling native code which returns
2369         a non int sized type, widen it to an int since newer versions of gcc seem to
2370         generate code which needs this.
2371
2372         * ssa2.c abcremoval2.c: Fix warnings.
2373
2374         * *: Merge the Linear IR branch.
2375
2376         The original branch is at trunk/branches/vargaz/mini-linear-il, and
2377         the ChangeLog file there describes all the changes done over the years. 
2378         Further documentation can be found at www.mono-project.com/Linear_IL.
2379
2380 2008-07-21  Bill Holmes  <billholmes54@gmail.com>
2381
2382         * mini-amd64.c (get_call_info): Winx64 fix for passing floats.
2383           The float param registers and other param registers must be the 
2384           same index on Windows x64.
2385
2386         Contributed under MIT/X11 license.
2387
2388 2008-07-21  Rodrigo Kumpera  <rkumpera@novell.com>
2389
2390         * mini.c: Make the previous fix GC safe.
2391
2392 2008-07-21  Raja R Harinath  <harinath@hurrynot.org>
2393
2394         * Makefile.am (version.h): Allow a trailing '/' in the repository URL.
2395
2396 2008-07-21  Bill Holmes  <billholmes54@gmail.com>
2397
2398         * mini-amd64.c (get_call_info): Correcting the case for MONO_TYPE_TYPEDBYREF
2399           on Winx64.  This type will not be passed on the stack (ArgOnStack), but 
2400           ArgValuetypeAddrInIReg instead.
2401
2402         Contributed under MIT/X11 license.
2403
2404 2008-07-21  Zoltan Varga  <vargaz@gmail.com>
2405
2406         * mini-codegen.c (get_register_spilling): Fix a warning.
2407
2408 2008-07-17  Rodrigo Kumpera  <rkumpera@novell.com>
2409
2410         * mini.c: Use mono_runtime_class_init_full to avoid leaking memory
2411         for types which the initialization fails. Raises the provided exception
2412         at the right stop after cleanup.
2413
2414 2008-07-16  Zoltan Varga  <vargaz@gmail.com>
2415
2416         * aot-compiler.c: Free most of the memory allocated during compilation.
2417
2418         * mini.c (mini_parse_debug_options): Fix a leak.
2419         
2420         * mini.c (mini_method_compile): Don't add the method to the jit info tables
2421         during aot compilation.
2422
2423 2008-07-14  Zoltan Varga  <vargaz@gmail.com>
2424
2425         * mini.c (mono_method_to_ir): Disable aot for code using CCASTCLASS on x86 as 
2426         it has too much register pressure.
2427
2428 2008-07-13  Zoltan Varga  <vargaz@gmail.com>
2429
2430         * inssel.brg (CEE_CASTCLASS): Remove some dead code.
2431
2432 2008-07-12  Zoltan Varga  <vargaz@gmail.com>
2433
2434         * mini-x86.h aot-compiler.c aot-runtime.c: Store the plt info offset inline
2435         on x86.
2436
2437         * mini-amd64.h aot-compiler.c aot-runtime.c: Store the plt info offset inline
2438         on amd64 similar to the way it is done on arm.
2439
2440         * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file format version.
2441
2442         * aot-runtime.c (load_aot_module): Rename 'info' to 'amodule' for 
2443         consistency, normalize error messages, avoid loading aot-only modules in
2444         normal mode.
2445
2446         * driver.c (mono_main): Rename --aot-only command line option to --full-aot
2447         for consistency.
2448
2449         * aot-compiler.c aot-runtime.c tramp-arm.c: Implement aot-only support.
2450
2451 2008-07-11  Martin Baulig  <martin@ximian.com>
2452
2453         * debug-debugger.h
2454         (MonoDebuggerInfo): Add `interruption_request'.
2455
2456 2008-07-12  Zoltan Varga  <vargaz@gmail.com>
2457
2458         * aot-compiler.c (emit_plt): Remove some dead code.
2459
2460         * exceptions-arm.c (mono_arch_get_call_filter_full): Initialize ji.
2461
2462         * aot-runtime.c (mono_aot_get_plt_info_offset): New helper function to
2463         return the plt info offset belonging to a given plt entry.
2464
2465         * mini-trampolines.c (mono_aot_plt_trampoline): Use 
2466         mono_aot_get_plt_info_offset.
2467         
2468         * aot-runtime.c aot-compiler.c tramp-arm.c: Change the arm plt code to be
2469         similar to the amd64 code by makeing jumps through a separate jump table 
2470         instead of embedding the jump addresses into the code.
2471
2472 2008-07-11  Zoltan Varga  <vargaz@gmail.com>
2473
2474         * mini.c (mono_method_to_ir): Disable aot for calling ldtoken in a generic
2475         method.
2476
2477 2008-07-10  Martin Baulig  <martin@ximian.com>
2478
2479         * mini.c (mini_method_compile): Disable generics sharing when
2480         running in the debugger.
2481
2482 2008-07-10  Zoltan Varga  <vargaz@gmail.com>
2483
2484         * mini.c (mono_method_to_ir): Create the got var in CEE_REFANYVAL.
2485
2486         * inssel.brg (CEE_CASTCLASS): Avoid reusing temporary registers to prevent
2487         the local register allocator from running out of registers on x86 when 
2488         using aot.
2489
2490 2008-07-10  Bill Holmes  <billholmes54@gmail.com>
2491
2492         * inssel-long.brg For OP_LCONV_TO_OVF_I4 an int cast is needed when 
2493         expressing IntMin for the VS Compiler.  See Compiler Warning (level 2) 
2494         C4146.
2495
2496         Contributed under MIT/X11 license.
2497
2498 2008-07-10  Zoltan Varga  <vargaz@gmail.com>
2499
2500         * aot-compiler.c: Get rid of whitespace in the generated assembly file to
2501         speed up the assembler.
2502
2503 2008-07-09  Zoltan Varga  <vargaz@gmail.com>
2504
2505         * mini-arm.h tramp-arm.c exceptions-arm.c aot-compiler.c: Beginnings of aot-only
2506         support.
2507
2508         * mini.c: Move the soft float handling macros a bit earlier, add 
2509         NEW_TEMPSTORE_SOFT_FLOAT macro, fix warnings, add soft-float support in one
2510         place.
2511
2512         * mini.h: Add prototype for mono_arch_fixup_jinfo.
2513
2514         * mini.c (mini_init): In aot-only mode, set the root domain code manager to
2515         read-only to help catch code allocation requests.
2516         
2517         * mini.c inssel.brg aot-compiler.c: Make the use of IMT runtime configurable,
2518         and turn it off when using --aot-only or when compiling with --aot=full.
2519
2520         * mini.c (mono_resolve_patch_target): In aot-only mode, allocate the
2521         jump table for switches from the normal domain mempool, not the code
2522         manager.
2523
2524         * mini-trampolines.c (get_unbox_trampoline): New function to return an
2525         unbox trampoline which handles aot-only mode too.
2526
2527         * aot-runtime.c (mono_aot_get_unbox_trampoline): New function to lookup
2528         an AOTed unbox trampoline.
2529
2530         * aot-compiler.c (emit_trampolines): Emit unbox trampolines.
2531
2532 2008-07-09  Bill Holmes  <billholmes54@gmail.com>
2533
2534         * wapihandles.c: Fixing MSVC builds.  Include statement changed from <> to
2535         ""
2536
2537         Contributed under MIT/X11 license.
2538
2539 2008-07-09  Bill Holmes  <billholmes54@gmail.com>
2540
2541         * mini.c (mono_codegen):  Allocate space at the end of the code block and store
2542           the unwind information for the method at the end of the allocated block.
2543           
2544         * mini-amd64.h: Added declarations for the unwind routines and adding field to 
2545           MonoCompileArch to hold the unwind info for SEH on Winx64
2546         
2547         * mini-amd64.c (mono_arch_emit_prolog): Calls to the unwind routines added to store
2548           frame pointer info for the method being compiled.
2549           
2550         * exceptions-amd64.c (mono_arch_get_throw_corlib_exception): Added a stack adjustment before
2551           the call to mono_exception_from_token.
2552           
2553         * exceptions-amd64.c: Added mono_arch_unwindinfo* implementations.  This code is responsible
2554           storing the method prolog information in a format that the Winx64 SEH can understand.  This
2555           information is stored a the end of the method block because it is all 32-bit offset based.
2556
2557         Contributed under MIT/X11 license.
2558
2559 2008-07-09  Zoltan Varga  <vargaz@gmail.com>
2560
2561         * mini.h: Remove duplicate definitions of the mini_wapi_ functions.
2562
2563         * wapihandles.c: Fix warnings.
2564
2565         * aot-runtime.c (load_aot_module): Add a missing error message in aot-only
2566         mode.
2567
2568         * mini-trampolines.c (mono_create_jit_trampoline_in_domain): Avoid calling 
2569         mono_jit_compile_method in aot-only mode since that calls the type 
2570         initializer.
2571         
2572         * mini-trampolines.c (mono_create_delegate_trampoline): Avoid calling
2573         get_delegate_invoke_impl in aot-only mode.
2574
2575         * mini.c (mono_global_codeman_reserve): Reenable the aot-only check.
2576
2577 2008-07-08  Zoltan Varga  <vargaz@gmail.com>
2578
2579         * trace.c (mono_trace_enter_method): Fix printing of Type instances.
2580
2581         * aot-compiler.c (compile_method): Disable the check for GSHARED since it
2582         is on by default.
2583
2584         * inssel-long.brg (reg): Add a rule for LCALL_REG (OP_I8CONST).
2585
2586         * tramp-amd64.c (mono_arch_nullify_plt_entry): Read the nullified class
2587         init trampoline from the AOT file as well.
2588
2589         * mini-amd64.c (mono_arch_register_lowlevel_calls): Register
2590         mono_amd64_throw_exception as a jit icall since it is needed by the aot-only
2591         code.
2592
2593         * mini.c (mini_init): Move the call to mono_exceptions_init () after 
2594         mono_init.
2595
2596         * exceptions-amd64.c: Add _full variants for the remaining exception code
2597         creation functions as well, allow emission of relocatable code, remove
2598         caching since that is now done by the caller.
2599
2600         * mini-exceptions.c: Add _full variants for the remaining exception code
2601         creation functions as well, add aot-only support.
2602
2603         * aot-compiler.c (compile_method): Allow calls to methods of constructed types
2604         if we can determine a proper token for them.
2605         (add_wrappers): Add a few more wrappers.
2606         (emit_method_code): Remove some dead code.
2607         (emit_trampolines): Emit exception code too.
2608
2609         * mini.c (mono_method_to_ir): Call mono_array_new_2 if possible.
2610
2611         * jit-icalls.c (mono_array_new_2): New jit icall, specialized version of
2612         mono_array_new_va which avoids varargs.
2613
2614         * mini-exceptions.c (mono_exceptions_init): Fix the ppc build.
2615
2616         * mini-trampolines.c: Call mono_create_specific_trampoline () instead of
2617         mono_arch_create_specific_trampoline () in all places.
2618
2619         * aot-compiler.c aot-runtime.c: Refactor the trampoline emitting/loading code
2620         a bit so it can be used for other things as well.
2621         
2622         * mini-exceptions.c (mono_exceptions_init): Initialize throw_exception_by_name
2623         on demand as well.
2624
2625         * exceptions-amd64.c: Rename the caching from the exception code creation
2626         functions, it is done by the caller instead.
2627         
2628         * exceptions-amd64.c: Change the signature of the exception code creation 
2629         functions to allow the creation of relocatable code later.
2630
2631         * mini-exceptions.c: Add a set of functions to query the various 
2632         runtime-generated exception functions.
2633
2634         * mini.c mini-exceptions.c: Use the newly added functions instead of the
2635         mono_arch_.. () functions.
2636         
2637 2008-07-07  Zoltan Varga  <vargaz@gmail.com>
2638
2639         * mini-trampolines.c (mono_aot_get_trampoline_code): Removed, no longer used.
2640
2641         * aot-runtime.c aot-compiler.c: AOT the generic trampolines in aot-only mode.
2642
2643         * mini.c (mini_get_imt_trampoline): Call mono_create_specific_trampoline ().
2644         (mini_get_vtable_trampoline): Ditto.
2645
2646         * tramp-amd64.c (mono_arch_create_trampoline_code_full): Create relocatable
2647         code in the AOT case by returning the code size and a list of relocations to
2648         the caller.
2649
2650         * mini-trampolines.c (mono_create_specific_trampoline): New helper function.
2651
2652 2008-07-07  Bill Holmes  <billholmes54@gmail.com>
2653
2654         * mini-amd64.c:  On Winx64 the calling convention always requires the caller to 
2655           clean the stack.
2656
2657         Contributed under MIT/X11 license.
2658
2659 2008-07-07  Zoltan Varga  <vargaz@gmail.com>
2660
2661         * aot-compiler.c (emit_exception_debug_info): Serialize the debug info first
2662         so the buffer size can be computed correctly. Fixes #404735.
2663
2664         * debug-mini.c (mono_debug_serialize_debug_info): Lookup the debug info
2665         normally as cfg->debug_info is already freed.
2666
2667 2008-07-06  Zoltan Varga  <vargaz@gmail.com>
2668
2669         * mini-amd64.c: For calls returning vtypes in registers, don't store
2670         the return address on the stack, instead allocate a separate local for
2671         it. Fixes #404729.
2672
2673 2008-07-05  Mark Probst  <mark.probst@gmail.com>
2674
2675         * mini-trampolines.c, mini.h: Add an argument to
2676         mono_create_jit_trampoline_in_domain() for turning off the adding
2677         of the sync wrapper.
2678
2679         * mini.c: Use the JIT trampoline without sync instead of
2680         ldftn_nosync in static RGCTX invoke wrappers so that the call can
2681         be patched.
2682
2683 2008-07-04  Mark Probst  <mark.probst@gmail.com>
2684
2685         * driver.c: Turn on GSHARED optimization by default.
2686
2687 2008-07-04  Zoltan Varga  <vargaz@gmail.com>
2688
2689         * mini-trampolines.c mini.c mini.h tramp-<ARCH>.c: Rename MONO_TRAMPOLINE_GENERIC
2690         to MONO_TRAMPOLINE_JIT since it better reflects what it does.
2691
2692         * mini-trampolines.c (mono_get_aot_trampoline_code): New internal function to
2693         create a variant of the generic trampoline code callable from AOTed trampolines.
2694
2695         * tramp-amd64.c (mono_arch_create_trampoline_code_full): Add support for generic
2696         trampoline code callable from AOTed trampolines.
2697
2698         * aot-compiler.c aot-runtime.c: Add support for AOTing trampolines.
2699
2700 2008-07-04  Mark Probst  <mark.probst@gmail.com>
2701
2702         * inssel.brg, mini-ops.h: New opcode for doing CHECK_THIS in a
2703         pass-through manner.
2704
2705         * mini.c: Generic method sharing.  Pass MRGCTX to generic methods
2706         and don't fail sharing for them anymore.
2707
2708         * mini-exceptions.c: Handle exceptions in shared generic methods.
2709
2710         * generic-sharing.c: When checking the context of a generic
2711         method, also check its class's context.  Don't treat wrappers as
2712         sharable.
2713
2714         * mini-trampolines.c: Some code factored out to
2715         metadata/generic-sharing.c.  Handle the MRGCTX case.
2716
2717         * jit-icalls.c, jit-icalls.h: ldvirtfn icall for generic sharing -
2718         we must deal with the method being of another instantiation of the
2719         class.  Add static rgctx invoke wrappers to generic methods.
2720
2721 2008-07-04  Mark Probst  <mark.probst@gmail.com>
2722
2723         * mini.c: Provide all jit infos of generic shared methods with a
2724         generic jit info.
2725
2726         * mini-exceptions.c: Handle the new situation that a generic info
2727         might be available, but not info about the this/vtable/mrgctx
2728         variable.
2729
2730 2008-07-03  Mark Probst  <mark.probst@gmail.com>
2731
2732         * mini.c: Don't accept ldftn and ldvirtftn with uninstantiated
2733         generic methods.
2734
2735 2008-07-03  Zoltan Varga  <vargaz@gmail.com>
2736
2737         * dominators.c (check_dominance_frontier): Fix a warning.
2738
2739         * mini.h: Add some missing prototypes.
2740
2741         * ssa.c local-propagation.c debug-debuger.c: Fix warnings.
2742
2743         * driver.c (mono_jit_init_version): Correct the comments since the first
2744         argument should be the name of the root domain, not a filename.
2745
2746         * aot-runtime.c (make_writable): Error out if this is called while running
2747         with --aot-only.
2748         (load_aot_module): Ditto.
2749
2750         * aot-compiler.c: Really fix the computation of method indexes.
2751
2752         * mini-amd64.c (mono_arch_get_delegate_invoke_impl): Remove the previous 
2753         optimizations as this is no longer called frequently.
2754
2755         * mini-trampolines.c (mono_create_delegate_trampoline): Precompute the invoke
2756         method and the invoke impl code and pass it to the delegate trampoline instead of
2757         just the delegate class.
2758
2759 2008-07-02  Zoltan Varga  <vargaz@gmail.com>
2760
2761         * aot-compiler.c: Fixup the computation of method indexes.
2762         (add_wrappers): Create the base methods of the runtime invoke wrappers using
2763         the method builder infrastructure.
2764
2765         * aot-runtime.c (decode_exception_debug_info): Don't crash if the method
2766         has no header.
2767
2768         * mini-trampolines.c (mono_create_jit_trampoline_in_domain): In aot-only
2769         mode, load the method right away instead of creating a trampoline.
2770
2771         * mini-x86.c (mono_arch_get_delegate_invoke_impl): Eliminate locking.
2772
2773         * mini-amd64.c (mono_arch_get_delegate_invoke_impl): Eliminate locking, speed up
2774         some checks a bit.
2775
2776 2008-07-01  Zoltan Varga  <vargaz@gmail.com>
2777
2778         * aot-runtime.c (decode_patch_info): Don't create trampolines in aot_only mode.
2779         (mono_aot_load_method): Use method_index instead of method->token.
2780
2781         * mini.c (mono_jit_compile_method_inner): Move the aot_only check down, so it
2782         can handle icalls etc. properly.
2783
2784         * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file format version.
2785
2786         * aot-compiler.c aot-runtime.c: Allow AOTing many wrapper types.
2787
2788         * mini.c (mono_resolve_patch_target): Handle JIT_ICALL_ADDR.
2789         (mono_codegen): Convert calls made by JIT icall wrappers to the icalls into
2790         JIT_ICALL_ADDR patch type.
2791
2792         * patch-info.h: Add JIT_ICALL_ADDR patch type.
2793
2794         * mini.c (mono_method_to_ir): Allow AOTing methods which access the interruption
2795         request flag.
2796         (mono_resolve_patch_target): Handle INTERRUPTION_REQUEST_FLAG.
2797
2798         * patch-info.h: Add INTERRUPTION_REQUEST_FLAG.
2799
2800 2008-06-30  Zoltan Varga  <vargaz@gmail.com>
2801
2802         * mini.c: Use domain->jit_code_hash_lock for controlling access to
2803         domain->jit_code_hash.
2804
2805 2008-06-29  Zoltan Varga  <vargaz@gmail.com>
2806
2807         * mini.c (mini_parse_debug_options): Add 'dont-free-domains' option.
2808
2809 2008-06-27  Zoltan Varga  <vargaz@gmail.com>
2810
2811         * mini-trampolines.c (mono_delegate_trampoline): Don't pass a gsctx to
2812         get_this_arg_from_call, let it compute it when needed.
2813
2814         * mini-amd64.c (mono_arch_get_this_arg_reg): Add a 'code' argument, compute
2815         gsctx from code only when needed.
2816
2817         * mini-trampolines.c (get_generic_context): Rename this to 
2818         mono_get_generic_context_from_code (), and move it to generic-sharing.c, where
2819         it can be called by the arch backends.
2820
2821         * mini-exceptions.c (mono_print_thread_dump): Allow the argument to be NULL.
2822
2823 2008-06-26  Zoltan Varga  <vargaz@gmail.com>
2824
2825         * driver.c (mono_main): Add experimental --aot-only command line option.
2826
2827         * mini.c: Error out when creating trampolines or JIT compiling if --aot-only is
2828         set.
2829
2830 2008-06-26  Kornél Pál  <kornelpal@gmail.com>
2831
2832         * driver.c (DllMain): Remove mono_module_handle.
2833
2834         Contributed under MIT/X11 license.
2835
2836 2008-06-25  Zoltan Varga  <vargaz@gmail.com>
2837
2838         * aot-compiler.c: Add not-yet-usable 'full' option. Add some infrastructure code
2839         for emitting methods which are not in the source assembly. Detect and report
2840         failure of assembling+linking.
2841         
2842         * aot-compiler.c (emit_klass_info): Call mono_class_setup_vtable ().
2843
2844         * aot-compiler.c: Move the contents of the has_glot_slots array to MonoCompile.
2845
2846 2008-06-24  Rodrigo Kumpera  <rkumpera@novell.com>
2847
2848         * mini.c: Check if stats is enabled so we don't allocate memory when not needed.
2849
2850 2008-06-24  Zoltan Varga  <vargaz@gmail.com>
2851
2852         * mini.h: Remove some obsolete prototypes.
2853
2854         * mini.c: Avoid storing MonoMethod pointers in the JIT stats, store their string format instead.
2855
2856 2008-06-24  Mark Probst  <mark.probst@gmail.com>
2857
2858         * mini.c (get_object_generic_inst): Variable-sized arrays are not
2859         supported by Visual Studio, so use alloca().
2860
2861 2008-06-23  Zoltan Varga  <vargaz@gmail.com>
2862
2863         * mini-ia64.c (add_valuetype): Increase *gr too when passing a HFA to be in sync with the ABi.
2864         Fixes #402585.
2865
2866 2008-06-23  Mark Probst  <mark.probst@gmail.com>
2867
2868         * mini.c: Fail sharing of a generic method if it contains an open
2869         catch clause (because we don't pass MRGCTXs yet).
2870
2871 2008-06-23  Mark Probst  <mark.probst@gmail.com>
2872
2873         * mini.c: When compiling a method with generic sharing, insert the
2874         method instantiated with an all-Object generic context into the
2875         jit info table, instead of the context of the first instantiation
2876         of the method we happen to compile.
2877
2878 2008-06-18  Martin Baulig  <martin@ximian.com>
2879
2880         * debug-debugger.h (MonoDebuggerInfo): Replaced `version' with
2881         `major_version' and `minor_version'.
2882
2883 2008-06-17  Mark Probst  <mark.probst@gmail.com>
2884
2885         * generic-sharing.c, mini.c, mini.h, aot-runtime.c:
2886         mono_method_is_generic_sharable_impl() takes an additional
2887         argument specifying whether to treat type variables as reference
2888         types.
2889
2890 2008-06-17  Mark Probst  <mark.probst@gmail.com>
2891
2892         * mini.h: Removed obsolete prototypes.
2893
2894 2008-06-17  Mark Probst  <mark.probst@gmail.com>
2895
2896         * mini.c: Don't fail generic sharing for initobj and sizeof - we
2897         already handle them.
2898
2899 2008-06-17  Mark Probst  <mark.probst@gmail.com>
2900
2901         * mini.h, mini-trampolines.c, tramp-alpha.c, tramp-amd64.c,
2902         tramp-arm.c, tramp-hppa.c, tramp-ia64.c, tramp-mips.c,
2903         tramp-ppc.c, tramp-s390.c, tramp-s390x.c, tramp-sparc.c,
2904         tramp-x86.c: Added a MonoGenericContext* argument to
2905         mono_arch_get_unbox_trampoline() so that it can call other
2906         functions which require it.
2907
2908 2008-06-17  Mark Probst  <mark.probst@gmail.com>
2909
2910         * mini.h, mini-trampolines.c, mini-amd64.c, mini-x86.c,
2911         mini-alpha.c, mini-arm.c, mini-ia64.c, mini-ppc.c:
2912         mono_arch_get_this_arg_from_call() takes a
2913         MonoGenericSharingContext* as well.
2914
2915 2008-06-17  Mark Probst  <mark.probst@gmail.com>
2916
2917         * mini.c: Factor out code for emitting unbox into emit_unbox() and
2918         implement generic sharing of unbox.
2919
2920 2008-06-17  Mark Probst  <mark.probst@gmail.com>
2921
2922         * mini.c: Don't compute the vtable to determine whether a field is
2923         special static, because it might not work for open types.
2924
2925 2008-06-17  Mark Probst  <mark.probst@gmail.com>
2926
2927         * mini.c: Removed the unused token_type and token_source arguments
2928         from get_runtime_generic_context_ptr().
2929
2930 2008-06-17  Marek Habersack  <mhabersack@novell.com>
2931
2932         * mini.c (ADD_BINOP): fix the build
2933
2934 2008-06-16  Zoltan Varga  <vargaz@gmail.com>
2935
2936         * mini.c (ADD_BINOP): When operating on a native int and an int32, insert
2937         a widening op.
2938
2939 2008-06-16  Mark Probst  <mark.probst@gmail.com>
2940
2941         * mini.h: Removed class relations enum that's not used anymore.
2942
2943 2008-06-16  Mark Probst  <mark.probst@gmail.com>
2944
2945         * tramp-x86.c, tramp-amd64.c: Slot access code for MRGCTXs.
2946
2947         * mini-trampolines.c: Distinguish between RGCTXs and MRGCTXs in
2948         the lazy fetch trampoline access code.
2949
2950 2008-06-15  Zoltan Varga  <vargaz@gmail.com>
2951
2952         * mini-codegen.c (mono_local_regalloc): Add some micro optimizations.
2953
2954 2008-06-14  Zoltan Varga  <vargaz@gmail.com>
2955
2956         * mini.c: Fix some soft-float bugs. Fixes #378735 and #398348.
2957
2958         * mini.h (MONO_INST_LIST_ENTRY): Fix warnings on arm.
2959
2960         * mini.c (mono_method_to_ir): Check call signature for NEWOBJ as well.
2961
2962 2008-06-13  Zoltan Varga  <vargaz@gmail.com>
2963
2964         * mini-x86.c inssel-x86.brg cpu-x86.md: Implement unsigned min/max
2965         intrinsics.
2966
2967         * mini-ops.h: Add MIN/MAX_UN opcodes.
2968
2969         * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Implement unsigned min/max
2970         intrinsics.
2971
2972         * basic-math.cs: Add more min/max tests.
2973
2974         * inssel.brg: Remove the OP_MIN/OP_MAX rules. Fix a warning.
2975
2976 2008-06-13  Mark Probst  <mark.probst@gmail.com>
2977
2978         * mini.c: Small fix in the prologue of emit_castclass.
2979
2980 2008-06-13  Zoltan Varga  <vargaz@gmail.com>
2981
2982         * inssel.brg: Remove the OP_MIN/OP_MAX rules. Fix a warning.
2983
2984         * mini.c (mini_get_inst_for_method): Remove the Min/Max intrinsics, they
2985         do not work even for unsigned types. Fixes #400014.
2986
2987         * basic-math.cs: Add regression tests for unsigned Min/Max.
2988
2989 2008-06-13  Mark Probst  <mark.probst@gmail.com>
2990
2991         * mini.c: Added additional context_used argument to several
2992         functions, which will be needed for sharing generic methods.  Use
2993         GET_RGCTX macro wherever appropriate.  Declare only one
2994         context_used in mono_method_to_ir().
2995
2996 2008-06-13  Mark Probst  <mark.probst@gmail.com>
2997
2998         * mini.c, generic-sharing.c: Removed generic class relations.
2999
3000         * mini.c, tramp-amd64.c, tramp-x86.c: Additional arguments to
3001         functions due to MRGCTX changes.
3002
3003 2008-06-13  Mark Probst  <mark.probst@gmail.com>
3004
3005         * inssel.brg, inssel-long.brg, inssel-long32.brg, mini-ops.h,
3006         graph.c, local-propagation.c, aliasing.c: New opcodes for calls
3007         with calculated IMT.
3008
3009         * mini.c: Generic sharing of calls via generic interfaces.
3010
3011         * jit-icalls.c, jit-icalls.h: Helper function for compiling a
3012         generic method with non-constant MonoGenericContext*.  Instead,
3013         the context is taken out of the method itself.
3014
3015 2008-06-13  Mark Probst  <mark.probst@gmail.com>
3016
3017         * mini.c: Generic sharing of ldvirtftn.
3018
3019 2008-06-13  Mark Probst  <mark.probst@gmail.com>
3020
3021         * mini.c: Generic sharing of ldftn.
3022
3023 2008-06-13  Mark Probst  <mark.probst@gmail.com>
3024
3025         * mini.c: Do pass VTable/RGCTX argument to static generic methods.
3026
3027 2008-06-13  Mark Probst  <mark.probst@gmail.com>
3028
3029         * mini.c: Generic sharing of the special case of ldtoken followed
3030         by a call to GetTypeFromHandle.
3031
3032 2008-06-13  Mark Probst  <mark.probst@gmail.com>
3033
3034         * mini.c: Generic sharing of box for nullable types.
3035
3036 2008-06-13  Zoltan Varga  <vargaz@gmail.com>
3037
3038         * mini-s390x.c (add_stackParm): Fix computation of offsets when arguments
3039         are passed on the stack. Fixes #324807.
3040
3041 2008-06-12  Bill Holmes  <billholmes54@gmail.com>
3042
3043         * mini-amd64.c:add_valuetype: Adding Winx64 code to fill the ArgInfo
3044         for the ArgValuetypeAddrInIReg case.
3045
3046         * mini-amd64.c:mono_arch_allocate_vars:  Adding a case for 
3047         ArgValuetypeAddrInIReg to avoid asserts.  Code needs to be added here.
3048
3049         * mini-amd64.c: mono_arch_call_opcode:  Adding Winx64 code for an ArgInfo of 
3050         type ArgValuetypeAddrInIReg.  The code emitted will copy the argument to a 
3051         local variable and pass the local variable by reference to the called method.
3052           
3053         * mini-amd64.c: mono_arch_emit_prolog:  Adjust the stack for calls to
3054         mono_jit_thread_attach and mono_get_lmf_addr for Winx64.
3055
3056         Contributed under MIT/X11 license.
3057
3058 2008-06-10  Rodrigo Kumpera  <rkumpera@novell.com>
3059
3060         * debug-mini.c (mono_debug_free_method_jit_info): Moved to metadata/mono-debug.c.
3061
3062         * debug-mini.c (mono_debug_print_vars): Release memory after printing
3063         everything.
3064
3065 2008-06-10  Martin Baulig  <martin@ximian.com>
3066
3067         * debug-mini.c
3068         (mono_debug_close_method): Check whether `cfg->epilogue_begin != NULL'.
3069
3070 2008-06-09  Kornél Pál  <kornelpal@gmail.com>
3071
3072         * main.c: Add and set argv [argc] to NULL to match C specification that fixes
3073         possible error when no arguments are passed.
3074
3075         Contributed under MIT/X11 license.
3076
3077 2008-06-09  Rodrigo Kumpera  <rkumpera@novell.com>
3078
3079         * mini-exceptions.c (ves_icall_get_trace): Skip source locations
3080         where the file name is NULL.
3081
3082 2008-06-09  Zoltan Varga  <vargaz@gmail.com>
3083
3084         * mini.c: Fix s390 build.
3085
3086 2008-06-08  Zoltan Varga  <vargaz@gmail.com>
3087
3088         * trace.c (mono_trace_parse_options): Fix warnings.
3089
3090         * mini-amd64.c: Revert most of the last patch for now as it breaks the build.
3091
3092 2008-06-07  Zoltan Varga  <vargaz@gmail.com>
3093
3094         * mini.c (remove_block_if_useless): Avoid printing the method name.
3095         
3096         * mini.c: Remove needless setting of ins->cil_code which is now done by 
3097         MONO_INST_NEW.
3098
3099         * mini-amd64.c: Add some code to avoid saving callee saved registers in the
3100         LMF. Not yet used.
3101
3102         * tramp-amd64.c (mono_arch_patch_callsite): Tell valgrind to discard the
3103         translated code after it has been patched.
3104
3105 2008-06-06  Zoltan Varga  <vargaz@gmail.com>
3106
3107         * mini-amd64.c (emit_call_body): Align the call displacement to 4 bytes to
3108         avoid problems during code patching on SMP systems.
3109         (emit_call): Avoid adding a patch info which is already added by 
3110         emit_call_body.
3111         (mono_arch_emit_exceptions): Ditto.
3112
3113 2008-06-05  Zoltan Varga  <vargaz@gmail.com>
3114
3115         * tramp-*.c (mono_arch_get_unbox_trampoline): No need to check for ret->byref,
3116         MONO_TYPE_ISSTRUCT already checks for it.
3117
3118 2008-06-05  Bill Holmes  <billholmes54@gmail.com>
3119
3120         * mini-amd64.c:merge_argument_class_from_type: When marshaling 
3121           structs with floats on Winx64 the float registers are not used.  
3122           The integer registers are always used..
3123         * mini-amd64.c:add_valuetype:  When marshaling structs on Winx64 
3124           only one register will be used and only if the size of the struct 
3125           is 1,2,4, or 8 bytes.
3126
3127         * tramp-amd64.c :  Adjusting size used for mono_global_codeman_reserve
3128           to work for Winx64.
3129
3130         Contributed under MIT/X11 license.
3131
3132 2008-06-05  Martin Baulig  <martin@ximian.com>
3133
3134         * debug-debugger.c (debugger_lookup_class): Also call
3135         mono_class_setup_methods() here; we're only called from RTI.
3136
3137 2008-06-05  Andreas Färber  <andreas.faerber@web.de>
3138
3139         * mini.c (mini_init): Add DTrace probes ves-init-{begin,end}.
3140         (mini_method_compile) Add DTrace probes method-compile-{begin,end}.
3141         * Makefile.am (libmono_la_LIBADD,libmono_static_la_LIBADD,mono_LDADD):
3142         Post-process object files and add dtrace-generated object, if necessary.
3143
3144         Contributed under MIT/X11 license.
3145
3146 2008-06-04  Mark Probst  <mark.probst@gmail.com>
3147
3148         * inssel.brg, mini-ops.h: Added opcode for unboxcast with computed
3149         element class.
3150
3151         * mini.c: Generic sharing for unbox.any and castclass.
3152
3153 2008-06-04  Mark Probst  <mark.probst@gmail.com>
3154
3155         * mini.c: Ignore tailcall prefix in shared generic code and when
3156         doing calls which require a vtable/rgctx argument.
3157
3158 2008-06-04  Mark Probst  <mark.probst@gmail.com>
3159
3160         * mini.c: Don't free the JIT info.
3161
3162         * driver.c: Changes in the JIT info table testing code.
3163
3164 2008-06-03  Zoltan Varga  <vargaz@gmail.com>
3165
3166         * tramp-arm.c (mono_arch_create_trampoline_code): Check for thread 
3167         interruption. Fix some warnings.
3168
3169         * tramp-*.c (mono_arch_create_trampoline_code): Call the _force_ variant of
3170         interruption_checkpoint.
3171
3172 Tue Jun 3 13:07:03 CEST 2008 Paolo Molaro <lupus@ximian.com>
3173
3174         * jit.h, mini.h, trace.c, driver.c: introduce an API to enable tracing
3175         from embedding applications.
3176
3177 2008-06-02  William Holmes  <billholmes54@gmail.com>
3178
3179         * mini-amd64.c :  Correcting some of the issues for Winx64 dealing with
3180           reserving 32 bytes on the stack when making calls. 
3181
3182         Contributed under MIT/X11 license.
3183
3184 2008-06-01  Zoltan Varga  <vargaz@gmail.com>
3185
3186         * mini-arm.c (mono_arch_output_basic_block): Merge some small fixes from
3187         the linear IL branch.
3188
3189         * driver.c: Print out more information for --version on arm.
3190
3191 2008-05-30  Zoltan Varga  <vargaz@gmail.com>
3192
3193         * mini-amd64.c (mono_arch_emit_prolog): Increase max_offset when processing
3194         bb_exit instead, since out of line bblocks might not actually be emitted
3195         out-of-line.
3196         
3197         * mini-amd64.c (mono_arch_emit_prolog): Increase bb->max_offset by the
3198         maximum epilog size for out of line bblocks if tracing is enabled.
3199
3200         * iltests.il.in: Merge tests/long-shift.regalloc.il into this file.
3201
3202 2008-05-28  Rodrigo Kumpera  <rkumpera@novell.com>
3203
3204         * arrays.cs: Regression tests for allocating arrays with negative sizes.
3205
3206 2008-05-28  Zoltan Varga  <vargaz@gmail.com>
3207
3208         * mini-x86.h mini-x86.c inssel-x86.brg cpu-x86.md: Add support for
3209         CAS instrinsics. Optimize the implementation of the ATOMIC_EXCHANGE 
3210         opcodes.
3211
3212 2008-05-27  Zoltan Varga  <vargaz@gmail.com>
3213
3214         * mini.c (mini_get_inst_for_method): Add support for CAS instrinsics when
3215         the 'value' to store is a constant.
3216
3217         * mini-ops.h: Add OP_ATOMIC_CAS_IMM opcodes.
3218
3219         * mini-amd64.c (mono_arch_output_basic_block): Optimize the the implementation
3220         of ATOMIC_EXCHANGE opcodes, add support for the CAS opcodes.
3221
3222 2008-05-26  Zoltan Varga  <vargaz@gmail.com>
3223
3224         * mini.c generic-sharing.c jit-icalls.c aot-compiler.c: Use accessor functions
3225         for accessing method->generic_container.
3226
3227 2008-05-24  Zoltan Varga  <vargaz@gmail.com>
3228
3229         * mini.c (mono_method_check_inlining): Avoid creating vtables if possible.
3230         
3231         * mini.c (SIG_HANDLER_SIGNATURE): Fix sparc build too.
3232
3233         * mini.c (SIG_HANDLER_SIGNATURE): Fix IA64 build.
3234
3235         * mini.c (mono_jit_compile_method_inner): Avoid a crash if mono_class_vtable ()
3236         fails.
3237
3238 2008-05-23  Zoltan Varga  <vargaz@gmail.com>
3239
3240         * driver.c (mono_main): Set mono_setup_vtable_in_class_init to FALSE.
3241
3242         * mini.c: Handle the case when mono_class_vtable () fails.
3243
3244 2008-05-23  Massimiliano Mantione  <massi@ximian.com>
3245         * mini.c (sigprof_signal_handler): Support call chains (backtrace) in
3246         the stat profiler.
3247
3248 2008-05-22  Mark Probst  <mark.probst@gmail.com>
3249
3250         * mini.c, jit-icalls.c, jit-icalls.h: Make generic sharing work
3251         together with domain sharing.
3252
3253 2008-05-22  Mark Probst  <mark.probst@gmail.com>
3254
3255         * mini.c: Treat callvirts to final methods like non-virtual calls
3256         when doing generic sharing, i.e. look them up in the runtime
3257         generic context.
3258
3259 2008-05-22  Mark Probst  <mark.probst@gmail.com>
3260
3261         * inssel.brg, mini-ops.h: Added opcodes for mkrefany and refanyval
3262         with computed types (for generic sharing).
3263
3264         * mini.c: Generic sharing for mkrefany and refanyval.
3265
3266 2008-05-22  Zoltan Varga  <vargaz@gmail.com>
3267
3268         * inssel.brg (mini_emit_virtual_call): Avoid constructing a generic vtable if
3269         possible.
3270
3271         * mini-trampolines.c (mono_magic_trampoline): Avoid calling setup_methods () in
3272         the generic sharing code.
3273         
3274         * mini-trampolines.c (mono_magic_trampoline): Call mono_class_setup_methods ()
3275         when needed.
3276
3277 2008-05-21  Zoltan Varga  <vargaz@gmail.com>
3278
3279         * mini.h: Remove the declaration of mono_aot_init_vtable ().
3280
3281 2008-05-21  C.J. Adams-collier <cjac@colliertech.org>
3282
3283         * driver.c: updated copyright date
3284
3285 2008-05-21  Zoltan Varga  <vargaz@gmail.com>
3286
3287         * aot-runtime.c mini.c: Remove the AOT init_vtable stuff as it is no longer
3288         needed.
3289
3290 2008-05-19  Martin Baulig  <martin@ximian.com>
3291
3292         * debug-debugger.h (MonoDebuggerInfo): Add `using_mono_debugger'
3293         pointing to the new `_mono_debug_using_mono_debugger' variable.
3294
3295         * driver.c
3296         (mono_main): Check mono_debug_using_mono_debugger() rather than
3297         the `MONO_INSIDE_MDB' environment variable to check whether we're
3298         inside the debugger.
3299
3300 2008-05-19  Zoltan Varga  <vargaz@gmail.com>
3301
3302         * mini.c (mini_method_compile): Use cfg->args [0] for accessing the this
3303         argument.
3304
3305 2008-05-08  Rodrigo Kumpera  <rkumpera@novell.com>
3306
3307         * declsec.h: Move MONO_SECMAN_FLAG to metadata/metadata-internals.h.
3308
3309         * mini.c: Added mini_assembly_can_skip_verification. This
3310         function checks if the assembly requested to skip verification. 
3311         Fixes part of #387274.
3312
3313 2008-05-07  Zoltan Varga  <vargaz@gmail.com>
3314
3315         * mini.c (mini_get_method): Disable the check for open generic classes when
3316         using generic sharing.
3317
3318         * generics.cs: Add a test for #387034.
3319
3320         * mini.c (mini_get_method): Check whenever the method class is an open generic
3321         type, and return NULL in that case, causing a verification error. Fixes
3322         #384123.
3323
3324 2008-05-06  Rodrigo Kumpera  <rkumpera@novell.com>
3325
3326         * driver.c (mono_main): Revert r102623. The right
3327         thing to do is to enable the verifier under verifiable
3328         unless a --security flag was passed.
3329
3330         We need this non-trivial behavior for --verify-all otherwise
3331         mcs-compileall won't be able to use it. As it needs everything to
3332         be verified under validil.
3333
3334 2008-05-06  Martin Baulig  <martin@ximian.com>
3335
3336         Fix #383749.
3337
3338         * debug-mini.c (mono_debugger_thread_created): Add proper locking.
3339         (mono_debugger_thread_cleanup): Likewise.
3340         (mono_debugger_extended_notification): Likewise.
3341
3342 2008-05-06  Rodrigo Kumpera  <rkumpera@novell.com>
3343
3344         * mini.c (mono_method_to_ir): Verify visibility of call related opcodes
3345         against both inflated and non-inflated methods. We need to check against the
3346         generic definition for cases where the instantiated method is not visible.
3347         We need to check against the inflated types for cases where the instantiation
3348         changes any super type. This fixes #382986.
3349
3350         Note that this doesn't need to be applied to other parts of mono_method_to_ir
3351         that check for visibiliy as generic params only appears as the type subject
3352         of tokens on call opcodes. Field manipulation and ldftn must always
3353         target an exact type.
3354
3355 2008-05-06  Rodrigo Kumpera  <rkumpera@novell.com>
3356
3357         * driver.c (mono_main): Using --verify-all enables the verifier under validil mode
3358         if no related --security flag is passed.
3359
3360 2008-05-05  Andreas Färber  <andreas.faerber@web.de>
3361
3362         * mini-arch.h: Prepare support for ppc64.
3363
3364         Contributed under MIT/X11 license.
3365
3366 2008-05-05  Andreas Färber  <andreas.faerber@web.de>
3367
3368         * aot-runtime.c: Prepare support for ppc64.
3369
3370         Contributed under MIT/X11 license.
3371
3372 2008-05-05  Andreas Färber  <andreas.faerber@web.de>
3373
3374         * mini-ops.h: Prepare support for ppc64.
3375
3376         Contributed under MIT/X11 license.
3377
3378 2008-05-04  Andreas Färber  <andreas.faerber@web.de>
3379
3380         * helpers.c: Add support for OSX/ppc64 and Linux/ppc64 (dis)assemblers.
3381
3382         Contributed under MIT/X11 license.
3383
3384 2008-05-03  Zoltan Varga  <vargaz@gmail.com>
3385
3386         * aot-runtime.c (load_aot_module): Avoid trying to load aot code for dynamic
3387         assemblies, since aot_name is not a full path, causing us to load MS.NET 
3388         assemblies on windows.
3389
3390 2008-04-28  Kornél Pál  <kornelpal@gmail.com>
3391
3392         * mini.c (mono_jit_compile_method_inner): Use g_warning instead of g_error
3393         for unsupported METHOD_IMPL_ATTRIBUTE_NATIVE.
3394         * main.c: Use UTF-8 encoded command line instead of Windows default code
3395         page on Windows to support Unicode.
3396         * driver.c (DllMain): New function for mixed-mode assembly support.
3397         * Makefile.am: Add -Wl,--kill-at to libmono_la_LDFLAGS on Windows to
3398         export __stdcall functions without decoration.
3399
3400         Contributed under MIT/X11 license.
3401
3402 2008-04-28  Mark Probst  <mark.probst@gmail.com>
3403
3404         * tramp-amd64.c, mini-amd64.c: Preserve R11 in the trampoline by
3405         saving it very early.
3406
3407 2008-04-28  Mark Probst  <mark.probst@gmail.com>
3408
3409         * mini.h, mini.c: Lots of code for accessing the old RGCTX
3410         deleted.  The only way to access the new RGCTX is via the
3411         trampline.
3412
3413         * mini.c, mini-amd64, mini-x86.c, mini-exceptions.c: Pass the
3414         vtable instead of the RGCTX to static methods.
3415
3416         * mini-tramplines.c, tramp-amd64.c, tramp-x86.c: Trampoline for
3417         accessing the new RGCTX.
3418
3419         * generic-sharing.c: There is no separation between self, type
3420         arguments and other types in the RGCTX anymore.
3421
3422 2008-04-25  Jonathan Chambers <joncham@gmail.com>
3423
3424         * mini-amd64.c (add_general): Remove previous stack adjustment.
3425         (mono_arch_call_opcode): Remove OP_OUTARG_MEMBASE and instead simply
3426         adjust stack pointer after pushing args. Adjust ARGS_OFFSET to account
3427         for 32 bytes of stack space reserved for all calls.
3428         
3429         * inssel-amd64.brg (OP_OUTARG_MEMBASE): Remove.
3430         (OP_AMD64_OUTARG_ALIGN_STACK): Take argument to specify size of stack 
3431         adjustment.
3432         
3433         Code contributed under MIT/X11 license.
3434
3435 2008-04-23  Rodrigo Kumpera  <rkumpera@novell.com>
3436
3437         * mini.c (mini_method_verify): Only verify non-inflated methods, check
3438         against the root definition, peeling out method and type instantiations.
3439         Cache verify success results, code that fails verification is still
3440         checked multiple times.
3441
3442 2008-04-23  Zoltan Varga  <vargaz@gmail.com>
3443
3444         * mini.c (mono_method_to_ir): Avoid inserting write barriers for stores of null.
3445
3446 2008-04-23  Jonathan Chambers <joncham@gmail.com>
3447
3448         * mini-amd64.c (add_general): Always increment stack on Win64.
3449         (mono_arch_call_opcode): Use OP_OUTARG_MEMBASE instead of OP_OUTARG
3450         on Win64.
3451         
3452         * inssel-amd64.brg (OP_OUTARG_MEMBASE): Add OP_OUTARG_MEMBASE for 
3453         stack based argument handling on Win64.
3454         
3455         Code contributed under MIT/X11 license.
3456
3457 2008-04-23  Raja R Harinath  <harinath@hurrynot.org>
3458
3459         * Makefile.am (version.h): Add support for git-svn.
3460
3461 2008-04-22  Zoltan Varga  <vargaz@gmail.com>
3462
3463         * mini-exceptions.c (mono_handle_native_sigsegv): Rework the gdb calling code
3464         so instead of calling g_spawn_command_line_sync, we do everything by hand, 
3465         avoiding allocations and libc functions which might deadlock.
3466         
3467         * mini-exceptions.c (mono_handle_native_sigsegv): Avoid calling gdb if the
3468         'no-gdb-backtrace' option is set.
3469
3470         * mini.c (mini_parse_debug_options): Parse 'no-gdb-backtrace' option.
3471
3472         * mini.h (MonoDebugOptions): Add 'no_gdb_backtrace' option.
3473
3474 2008-04-21  Martin Baulig  <martin@ximian.com>
3475
3476         * debug-debugger.h (MonoDebuggerInfo): Removed `attach', `detach'
3477         and `get_lmf_addr'; `notification_address' is no longer a pointer.
3478
3479 2008-04-21  Martin Baulig  <martin@ximian.com>
3480
3481         * debug-debugger.h (MonoDebuggerInfo): Added `thread_vtable_ptr',
3482         `thread_vtable', `event_handler_ptr' and `event_handler'.
3483
3484 2008-04-21  Martin Baulig  <martin@ximian.com>
3485
3486         * debug-debugger.h (MonoDebuggerInfo): Added `init_code_buffer';
3487         allows delayed initialization of the `executable_code_buffer' when
3488         attaching.
3489
3490 2008-04-21  Martin Baulig  <martin@ximian.com>
3491
3492         * mini.h (mono_debugger_create_notification_function): Removed.
3493         * tramp-*.c (mono_debugger_create_notification_function): Removed.
3494
3495         * mdb-debug-info64.s
3496         (MONO_DEBUGGER__notification_function): Added this in the .text section.
3497
3498         * mdb-debug-info32.s
3499         (MONO_DEBUGGER__notification_function): Added this in the .text section.
3500
3501         * Makefile.am: Fix the mdb-debug-info*.s logic; the debugger
3502         currently only works on x86 and x86_64, so don't create it on ppc.
3503
3504 2008-04-21  Martin Baulig  <martin@ximian.com>
3505
3506         * mini.h (MonoDebugOptions): Added `mdb_optimizations'.
3507
3508         * mini.c
3509         (mini_method_compile): In the fp elimination check, check
3510         `debug_options.mdb_optimizations' in addition to
3511         mono_debug_using_mono_debugger().       
3512
3513         * driver.c (mono_main): Added `--debug=mdb-optimizations' option to
3514         disable some JIT optimizations which are only disabled when
3515         running inside the debugger.
3516         Added `--help-debug' option to describe the debugging options.
3517         (parse_debug_options): New static function to parse the `--debug'
3518         options, so we can easily add more stuff in future.
3519
3520 2008-04-20  Zoltan Varga  <vargaz@gmail.com>
3521
3522         * mini.c (set_exception_type_from_invalid_il): Avoid reading invalid memory when
3523         the method has no body.
3524
3525 2008-04-19  Jonathan Chambers <joncham@gmail.com>
3526
3527         * mini-amd64.c (cpuid): Implement with MSVC intrinsic as inline
3528         assembly is not allowed in MSVC 64-bit compiler. 
3529         (mono_arch_cpu_init): Don't set floating point precision on MSVC build
3530         as we get floating point exceptions everywhere.
3531         
3532         * exceptions-amd64.c (get_throw_trampoline): Push empty args on stack to
3533         correctly align arguments for call to throw_exception.
3534         (prepare_for_guard_pages): Cast to guint64 instead of unsigned long.
3535         
3536         Code contributed under MIT/X11 license.
3537
3538 2008-04-19  Zoltan Varga  <vargaz@gmail.com>
3539
3540         * mini-amd64.c (amd64_patch): Make the check for (%rip) addressing more strict.
3541
3542 2008-04-17  Zoltan Varga  <vargaz@gmail.com>
3543
3544         * inssel.brg (OP_SWITCH): Use (gint64) instead of (long) to cast a large constant.
3545
3546         * mini-amd64.c (NEW_INS): Set cil_code.
3547
3548         * mini.c (mini_method_compile): Move the disabling of fp elimination to here
3549         from mini-amd64.c so all debugger related logic is in one place.
3550
3551         * mini.c: Set cfg->ip to NULL after passes which set it so instructions created
3552         later won't have a random ip assigned to them.
3553
3554 2008-04-16  Zoltan Varga  <vargaz@gmail.com>
3555
3556         * mini-trampolines.c (mono_create_jump_trampoline): Add an assert to check that
3557         the arch specific function initializes code_size.
3558         (mono_create_delegate_trampoline): Ditto.
3559
3560         * mini-mips.h mini-mips.c inssel-mips.brg inssel-long32-mips.brg cpu-mips.md
3561         tramp-mips.c: Resurrect MIPS port and also fix the issues on little-endian
3562         platforms.
3563
3564         * liveness.c (mono_analyze_liveness): Disable the initlocals optimization if 
3565         running under the debugger.
3566
3567         * linear-scan.c (mono_linear_scan): Avoid sharing registers if running under the
3568         debugger.
3569
3570         * mini.c (mini_method_compile): Set a few flags in cfg if running under the
3571         debugger. Also move the disabling of optimizations here from driver.c.
3572         (mono_allocate_stack_slots_full): Avoid sharing stack slots if running under the
3573         debugger.
3574
3575         * mini.h (MonoCompile): Add a few new flags.
3576
3577 2008-04-15  Zoltan Varga  <vargaz@gmail.com>
3578
3579         * mini.c (mono_method_to_ir): Set cfg->ip before processing an IL instruction
3580         so the cil_code field of created MonoInst's is properly set.
3581         (mini_select_instructions): Ditto.
3582
3583         * mini.h (MONO_INST_NEW): Initialize the cil_code field using cfg->ip.
3584         (MONO_INST_NEW_CALL): Ditto.
3585
3586         * mini.c inssel.brg inssel-x86.brg inssel-amd64.brg: Use MONO_INST_NEW ()
3587         in many places so the ins->cil_code field is properly initialized.
3588
3589         * mini.c (mono_bblock_add_inst): Call MONO_ADD_INS () so the logic is in one
3590         place.
3591
3592 2008-04-14  Zoltan Varga  <vargaz@gmail.com>
3593
3594         * mini.c (mini_method_compile): Print a different message when compiling a 
3595         shared method.
3596         
3597         * mini.c (GENERIC_SHARING_FAILURE): Print a failure message when verbose_level
3598         > 1.
3599
3600 2008-04-11  Zoltan Varga  <vargaz@gmail.com>
3601
3602         * mini-amd64.c (mono_arch_output_basic_block): Implement OP_ABS directly using
3603         SSE2 instructions.
3604
3605         * basic-math.cs: Fix warnings. Add a test for Math.Abs ().
3606         
3607 2008-04-11  Zoltan Varga  <vargaz@gmail.com>
3608
3609         * mini.c (handle_stack_args): Make this return void since its return value was
3610         never used. Also set cfg->unverifiable for invalid IL instead of calling
3611         G_BREAKPOINT ().
3612
3613 2008-04-10  Mark Probst  <mark.probst@gmail.com>
3614
3615         * mini.c: Make sure "this" is live in catch clauses with type
3616         variables in shared generic code.
3617
3618 2008-04-08  Mark Probst  <mark.probst@gmail.com>
3619
3620         * mini.c: Replaced uses of MONO_TYPE_IS_REFERENCE with calls to
3621         generic_class_is_reference_type() to ensure the proper behaviour
3622         when sharing generic code and the type in question is a type
3623         argument.
3624
3625 2008-04-08  Zoltan Varga  <vargaz@gmail.com>
3626
3627         * mini-exceptions.c: Applied patch from Mark Spruiell (mes@zeroc.com). Fix
3628         race conditions when printing thread dumps. Fixes #377738.
3629
3630 2008-04-08  Massimiliano Mantione  <massi@ximian.com>
3631         
3632         aliasing.c (update_aliasing_information_on_inst): Fixed a bug which
3633         shows up when both MonoInst arguments can cause aliasig.
3634         There is likely no way in the current JIT to trigger this problem, but
3635         it showed up in the development of generics sharing, when in a new
3636         opcode both args of an OP_GROUP can be aliases (addresses of a local).
3637         When the generics sharing code will be committed, its tests will be
3638         valid also for this bug.
3639
3640 2008-04-08  Zoltan Varga  <vargaz@gmail.com>
3641
3642         * aot-runtime.c (decode_patch_info): Always transform PATCH_INFO_WRAPPER to
3643         PATCH_INFO_METHOD.
3644
3645         * mini.c (mono_resolve_patch_target): Fix a crash in the AOT case if method is
3646         NULL.
3647
3648 2008-04-07  Zoltan Varga  <vargaz@gmail.com>
3649
3650         * mini-exceptions.c (mono_handle_exception_internal): When --debug=casts is used,
3651         use a more detailed exception message for InvalidCastException.
3652
3653         * mini.h (MonoJitTlsData): Add 'class_cast_from' and 'class_cast_to' fields.
3654
3655         * driver.c (mono_main): Add --debug=casts option to turn on better 
3656         InvalidCastException message details.
3657
3658         * mini.c (mini_get_debug_options): New helper function to return the address of
3659         the debug_options variable.
3660
3661         * mini.c (mono_get_jit_tls_intrinsic): New helper function to create a load of
3662         the jit_tls TLS variable.
3663
3664         * mini.c (mono_jit_tls): New TLS variable.
3665
3666         * inssel.brg: Save the details of a cast to a TLS variable when the --debug=casts
3667         option is used.
3668
3669 2008-04-07  Rodrigo Kumpera  <rkumpera@novell.com>
3670
3671         * mini.h: Removed verifer related stuff. This code was moved to verify.c
3672
3673         * mini.c: Removed verifer related stuff, code moved to verify.c.
3674
3675         * driver.c: Using code from verify.c instead of mini.c.
3676
3677 2008-04-05  Zoltan Varga  <vargaz@gmail.com>
3678
3679         * mini.c (check_for_method_verify): Remove the mscorlib comment since it is no
3680         longer valid.
3681
3682 2008-04-04  Rodrigo Kumpera  <rkumpera@novell.com>
3683
3684         * mini.c (check_for_method_verify): Enabling verification of
3685         corlib if mono_verify_all is set. Bugs in the verifier preventing that
3686         have been fixed.
3687
3688 2008-04-04  Zoltan Varga  <vargaz@gmail.com>
3689
3690         * exceptions-amd64.c (throw_exception): Unify the win32/non-win32 cases, save
3691         caller saved registers as well.
3692         
3693         * exceptions-amd64.c (mono_arch_get_restore_context): Restore most caller
3694         saved registers as well.
3695
3696 2008-03-30  Zoltan Varga  <vargaz@gmail.com>
3697
3698         * mini-x86.c cpu-x86.md inssel-x86.brg: Add min/max intrinsics.
3699
3700         * mini-amd64.c mini-amd64.h cpu-amd64.md: Get rid of the non-SSE2 floating point
3701         code.
3702
3703 2008-03-27  Zoltan Varga  <vargaz@gmail.com>
3704
3705         * mini-amd64.c (mono_arch_get_this_arg_reg): Add a 'gsctx' argument and pass it
3706         to get_call_info.
3707         (get_call_info): Take a gsctx argument instead of 'cfg'.
3708
3709 2008-03-26  Zoltan Varga  <vargaz@gmail.com>
3710
3711         * mini.c (check_for_method_verify): Avoid verifying mscorlib methods even if
3712         mono_verify_all is set.
3713
3714         * driver.c (compile_all_methods_thread_main): Don't exit at the first error.
3715
3716         * mini.c mini.h: Remove the unused and incomplete stack merge verification code.
3717
3718 2008-03-25  Zoltan Varga  <vargaz@gmail.com>
3719
3720         * driver.c (compile_all_methods_thread_main): Error out if compilation fails with
3721         an exception.
3722
3723         * driver.c mini.c mini.h: Add a --verify-all development option to test the
3724         verifier and the code generated by the compiler.
3725
3726 2008-03-25  Mark Probst  <mark.probst@gmail.com>
3727
3728         * mini.c: Generic sharing of the non-nullable case of the box
3729         instruction.
3730
3731 2008-03-24  Zoltan Varga  <vargaz@gmail.com>
3732
3733         * inssel.brg: Fix the build.
3734
3735         * iltests.il.in: Add a test for lconv.ovf.u8.un.
3736
3737 2008-03-24  Rodrigo Kumpera  <rkumpera@novell.com>
3738
3739         * mini.c (mono_method_to_ir): Implement readonly for ldelema and
3740         Array:Address. Fixes #372410.
3741
3742         * iltests.il.in: New tests for readonly prefix.
3743
3744 2008-03-23  Zoltan Varga  <vargaz@gmail.com>
3745
3746         * mini.h mini.c mini-trampolines.c: Move trampoline related code to 
3747         mini-trampolines.c.
3748
3749         * mini.h mini.c mini-exceptions.c: Move mini_init_exceptions () to 
3750         mini-exceptions.c.
3751
3752         * mini-amd64.c mini-s390.c (mono_arch_lowering_pass): Use mono_decompose_op_imm ().
3753         
3754         * mini.c (mono_decompose_op_imm): New helper function.
3755
3756         * mini-s390x.c (calculate_sizes): Rename this to get_call_info for consistency
3757         with the other architectures, add an 'mp' argument, fold 'sz' argument into the
3758         return value.
3759
3760         * mini-s390x.c: Handle DIV_IMM/REM_IMM in the lowering pass instead of in 
3761         mono_arch_output_basic_block. Fix warnings.
3762
3763         * inssel-s390x.brg: Remove the unneccesary OP_LMUL_IMM rule to fix the s390x build
3764         for now.
3765
3766 2008-03-22  Zoltan Varga  <vargaz@gmail.com>
3767
3768         * mini-exceptions.c (ves_icall_get_frame_info): Remove the ia64/s390 workarounds
3769         since the extra frame is now detected automatically inside the loop.
3770
3771         * mini-s390.c (mono_arch_peephole_pass_2): Remove the arch independent peephole 
3772         opts which are now in mono_peephole_ins ().
3773         
3774         * mini-s390.c (mono_arch_output_basic_block): Fix OP_FCALL_MEMBASE.
3775
3776         * mini-exceptions.c (ves_icall_get_frame_info): Skip native-to-managed wrapper
3777         frames and skip duplicate managed-to-native frames. Fixes #367665.
3778
3779         * mini-x86.c (mono_arch_peephole_pass_1): Remove the arch independent peephole
3780         opts which are now in mono_peephole_ins ().
3781         (mono_arch_peephole_pass_2): Ditto.
3782
3783         * mini-codegen.c (mono_peephole_ins): Fix a problem on 32 bit platforms.
3784
3785         * mini-codegen.c (mono_peephole_ins): New helper function containing the
3786         arch independent peephole optimizations.
3787
3788         * mini-amd64.c (mono_arch_peephole_pass_1): Remove the arch independent peephole
3789         opts which are now in mono_peephole_ins ().
3790
3791         * mini-amd64.c (mono_arch_peephole_pass_2): Ditto.
3792         
3793         * mini-s390.c (mono_arch_output_basic_block): Fix build.
3794
3795         * tramp-s390.c (mono_arch_get_vcall_slot): Handle an additional instruction
3796         pattern.
3797
3798         * mini-s390.c (mono_arch_output_basic_block): Handle big offsets in the
3799         CALL_MEMBASE opcodes. Fix setting of the destination in the OP_LCONV_TO_OVF_I
3800         opcode. 
3801
3802 2008-03-21  Zoltan Varga  <vargaz@gmail.com>
3803
3804         * mini-s390.c (calculate_sizes): Rename this to get_call_info for consistency
3805         with the other architectures, add an 'mp' argument, fold 'sz' argument into the
3806         return value.
3807
3808         * mini-s390.c: Handle DIV_IMM/REM_IMM in the lowering pass instead of in 
3809         mono_arch_output_basic_block. Fix warnings.
3810
3811 2008-03-20  Zoltan Varga  <vargaz@gmail.com>
3812
3813         * inssel-long32.brg: Add rules for long conv.ovf.i/conv.ovf.u/conv.ovf.i.un/
3814         conv.ovf.u.un.
3815
3816 2008-03-20  Zoltan Varga  <vargaz@gmail.com>
3817
3818         * inssel-long.brg: Add rules for long conv.ovf.i/conv.ovf.u/conv.ovf.i.un/
3819         conv.ovf.u.un.
3820
3821         * iltests.il: Add new tests.
3822
3823 2008-03-20  Kornél Pál  <kornelpal@gmail.com>
3824
3825         * mini.c: Removed Windows version macros.
3826
3827 2008-03-20  Mark Probst  <mark.probst@gmail.com>
3828
3829         * generic-sharing.c: Put reflection types in the extensible part
3830         of the runtime generic context.
3831
3832         * mini.c: Generic sharing of the GetTypeHandle special case of the
3833         ldtoken instruction.
3834
3835 2008-03-20  Zoltan Varga  <vargaz@gmail.com>
3836
3837         * mini.h (MONO_BB_FOR_EACH_INS_SAFE): New helper macro.
3838
3839         * mini-<ARCH>.c: Use the new macro instead in the peephole/lowering passes.
3840         
3841         * mini.h (MONO_DEL_INS): Rename to MONO_DELETE_INS and Add a 'bb' argument for 
3842         consistency with the other version on the linear IR branch.
3843
3844         * mini-<ARCH>.c: Update callers of MONO_DEL_INS.
3845
3846         * inssel-long32.brg inssel-long.brg: Add rules for conv.ovf.i/conv.ovf.u.
3847
3848         * iltests.il.in: Add new tests.
3849
3850 2008-03-19  Zoltan Varga  <vargaz@gmail.com>
3851
3852         * inssel-long32.brg inssel-long.brg: Add rules for conv.ovf.i.un/conv.ovf.u.un.
3853
3854         * iltests.il.in: Add new tests.
3855
3856 2008-03-19  Mark Probst  <mark.probst@gmail.com>
3857
3858         * mini.c: Two variables with the same name were declared in
3859         nesting contexts and one wasn't initialized.  Fixed.
3860
3861 2008-03-19  Mark Probst  <mark.probst@gmail.com>
3862
3863         * mini.c: Generic sharing of the initobj instruction.
3864
3865 Tue Mar 18 20:18:02 CET 2008 Paolo Molaro <lupus@ximian.com>
3866
3867         * mini.c: make the test to optimize ldtoken from typeof() more
3868         precise.
3869
3870 2008-03-18  Mark Probst  <mark.probst@gmail.com>
3871
3872         * mini.c: Generic sharing of the initobj instruction for reference
3873         types.
3874
3875 Tue Mar 18 12:39:27 CET 2008 Paolo Molaro <lupus@ximian.com>
3876
3877         * mini.h, mini-amd64.c, mini-x86.c, tramp-amd64.c, tramp-x86.c: change
3878         the mono_breakpoint_clean_code() code to perform bound checks.
3879
3880 Tue Mar 18 11:50:14 CET 2008 Paolo Molaro <lupus@ximian.com>
3881
3882         * mini.h, mini-trampolines.c, tramp-*.c: change the signature of
3883         mono_arch_patch_callsite() to include the start of the managed method
3884         to be able to perform bound checks.
3885
3886 2008-03-17  Mark Probst  <mark.probst@gmail.com>
3887
3888         * mini.c: Generic sharing for the isinst instruction.
3889
3890 2008-03-17  Mark Probst  <mark.probst@gmail.com>
3891
3892         * mini-ops.h, inssel.brg, inssel-long.brg, inssel-long32.brg,
3893         inssel-long32-mips.brg: Added opcodes for doing indirect calls
3894         with the runtime generic context argument.
3895
3896         * mini.c: Share calls to several types of unsharable methods by
3897         putting the address of the method code in the runtime generic
3898         context and doing an indirect call.
3899
3900         * graph.c, local-propagation.c, aliasing.c: Added the new opcodes
3901         to switches.
3902
3903 2008-03-16  Mark Probst  <mark.probst@gmail.com>
3904
3905         * generic-sharing.c: Change due to a change in the runtime genric
3906         context API.
3907
3908 2008-03-15  Martin Baulig  <martin@ximian.com>
3909
3910         * tramp-x86.c
3911         (mono_arch_nullify_class_init_trampoline): Add call to
3912         mono_breakpoint_clean_code() to make things work when running
3913         inside the debugger.
3914
3915         * tramp-amd64.c
3916         (mono_arch_nullify_class_init_trampoline): Add call to
3917         mono_breakpoint_clean_code() to make things work when running
3918         inside the debugger.
3919
3920 2008-03-14  Zoltan Varga  <vargaz@gmail.com>
3921
3922         * inssel-long.brg (reg): Fix 64 bit build.
3923
3924 2008-03-14  Mark Probst  <mark.probst@gmail.com>
3925
3926         * mini.c, mini.h: Share static generic code by passing it an
3927         implicit argument pointing to the runtime generic context.
3928
3929         * mini-ops.h, inssel.brg, inssel-long.brg, inssel-long32.brg,
3930         inssel-long32-mips.brg: New opcodes for calling shared static,
3931         which need to be passed the runtime generic context.
3932
3933         * mini-amd64.c, mini-x86.c: Save the runtime generic context
3934         argument on the stack in the prologue if needed.  New function for
3935         finding the runtime generic context argument from the registers
3936         saved by the trampoline.
3937
3938         * mini-amd64.h, mini-x86.h: Specify which register to use for the
3939         runtime generic context argument.
3940
3941         * tramp-amd64.c: Also restore the register used for the runtime
3942         generic context argument.
3943
3944         * mini-trampoline.c: Resolve shared static calls by consulting the
3945         runtime generic context via the new argument.
3946
3947         * generic-sharing.c: Add an argument to sharability-checking
3948         functions that specifies whether type variables should be treated
3949         as sharable type arguments.
3950
3951         * inssel-x86.brg: Removed a superfluous, buggy rule.
3952
3953         * graph.c, local-propagation.c, aliasing.c: Added the new opcodes
3954         to switches.
3955
3956 2008-03-14  Martin Baulig  <martin@ximian.com>
3957
3958         * debug-debugger.c (main_thread_handler): Call
3959         mono_runtime_run_main() without sending any notifications.
3960
3961         * debug-debugger.h (MonoDebuggerInfo): Added `get_method_signature.
3962
3963 2008-03-14  Zoltan Varga  <vargaz@gmail.com>
3964
3965         * mini-trampolines.c (mono_magic_trampoline): Fix build on platforms without IMT.
3966
3967 2008-03-14  Mark Probst  <mark.probst@gmail.com>
3968
3969         * tramp-x86.c: Fixed register restore offsets in the trampoline
3970         code for ECX and EDX.
3971
3972 2008-03-12  Geoff Norton  <gnorton@novell.com>
3973
3974         * mini-arm.h: Add some #defines for locating sp, pc, r4 with
3975         different ucontext_t implementations.
3976         * exceptions-arm.c: Use the above defines to get exceptions working on 
3977         iPhone (based on a patch by Luke Howard lukeh@padl.com)
3978         * mini-arm.c: Implement iPhone icache support (based on a patch by
3979         Luke Howard lukeh@padl.com)
3980
3981 2008-03-12  Mark Probst  <mark.probst@gmail.com>
3982
3983         * mini.c: Enable generic sharing of calls to non-static
3984         non-interface non-generic non-value-type methods.
3985
3986         * mini-trampolines.c: Resolve calls from shared generic code.
3987
3988 2008-03-11  Zoltan Varga  <vargaz@gmail.com>
3989
3990         * Makefile.am il2tests.il iltests.il.in: Delete il2tests, merge it into iltests.
3991
3992         * tramp-amd64.c (mono_arch_create_trampoline_code): Correctly save RBP as well.
3993
3994 Mon Mar 10 11:59:34 CET 2008 Paolo Molaro <lupus@ximian.com>
3995
3996         * mini.c: some fixes for the AOT compiler.
3997
3998 2008-03-07  Zoltan Varga  <vargaz@gmail.com>
3999
4000         * cpu-amd64.md: Add clob:1 to some float opcodes.
4001
4002 2008-03-07  Rodrigo Kumpera  <rkumpera@novell.com>
4003
4004         * mini.h: Added MiniVerifierMode enumeration.
4005
4006         * mini.c: Added mini_verifier_set_mode to control
4007         the usage of the new verifier.
4008
4009         * mini.c (mono_method): Integrated the new verifier.
4010
4011         * driver.c: Extended --security option with validil and
4012         verifiable options to activate the new verifier.
4013
4014 2008-03-07  Zoltan Varga  <vargaz@gmail.com>
4015
4016         * mini.c jit-icalls.h jit-icalls.c: Generalize the exception creation 
4017         optimization to ctors taking 0 or 2 arguments too.
4018
4019         * mini.c (mono_method_to_ir): Optimalize the size of the exception throwing code
4020         a bit.
4021
4022         * jit-icalls.h (mono_create_corlib_exception): New JIT icall.
4023
4024         * mini-amd64.c (mono_arch_emit_prolog): Improve the first_bb optimization a bit.
4025
4026 2008-03-06  Zoltan Varga  <vargaz@gmail.com>
4027
4028         * mini.c (mono_method_to_ir): Apply one of the ldstr optimizations in the
4029         non-aot case as well.
4030
4031         * cpu-amd64.md: Reduce the max size of some frequently used opcodes.
4032
4033         * aot-runtime.c (decode_patch_info): Update this after the ldfld/stfld wrapper
4034         changes.
4035
4036         * aot-compiler.c (encode_patch): Ditto.
4037
4038         * mini.h (G_MININT32): Fix the definition of this.
4039
4040 2008-03-05  Zoltan Varga  <vargaz@gmail.com>
4041
4042         * mini.h: Define G_MININT32/G_MAXINT32 if using an older glib version.
4043
4044         * cfold.c: Remove definition of G_MININT32 which is now in mini.h.
4045
4046 2008-03-04  Zoltan Varga  <vargaz@gmail.com>
4047
4048         * mini-amd64.c (mono_arch_compute_omit_fp): Don't disable fp elimination for 
4049         methods returning vtypes in registers.
4050         (mono_arch_allocate_vars): Ditto.
4051
4052         * mini-amd64.c (mono_arch_get_this_arg_reg): New arch specific helper function.
4053
4054         * tramp-amd64.c (mono_arch_get_unbox_trampoline): Use mono_arch_get_this_arg_reg ().    
4055
4056         * generics.cs: Add a test from the linear IR branch.
4057
4058         * mini-amd64.c (emit_load_volatile_arguments): Handle vtypes passed in regs too.
4059
4060         * mini.c (inline_method): Cache failed inline attempts.
4061
4062 2008-03-04  Mark Probst  <mark.probst@gmail.com>
4063
4064         * mini.c: For shared methods of generic classes put the location
4065         of "this" into the MonoGenericJitInfo.
4066
4067         * mini-x86.c, mini-amd64.c, mini.h: Added function for fetching a
4068         register out of a MonoContext by register number.  Add the generic
4069         sharing context as an argument to mono_arch_find_this_argument().
4070
4071         * mini-alpha.c, mini-arm.c, mini-hppa.c, mini-ia64.c, mini-mips.c,
4072         mini-ppc.c, mini-s390.c, mini-s390x.c, mini-sparc.c: Added stub
4073         for new arch function.
4074
4075         * mini-exception.c: Handle open exception clauses in shared
4076         generic code.
4077
4078         * mini-trampolines.c: Supply additional argument to
4079         mono_arch_find_this_argument().
4080
4081 2008-03-04  Zoltan Varga  <vargaz@gmail.com>
4082
4083         * Makefile.am (regtests): Run the bench.exe tests last.
4084
4085 2008-03-03  Zoltan Varga  <vargaz@gmail.com>
4086
4087         * mini-amd64.c (mono_arch_emit_prolog): Improve the first bblock optimization
4088         a bit.
4089
4090 2008-03-02  Zoltan Varga  <vargaz@gmail.com>
4091
4092         * mini.c (mono_method_to_ir): Allow callvirt on static methods for compatibility
4093         with MS.
4094
4095         * mini-amd64.c (mono_arch_emit_prolog): Fix tracing after the last change.
4096         
4097         * mini-amd64.c (mono_arch_emit_prolog): Avoid saving dead arguments.
4098
4099         * mini.c (mono_method_check_inlining): Avoid disabling inlining for methods
4100         whose class has no cctor.
4101
4102         * liveness.c (mono_analyze_liveness): Mark dead arguments with MONO_INST_IS_DEAD.
4103
4104 2008-03-01  Zoltan Varga  <vargaz@gmail.com>
4105
4106         * mini.c (mono_method_to_ir): Report calling a static method using callvirt as
4107         unverified.
4108
4109 2008-02-29  Zoltan Varga  <vargaz@gmail.com>
4110
4111         * mini-ops.h: Remove OP_SPARC_INARG_VT, add a new OP_VTARG_ADDR opcode instead
4112         to be in sync with the code on the linear IR branch.
4113
4114         * mini-sparc.c inssel-sparc.brg: Use OP_VTARG_ADDR.
4115
4116         * inssel-s390.brg (OP_SETRET (freg)): Set dreg correctly.
4117
4118 2008-02-27  Zoltan Varga  <vargaz@gmail.com>
4119
4120         * mini-mips.c: Use cfg->vret_addr instead of cfg->ret.
4121
4122         * mini-s390x.c: Use cfg->vret_addr instead of cfg->ret.
4123
4124         * mini-s390.c: Use cfg->vret_addr instead of cfg->ret.
4125
4126         * mini-<ARCH>.h mini.c: Get rid of the MONO_ARCH_HAVE_CREATE_VARS define.
4127
4128         * mini-<ARCH>.c (mono_arch_create_vars): Define this for all architectures.
4129         
4130         * mini.c (mono_method_to_ir): Avoid invalid memory reads for methods without a
4131         body.
4132
4133 2007-11-14  Yoichi NAKAYAMA  <nakayama@pixela.co.jp>
4134
4135         * inssel-mips.brg (OP_OUTARG_MEMBASE (CEE_LDIND_R4 (base))): Add missing
4136         OP_LOADR4_MEMBASE emission.
4137
4138         * mini-codegen.c (mono_spillvar_offset_int): Remove assertion.
4139         (mono_spillvar_offset_float): Ditto.
4140
4141         * mini-mips.c (mono_arch_emit_prolog): Ditto.
4142
4143         * inssel-long32-mips.brg: Fix wrong branching, reduce redundant code
4144         emission.
4145
4146         * basic-long.cs: Add regression tests for them.
4147
4148         * mini-mips.c (add_float32_arg): Respect o32 calling convention in gr
4149         use.
4150         (mono_arch_allocate_vars): Fix representation of single-precision float
4151         argument.
4152         (mono_arch_output_basic_block): Ditto.
4153
4154         * inssel-mips.brg: Ditto, remove duplicate items.
4155
4156         * mini-mips.c (emit_load_volatile_arguments): New function to handle
4157         arguments of tail calls as on other platforms.
4158         (mono_arch_output_basic_block): Handle tail calls.
4159
4160         * inssel-mips.brg (OP_OUTARG_VT (CEE_LDOBJ (base))): Correct destination
4161         register.
4162
4163         * objects.cs (test_5_pass_static_struct): Add test for it.
4164
4165         Contributed under MIT/X11 license.
4166
4167 2008-02-26  Zoltan Varga  <vargaz@gmail.com>
4168
4169         * Makefile.am: Use gmcs for compiling the regression tests.
4170
4171         * *.2.cs *.2.il: Rename to *.cs and *.il.
4172
4173 2008-02-24  Zoltan Varga  <vargaz@gmail.com>
4174
4175         * regalloc.h: Make the vassign array smaller.
4176
4177         * mini.c (mini_method_compile): Remove an unused field in cfg.
4178
4179         * mini-codegen.c: Add a bunch of micro optimizations.
4180
4181 2008-02-23  Zoltan Varga  <vargaz@gmail.com>
4182
4183         * regalloc.h: Remove some unused fields.
4184
4185 2008-02-22  Zoltan Varga  <vargaz@gmail.com>
4186
4187         * mini-amd64.c (mono_arch_patch_code): Fix a warning.
4188
4189         * ssa.c (mono_ssa_remove): Avoid declaring volatile variables dead.
4190
4191 2008-02-22  Mark Probst  <mark.probst@gmail.com>
4192
4193         * mini.h: New trampoline type (RGCTX_LAZY_FETCH).
4194
4195         * mini-trampolines.c, tramp-amd64.c, tramp-x86.c: RGCTX lazy fetch
4196         trampoline: Fetch an entry from the runtime generic context.  If
4197         it's NULL, jump to the actual trampoline to fill the runtime
4198         generic context.  Otherwise, return it.
4199
4200         * mini.c: Call the lazy fetch trampoline to get entries out of the
4201         runtime generic context.
4202
4203         * tramp-ia64.c, tramp-arm.c, tramp-alpha.c, tramp-s390.c,
4204         tramp-s390x.c, tramp-ppc.c, tramp-hppa.c, tramp-mips.c,
4205         tramp-sparc.c: Stubs for the lazy fetch trampoline.
4206
4207 2008-02-21  Mark Probst  <mark.probst@gmail.com>
4208
4209         * mini.c: Fetch data out of the extensible part of the runtime
4210         generic context instead of calling a helper function.
4211
4212         * generic-sharing.c: Some functions moved into
4213         metadata/generic-sharing.c.  Helper function for fetching other
4214         types now checks and asserts against extensible rgctx (just for
4215         debugging purposes - the helper function isn't called anymore
4216         unless for debugging).
4217
4218 2008-02-21  Zoltan Varga  <vargaz@gmail.com>
4219
4220         * mini-arm.c (mono_arch_output_basic_block): Implement proper argument passing
4221         for tail calls up to the point that the tests in iltests.exe run. Also add a
4222         dummy CKFINITE implementation.
4223         (mono_arch_emit_prolog): Avoid saving the method in the LMF since it is only
4224         needed for trampoline LMF frames.
4225
4226         * exceptions-arm.c (mono_arch_find_jit_info): Only read lmf->method for 
4227         trampoline LMF frames.
4228
4229 2008-02-21  Rodrigo Kumpera  <rkumpera@novell.com>
4230
4231         * mini.c (inline_method): clean any pending loader error when inlining fail.
4232         Otherwise loader errors in mono_method_to_ir leaks and cause spurious errors.
4233
4234 2008-02-21  Zoltan Varga  <vargaz@gmail.com>
4235
4236         * aot-compiler.c (encode_patch): Handle ICALL_ADDR patch type.
4237
4238         * aot-runtime.c (decode_patch_info): Ditto.
4239
4240         * mini.c (mono_resolve_patch_target): Ditto.
4241         
4242         * aot-compiler.c (compile_method): Add some experimental code for AOT compiling
4243         icall wrappers.
4244
4245         * patch-info.h (PATCH_INFO): Add 'ICALL_ADDR' patch type.
4246         
4247         * mini.c (mono_method_to_ir): Convert a CEE_MONO_LDPTR opcode to an AOT constant
4248         if it references an icall address.
4249
4250 2008-02-20  Zoltan Varga  <vargaz@gmail.com>
4251
4252         * cpu-s390x.md: Remove some more unused opcodes.
4253         
4254         * cpu-s390x.md: Remove some unused opcodes.
4255
4256         * mini-ia64.c (mono_arch_lowering_pass): Add some more opcodes. Use
4257         mono_op_imm_to_op ().
4258
4259         * mini-sparc.c (opcode_to_sparc_cond): Use the mono_opcode_to_cond () functions
4260         instead of a switch statement.
4261         
4262         * mini-sparc.c (mono_arch_allocate_vars): Allocate a stack slot for use by
4263         the int<->float conversion opcodes instead of using mono_spillvar_offset_float ().
4264
4265         * mini-codegen.c: Eliminate rassign macro which is no longer needed.
4266         
4267         * mini-codegen.c: Remove unused mono_regstate2_... functions.
4268
4269         * mini-codegen.c (mono_print_ins_index): Avoid printing an index when it is
4270         -1.
4271
4272 2008-02-19  Zoltan Varga  <vargaz@gmail.com>
4273
4274         * driver.c (mono_main): Improve error reporting when an assembly cannot be
4275         opened. Fixes #362607.
4276
4277         * cpu-ia64.md cpu-s390x.md: Remove some unused opcodes.
4278
4279         * iltests.il.in: Add a test for static methods in interfaces.
4280
4281 2008-02-18  Zoltan Varga  <vargaz@gmail.com>
4282
4283         * genmdesc.c (build_table): Fix a crash on older glib versions.
4284
4285         * cpu-sparc.md: Remove some unused opcodes.
4286         
4287         * genmdesc.c: Error out if the .md contains CEE_ opcodes if 
4288         MONO_ARCH_ENABLE_NORMALIZE_OPCODES is defined.
4289
4290         * cpu-amd64.md: Remove some unused opcodes.
4291
4292         * mini.h mini-ops.h mini.c: Define the OP_Ccc opcodes in mini-ops.h normally
4293         like the other opcodes.
4294
4295 2008-02-17  Zoltan Varga  <vargaz@gmail.com>
4296
4297         * mini-ia64.c: Use cfg->vret_addr instead of cfg->ret.
4298
4299         * mini-arm.h mini-arm.c: Use cfg->vret_addr instead of cfg->ret.
4300
4301         * mini-sparc.c: Use cfg->vret_addr instead of cfg->ret. Name the MonoCompile
4302         variables 'cfg' instead of 'm' for consistency.
4303
4304         * mini-x86.c: Use cfg->vret_addr instead of cfg->ret.
4305
4306         * mini.h (MonoCompile): Add new 'vret_addr' field which represents the hidden
4307         argument holding the vtype return address, to avoid the ambigious use of
4308         cfg->ret for this purpose.
4309
4310         * mini.c (NEW_RETLOADA): Use vret_addr if set.
4311
4312         * mini-amd64.c: Use cfg->vret_addr instead of cfg->ret.
4313         
4314         * mini-codegen.c (mono_print_ins): Rename to mono_print_ins_index (), Add a
4315         new mono_print_ins () function which only takes one argument.
4316
4317 2008-02-15  Zoltan Varga  <vargaz@gmail.com>
4318
4319         * mini-s390.h (MONO_OUTPUT_VTR): Use cfg instead of s, avoid assignments to
4320         macro arguments.
4321
4322 2008-02-14  Zoltan Varga  <vargaz@gmail.com>
4323
4324         * mini-ops.h: Get rid of OP_SPARC_LOCALLOC_IMM.
4325
4326         * mini-sparc.c inssel-sparc.brg: Use OP_LOCALLOC_IMM instead of OP_SPARC_LOCALLOC_IMM.
4327
4328         * mini-x86.c: Sync with the version on the linear IR branch by adding new 
4329         opcodes and other small changes.
4330
4331         * mini-ops.h: Add some new opcodes from the linear IR branch.
4332
4333         * mini-ops.h: Get rid of the OP_X86_..._MEMBASE opcodes.
4334
4335         * mini-x86.c inssel-x86.brg cpu-x86.md: Get rid of the confusing _MEMBASE
4336         opcodes, use the REG_MEMBASE opcodes instead.
4337         
4338         * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Get rid of the confusing _MEMBASE
4339         opcodes, use the REG_MEMBASE opcodes instead.
4340         
4341         * mini-amd64.c (mono_arch_output_basic_block): Sync with the version on the
4342         linear IR branch.
4343
4344         * mini.c (mono_op_imm_to_op): New helper function.
4345
4346         * mini-ops.h: Add some opcodes from linear IR branch.
4347
4348 2008-02-13  Zoltan Varga  <vargaz@gmail.com>
4349
4350         * mini-alpha.h mini-alpha.c tramp-alpha.c: Alpha port updates from Sergey Tikhonov 
4351         <tsv@solvo.ru>.
4352
4353 2008-02-12  Zoltan Varga  <vargaz@gmail.com>
4354
4355         * mini.c (mono_normalize_opcodes): Always convert CEE_CONV_R4/R8 to 
4356         OP_ICONV_TO_R4/R8.
4357
4358         * mini-ia64.c cpu-ia64.md: Add OP_ICONV_TO_R4/R8.
4359
4360 2008-02-09  Zoltan Varga  <vargaz@gmail.com>
4361
4362         * aot-compiler.c (emit_method_code): Add an assert.
4363
4364         * mini-arm.h mini-arm.c exceptions-arm.c: Modify the exception throwing code and
4365         the IMT code so it is AOT friendly. Enable AOT for methods which call interface
4366         methods.
4367
4368 2008-02-08  Zoltan Varga  <vargaz@gmail.com>
4369
4370         * mini-arm.c (mono_arch_output_basic_block): Fix the ordering of arguments for 
4371         some load/store opcodes so they are consistent. 
4372         (mono_arch_emit_prolog): Simplify some code.
4373
4374         * aot-runtime.c (mono_aot_get_plt_entry): Fix a warning.
4375
4376         * objects.cs: Add tests for large argument offsets on ARM.
4377
4378         * mini-arm.c (mono_arch_emit_prolog): Fix handling of arguments with large 
4379         stack offsets. Fixes #359651.
4380
4381         * mini.c (mono_normalize_opcodes): Remap CEE_CONV_R4/R8 properly.
4382
4383         * cpu-s390x.md: Add OP_LCONV_TO_R4/R8.
4384
4385         * cpu-ia64.md mini-ia64.h mini-ia64.c: Get rid of CEE_ opcodes.
4386
4387         * mini-ops.h: Add OP_ICONV_TO_R_UN opcode.
4388
4389         * mini.c (mono_normalize_opcodes): Remap CEE_CONV_R_UN too.
4390
4391         * cpu-s390x.md cpu-s390.md mini-s390x.c mini-arm.c cpu-arm.md mini-s390.c: Get
4392         rid of CEE_CONV_R_UN.
4393
4394         * mini-s390x.c mini-s390x.h cpu-s390x.md inssel-s390x.brg: Get rid of CEE_ opcodes.
4395
4396 2008-02-07  Zoltan Varga  <vargaz@gmail.com>
4397
4398         * mini-s390.c mini-s390.h cpu-s390.md: Get rid of CEE_ opcodes.
4399
4400         * mini.c (mono_normalize_opcodes): Add some more opcodes.
4401
4402         * mini-arm.c mini-arm.h cpu-arm.md: Get rid of CEE_ opcodes.
4403
4404         * cpu-amd64.md: Remove some unused opcodes.
4405
4406         * mini-sparc.c mini-sparc.h cpu-sparc.md: Get rid of CEE_ opcodes.
4407
4408         * mini-x86.c mini-x86.h cpu-x86.md: Get rid of CEE_ opcodes.
4409
4410         * mini.c mini-<ARCH>.c: Remove mono_arch_local_regalloc (), instead make 
4411         arch specific functions for its parts. Call the peephole pass after local
4412         regalloc so the prolog can compute a more accurate max_offset.
4413         
4414         * mini.c (mono_normalize_opcodes): New mini pass to convert CEE_ opcodes to
4415         the corresponding OP_I/OP_L opcodes.
4416
4417         * mini-amd64.c mini-amd64.h cpu-amd64.md: Get rid of CEE_ opcodes.
4418
4419         * mini-sparc.c (mono_arch_output_basic_block): Fix the sparc build.
4420
4421 2008-02-06  Zoltan Varga  <vargaz@gmail.com>
4422
4423         * mini-s390.c (mono_arch_get_inst_for_method): Remove the Interlocked cases
4424         as they are handled in mini.c.
4425
4426         * mini-s390x.c (mono_arch_get_inst_for_method): Ditto.
4427         
4428         * mini-<ARCH>.c (mono_arch_get_inst_for_method): Remove the MemoryBarrier
4429         case since it is handled in mini.c.
4430
4431         * cpu-sparc.md (sparc_setfreg_float): Fix the sparc build.
4432
4433         * mini-ops.h: Add new opcodes OP_CALL/OP_CALLVIRT.
4434
4435         * *.c: Use the new opcodes in the IR and back end code.
4436
4437         * mini-ops.h cpu-<ARCH>.md: Correct the name of the bgt_un opcodes.
4438
4439         * mini-amd64.c (emit_call_body): Use a far-call for calling dynamic methods.
4440
4441 2008-02-06  Mark Probst  <mark.probst@gmail.com>
4442
4443         * mini-trampolines.c (mono_generic_class_init_trampoline): Removed
4444         an assert because it has a race condition.
4445
4446 2008-02-06  Zoltan Varga  <vargaz@gmail.com>
4447
4448         * tramp-amd64.c (mono_arch_patch_callsite): Add more diagnostics.
4449
4450         * inssel.brg mini-<ARCH>.c cpu-<ARCH>.md: Get rid of unused CEE_RET opcode.
4451
4452         * mini-<ARCH>.c cpu-<ARCH>.md: Get rid of unused LDIND/STIND opcodes.
4453
4454         * *.brg mini-<ARCH>.c cpu-<ARCH>.md: Get rid of OP_SETREG/OP_SETFREG/OP_SETREGIMM,
4455         use OP_MOVE/OP_FMOVE/OP_ICONST instead.
4456
4457 2008-02-05  Zoltan Varga  <vargaz@gmail.com>
4458
4459         * cpu-amd64.md (move): Correct the maximum size of move.
4460
4461 2008-02-05  Mark Probst  <mark.probst@gmail.com>
4462
4463         * tramp-amd64.c, tramp-x86.c, mini-trampolines.c: Added a check in
4464         the generic class init trampoline to return quickly if the class
4465         is already inited.
4466
4467 2008-02-04  Zoltan Varga  <vargaz@gmail.com>
4468
4469         * tramp-amd64.c (mono_arch_patch_callsite): Add some diagnostics to help debug
4470         issues where an 32 bit callsite cannot be patched by a 64 bit address.
4471
4472 2008-02-03  Zoltan Varga  <vargaz@gmail.com>
4473
4474         * generics.2.cs generics-variant-types.2.il: Merge some tests from the linear IR
4475         branch.
4476
4477 2008-01-31  Zoltan Varga  <vargaz@gmail.com>
4478
4479         * objects.cs: Add some soft-float tests.
4480
4481         * mini.c: Fix a couple more soft-float issues.
4482
4483         * helpers.c (mono_disassemble_code): Fix disassembly on ARM.
4484
4485         * mini-amd64.c (peephole_pass): Use IXOR instead of LXOR for zeroing a register to
4486         avoid a REX prefix.
4487
4488 2008-01-30  Zoltan Varga  <vargaz@gmail.com>
4489
4490         * exceptions-x86.c (mono_arch_find_jit_info): Fix stack unwinding when an
4491         exception happens while compiling a virtual method.
4492
4493 2008-01-29  Zoltan Varga  <vargaz@gmail.com>
4494
4495         * mini-sparc.c (mono_arch_emit_epilog): Fix folding of negative return values.
4496         
4497         * mini-sparc.c: Fix build.
4498
4499         * mini-sparc.c (get_call_info): Add support for generic sharing.
4500
4501         * mini-exceptions.c: Add a FIXME.
4502
4503 2008-01-27  Zoltan Varga  <vargaz@gmail.com>
4504
4505         * mini-exceptions.c (mono_handle_exception_internal): Remove the old style
4506         altstack handling code.
4507
4508         * mini-s390.c (mono_arch_emit_exceptions): Really fix a warning.
4509         
4510         * mini-s390.c (mono_arch_emit_exceptions): Fix a warning.
4511
4512         * mini-s390.c: Add support for generic sharing.
4513
4514         * mini-exceptions.c (ves_icall_System_Security_SecurityFrame_GetSecurityFrame): 
4515         Fix CAS on s390.
4516         (ves_icall_System_Security_SecurityFrame_GetSecurityStack): Ditto.
4517
4518         * mini-s390x.c (mono_arch_emit_exceptions): Fix a warning.
4519
4520         * mini-s390x.c: Add support for generic sharing.
4521         
4522         * mini-exceptions.c (ves_icall_System_Security_SecurityFrame_GetSecurityFrame): 
4523         Fix CAS on ia64.
4524         (ves_icall_System_Security_SecurityFrame_GetSecurityStack): Ditto.
4525
4526         * mini-s390x.c: Use is_imm16 instead of is_uimm16 when checking whenever s390_aghi
4527         can be used since it takes a 16 bit signed immediate.
4528
4529         * inssel-s390x.brg: Fix OP_SETRET.
4530
4531         * mini-s390x.c (mono_arch_output_basic_block): Fix OP_BREAK.
4532
4533         * mini-codegen.c (mono_opcode_to_cond): Fix a warning.
4534
4535         * mini-s390x.c cpu-s390x.md: Implement sext.i4 properly by sign extension.
4536
4537         * mini.c (mono_create_delegate_trampoline): Don't use mono_create_ftpntr here.
4538
4539         * mini-trampolines.c (mono_delegate_trampoline): Use mono_get_addr_from_ftnptr
4540         in one place.
4541
4542         * mini-ia64.h mini-ia64.c: Add minimal support for the delegate trampoline 
4543         stuff.
4544
4545         * mini.h inssel-x86.brg inssel-amd64.brg tramp-alpha.c tramp-ia64.c: Get rid
4546         of the unused mono_arch_patch_delegate_trampoline stuff.
4547
4548 2008-01-26  Zoltan Varga  <vargaz@gmail.com>
4549
4550         * basic-long.cs: Move the fp related tests to basic-float.cs.
4551
4552         * mini-ops.h (OP_OUTARG_FREG_R4): New opcode.
4553
4554         * mini-ia64.c inssel-ia64.brg: Implement proper R4 argument passing.
4555
4556         * basic-calls.cs: Add a test for proper float argument passing.
4557
4558         * mini-ia64.h (mono_ia64_context_get_ip): Do not substract 1 from the ip
4559         if the context corresponds to an exception received through a signal.
4560
4561         * exceptions.cs: Add a test for nullref handling at the start of a try
4562         clause.
4563
4564         * mini-ia64.c (mono_arch_call_opcode): Fix ia64 argument passing.
4565
4566         * jit-icalls.c (mono_break): New JIT icall.
4567
4568         * mini-<ARCH>.c: Use mono_break instead of mono_arch_break.
4569
4570         * mini-arm.c (arm_patch): Add support for patching the blx calling sequence.
4571
4572 2008-01-25  Zoltan Varga  <vargaz@gmail.com>
4573
4574         * cpu-*.md: Get rid of unused opcodes.
4575
4576         * cpu-g4.md: Rename this to cpu-ppc.md for consistency with other archs.
4577
4578         * Makefile.am: Move mini-trampolines.c to $(common_sources) since it is now used
4579         by all platforms.
4580
4581         * mini-<ARCH>.h mini.c: Get rid of the MONO_ARCH_HAVE_CREATE_SPECIFIC_TRAMPOLINE
4582         define.
4583
4584         * mini-s390x.h tramp-s390x.c Makefile.am: Rework the s390x trampoline code to use
4585         the arch independent trampoline code in mini-trampolines.c.
4586
4587         * aot-runtime.c (mono_aot_init_vtable): Fix a warning.
4588
4589         * mini.c (get_runtime_generic_context_ptr): Fix a warning.
4590
4591         * mini-s390.h: Remove an unused define.
4592         
4593         * mini-s390.h tramp-s390.c Makefile.am: Rework the s390 trampoline code to use
4594         the arch independent trampoline code in mini-trampolines.c.
4595
4596         * mini-arm.c (mono_arch_emit_prolog): Fix build.
4597
4598 2008-01-24  Zoltan Varga  <vargaz@gmail.com>
4599
4600         * mini-sparc.c (mono_arch_output_basic_block): Remove some unecessary code.
4601
4602         * mini-s390.c (mono_arch_emit_prolog): Fix build.
4603
4604         * mini-s390x.c (mono_arch_emit_prolog): Fix build.
4605
4606         * mini-ppc.c (mono_arch_emit_prolog): Fix build.
4607
4608         * cpu-amd64.md: Use smaller sizes for int opcodes.
4609
4610         * *.c: Get rid of the NOT_IMPLEMENTED define which is now in mini.h.
4611
4612         * *.cs: Add some tests from the linear-ir branch. Move structs tests to 
4613         objects.cs.
4614
4615         * driver.c (mono_main): Add a --break-at-bb command line argument for JIT
4616         debugging.
4617
4618         * mini.h *.c: Change cfg->vars to contain the MonoMethodVar entries directly
4619         instead of though a pointer to save an indirection when accessing elements of
4620         the array.
4621
4622         * mini.h (MONO_IS_COND_BRANCH_OP): Move these macros here from mini.c. Fix
4623         some typos.
4624         (NOT_IMPLEMENTED): New helper macro.
4625         (MONO_BB_FOR_EACH_INS): New helper macro to iterate through the instructions
4626         of a bb.
4627
4628         * *.c: Use the new helper macro.
4629
4630 2008-01-21  Zoltan Varga  <vargaz@gmail.com>
4631
4632         * mini-x86.h (MONO_ARCH_AOT_SUPPORTED): Disable AOT for apple x86.
4633
4634 2008-01-20  Zoltan Varga  <vargaz@gmail.com>
4635
4636         * mini-amd64.c (mono_arch_emit_prolog): Optimize the omit fp case to save two
4637         stack slots.
4638
4639 2008-01-18  Zoltan Varga  <vargaz@gmail.com>
4640
4641         * mini-amd64.c (mono_arch_emit_prolog): Disable the new optimization if
4642         profiling is enabled.
4643         
4644         * mini-amd64.c (mono_arch_call_opcode): Emit the save_sp_to_lmf instruction at
4645         the end.
4646         (mono_arch_emit_prolog): Add more first bblock optimizations.
4647
4648         * mini-amd64.c (mono_arch_call_opcode): Keep assignments to the arg registers
4649         in order if possible.
4650         (mono_arch_emit_prolog): Optimize assignments to arg registers in the first
4651         bblock, since the arguments are still in their original registers.
4652
4653         * mini.c (type_from_op): Calling add.ovf on floats is not valid IL code.
4654
4655 2008-01-17  Zoltan Varga  <vargaz@gmail.com>
4656
4657         * mini.c (mono_method_to_ir): Use the no-spilling optimization for CEE_CALLI
4658         as well.
4659
4660         * mini-amd64.c (mono_arch_emit_prolog): Save an instruction if the LMF is at
4661         offset 0.
4662
4663         * mini-amd64.h (MONO_ARCH_HAVE_NOTIFY_PENDING_EXC): Turn on this for amd64.
4664
4665         * exceptions-amd64.c (mono_arch_notify_pending_exc): New function to 
4666         process async exceptions received while in unmanaged code.
4667
4668         * mini.c (mini_init): Install a callback with the runtime which will be called
4669         when a thread receives an async exception while in unmanaged code.
4670
4671         * mini.c driver.c: Update after mono_get_native_wrapper () signature change.
4672
4673         * mini-s390x.c (mono_arch_output_basic_block): Fix s390x build.
4674
4675 2008-01-16  Wade Berrier  <wberrier@novell.com>
4676
4677         * cpu-g4.md:
4678         * cpu-arm.md:
4679         * cpu-s390x.md:
4680         fix build
4681
4682 2008-01-16  Zoltan Varga  <vargaz@gmail.com>
4683
4684         * mini-x86.c (mono_arch_output_basic_block): Remove some gccism which prevents
4685         compilation with sun cc.
4686
4687         * cpu-*.md: Fix the build.
4688
4689         * cpu-x86.md: Fix the length of some load membase opcodes. Fixes #354241.
4690
4691         * mini-amd64.h: Add some comments to the MonoLMF structure.
4692
4693         * mini-ops.h cpu-amd64.c: Add a OP_AMD64_SAVE_SP_TO_LMF opcode.
4694         
4695         * mini-amd64.c exceptions-amd64.c tramp-amd64.c: Avoid setting the rip field
4696         in the LMF structure if possible. This saves two instructions in the
4697         managed->native wrappers.
4698
4699         * mini-ops.h *.md: Make some opcodes names uniform by removing the op_ prefix.
4700
4701 2008-01-16  Mark Probst  <mark.probst@gmail.com>
4702
4703         * generic-sharing.c: New type argument lookup code which uses the
4704         runtime generic context template.
4705
4706 2008-01-15  Zoltan Varga  <vargaz@gmail.com>
4707
4708         * mini.c (mono_method_to_ir): Avoid emitting a write barrier when storing NULL.
4709
4710         * mini-arm.c (add_general): Fix arm eabi parameter passing.
4711         (mono_arch_output_basic_block): Fix localloc implementation.
4712
4713         * mini-amd64.c (peephole_pass): Sync store+load optimizations with the x86 version.
4714
4715         * mini-ia64.c (peephole_pass): Fix ia64 build.
4716
4717         * mini-amd64.c (peephole_pass): Fix a warning.
4718         
4719         * mini-amd64.c (mono_arch_allocate_vars): Make sure the LMF is always stored
4720         at a constant offset from sp/fp.
4721
4722         * exceptions-amd64.c (mono_arch_find_jit_info): Compute the LMF address from fp/sp
4723         instead of obtaining it from *lmf in the managed method case.
4724
4725 2008-01-14  Zoltan Varga  <vargaz@gmail.com>
4726
4727         * exceptions-amd64.c (mono_arch_find_jit_info): Remove some duplicate code.
4728
4729 Mon Jan 14 12:33:06 CET 2008  David S. Miller  <davem@davemloft.net>
4730
4731         * mini.h (MonoInstList): New type.
4732         (MONO_INST_LIST_INIT, MONO_INST_LIST_EMPTY,
4733         __MONO_INST_LIST_ADD, MONO_INST_LIST_ADD,
4734         MONO_INST_LIST_ADD_TAIL, __MONO_INST_LIST_DEL,
4735         __MONO_INST_LIST_SPLICE, MONO_INST_LIST_SPLICE,
4736         MONO_INST_LIST_SPLICE_TAIL, MONO_INST_LIST_SPLICE_INIST,
4737         MONO_INST_LIST_SPLICE_TAIL_INIT, mono_container_of,
4738         MONO_INST_LIST_ENTRY, MONO_INST_LIST_FIRST_ENTRY,
4739         MONO_INST_LIST_LAST_ENTRY, MONO_INST_LIST_FOR_EACH,
4740         MONO_INST_LIST_FOR_EACH_PREV, MONO_INST_LIST_FOR_EACH_SAFE,
4741         MONO_INST_LIST_FOR_EACH_PREV_SAFE,
4742         MONO_INST_LIST_FOR_EACH_ENTRY,
4743         MONO_INST_LIST_FOR_EACH_ENTRY_REVERSE,
4744         MONO_INST_LIST_FOR_EACH_ENTRY_SAFE,
4745         mono_inst_list_first, mono_inst_list_last,
4746         mono_inst_list_next, mono_inst_list_prev): New instruction
4747         list handling interfaces.
4748         (MonoBasicBlock): Remove 'last_ins' and 'code', replace with
4749         list head 'ins_list'.
4750         (MonoInst): Replace next pointer with list head 'node'.
4751         (MonoCallInst): Make 'out_args' a MonoInstList.
4752         (MONO_INST_NEW_CALL): Explicitly init ->out_args.
4753         (MonoCompile): Delete reverse_inst_list and
4754         reverse_inst_list_len.
4755         * mini-hppa.c (mono_arch_call_opcode, NEW_INS,
4756         mono_arch_lowering_pass, mono_arch_local_regalloc,
4757         mono_arch_output_basic_block, mono_arch_emit_prolog):
4758         Convert to new instruction lists.
4759         (insert_after_ins): Delete.
4760         * inssel.brg (MONO_EMIT_NEW_BRANCH_BLOCK): Convert to new
4761         instruction lists.
4762         * mini-hppa.h (MONO_EMIT_NEW_COMPARE_BRANCH_BLOCK): Likewise.
4763         * mini.c (NEW_BBLOCK, ADD_BBLOCK, CHECK_BBLOCK,
4764         split_bblock, mono_add_ins_to_end, mono_emit_call_args,
4765         mono_emulate_opcode, mono_emit_load_got_addr,
4766         inline_method, mono_method_to_ir, mono_print_bb_code,
4767         print_dfn, decompose_pass, nullify_basic_block,
4768         replace_out_block_in_code, remove_block_if_useless,
4769         merge_basic_blocks, move_basic_block_to_end,
4770         try_unsigned_compare, optimize_branches, mono_print_code,
4771         mini_select_instructions, remove_critical_edges): Likewise.
4772         * mini-amd64.c (emit_sig_cookie, mono_arch_call_opcode,
4773         peephole_pass_1, peephole_pass, mono_arch_lowering_pass,
4774         mono_arch_output_basic_block, mono_arch_emit_prolog):
4775         Likewise.
4776         * mini-mips.c (mono_arch_call_opcode, peephole_pass,
4777         NEW_INS, mono_arch_lowering_pass, mono_arch_local_regalloc,
4778         mono_arch_output_basic_block): Likewise.
4779         (inst_list_prepend, insert_after_ins): Delete.
4780         * mini-mips.h (MONO_EMIT_NEW_BRANCH_NONZERO_LABEL,
4781         MONO_EMIT_NEW_COMPARE_BRANCH_BLOCK): Convert to new
4782         instruction lists.
4783         * mini-x86.c (emit_sig_cookie, mono_arch_call_opcode,
4784         peephole_pass_1, peephole_pass, mono_arch_output_basic_block,
4785         mono_arch_emit_prolog): Likewise.
4786         * cfold.c (mono_constant_fold): Likewise.
4787         * liveness.c (visit_bb, mono_analyze_liveness,
4788         optimize_initlocals): Likewise.
4789         * ssapre.c (dump_code, process_bb, code_motion): Likewise.
4790         * graph.c (mono_draw_code_cfg): Likewise.
4791         * ssa.c (mono_ssa_rename_vars, mono_ssa_compute,
4792         mono_ssa_remove, mono_ssa_avoid_copies, mono_ssa_create_def_use,
4793         mono_ssa_cprop): Likewise.
4794         * abcremoval (get_relations_from_previous_bb, process_block):
4795         Likewise.
4796         * local-propagation (mono_cprop_invalidate_values,
4797         mono_local_cprop_bb): Likewise.
4798         * mini-s390x.c (mono_arch_call_opcode, emit_sig_cookie,
4799         peephole_pass, mono_arch_output_basic_block,
4800         mono_arch_emit_prolog): Likewise.
4801         * mini-arm.c (mono_arch_call_opcode, peephole_pass,
4802         NEW_INS, mono_arch_lowering_pass, mono_arch_local_regalloc,
4803         mono_arch_emit_prolog): Likewise.
4804         (insert_after_ins): Delete.
4805         * aliasing.c (print_code_with_aliasing_information,
4806         mono_build_aliasing_information, mono_aliasing_deadce):
4807         Convert to new instruction lists.
4808         * mini-ia64.c (emit_sig_cookie, mono_arch_call_opcode,
4809         peephole_pass, NEW_INS, mono_arch_lowering_pass,
4810         mono_arch_local_regalloc, mono_arch_output_basic_block):
4811         Likewise.
4812         (insert_after_ins): Delete.
4813         * mini-sparc.c (emit_sig_cookie, mono_arch_call_opcode,
4814         peephole_pass, mono_arch_output_basic_block): Convert to
4815         new instruction lists.
4816         * mini-codegen (InstList, inst_list_prepend,
4817         insert_after_ins): Delete.
4818         (insert_before_ins, get_register_force_spilling,
4819         get_register_spilling, free_up_ireg, free_up_reg,
4820         create_copy_ins, create_spilled_store, alloc_int_reg,
4821         alloc_float_reg, alloc_reg, mono_local_regalloc): Convert
4822         to new instruction lists.
4823         * mini-ppc.c (mono_arch_call_opcode, peephole_pass,
4824         NEW_INS, mono_arch_lowering_pass, mono_arch_local_regalloc,
4825         mono_arch_output_basic_block, mono_arch_emit_prolog): Likewise.
4826         (insert_after_ins): Delete.
4827         * mini-alpha.c (NEW_INS, peephole_pass, mono_arch_lowering_pass,
4828         mono_arch_local_regalloc, mono_arch_output_basic_block,
4829         mono_arch_call_opcode): Convert to new instruction lists.
4830         (insert_after_ins): Delete.
4831         * mini-s390.c (mono_arch_call_opcode, emit_sig_cookie,
4832         peephole_pass, mono_arch_output_basic_block,
4833         mono_arch_emit_prolog): Convert to new instruction lists.
4834
4835 2008-01-11  Zoltan Varga  <vargaz@gmail.com>
4836
4837         * mini-amd64.c (mono_arch_output_basic_block): Use a 4 byte load in OP_CHECK_THIS.
4838
4839         * mini-sparc.c (mono_arch_output_basic_block): Use a byte load in CHECK_THIS.
4840         Fixes #353182.
4841
4842         * Makefile.am (version.h): Make this work with non-bash shells.
4843
4844 2008-01-10  Zoltan Varga  <vargaz@gmail.com>
4845
4846         * mini.c (handle_delegate_ctor): Optimize away setting of NULL target.
4847
4848 2008-01-08  Zoltan Varga  <vargaz@gmail.com>
4849
4850         * mini.c (mono_method_to_ir): Fix possible reading of invalid memory in 
4851         the InitializeArray optimization.
4852
4853 2008-01-06  Zoltan Varga  <vargaz@gmail.com>
4854
4855         * mini.c driver.c: Don't include os/gc_wrapper.h.
4856
4857 2008-01-05  Zoltan Varga  <vargaz@gmail.com>
4858
4859         * mini.c (print_jit_stats): Print GC statistics if available.
4860
4861 2008-01-04  Zoltan Varga  <vargaz@gmail.com>
4862
4863         * mini-amd64.c (mono_arch_allocate_vars): Align argument storage offsets to 8.
4864
4865 2007-12-29  Zoltan Varga  <vargaz@gmail.com>
4866
4867         * mini-ppc.c (mono_arch_get_delegate_invoke_impl): Fix flushing of icache.
4868
4869 2007-12-26  Zoltan Varga  <vargaz@gmail.com>
4870
4871         * mini.c (mini_init): Move the setting of GC_stackbottom to mono_gc_base_init ().
4872         
4873         * mini.c (mini_init): Call mono_gc_base_init () instead of MONO_GC_PRE_INIT ().
4874
4875         * driver.c (mono_main): Ditto.
4876
4877 2007-12-23  Zoltan Varga  <vargaz@gmail.com>
4878
4879         * mini-trampolines.c (mono_delegate_trampoline): Use mono_get_delegate_invoke ().
4880
4881         * aot-compiler.c (emit_klass_info): Avoid emitting info if one of the methods
4882         in the vtable can't be encoded.
4883         (compile_method): Ditto.
4884
4885 2007-12-21  Zoltan Varga  <vargaz@gmail.com>
4886
4887         * mini.c (setup_jit_tls_data): Use the MONO_ARCH_INIT_TOP_LMF_ENTRY macro if
4888         defined.
4889
4890         * mini-amd64.h mini-amd64.c exceptions-amd64.c tramp-amd64.c: Rename lmf->ebp to 
4891         lmf->rbp.
4892
4893         * exceptions-amd64.c (mono_arch_find_jit_info): Fix the detection of whenever
4894         the top LMF entry belongs to the current method.
4895
4896         * mini.c: Update after renaming of mono_thread_get_pending_exception ().
4897
4898 2007-12-20  Zoltan Varga  <vargaz@gmail.com>
4899
4900         * tramp-ia64.c (mono_arch_create_trampoline_code): Fix a warning.
4901         
4902         * tramp-ia64.c (mono_arch_create_trampoline_code): Ditto.
4903
4904         * tramp-sparc.c (mono_arch_create_trampoline_code): Check for thread interruption.
4905
4906         * tramp-amd64.c (mono_arch_create_trampoline_code): Ditto.
4907
4908         * tramp-x86.c (mono_arch_create_trampoline_code): Check for thread interruption.
4909
4910         * cpu-amd64.md mini-amd64.h mini-amd64.c inssel-amd64.brg: Add ulong->double 
4911         implementation.
4912
4913         * basic-float.cs: Add an ulong->double cast test.
4914
4915 2007-12-15  Zoltan Varga  <vargaz@gmail.com>
4916
4917         * mini.c (mono_method_to_ir): Fix a warning.
4918
4919 2007-12-14  Zoltan Varga  <vargaz@gmail.com>
4920
4921         * mini-ops.h: Add OP_SWITCH.
4922
4923         * mini.c graph.c ssa.c aliasing.c mini-<ARCH>.c inssel-<ARCH>.brg: Avoid using
4924         CEE_SWITCH in back-end code, use OP_SWITCH instead.
4925
4926 2007-12-11  Geoff Norton  <gnorton@novell.com>
4927
4928         * mini-s390x.c: Minor change to the MAX() define to allow
4929         it to compile with other gcc versions.
4930
4931 2007-12-11  Geoff Norton  <gnorton@novell.com>
4932
4933         * cpu-s390x.md:
4934         * mini-s390x.c: Implement sext_i4 to fix the build on s390x
4935
4936 2007-12-11  Rodrigo Kumpera  <rkumpera@novell.com>
4937
4938         exceptions-arm.c (mono_arch_get_restore_context): Restore
4939         the frame pointer.
4940
4941         exceptions-arm.c (throw_exception): Save the frame pointer.
4942         This is a partial fix for #323747. Only the client side is
4943         fixed.
4944
4945 2007-12-11  Rodrigo Kumpera  <rkumpera@novell.com>
4946
4947         * mini.c (mono_method_to_ir): Verbose message in CEE_NEWOBJ
4948         was using an unrelated variable to log the class which
4949         needed the cctor to be called. This was crashing on arm.
4950
4951 2007-12-09  Robert Jordan  <robertj@gmx.net>
4952
4953         * mini-x86.c (mono_arch_emit_epilog):
4954         Consider all kinds of 64-bit types. Fixes #323114.
4955
4956 2007-12-08  Zoltan Varga  <vargaz@gmail.com>
4957
4958         * tramp-amd64.c (mono_arch_create_trampoline_code): Clean up the code a bit.
4959
4960 2007-12-07  Zoltan Varga  <vargaz@gmail.com>
4961
4962         * mini-amd64.c (peephole_pass): Add a missing instruction check.
4963
4964 Fri Dec 7 22:08:23 CET 2007 Paolo Molaro <lupus@ximian.com>
4965
4966         * mini.c: run type ctor before allocating an object, not only
4967         when running it's constructor method (fixes at least part of bug #342507).
4968
4969 2007-12-07  Zoltan Varga  <vargaz@gmail.com>
4970         
4971         * mini-trampolines.c (mono_delegate_trampoline): Fix a warning.
4972         
4973         * mini-trampolines.c (mono_generic_class_init_trampoline): Remove a debug printf.
4974         * mini.h mini-amd64.c mini-x86.c: Get rid of the mono_arch_find_vtable () 
4975         function.
4976
4977         * tramp-x86.c tramp-amd64.c mini-trampolines.c: Pass the vtable argument to
4978         mono_generic_class_init_trampoline () the same as it is done with the other
4979         trampolines.
4980
4981         * mini-arm.h mini-arm.c tramp-arm.c inssel-arm.brg cpu-arm.md 
4982         aot-runtime.c aot-compiler.c: Implement AOT support.    
4983
4984 2007-12-07  Mark Probst  <mark.probst@gmail.com>
4985
4986         * mini-trampolines.c (mono_generic_class_init_trampoline): Fixed
4987         build for archs which don't have the vtable trampoline defined
4988         yet.
4989
4990 2007-12-07  Zoltan Varga  <vargaz@gmail.com>
4991
4992         * tramp-x86.c (mono_arch_create_trampoline_code): Fix the build.
4993
4994         * tramp-ppc.c (mono_arch_create_trampoline_code): Use the new helper function.
4995
4996         * mini-trampolines.c (mono_get_trampoline_func): New helper function.
4997
4998         * tramp-<ARCH>.c: Use the new helper function.
4999
5000 2007-12-07  Mark Probst  <mark.probst@gmail.com>
5001
5002         * inssel.brg: Added a pattern for the OP_TRAMPCALL_VTABLE
5003         trampoline call, which takes a vtable argument.
5004
5005         * graph.c, mini-ops.h, local-propagation.c, aliasing.c: Treat
5006         OP_TRAMPCALL_VTABLEs like other calls.
5007
5008         * mini-amd64.c, mini-amd64.h, mini-x86.c, mini-x86.h: Designated a
5009         register to hold the vtable argument to the OP_TRAMPCALL_VTABLE
5010         call.  Implemented a support function which fetches the vtable
5011         from a register set.
5012
5013         * mini.c, mini.h, tramp-amd64.c, tramp-x86.c, mini-trampolines.c:
5014         Implemented a generic class init trampoline, using the
5015         OP_TRAMPCALL_VTABLE opcode.
5016
5017         * mini.c: Implemented static field access when sharing generic
5018         code.  This implies initing the class using the new
5019         OP_TRAMPCALL_VTABLE call.
5020
5021 2007-12-07  Mark Probst  <mark.probst@gmail.com>
5022
5023         * mini.c: Don't compile methods with sharing enabled if their
5024         classes are disabled for sharing.
5025
5026 2007-12-06  Zoltan Varga  <vargaz@gmail.com>
5027
5028         * inssel.brg: Add a missing sign extension to the GETCHR and array access
5029         opcodes. Fixes #346563.
5030
5031         * objects.cs: Add a new test.
5032
5033         * aot-compiler.c (emit_method_code): Put back an #ifdef which is needed.
5034
5035         * mini-<ARCH>.h mini.c aot-compiler.c aot-runtime.c: Get rid of the
5036         HAVE_PIC_AOT define and use AOT_SUPPORTED instead.
5037
5038 2007-12-06  Zoltan Varga  <vargaz@gmail.com>
5039
5040         * mini-arm.h mini-arm.c: Add support for the common vtable trampoline.
5041
5042 2007-12-03  Zoltan Varga  <vargaz@gmail.com>
5043
5044         * mini-arm.c (mono_arch_emit_exceptions): Avoid uninitialized memory in the
5045         code stream.
5046
5047 2007-12-02  Zoltan Varga  <vargaz@gmail.com>
5048
5049         * patch-info.h (PATCH_INFO): Add DELEGATE_TRAMPOLINE.
5050
5051         * mini.c aot-compiler.c aot-runtime.c: Implement the delegate creation 
5052         optimization in the AOT case.
5053         
5054 2007-11-30  Zoltan Varga  <vargaz@gmail.com>
5055
5056         * aot-runtime (mono_aot_get_method_from_vt_slot): Add support for multi-byte method ref encodings.
5057         
5058         * aot-runtime.c (decode_klass_ref): Implement decoding of generic instances.
5059
5060         * aot-compiler.c (encode_klass_ref): Implement proper encoding of generic instances.
5061
5062         * mini.c (mono_method_to_ir): Optimize the common ldftn+create delegate combination.
5063
5064         * mini-trampolines.c (mono_delegate_trampoline): Add some code to handle the case when the delegate
5065         is created by the inlined delegate ctor.
5066
5067         * mini-x86.c (mono_arch_output_basic_block): Unify div/rem code and handle the case when sreg2 is EDX.  
5068
5069         * mini.c (mono_jit_compile_method_inner): Replace calls to delegate invoke with the trampoline here too.
5070
5071 2007-11-29  Zoltan Varga  <vargaz@gmail.com>
5072
5073         * cpu-x86.md: Fix the length of ckfinite.
5074
5075 2007-11-28  Zoltan Varga  <vargaz@gmail.com>
5076
5077         * mini-x86.c (mono_arch_output_basic_block): Unify div/rem code and handle the case when sreg2 is EDX.
5078         
5079         * mini-x86.c (mono_arch_output_basic_block): Clean up the fp stack properly in CKFINITE.
5080         (mono_arch_output_basic_block): Get rid of unused last_ins and last_offset.
5081
5082         * mini-x86.c (mono_arch_output_basic_block): Add some micro optimizations.
5083
5084         * mini-x86.c inssel-x86.brg cpu-x86.md: Move the implementation of the 
5085         OP_START_HANDLER/OP_ENDFINALLY/OP_ENDFILTER opcodes to mini-x86.c.
5086
5087 2007-11-28  Martin Baulig  <martin@ximian.com>
5088
5089         * mini-x86.c
5090         (mono_arch_get_delegate_invoke_impl): Call mono_debug_add_delegate_trampoline()
5091         after creating the trampoline.
5092
5093 2007-11-27  Zoltan Varga  <vargaz@gmail.com>
5094
5095         * aot-runtime.c (load_aot_module): Check runtime version if needed.
5096
5097         * aot-compiler.c: Add bind-to-runtime-version for producing AOT files which only load into a runtime with
5098         the same version.
5099
5100         * generic-sharing.c (mono_helper_get_rgctx_other_ptr): Change the signature to take the calling class
5101         instead of the calling method to help AOT.
5102
5103         * mini.c (get_runtime_generic_context_other_ptr): Update after the change.
5104
5105 2007-11-26  Zoltan Varga  <vargaz@gmail.com>
5106
5107         * aot-runtime.c (mono_aot_init_vtable): Simplify this if MONO_ARCH_COMMON_VTABLE_TRAMPOLINE
5108         is defined.
5109
5110 2007-11-23  Zoltan Varga  <vargaz@gmail.com>
5111
5112         * aot-compiler.c (emit_class_name_table): Properly encode generic class names.
5113         
5114         * aot-compiler.c (compile_method): Correct check for generic method definitions.
5115         (encode_method_ref): No need to handle generic method definitions specially.
5116
5117         * mini.h (MONO_AOT_FILE_VERSION): Bump this.
5118
5119         * aot-runtime.c (decode_klass_ref): Clean this up and rename from 
5120         decode_klass_info.
5121
5122         * aot-compiler.c (encode_klass_ref): Clean this up and rename from
5123         encode_klass_info.
5124         (compile_method): Enable generic sharing.
5125
5126 2007-11-22  Zoltan Varga  <vargaz@gmail.com>
5127
5128         * mini.c (get_runtime_generic_context_other_ptr): Disable AOT here.
5129         (mini_method_compile): Add preliminary support for AOTing shared generic code.
5130
5131         * aot-compiler.c (compile_method): Add preliminary support for AOTing shared
5132         generic code.
5133
5134         * mini-trampolines.c: Fix a warning.
5135
5136         * mini.c (get_runtime_generic_context_other_ptr): Use NEW_METHODCONST instead of
5137         NEW_PCONST.
5138         (mono_method_to_ir): Use NEW_DOMAINCONST in one place.
5139         (generic_class_is_reference_type): Remove unused function.
5140
5141         * mini-trampolines.c (mono_magic_trampoline): Avoid loading metadata if possible
5142         in the generic vtable trampoline case.
5143
5144         * aot-runtime.c (mono_aot_init_vtable): Use the generic vtable trampoline.
5145         
5146         * aot-runtime.c (mono_aot_get_method_from_vt_slot): New helper function to
5147         return an AOT method based on a vtable slot.
5148
5149         * aot-compiler.c (compile_method): Avoid AOTing synchronized methods for now.
5150
5151         * mini.c (mini_get_vtable_trampoline): Export this.
5152
5153 2007-11-22  Martin Baulig  <martin@ximian.com>
5154
5155         * debug-debugger.h
5156         (MonoDebuggerInfo): Move `debugger_version' up.
5157
5158 2007-11-22  Martin Baulig  <martin@ximian.com>
5159
5160         * mini-amd64.c
5161         (mono_arch_get_delegate_invoke_impl): Call mono_debug_add_delegate_trampoline().
5162
5163         * mini-trampolines.c
5164         (mono_delegate_trampoline): Call mono_debugger_trampoline_compiled()
5165         after compiling the method.
5166
5167 2007-11-20  Martin Baulig  <martin@ximian.com>
5168
5169         * debug-mini.c
5170         (mono_debugger_insert_method_breakpoint): Moved into mono-debug-debugger.c.
5171         (mono_debugger_remove_breakpoint): Likewise.
5172         (mono_debugger_check_breakpoints): Likewise.
5173
5174         * debug-debugger.c: Implement the new breakpoint interface here.
5175
5176 2007-11-18  Zoltan Varga  <vargaz@gmail.com>
5177
5178         * mini-amd64.c (mono_arch_output_basic_block): Unify the implementation of
5179         CEE_CONV_I1/SEXT_I1 and I2 since they are the same.
5180
5181         * mini-x86.c (mono_arch_output_basic_block): Ditto.     
5182
5183 2007-11-17  Zoltan Varga  <vargaz@gmail.com>
5184
5185         * mini-amd64.c (mono_arch_output_basic_block): Fix a typo.
5186
5187         * mini-x86.c (mono_arch_get_inst_for_method): Remove code which is now in
5188         mini.c.
5189
5190         * mini-ia64.c (mono_arch_get_inst_for_method): Remove code which is now in
5191         mini.c.
5192
5193         * mini-amd64.c (mono_arch_compute_omit_fp): Disable fp elimination for methods
5194         returning a vtype in a register.
5195
5196         * mini.c (mini_get_inst_for_method): Move the handling of the atomic operations
5197         here from the arch specific code.
5198
5199         * mini-amd64.c (mono_arch_get_inst_for_method): Remove code which is now in
5200         mini.c.
5201
5202         * mini-amd64.c (mono_arch_output_basic_block): Add some micro optimizations.
5203         (mono_arch_emit_prolog): Increment maximum prolog size.
5204
5205         * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Move the implementation of the
5206         START_HANDLER/ENDFINALLY/ENDFILTER opcodes to mini-amd64.c.
5207
5208         * mini-x86.c (get_call_info): Receive a MonoCompile instead of a 
5209         MonoGenericSharingContext.
5210
5211         * mini-ia64.c (get_call_info): Receive a MonoCompile instead of a 
5212         MonoGenericSharingContext. Allocate memory from the cfg mempool.
5213
5214 2007-11-15  Mark Probst  <mark.probst@gmail.com>
5215
5216         * mini.c, mini.h, generic-sharing.c: Functions for producing code
5217         which extract fields out of the runtime generic context.  Full
5218         sharing of the NEWARR opcode.
5219
5220 Thu Nov 15 14:20:21 CET 2007 Paolo Molaro <lupus@ximian.com>
5221
5222         * abcremoval.c, mini.c, ssa.c, ssapre.c: updated to implement
5223         --enable-minimal=ssa.
5224
5225 2007-11-13  Zoltan Varga  <vargaz@gmail.com>
5226
5227         * mini-trampolines.c (mono_delegate_trampoline): Update after 
5228         mono_marshal_get_delegate_invoke () signature change.
5229
5230 2007-11-13  Mark Probst  <mark.probst@gmail.com>
5231
5232         * mini.c: Removed the shared context in favor of the generic
5233         sharing context.  Allocate the MonoJitInfo structure with room for
5234         the generic sharing context if it's needed.
5235
5236         * mini.h: Remove MonoGenericSharingContext declaration.  It's in
5237         domain-internals.h now.
5238
5239         * mini-x86.c: Pass the generic sharing context to get_call_info ().
5240
5241         * generic-sharing.c: Several changes for working without a shared
5242         context and instead operating on open types instead.
5243
5244 2007-11-12  David S. Miller  <davem@davemloft.net>
5245
5246        * inssel-sparc.brg: Fix double instruction emit.
5247
5248 2007-11-12  Zoltan Varga  <vargaz@gmail.com>
5249
5250         * mini.c (mono_jit_runtime_invoke): Avoid trying to compile the Array 
5251         Get/Set/Address methods.
5252         
5253         * mini.c debug-debugger.c mini-trampolines.c: Update after 
5254         mono_marshal_get_delegate_invoke signature change.
5255
5256 2007-11-12  Rodrigo Kumpera  <rkumpera@novell.com>
5257
5258         * cpu-arm.md: Increase the max size of OP_THROW to 24 bytes.
5259         This can happens with dynamic methods. Fixes the other bug in #322722.
5260
5261 2007-11-12  Rodrigo Kumpera  <rkumpera@novell.com>
5262
5263         * tramp-arm.c (mono_arch_patch_callsite): Support patching
5264         BX call sequence.
5265
5266         * mini-arm.c (arm_patch): Implement patching of BX call
5267         sequence. Fixes one of the bugs in #322722.
5268
5269 2007-11-03  David S. Miller  <davem@huronp11.davemloft.net>
5270
5271        * mini-sparc.c (mono_arch_flush_icache): Make more efficient
5272        under Linux.  We only need to flush every 32-byte cache line.    
5273
5274 2007-11-07  Massimiliano Mantione  <massi@ximian.com>
5275
5276         * mini.c:
5277         move_basic_block_to_end: Add branches when needed, eventually creating
5278         a new BB.
5279         optimize_branches: added a parameter that tells if it's ok to create
5280         new BBs (doing is "df_visit" has been called is (IMHO) a nightmare),
5281         and avoid calling move_basic_block_to_end when it's not ok.
5282         Fixes bug 318677.
5283
5284 2007-11-07  Mark Probst  <mark.probst@gmail.com>
5285
5286         * mini.c: Abort inlining call to InitializeArray if something
5287         looks wrong.  Let the icall handle it, which now has proper safety
5288         checks.
5289
5290 2007-11-05  Rodrigo Kumpera  <rkumpera@novell.com>
5291
5292         * mini.c (mono_spill_call): add support for soft-float.
5293
5294         * mini.c (mono_method_to_ir): add support for soft-float
5295         to inlined functions that return float.
5296
5297         * mini.c (mono_method_to_ir): add support for soft-float
5298         to cee_stsfld opcode on float fields.
5299
5300 2007-11-05  Geoff Norton  <gnorton@novell.com>
5301
5302         * mini-x86.h: Fix the structure access for X86 Leopard.
5303
5304
5305 2007-11-05  Martin Baulig  <martin@ximian.com>
5306
5307         * mini-trampolines.c
5308         (mono_magic_trampoline): Call mono_debugger_trampoline_compiled()
5309         after compiling the method to notify the debugger.
5310
5311 2007-11-05  Martin Baulig  <martin@ximian.com>
5312
5313         * debug-debugger.h (MonoDebuggerInfo): Use the new breakpoint tables.
5314
5315 2007-11-02  Zoltan Varga  <vargaz@gmail.com>
5316
5317         * mini-sparc.c (EMIT_COND_SYSTEM_EXCEPTION_GENERAL): Applied patch from
5318         David Miller <davem@davemloft.net>. Allow larger offsets in branches.
5319
5320 2007-11-01  Zoltan Varga  <vargaz@gmail.com>
5321
5322         * mini-amd64.c (mono_arch_emit_prolog): Check the domain as well for
5323         native-to-managed wrappers.
5324         
5325 2007-11-01  Geoff Norton  <gnorton@novell.com>
5326
5327         * mini-ppc.h, mini-x86.h:  Handle Leopards renaming of some structure 
5328         members.
5329
5330 Wed Oct 31 20:23:14 CET 2007 Paolo Molaro <lupus@ximian.com>
5331
5332         * mini.c, mini-x86.c: when getting back from unmanaged code
5333         to managed via a marshaled delegate we also need to set the
5334         right domain.
5335
5336 Wed Oct 31 19:53:33 CET 2007 Paolo Molaro <lupus@ximian.com>
5337
5338         * mini-amd64.c, mini-amd64.h, tramp-amd64.c: breakpoint table support
5339         for amd64.
5340
5341 Wed Oct 31 19:29:30 CET 2007 Paolo Molaro <lupus@ximian.com>
5342
5343         * mini.c, mini.h, mini-x86, tramp-x86.c, mini-x86.h: added API to
5344         let the debugger or other external agents to tell the JIT when
5345         a sw breakpoint has been inserted in the code that the JIT needs
5346         to be able to inspect.
5347
5348 2007-10-31  Martin Baulig  <martin@ximian.com>
5349
5350         * debug-debugger.h
5351         (MonoDebuggerInfo): Remove `runtime_class_init'.
5352
5353 2007-10-30  Martin Baulig  <martin@ximian.com>
5354
5355         * debug-mini.h
5356         (mono_debugger_thread_created): Added `MonoThread *' argument.
5357         (mono_debugger_extended_notification): New public method.
5358         (mono_debugger_trampoline_compiled): New public method.
5359
5360         * debug-mini.c
5361         (MonoDebuggerThreadInfo): Added `thread' and
5362         `extended_notifications' fields.
5363
5364         * debug-debugger.c
5365         (debugger_executable_code_buffer): New static variable.
5366
5367         * debug-debugger.h
5368         (MonoDebuggerInfo): Added `executable_code_buffer',
5369         `executable_code_buffer_size', `breakpoint_info_area',
5370         `breakpoint_table' and `breakpoint_table_size'.
5371
5372 2007-10-26  Rodrigo Kumpera  <rkumpera@novell.com>
5373
5374         * mini-arm.c (mono_arch_build_imt_thunk): Take the advantage
5375         that IP  either is an unused value or the vtable pointer. IMT 
5376         calls use vtable + offset now. Reduced by almost half the size
5377         of IMT entries.
5378
5379 2007-10-26  Jonathan Chambers <joncham@gmail.com>
5380
5381         * mini-amd64.c: Begin Win64 port. Use AMD64_ARG_REG#
5382         defines to access param registers. Replace long usage with
5383         gsize as sizeof(long) != sizeof(void*) on Win64.
5384
5385         * mini-amd64.h: Add %rdi and %rsi to MonoLMF structure
5386         on Win64. Fix intrinsic, use _AddressOfReturnAddress
5387         instead of non-existant _GetAddressOfReturnAddress.
5388
5389         * tramp-amd64.c: Use AMD64_ARG_REG#     defines to access 
5390         param registers. Save/restore %rdi and %rsi in MonoLMF.
5391
5392         * exceptions-amd64.c: Use AMD64_ARG_REG# defines to access 
5393         param registers. Modify (throw_exception) signature to take 
5394         %rdi and %rsi on Win64. 
5395
5396         Code is contributed under MIT/X11 license.
5397
5398 Thu Oct 25 23:06:58 CEST 2007 Paolo Molaro <lupus@ximian.com>
5399
5400         * helpers.c: unlink debugging output files.
5401
5402 2007-10-25  Zoltan Varga  <vargaz@gmail.com>
5403
5404         * mini.c: Move mono_create_ftnptr () to object.c.
5405
5406 2007-10-24  Rodrigo Kumpera  <rkumpera@novell.com>
5407
5408         * helpers.c (mono_disassemble_code): MonoCompile parameter is now
5409         optional. This function can now be used to disassemble code generated
5410         outside the JIT such as trampolines and IMT thunks.
5411
5412         * mini-arm.h: defined MONO_ARCH_HAVE_IMT.
5413
5414         * mini-arm.c (decode_vcall_slot_from_ldr): added, extract the
5415         vtable pointer from a ldr instruction.
5416
5417         * mini-arm.c (mono_arch_get_vcall_slot_addr): support the
5418         new IMT call sequence.
5419
5420         * mini-arm.c (mono_arch_output_basic_block): emit the IMT
5421         call sequence for interface invocations.
5422
5423         * mini-arm.c (mono_arch_emit_imt_argument): added, required
5424         for imt support. This function is empty since IMT on ARM requires no
5425         special handling on the IR side.
5426
5427         * mini-arm.c (mono_arch_find_imt_method): added, required for
5428         imt support.
5429
5430         * mini-arm.c (mono_arch_find_this_argument): added, required
5431         for imt support.
5432
5433         * mini-arm.c (arm_emit_value_and_patch_ldr): added, patches
5434         a ldr instruction to load a value stored in the code stream.
5435
5436         * mini-arm.c (mono_arch_build_imt_thunk):added, required
5437         for imt support.
5438
5439
5440 2007-10-23  Zoltan Varga  <vargaz@gmail.com>
5441
5442         * mini.c (mini_init): Install the jump trampoline callback.
5443
5444 Tue Oct 23 17:07:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
5445
5446         * mini-trampolines.c: handle synchronized methods with the common
5447         vtable trampoline (bug #335601).
5448
5449 2007-10-17  Zoltan Varga  <vargaz@gmail.com>
5450
5451         * mini-ia64.h mini-amd64.c: Add support for the common vtable trampoline.
5452
5453         * inssel.brg (mini_emit_virtual_call): Fix the computation of ins->inst_offset on
5454         64 bit platforms.
5455
5456         * mini-ia64.h mini-ia64.c: Add support for IMT.
5457
5458         * mini-x86.c (mono_arch_emit_prolog): Increase the size allocated for the
5459         prolog. Fixes #331958.
5460
5461 2007-10-15  Zoltan Varga  <vargaz@gmail.com>
5462
5463         * mini-sparc.h mini-sparc.c: Add support for the common vtable trampoline.
5464
5465 Mon Oct 15 11:18:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
5466
5467         * mini-ppc.c, mini-ppc.h: ppc support for the common vtable
5468         trampoline.
5469
5470 Mon Oct 15 10:41:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
5471
5472         * mini-amd64.c, mini-amd64.h: amd64 support for the common vtable
5473         trampoline.
5474
5475 Mon Oct 15 10:39:26 CEST 2007 Paolo Molaro <lupus@ximian.com>
5476
5477         * mini-x86.c, mini-x86.h: x86 support for the common vtable
5478         trampoline.
5479
5480 Mon Oct 15 10:37:15 CEST 2007 Paolo Molaro <lupus@ximian.com>
5481
5482         * mini-trampolines.c: changed the magic rampoline to understand
5483         the common vtable trampoline method: the method to invoke is
5484         determined by the vtable displacement of the call.
5485
5486 Mon Oct 15 10:35:12 CEST 2007 Paolo Molaro <lupus@ximian.com>
5487
5488         * mini.c, mini.h: register the common vtable trampoline if the
5489         architecture supports it.
5490
5491 Mon Oct 15 09:50:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
5492
5493         * cpu-amd64.md: use the correct max length for tls_get.
5494
5495 2007-10-14  Zoltan Varga  <vargaz@gmail.com>
5496
5497         * mini.c (mono_method_to_ir): Use mini_get_class in CEE_LDELEM_ANY and
5498         CEE_STELEM_ANY. Fixes #333696.
5499
5500 Thu Oct 11 18:04:29 CEST 2007 Paolo Molaro <lupus@ximian.com>
5501
5502         * exceptions-x86.c: provide more graceful handling of the case where
5503         we followed a bogus function pointer from managed code (bug #332866).
5504
5505 2007-10-11  Mark Probst  <mark.probst@gmail.com>
5506
5507         * mini.h, mini.c: Introduced the MonoGenericSharingContext, which
5508         replaces the generic_shared flag and will carry more information
5509         in the future.
5510
5511         * generic-sharing.c: Added mini_type_stack_size() which allows
5512         allows open types if given a generic sharing context.
5513         mini_get_basic_type_from_generic() takes a
5514         MonoGenericSharingContext* instead of a MonoCompile* now.
5515
5516         * mini-alpha.c, mini-amd64.c, mini-arm.c, mini-hppa.c,
5517         mini-ia64.c, mini-mips.c, mini-ppc.c, mini-s390.c, mini-s390x.c,
5518         mini-sparc.c, mini-x86.c: Trivial changes required by the two
5519         changes above.  Just passing arguments through to the right
5520         places.
5521
5522 Wed Oct 10 19:44:42 CEST 2007 Paolo Molaro <lupus@ximian.com>
5523
5524         * mini-arm.c: unify the call emission to emit_code_seq().
5525
5526 Wed Oct 10 13:05:46 CEST 2007 Paolo Molaro <lupus@ximian.com>
5527
5528         * tramp-arm.c: reduced the trampoline size.
5529
5530 2007-10-10  Mark Probst  <mark.probst@gmail.com>
5531
5532         * generic-sharing.c, mini.h, mini-amd64.c, mini-x86.c: Moved type
5533         variable handling out of arch-specific code.
5534
5535 Wed Oct 10 10:49:28 CEST 2007 Paolo Molaro <lupus@ximian.com>
5536
5537         * mini-arm.c: implemented fast delegate dispatch.
5538
5539 2007-10-09  Zoltan Varga  <vargaz@gmail.com>
5540
5541         * mini-amd64.c (mono_arch_compute_omit_fp): Add more checks to ensure
5542         that fp elimination is turned off if the space required by locals is too
5543         big. Fixes #331958.
5544
5545 Tue Oct 9 21:01:03 CEST 2007 Paolo Molaro <lupus@ximian.com>
5546
5547         * Makefile.am, mini-arm.c, mini-arm.h, tramp-arm.c: ported
5548         ARM to the new style trampoline.
5549
5550 2007-10-09  Zoltan Varga  <vargaz@gmail.com>
5551
5552         * tramp-amd64.c: Rework the specific trampoline code to make it smaller.
5553
5554         * mini-amd64.h mini-amd64.c: Export amd64_patch as mono_amd64_patch.
5555
5556 2007-10-09  Martin Baulig  <martin@ximian.com>
5557
5558         * debug-debugger.h
5559         (MonoDebuggerMetadataInfo): Added `field_info_type_offset' and
5560         `field_info_offset_offset'.     
5561
5562 Tue Oct 9 09:47:51 CEST 2007 Paolo Molaro <lupus@ximian.com>
5563
5564         * mini-ppc.c, mini-ppc.h, mini-ops.h, inssel-ppc.brg, cpu-g4.md:
5565         removed more internal usage of the r11 register and made it available
5566         to the register allocator.
5567
5568 2007-10-08  Mark Probst  <mark.probst@gmail.com>
5569
5570         * mini.c, mini-amd64.c, mini-x86.c: Allow open generic contexts
5571         when sharing generics and treat type variables as references.
5572
5573 Mon Oct 8 10:55:38 CEST 2007 Paolo Molaro <lupus@ximian.com>
5574
5575         * mini-ppc.c: started removing the internal uses of register r11
5576         to eventually allow the register allocator to manage it as an
5577         additional available register.
5578
5579 Mon Oct 8 14:25:39 CEST 2007 Paolo Molaro <lupus@ximian.com>
5580
5581         * tramp-amd64.c: fixed memory corruption in the trampoline generation.
5582
5583 Mon Oct 8 12:06:33 CEST 2007 Paolo Molaro <lupus@ximian.com>
5584
5585         * tramp-ppc.c, tramp-x86.c: reduce the alignment requirements for
5586         specific trampolines as they are not performance critical as a jump
5587         target (maybe align as before only for AOT code?). This saves about
5588         200 KB of native code on x86 for monodevelop startup.
5589
5590 Mon Oct 8 10:04:40 CEST 2007 Paolo Molaro <lupus@ximian.com>
5591
5592         * tramp-ppc.c: reduce the size of the trampolines, saves 160KB on
5593         monodevelop startup.
5594
5595 2007-10-06  Zoltan Varga  <vargaz@gmail.com>
5596
5597         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Allow signed displacements.
5598
5599         * mini-sparc.h mini-sparc.c: Implement IMT support.
5600
5601         * tramp-sparc.c (mono_arch_create_trampoline_code): Rework the trampoline code so
5602         its smaller and doesn't clobber sparc_g1.
5603
5604         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Update after trampoline changes.
5605
5606 Fri Oct 5 18:28:11 CEST 2007 Paolo Molaro <lupus@ximian.com>
5607
5608         * mini-ppc.c: optimized the size of the IMT thunks a bit.
5609
5610 Fri Oct 5 18:08:30 CEST 2007 Paolo Molaro <lupus@ximian.com>
5611
5612         * mini-ppc.c: implemented fast delegate invocation.
5613
5614 Fri Oct 5 00:01:05 CEST 2007 Paolo Molaro <lupus@ximian.com>
5615
5616         * mini-ppc.h, mini-ppc.c: IMT support for the PPC architecture.
5617
5618 Thu Oct 4 22:04:49 CEST 2007 Paolo Molaro <lupus@ximian.com>
5619
5620         * mini-ppc.c, mini-ppc.h, tramp-ppc.c, Makefile.am: port the PPC
5621         code to the new style trampoline in preparation for IMT support.
5622
5623 Thu Oct 4 19:01:59 CEST 2007 Paolo Molaro <lupus@ximian.com>
5624
5625         * mini-ppc.c, tramp-ppc.c: don't use r13 as it's used by the PPC EABI
5626         systems already. This also reduces the specific trampiline sizes and
5627         prepares for the use of r12 as the IMT identifier register.
5628
5629 Thu Oct 4 16:38:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
5630
5631         * mini-mips.h: endianess fix (simplified from a patch by
5632         Thomas Kunze <thommy@tabao.de>, bug #323737).
5633
5634 Thu Oct 4 14:43:49 CEST 2007 Paolo Molaro <lupus@ximian.com>
5635
5636         * exceptions-ppc.c, mini-ppc.h: refactor to use macros
5637         to access ucontext fields and enable netbsd support
5638         (partially from Magnus Henoch <mange@freemail.hu>).
5639
5640 Thu Oct 4 12:35:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
5641
5642         * genmdesc.pl: patch from Henryk Plötz <henryk@openmoko.org> to
5643         use the preprocessor from the CPP env var if it is set.
5644
5645 Wed Oct 3 17:11:38 CEST 2007 Paolo Molaro <lupus@ximian.com>
5646
5647         * mini-trampolines.c: fixed an assertion and moved it earlier in the
5648         code, before interface_offset gets used.
5649
5650 2007-10-02  Zoltan Varga  <vargaz@gmail.com>
5651
5652         * mini-trampolines.c (mono_convert_imt_slot_to_vtable_slot): Call 
5653         mono_class_setup_vtable () before accessing klass->vtable.
5654
5655 2007-10-01  Zoltan Varga  <vargaz@gmail.com>
5656
5657         * aot-compiler.c (get_plt_index): Rework the handling of wrappers to be not so
5658         hackish.
5659
5660 Mon Oct 1 15:00:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
5661
5662         * mini.c, mini-trampolines.c, mini.h: enable the lazy filling of the
5663         IMT slots (this saves hundreds of KB of memory in programs like
5664         IronPython and Monodevelop).
5665
5666 Mon Oct 1 14:44:19 CEST 2007 Paolo Molaro <lupus@ximian.com>
5667
5668         * mini.c: print the delegate counter.
5669
5670 Mon Oct 1 14:36:50 CEST 2007 Paolo Molaro <lupus@ximian.com>
5671
5672         * mini-x86.c: make it easier to enable the debugging code for IMT
5673         slots.
5674
5675 2007-09-28  Martin Baulig  <martin@ximian.com>
5676
5677         * debug-debugger.h
5678         (MonoDebuggerMetadataInfo): Add `klass_image_offset',
5679         `mono_method_klass_offset' and `mono_method_token_offset'.
5680
5681 2007-09-20  Mark Probst  <mark.probst@gmail.com>
5682
5683         * mini.c: First generics sharing implementation.  Can only share
5684         in very simple cases.  If sharing doesn't work it falls back to
5685         dedicated compilation.
5686
5687         * mini.h: Flag in MonoCompile to specify whether generic
5688         compilation is shared.  Flags enum for marking which generic inst
5689         of a context is used.  Prototypes for helper functions.
5690
5691         * generic-sharing.c: Helper functions for generic method sharing.
5692
5693         * optflags-def.h: Optimization flag (gshared) for enabling generic
5694         method sharing added.
5695
5696         * Makefile.am: generic-sharing.c added.
5697
5698 2007-09-19 Daniel Nauck <dna@mono-project.de>
5699
5700         * mini.c (mono_thread_abort): fixed typo in r86014. It should be '==' instead of '!='.
5701
5702 2007-09-19  Massimiliano Mantione  <massi@ximian.com>
5703         * mini.c (mono_thread_abort): Correctly handle ThreadAbortException,
5704         fixes bug 325507.
5705
5706 2007-09-19  Martin Baulig  <martin@ximian.com>
5707
5708         * mini.c (mini_cleanup): Only call mono_debugger_cleanup() here;
5709         mono_debug_cleanup() is now part of mono_cleanup().
5710
5711 2007-09-18  Zoltan Varga  <vargaz@gmail.com>
5712
5713         * driver.c (mono_main): Fix a warning.
5714
5715 2007-09-17  Zoltan Varga  <vargaz@gmail.com>
5716
5717         * aot-compiler.c: Optimize various parts when processing large assemblies.
5718         Fixes ##325568.
5719
5720         * mini.c (mono_patch_info_hash): Improve hash function.
5721
5722 2007-09-14  Jonathan Chambers <joncham@gmail.com>
5723
5724         * mini-exceptions.c: Add HAVE_UNISTD_H check around include.
5725         
5726         Code is contributed under MIT/X11 license.
5727
5728 2007-09-14  Zoltan Varga  <vargaz@gmail.com>
5729
5730         * mini.c (mini_init): Fix a leak.
5731
5732         * debug-mini.c (mono_debug_free_method_jit_info): Fix a leak.
5733
5734 Fri Sep 14 12:53:13 CEST 2007 Paolo Molaro <lupus@ximian.com>
5735
5736         * mini.c: redirect string.InternalAllocStr() to the managed allocator.
5737
5738 2007-09-14  Zoltan Varga  <vargaz@gmail.com>
5739
5740         * mini-amd64.c (mono_arch_find_imt_method): Add support for AOT code.
5741
5742 2007-09-13  Zoltan Varga  <vargaz@gmail.com>
5743
5744         * Makefile.am generics-variant-types.2.il generics.cs: Add some generics
5745         variance tests.
5746
5747         * inssel.brg: Reorganize the isinst/castclass code to reduce code duplication.
5748
5749         * mini.c (handle_alloc): Enable managed allocators in AOT code.
5750
5751         * aot-compiler.c (encode_patch): Add support for MONO_WRAPPER_ALLOC.
5752
5753         * aot-runtime.c (decode_patch_info): Ditto.
5754
5755 2007-09-12  Jonathan Chambers <joncham@gmail.com>
5756
5757         * mini-x86.c (mono_arch_get_delegate_invoke_impl): Implement
5758         static case. Cache delegates in architecture specific code, 
5759         based on number of parameters.
5760         
5761         * mini-amd64.c (mono_arch_get_delegate_invoke_impl): Cache delegates
5762         in architecture specific code, based on number of parameters.
5763         
5764         * mini-trampolines.c (mono_delegate_trampoline): Architecture specific 
5765         caching happen in architecture specific code now.
5766         
5767         Code is contributed under MIT/X11 license.
5768
5769 2007-09-12  Jonathan Chambers <joncham@gmail.com>
5770
5771         * mini.h, mini.c, mini-x86.c, mini-amd64.c, mini-hppa.c, mini-mips.c,
5772         mini-s390x.c, mini-arm.c, mini-ia64.c, mini-sparc.c, mini-ppc.c, mini-alpha.c,
5773         mini-s390.c: Add mono_arch_init and mono_arch_cleanup methods.
5774
5775         Code is contributed under MIT/X11 license.
5776
5777 2007-05-15  Massimiliano Mantione  <massi@ximian.com>
5778         * mini.c: (mono_thread_abort) Fixed bug #82416.
5779
5780 Tue Sep 11 16:15:53 CEST 2007 Paolo Molaro <lupus@ximian.com>
5781
5782         * mini.: hook the new managed GC allocation feature into the JIT.
5783
5784 Tue Sep 11 16:14:16 CEST 2007 Paolo Molaro <lupus@ximian.com>
5785
5786         * mini.c: implementation for the new runtime tls opcode.
5787
5788 2007-09-11  Martin Baulig  <martin@ximian.com>
5789
5790         * debug-debugger.h
5791         (MonoDebuggerMetadataInfo): Add `mono_method_flags_offset' and
5792         `mono_method_inflated_offset'.
5793
5794 2007-09-07  Zoltan Varga  <vargaz@gmail.com>
5795
5796         * driver.c mini.h mini.c: Add a new devel command line option for injecting
5797         async exceptions into a method.
5798
5799         * mini-amd64.h mini-amd64.c: Implement injecting of async exceptions for the
5800         purpose of testing whenever the unwinder works at every instruction.
5801
5802 Thu Sep 6 12:42:14 CEST 2007 Paolo Molaro <lupus@ximian.com>
5803
5804         * mini.c: check accessibility of method used in ldftn (fixes
5805         bug #82635).
5806
5807 2007-09-04  Zoltan Varga  <vargaz@gmail.com>
5808
5809         * mini-amd64.c (mono_arch_output_basic_block): Fix a warning.
5810
5811         * inssel.brg: Fix a warning.
5812
5813 2007-09-03  Martin Baulig  <martin@ximian.com>
5814
5815         * debug-debugger.c: `MONO_DEBUGGER_EVENT_INITIALIZE_MANAGED_CODE'
5816         now takes the `main_method' as argument.
5817
5818 2007-09-02  Zoltan Varga  <vargaz@gmail.com>
5819
5820         * cpu-sparc.md (endfilter): Add missing src1:i argument.
5821
5822 2007-08-30  Jonathan Chambers <joncham@gmail.com>
5823
5824         * driver.c: include the cil-coff.h header on Windows.
5825         
5826         Code is contributed under MIT/X11 license.
5827
5828 Thu Aug 30 16:17:23 CEST 2007 Paolo Molaro <lupus@ximian.com>
5829
5830         * mini.c, driver.c: don't include the cil-coff.h header.
5831
5832 Thu Aug 30 14:50:53 CEST 2007 Paolo Molaro <lupus@ximian.com>
5833
5834         * mini.c: flag places that needs fixes fo soft-float support.
5835
5836 Wed Aug 29 18:26:20 CEST 2007 Paolo Molaro <lupus@ximian.com>
5837
5838         * mini.h, inssel-float.brg: fix soft-float constant loads on big
5839         endian systems (partially from Dean Jenkins, bug #81924).
5840
5841 2007-08-28  Mark Probst  <mark.probst@gmail.com>
5842
5843         * mini.c (check_linkdemand): Remove embedded reference object in
5844         call to LinkDemandSecurityException.
5845         (mono_jit_compile_method_inner): Call LinkDemandSecurityException
5846         with an IntPtr instead of a reference object.
5847
5848 2007-08-28  Zoltan Varga  <vargaz@gmail.com>
5849
5850         * mini.c (handle_initobj): Handle alignment properly.
5851
5852         * inssel.brg (mini_emit_memset): Ditto. 
5853
5854         * inssel.brg (mini_emit_memcpy): Ditto. 
5855
5856         * inssel-sparc.brg: Ditto.              
5857
5858         * mini.h mini.c inssel-*.brg: Pass alignment information to OP_MEMCPY/MEMSET.
5859
5860 2007-08-26  Zoltan Varga  <vargaz@gmail.com>
5861
5862         * mini-exceptions.c (mono_handle_exception_internal): Skip the first frame for
5863         exceptions raised in unmanaged code. Fixes part of #82594.
5864
5865 2007-08-24  Mark Probst  <mark.probst@gmail.com>
5866
5867         * mini.c (mono_method_to_ir), declsec.c
5868         (mono_declsec_linkdemand_aptc): Fixed custom attr leaks.
5869
5870 2007-08-22  Martin Baulig  <martin@ximian.com>
5871
5872         * debug-mini.h
5873         (MonoDebuggerThreadInfo): New typedef.
5874         (mono_debugger_thread_table): New global variable.
5875         (mono_debugger_thread_created): New public function.
5876         (mono_debugger_thread_cleanup): New public function.
5877
5878         * debug-debugger.h
5879         (MonoDebuggerInfo):
5880         - removed `get_current_thread' and `lookup_assembly'.
5881         - removed `data_table'.
5882         - added `thread_table'.
5883
5884         * mini.c
5885         (mono_thread_start_cb): Call mono_debugger_thread_created().
5886         (mono_thread_attach_cb): Likewise.
5887         (mini_thread_cleanup): Call mono_debugger_thread_cleanup().
5888         (mini_cleanup): Move mono_debug_cleanup() down, after free'ing the
5889         initial domain.
5890
5891         * driver.c (mono_main): Move mono_debug_init() up, before calling
5892         mini_init(); mono_debug_init_1() and mono_debug_init_2() are gone.
5893
5894 Tue Aug 21 16:40:04 CEST 2007 Paolo Molaro <lupus@ximian.com>
5895
5896         * mini-x86.c, inssel-x86.brg: group multiple stack adjustments
5897         together when passing several arguments of type double (gives a small
5898         speedup and saves a few bytes of generated code).
5899
5900 2007-08-20  Jb Evain  <jbevain@novell.com>
5901
5902         * mini.c (mono_method_to_ir): fix leak on InvalidProgramException.
5903
5904 2007-08-20  Jb Evain  <jbevain@novell.com>
5905
5906         * mini.c (mono_method_to_ir): throw MethodAccessException
5907         and FieldAccessException instead of InvalidProgramException.
5908
5909 2007-08-20  Mark Probst  <mark.probst@gmail.com>
5910
5911         * mini.c: CoreCLR security checks.
5912
5913         * mini.h: Removed MonoSecurityMode (moved to
5914         metadata/security-manager.h) and mono_security_mode global var
5915         (replaced by set/get functions in security-manager.h).
5916
5917         * driver.c: Added "core-clr-test" security mode for testing.  Used
5918         set-function for setting security mode.
5919
5920 2007-08-17  Mark Probst  <mark.probst@gmail.com>
5921
5922         * mini.c: MonoJitInfo's are freed hazardously now.  Statistics for
5923         the new jit_info_table.
5924
5925         * driver.c: Test code for the new jit_info_table (enabled by the
5926         define MONO_JIT_INFO_TABLE_TEST).
5927
5928 2007-08-14  Zoltan Varga  <vargaz@gmail.com>
5929
5930         * tramp-amd64.c (mono_arch_nullify_class_init_trampoline): Fix
5931         detection of call <REG> instruction sequence. Fixes build on freebsd.
5932
5933 2007-08-13  Zoltan Varga  <vargaz@gmail.com>
5934
5935         * mini-exceptions.c: Fix a warning.
5936
5937 2007-08-11  Zoltan Varga  <vargaz@gmail.com>
5938
5939         * exceptions-amd64.c (mono_arch_handle_altstack_exception): Enable the new
5940         stack overflow handling code on amd64 too.
5941
5942         * mini-exceptions.c (mono_setup_altstack): Make this use 
5943         mono_thread_get_stack_bounds ().
5944
5945         * mini-x86.h: Disable sigaltstack on solaris x86.
5946
5947 2007-08-10  Zoltan Varga  <vargaz@gmail.com>
5948
5949         * mini-exceptions.c (mono_setup_altstack): Enable this to work on solaris x86.
5950
5951 2007-08-10  Geoff Norton  <gnorton@customerdna.com>
5952
5953         * tramp-x86.c: Remove some unneeded alignment changes on Apple.  Fixes #82387.
5954
5955 2007-08-08  Zoltan Varga  <vargaz@gmail.com>
5956
5957         * mini-exceptions.c (mono_print_thread_dump): Enable this on amd64 too.
5958
5959         * mini-amd64.h (MONO_INIT_CONTEXT_FROM_FUNC): Fix a warning.
5960
5961 2007-08-03  Neale Ferguson <neale@sinenomine.net>
5962
5963         * mini-s390.c (add_general): Adjust offset calculation to take into account of rounding up
5964         due to alignment.
5965
5966 Thu Aug 2 17:36:22 CEST 2007 Paolo Molaro <lupus@ximian.com>
5967
5968         * mini-ppc.c: avoid an invalid encoding of unsigned right shift by 0
5969         to be emitted (bug #82281).
5970
5971 2007-08-01  Martin Baulig  <martin@ximian.com>
5972
5973         Merged the `debugger-dublin' branch.
5974
5975         * debug-debugger.h (MonoDebuggerInfo):
5976         Removed the `old_*' compatibility entries.
5977         Added `debugger_version' and `data_table'.
5978         Renamed `get_method_addr_or_bpt' -> `insert_breakpoint'.
5979         Renamed `remove_method_breakpoint' -> `remove_breakpoint'.
5980
5981         * debug-mini.c
5982         (MiniDebugMethodBreakpointInfo): Add `address_list'.
5983         (mono_debugger_check_breakpoints): Take a `MonoDebugMethodAddress *'
5984         instead of a `gconstpointer'.
5985         (mono_debugger_insert_method_breakpoint): Return a
5986         `MonoDebugMethodAddressList *'.
5987
5988 2007-06-28  Martin Baulig  <martin@ximian.com>
5989
5990         * debug-debugger.h (MonoDebuggerInfo): Added `debugger_version'.
5991
5992 2007-08-01  Zoltan Varga  <vargaz@gmail.com>
5993
5994         * mini-amd64.h (MONO_INIT_CONTEXT_FROM_FUNC): Avoid using 
5995         __builtin_frame_address () since it is broken on older gcc versions.
5996
5997 Tue Jul 31 17:34:42 CEST 2007 Paolo Molaro <lupus@ximian.com>
5998
5999         * mini.c, mini.h, mini-exceptions.c: added a bit of documentation
6000         on the stack overflow handling and made the managed stack overflows
6001         catchable in most cases using soft guard pages.
6002         * exceptions-x86.c: added code to restore the protection in the soft
6003         guard pages at the end of exception handling.
6004
6005 2007-07-31  Zoltan Varga  <vargaz@gmail.com>
6006
6007         * mini.c (SIG_HANDLER_SIGNATURE): Fix a warning.
6008
6009 Mon Jul 30 17:43:13 CEST 2007 Paolo Molaro <lupus@ximian.com>
6010
6011         * exceptions-ppc.c, mini-ppc.h: arch-specific stack overflow
6012         exception handling.
6013
6014 Mon Jul 30 17:38:13 CEST 2007 Paolo Molaro <lupus@ximian.com>
6015
6016         * mini-alpha.h, mini-ia64.h, mini-sparc.h: disable the altstack
6017         signal handling support until it has been ported to the new mechanism.
6018         * mini.c: fixed stack overflow detection and use the new
6019         architecture code  to handle signals on the altstack.
6020
6021 Mon Jul 30 17:33:02 CEST 2007 Paolo Molaro <lupus@ximian.com>
6022
6023         * exceptions-amd64.c, mini-amd64.h: amd64 code to handle
6024         stack overflows on the alt stack.
6025
6026 Mon Jul 30 17:29:56 CEST 2007 Paolo Molaro <lupus@ximian.com>
6027
6028         * exceptions-x86.c, mini-x86.h, mini.h: new code to handle
6029         stack overflows on the alt stack.
6030
6031 Mon Jul 30 11:50:06 CEST 2007 Paolo Molaro <lupus@ximian.com>
6032
6033         * exceptions-ppc.c: cleanup preparing for altstack support.
6034
6035 Mon Jul 30 11:31:24 CEST 2007 Paolo Molaro <lupus@ximian.com>
6036
6037         * exceptions-arm.c: cleanup preparing for altstack support.
6038
6039 2007-07-27  Mark Probst  <mark.probst@gmail.com>
6040
6041         * mini.c (print_jit_stats): Output hazard pointer stats.
6042
6043 2007-07-26  Mark Probst  <mark.probst@gmail.com>
6044
6045         * driver.c, mini.c: Replaced security mode flags with a single
6046         enum variable.
6047
6048 Thu Jul 26 20:12:12 CEST 2007 Paolo Molaro <lupus@ximian.com>
6049
6050         * mini.c, mini-exceptions.c: cleanup the sigaltstack code.
6051
6052 2007-07-25  Mark Probst  <mark.probst@gmail.com>
6053
6054         * mini.c, mini.h, driver.c (mono_main): Added command-line flag
6055         (which doesn't do anything yet) for activating Core CLR
6056         (Silverlight) security.
6057
6058 Tue Jul 24 21:16:17 CEST 2007 Paolo Molaro <lupus@ximian.com>
6059
6060         * mini-codegen.c: work around a possible gcc bug on arm.
6061
6062 Tue Jul 24 17:20:19 CEST 2007 Paolo Molaro <lupus@ximian.com>
6063
6064         * driver.c, mini-x86.h, mini-amd64.h: print a nice error
6065         message for platforms that don't support AOT compilation.
6066
6067 Mon Jul 23 10:29:29 CEST 2007 Paolo Molaro <lupus@ximian.com>
6068
6069         * mini.h, mini.c, driver.c: temporary smcs hack.
6070
6071 Mon Jul 23 09:29:34 CEST 2007 Paolo Molaro <lupus@ximian.com>
6072
6073         * mini-arm.h, mini-arm.c: arm EABI fixes.
6074
6075 2007-07-22  Zoltan Varga  <vargaz@gmail.com>
6076
6077         * exceptions-x86.c (mono_arch_find_jit_info): Handle the lmf->method == NULL
6078         case.
6079
6080         * tramp-x86.c (mono_arch_create_trampoline_code): Only set lmf->method for
6081         trampolines taking a method argument.
6082
6083         * mini-x86.h (MonoLMF): Add an 'esp' field plus comments.
6084
6085         * mini-x86.c (mono_arch_emit_prolog): Update after changes to the LMF structure.
6086         * tramp-x86.c (mono_arch_create_trampoline_code): Ditto.
6087
6088         * exceptions-x86.c (mono_arch_get_jit_info): Properly clean up the stack after
6089         JIT compilation throws an exception. Fixes #82050.
6090
6091 2007-07-19  Mark Probst  <mark.probst@gmail.com>
6092
6093         * mini.c: Removed the MonoLoaderErrorKind enum and replaced it
6094         with the MONO_EXCEPTION_ defines.
6095
6096 2007-07-17  Zoltan Varga  <vargaz@gmail.com>
6097
6098         * mini-amd64.c (mono_arch_find_imt_method): Handle mov reg,IMM64 case. Fixes
6099         #82117.
6100         
6101         * mini-amd64.c (mono_arch_find_imt_method): Add some debug code to help find out
6102         the cause of an assertion.
6103
6104 Mon Jul 16 19:31:21 CEST 2007 Paolo Molaro <lupus@ximian.com>
6105
6106         * mini.c, jit-icalls.c: mono_get_inflated_method() is obsolete,
6107         removed.
6108
6109 2007-07-15  Zoltan Varga  <vargaz@gmail.com>
6110
6111         * mini-amd64.c (mono_arch_build_imt_thunk): Remove the non-32bit MonoMethod
6112         assert. Should fix #82103.
6113
6114 2007-07-14  Zoltan Varga  <vargaz@gmail.com>
6115
6116         * mini-exceptions.c (mono_jit_walk_stack_from_ctx): Use MONO_CONTEXT_GET_SP ()
6117         here too. Fixes #82095.
6118
6119         * mini-amd64.c (mono_arch_build_imt_thunk): Add support for non-32bit MonoMethod
6120         addresses.
6121
6122         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add a couple asserts.
6123
6124         * mini-amd64.h: Enable IMT for amd64.
6125         
6126         * mini-amd64.c (mono_arch_build_imt_thunk): Optimize IMT thunk size.
6127
6128 2007-07-12  Zoltan Varga  <vargaz@gmail.com>
6129
6130         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add support for IMT call sequences.
6131
6132 2007-07-12  Mark Probst  <mark.probst@gmail.com>
6133
6134         * mini.c (check_linkdemand, mono_method_to_ir): Abort compilation
6135         as soon as check_linkdemand sets an exception_type.
6136
6137 Thu Jul 12 12:18:22 CEST 2007 Paolo Molaro <lupus@ximian.com>
6138
6139         * mini-x86.c: fixed offsets for IMT call sequence.
6140         * mini-x86.h: enable IMT again.
6141
6142 2007-07-11  Zoltan Varga  <vargaz@gmail.com>
6143
6144         * trace.c (mono_trace_enter_method): Decode MonoType too.
6145
6146         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Handle signed displacements too.
6147
6148         * mini.h mini-x86.h mini-trampolines.c: Change the signature of mono_arch_find_imt_method () to pass the calling code address too.
6149
6150         * mini-amd64.c: Add preliminary IMT implementation.
6151         
6152 Wed Jul 11 18:21:30 CEST 2007 Paolo Molaro <lupus@ximian.com>
6153
6154         * mini-x86.c: adjusted mono_arch_get_vcall_slot_addr () to
6155         understand the new IMT-base interface invocation (thanks to
6156         Daniel Nauck for the report and the remote debugging session).
6157
6158 Wed Jul 11 14:54:39 CEST 2007 Paolo Molaro <lupus@ximian.com>
6159
6160         * mini-x86.c: size and speed optimizations for the IMT bsearch.
6161
6162 2007-07-11  Zoltan Varga  <vargaz@gmail.com>
6163
6164         * Makefile.am (aotcheck): Make this actually use the AOTed code.
6165
6166 Wed Jul 11 12:41:32 CEST 2007 Paolo Molaro <lupus@ximian.com>
6167
6168         * mini-trampolines.c: implement AOT IMT support.
6169         * mini-x86.h: enable IMT support for wider testing.
6170
6171 2007-07-10  Zoltan Varga  <vargaz@gmail.com>
6172
6173         * inssel.brg (emit_imt_argument): Add aot support here.
6174
6175         * aot-runtime.c (decode_patch_info): Fix reading of MONO_PATCH_INFO_METHOD.
6176
6177 Tue Jul 10 17:50:58 CEST 2007 Paolo Molaro <lupus@ximian.com>
6178
6179         * mini-x86.c, mini-x86.h, tramp-x86.c: x86 arch-specific changes
6180         of the IMT implementation, partially from massi, with my
6181         implementation of the bsearch sequence. Disabled by default until
6182         the AOT code is implemented.
6183
6184 2007-07-10  Zoltan Varga  <vargaz@gmail.com>
6185
6186         * cpu-x86.md: The source argument of sext_i1/i2 must by a byte reg.
6187
6188         * inssel-x86.brg: Add reg:ldind.i1(regvar) rules. Fixes #82056.
6189
6190 Tue Jul 10 17:33:12 CEST 2007 Paolo Molaro <lupus@ximian.com>
6191
6192         * inssel.brg, mini.c, mini.h, mini-trampolines.c:
6193         arch-independent IMT JIT code from Massimiliano
6194         Mantione (massi@ximian.com) with small cleanups from me.
6195
6196 Tue Jul 10 13:07:24 CEST 2007 Paolo Molaro <lupus@ximian.com>
6197
6198         * Makefile.am: fix svn invocation to get the svn revision to be
6199         independent of the local language (build fix).
6200
6201 2007-07-09  Mark Probst  <mark.probst@gmail.com>
6202
6203         * mini.c (inline_method): Reset cfg->exception_type if the
6204         inlining is aborted.  Fixes: 82049.
6205
6206 Mon Jul 9 17:26:47 CEST 2007 Paolo Molaro <lupus@ximian.com>
6207
6208         * mini.c: remove assert from exception handling code when exception_ptr
6209         is not set.
6210
6211 2007-07-05  Zoltan Varga  <vargaz@gmail.com>
6212
6213         * mini.c (mono_codegen): Add an assert.
6214
6215         * mini-x86.c (mono_arch_emit_prolog): Allocate space for the profiler method 
6216         enter and leave code.
6217         * mini-amd64.c (mono_arch_emit_prolog): Likewise.
6218
6219 Thu Jul 5 20:12:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
6220
6221         * mini-ppc.c: fixed memory corruption for localloc(0)
6222         (bug #81852).
6223
6224 2007-07-05  Zoltan Varga  <vargaz@gmail.com>
6225         
6226         * mini.c: Fix warnings.
6227
6228 Wed Jul 4 15:30:36 CEST 2007 Paolo Molaro <lupus@ximian.com>
6229
6230         * optflags-def.h, mini-x86.c: added sse2 optimization flag and use it
6231         to emit better double->int conversions.
6232
6233 Tue Jul 3 19:42:16 CEST 2007 Paolo Molaro <lupus@ximian.com>
6234
6235         * mini.c: the provided Min/Max optimizations are valid for unisgned
6236         ints.
6237
6238 2007-07-03  Rodrigo Kumpera  <rkumpera@novell.com>
6239
6240         * 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
6241
6242 2007-06-28  Miguel de Icaza  <miguel@novell.com>
6243
6244         * mini.c (mono_running_on_valgrind): Add support for reporting the
6245         method and  its boundaries to valgrind.
6246
6247 2007-06-28  Martin Baulig  <martin@ximian.com>
6248
6249         * debug-debugger.h (MonoDebuggerInfo): Added `debugger_version'.
6250
6251 2007-06-25  Zoltan Varga  <vargaz@gmail.com>
6252
6253         * ssa.c (visit_inst): Add support for OP_BR. Fixes #81946.
6254
6255         * generic.2.cs: Add new test case.
6256
6257 2007-06-25  Martin Baulig  <martin@ximian.com>
6258
6259         Merged the `debugger-dublin' branch.
6260
6261         * debug-mini.c
6262         (mono_debugger_insert_method_breakpoint): New public method.
6263         (mono_debugger_remove_method_breakpoint): Likewise.
6264         (mono_debugger_check_breakpoints): New static method.
6265         (mono_debug_close_method): Call mono_debugger_check_breakpoints().
6266
6267         * debug-debugger.h (MonoDebuggerInfo):
6268         Renamed (to keep backward compatibility in the vtable):
6269         `insert_breakpoint' -> `old_insert_breakpoint'.
6270         `remove_breakpoint' -> `old_remove_breakpoint'.
6271         `create_string' -> `old_create_string'.
6272         `lookup_class' -> `old_lookup_class'.
6273         `lookup_type' -> removed; changed into a dummy field.
6274         `lookup_assembly' -> `old_lookup_assembly'.
6275         Added (same functionality, but different signature):
6276         `create_string', `lookup_class', `lookup_assembly'
6277         Added new:
6278         `get_method_addr_or_bpt', `remove_method_breakpoint',
6279         `runtime_class_init'.
6280
6281         * debug-debugger.c: Merged the `debugger-dublin' branch.
6282
6283 2007-06-23  Zoltan Varga  <vargaz@gmail.com>
6284
6285         * mini-amd64.c (peephole_pass_1): Optimize away moves at the beginning of the bb as
6286         well.
6287         (peephole_pass): Likewise.
6288
6289 Fri Jun 22 09:17:08 CEST 2007 Paolo Molaro <lupus@ximian.com>
6290
6291         * driver.c: hopefully make setaffinity work also for ancient
6292         versions of linux.
6293
6294 2007-06-22  Atsushi Enomoto  <atsushi@ximian.com>
6295
6296         * driver.c : win32 build fix.
6297
6298 Thu Jun 21 19:24:03 CEST 2007 Paolo Molaro <lupus@ximian.com>
6299
6300         * driver.c: check for the MONO_NO_SMP env var and bind to a single
6301         processor if it is set.
6302
6303 2007-06-21  Martin Baulig  <martin@ximian.com>
6304
6305         * debug-mini.h: New file.
6306
6307         * debug-mini.c
6308         (mono_debugger_insert_breakpoint_full): Moved here from
6309         ../metadata/mono-debug-debugger.c.
6310         (mono_debugger_remove_breakpoint): Likewise.
6311         (mono_debugger_breakpoint_callback): Likewise.
6312
6313 2007-06-15  Raja R Harinath  <rharinath@novell.com>
6314
6315         * jit-icalls.c (mono_helper_compile_generic_method): Update to
6316         changes in MonoGenericClass.
6317
6318 2007-06-14  Zoltan Varga  <vargaz@gmail.com>
6319
6320         * mini-codegen.c (mono_opcode_to_type): Fix ia64 build.
6321
6322 2007-06-14  Raja R Harinath  <rharinath@novell.com>
6323
6324         * jit-icalls.c (mono_helper_compile_generic_method): Update to
6325         removal of MonoGenericMethod.
6326
6327 Thu Jun 14 12:42:04 CEST 2007 Paolo Molaro <lupus@ximian.com>
6328
6329         * mini-exceptions.c: hooks for the exception events profiling API.
6330
6331 2007-06-14  Randolph Chung  <tausq@debian.org>
6332
6333         * Makefile.ma: Add hppa target.
6334         * mini-arch.h: Include mini-hppa.h
6335         * cpu-hppa.md, exceptions-hppa.c, inssel-hppa.brg, mini-hppa.c,
6336         mini-hppa.h, tramp-hppa.c: New files for 32-bit HPPA port.
6337         Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
6338
6339 2007-06-14  Randolph Chung  <tausq@debian.org>
6340
6341         * inssel.brg: Add rules for "chained" compare-branch operations so that
6342         a single compare op can affect multiple branches.  Adjust cost for
6343         OP_CEQ/OP_CGT/OP_CGT_UN/OP_CLT/OP_CLT_UN.
6344         * inssel-long32.brg: Update rules to use compare-branch macros.  Adjust
6345         cost for some rules so that they can more easily be overridden by
6346         per-arch rules (with fixes from lupus).
6347         Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
6348
6349 2007-06-13  Randolph Chung  <tausq@debian.org>
6350
6351         * mini-ops.h: Reorder branch ops so that they match the order of the
6352         corresponding CEE_* ops.  The code expects them this way.
6353         Add new ops for HPPA target.
6354         Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
6355
6356 2007-06-13  Randolph Chung  <tausq@debian.org>
6357
6358         * mini-exceptions.c: Handle cases where the stack grows towards
6359         larger addresses.
6360         Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
6361
6362 Wed Jun 13 19:13:23 CEST 2007 Paolo Molaro <lupus@ximian.com>
6363
6364         * jit-icalls.c, mini.h, mini.c: added virtual generic invoke
6365         counter.
6366         * driver.c: explain where a non-matching corlib is found.
6367
6368 2007-06-13  Mark Probst  <mark.probst@gmail.com>
6369
6370         * mini.c (print_jit_stats): Output dynamic code allocation stats.
6371
6372 2007-06-10  Sanghyeon Seo <sanxiyn@gmail.com>
6373
6374         * mini-exceptions.c: Generate a method profile leave event during
6375         an exception to ensure that the profiler gets notified.
6376
6377 2007-06-07  Zoltan Varga  <vargaz@gmail.com>
6378
6379         * mini-amd64.c (peephole_pass): Merge some small changes from the linear-ir 
6380         branch.
6381
6382         * cpu-amd64.md: Add long_and/or/xor opcodes.
6383
6384 2007-06-06  Wade Berrier  <wberrier@novell.com>
6385
6386         * cpu-s390x.md (shr_imm): Correct the length of shr_imm instruction.
6387         (./class/lib/monolite/mcs.exe:25498): WARNING **: wrong maximal instruction 
6388         length of instruction shr_imm (expected 8, got 10)
6389
6390 2007-06-06  Zoltan Varga  <vargaz@gmail.com>
6391
6392         * mini-ia64.c (mono_arch_output_basic_block): Really fix the build.
6393
6394 2007-06-06  Mark Probst  <mark.probst@gmail.com>
6395
6396         * mini.c, driver.c: Changed MonoDomain.jit_code_hash to a
6397         MonoInternalHashTable again (fixed bug in the internal hash table
6398         code).
6399
6400 2007-06-06  Mark Probst  <mark.probst@gmail.com>
6401
6402         * mini.c, driver.c: Reverted the MonoInternalHashTable changes.
6403         Have to figure out what makes it crash the SWF regression.
6404
6405 2007-06-05  Zoltan Varga  <vargaz@gmail.com>
6406
6407         * mini-ia64.c (mono_arch_lowering_pass): Fix ia64 build.
6408
6409 Tue Jun 5 17:40:04 CEST 2007 Paolo Molaro <lupus@ximian.com>
6410
6411         * mini.c: optimize out the type check when storing null in a
6412         reference array.
6413
6414 2007-06-04  Mark Probst  <mark.probst@gmail.com>
6415
6416         * mini.c, driver.c: Changed MonoDomain.jit_code_hash to a
6417         MonoInternalHashTable.
6418
6419 Mon Jun 4 11:29:43 CEST 2007 Paolo Molaro <lupus@ximian.com>
6420
6421         * inssel.brg, mini.c, mini-ops.h: optimized Math.Mini/Max
6422         signed integer methods.
6423
6424 2007-06-02  Zoltan Varga  <vargaz@gmail.com>
6425
6426         * mini-x86.c (mono_arch_get_delegate_invoke_impl): Disable the static case 
6427         permanently since the current approach doesn't work.
6428
6429 2007-06-02  Zoltan Varga  <vargaz@gmail.com>
6430
6431         * inssel.brg (stmt): Only call delegate->invoke_impl if 
6432         MONO_ARCH_HAVE_CREATE_DELEGATE_TRAMPOLINE is defined.
6433
6434 2007-06-01  Zoltan Varga  <vargaz@gmail.com>
6435
6436         * mini-amd64.c (mono_arch_output_basic_block): Unify div/rem opcodes and handle
6437         the sreg2==rdx case.
6438         
6439         * mini-amd64.c cpu-amd64.md: Correct length of r4const instruction and take into
6440         account if it contains a rex prefix.
6441         (peephole_pass): Handle OP_FMOVE as well.
6442
6443 2007-06-01  Zoltan Varga  <vargaz@gmail.com>
6444
6445         * mini-x86.c (mono_arch_get_delegate_invoke_impl): Disable the static case for now
6446         as it causes regressions.
6447
6448 2007-05-31  Zoltan Varga  <vargaz@gmail.com>
6449
6450         * mini-x86.c (mono_arch_get_delegate_invoke_impl): Implement support for the
6451         static case as well.
6452
6453         * tramp-ia64.c (mono_arch_create_trampoline_code): Fix ia64 build.
6454
6455         * mini-x86.c (mono_arch_get_delegate_invoke_impl): New arch dependent function.
6456         (mono_arch_get_this_arg_from_call): Ditto.
6457
6458         * tramp-x86.c (mono_arch_patch_delegate_trampoline): Removed.
6459
6460         * inssel.brg (mini_emit_virtual_call): Call delegate->Invoke through the delegate's
6461         invoke_impl field.
6462
6463         * mini-amd64.c (mono_arch_get_delegate_invoke_impl): New arch dependent function.
6464         (mono_arch_get_this_arg_from_call): Ditto.
6465
6466         * tramp-amd64.c (mono_arch_patch_delegate_trampoline): Removed.
6467         
6468         * mini-trampolines.c (mono_delegate_trampoline): Complete rewrite. On first call,
6469         try to create optimized invoke code and use that for further invocations. 
6470         Otherwise, use the original mono_marshal_get_delegate_invoke () implementation.
6471
6472         * mini-x86.h mini-ia64.h: Remove MONO_ARCH_HAS_CREATE_DELEGATE_TRAMPOLINE for now.
6473
6474 2007-05-29  Rodrigo Kumpera  <kumpera@gmail.com>
6475
6476         * inssel.brg (mini_emit_virtual_call): Statically dispatch virtual calls to
6477         sealed classes or methods.
6478         *devirtualization.cs: tests for the new optimization
6479
6480 2007-05-29  Zoltan Varga  <vargaz@gmail.com>
6481
6482         * liveness.c (update_gen_kill_set): No need to set VOLATILE flags here, it is done
6483         by the update_volatile () function.
6484
6485 2007-05-27  Zoltan Varga  <vargaz@gmail.com>
6486
6487         * driver.c (mono_main): Call g_thread_init () early since newer glib versions
6488         require it.
6489
6490         * abcremoval.c (mono_perform_abc_removal): Avoid using alloca.
6491
6492 2007-05-24  Jonathan Chambers  <joncham@gmail.com>
6493
6494         * mini.c: Add configure checks for header files.
6495         * mini-x86.c: Add configure checks for header files.
6496         * trace.c: Add configure checks for header files.
6497         * aot-runtime.c: Add configure checks for header files.
6498         * aot-compiler.c: Add configure checks for header files.
6499         * driver.c: Add configure checks for header files.
6500         * mini-codegen.c: Add configure checks for header files.
6501         
6502         Code is contributed under MIT/X11 license.
6503
6504 2007-05-22  Zoltan Varga  <vargaz@gmail.com>
6505
6506         * mini-ia64.c (mono_arch_lowering_pass): Fix the handling of
6507         icompare_imm -128 + op_iclt. Fixes #81703.
6508
6509 2007-05-19  Zoltan Varga  <vargaz@gmail.com>
6510
6511         * mini-codegen.c (mono_local_regalloc): Fix long-shift-regalloc on amd64.
6512
6513 2007-05-15  Massimiliano Mantione  <massi@ximian.com>
6514
6515         * inssel.brg: added "mini_emit_load_intf_bit_reg_vtable", and used it
6516         inside "mini_emit_isninst_iface_cast" and "mini_emit_castclass_iface"
6517         so that all isinst checks now use "interface_bitmap".
6518
6519 2007-05-15  Zoltan Varga  <vargaz@gmail.com>
6520
6521         * cpu-amd64.md (jmp): Fix a warning.
6522
6523         * inssel.brg (CEE_SWITCH): Hopefully fix #80738.
6524
6525         * basic.cs: Add new regression test.
6526
6527         * basic.cs: Remove test which is now in basic-long.cs.
6528
6529         * mini-ia64.c (mono_arch_output_basic_block): Sign extend in CEE_CONV_I8/CEE_CONV_I.
6530
6531         * basic-long.cs: Add new test.
6532         
6533 2007-05-13  Zoltan Varga  <vargaz@gmail.com>
6534
6535         * mini-sparc.c (mono_spillvar_offset_float): Fix sparc build.
6536
6537 2007-05-12  Zoltan Varga  <vargaz@gmail.com>
6538
6539         * cpu-x86.md minix-86.c: Add a peephole_pass_1 () as on amd64.
6540
6541         * mini-x86.c (mono_arch_output_basic_block): Use mono_opcode_to_cond () in a few
6542         places.
6543         
6544         * mini-x86.c (mono_arch_emit_exceptions): Decrease the size of the exception 
6545         throwing code a bit.
6546
6547         * exceptions-x86.c (mono_arch_get_throw_corlib_exception): Decrease the size of 
6548         the exception throwing code a bit.
6549
6550         * mini-x86.c (get_call_info): Allocate result from a mempool.
6551
6552 2007-05-11  Zoltan Varga  <vargaz@gmail.com>
6553
6554         * aot-compiler.c (find_typespec_for_class): Fix the assert.
6555
6556         * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file version.
6557
6558         * mini.h (MonoCompile): Add 'token_info_hash' field.
6559
6560         * mini.c: Save token->method associations during compilation so the AOT 
6561         compiler can use it.
6562         
6563         * aot-compiler.c aot-runtime.c: Add support for compiling non-generic methods
6564         which reference generic classes and methods.
6565
6566 2007-05-10  Zoltan Varga  <vargaz@gmail.com>
6567
6568         * mini.h mini-<ARCH>.h: Get rid of MONO_ARCH_HAS_XP_LOCAL_REGALLOC.
6569
6570         * aot-compiler.c (compile_method): Fix a typo in a comment.
6571
6572         * aot-runtime.c (decode_cached_class_info): Skip generic types.
6573
6574         * aot-compiler.c: Add minimal support for AOTing generic code by skipping 
6575         everything generic.
6576
6577         * mini.c (mono_method_to_ir): Disable AOT when calling helper_compile_generic_method.
6578
6579 2007-05-09  Zoltan Varga  <vargaz@gmail.com>
6580
6581         * mini.h (MonoCompile): Add 'args' field.
6582
6583         * mini.c (mono_compile_create_vars): Store variables representing the arguments
6584         into cfg->args.
6585
6586         * mini-<ARCH>.c: Use cfg->args for accessing the method arguments.
6587
6588 2007-05-08  Zoltan Varga  <vargaz@gmail.com>
6589
6590         * mini.c (mono_compile_get_interface_var): Remove this unused function.
6591
6592         * mini-ops.h inssel.brg mini-<ARCH>.c: Add a new opcode for ckfinite as well.
6593
6594         * mini-ops.h: Introduce new opcodes used in the IR instead of the original CEE_
6595         opcodes for some opcodes.
6596
6597         * mini.h *.brg *.c: Use the new opcodes.
6598
6599 2007-05-08  Massimiliano Mantione  <massi@ximian.com>
6600
6601         * mini.h: Bumped aot revision.
6602
6603         * inssel.brg: modified code generation of type checks for interfaces
6604         to use the new "MonoClass.interface_bitmap" instead of the old
6605         "MonoClass.interface_offsets".
6606
6607 2007-04-30  Zoltan Varga  <vargaz@gmail.com>
6608
6609         * cpu-amd64.md (jmp): Increase the maximum size of the jmp opcode to 128.
6610
6611 2007-04-29  Zoltan Varga  <vargaz@gmail.com>
6612
6613         * abcremoval.c (summarize_integer_value): Handle OP_LCONV_TO_I4 to fix abcrem on
6614         64 bit platforms.
6615
6616 2007-04-27  Neale Ferguson <neale@sinenomine.net>
6617
6618         * mini-s390x.c: Fix MONO_TYPE_VALUETYPE processing.
6619
6620 2007-04-27  Wade Berrier  <wberrier@novell.com>
6621
6622         * mini-s390x.c: Remove redeclaration of CompRelation and CompType (defined in 
6623         mini.h) to fix build.
6624
6625 2007-04-26  Zoltan Varga  <vargaz@gmail.com>
6626
6627         * mini-amd64.c (peephole_pass_1): Fix and reenable this pass.
6628         
6629         * mini-amd64.c (mono_arch_local_regalloc): Disable the new peephole_pass_1 as it
6630         causes the corlib unit tests to fail.
6631
6632 2007-04-25  Zoltan Varga  <vargaz@gmail.com>
6633
6634         * mini-codegen.c (mono_opcode_to_type): Fix a bug in the previous patch.
6635
6636         * mini-amd64.c (peephole_pass_1): New pass to perform before local regalloc.
6637
6638         * mini-codegen.c (mono_opcode_to_cond): New helper function to convert conditional 
6639         opcodes to the comparison relations.
6640
6641         * mini-codegen.c (mono_opcode_to_type): New helper function to convert conditional 
6642         opcodes to their types.
6643         
6644         * mini-ia64.c mini-amd64.c: Use mono_opcode_to_cond and mono_opcode_to_type.
6645
6646         * mini-amd64.c (get_call_info): Allocate the result from the cfg mempool and cache 
6647         it in cfg->arch.cinfo.
6648
6649         * local-propagation.c (mono_local_cprop_bb): Fix a warning.
6650
6651         * mini.h mini.c branch-opts.c: Change bbhash to be an array and store it in 
6652         cfg->cil_offset_to_bb.
6653
6654 2007-04-24  Zoltan Varga  <vargaz@gmail.com>
6655
6656         * liveness.c (optimize_initlocals): New mini-pass to optimize away dead assignments
6657         created becase of initlocals.
6658
6659 2007-04-23  Zoltan Varga  <vargaz@gmail.com>
6660
6661         * mini-alpha.c cpu-alpha.md: More alpha port work from 
6662         Sergey Tikhonov <tsv@solvo.ru>.
6663
6664 2007-04-21  Andreas Faerber  <andreas.faerber@web.de>
6665
6666         * Makefile.am (BUILT_SOURCES): Fix for automake 1.6.x. Fixes #81417.
6667
6668 2007-04-19  Zoltan Varga  <vargaz@gmail.com>
6669
6670         * cpu-s390.md (break): Correct the length of break instruction.
6671
6672 Thu Apr 19 16:28:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
6673
6674         * mini.c: fix a couple of soft-float issues and comments.
6675
6676 2007-04-15  Miguel de Icaza  <miguel@novell.com>
6677
6678         * trace.c (is_filenamechar): - is also a filename char.
6679
6680 2007-04-15  Neale Ferguson <neale@sinenomine.net>
6681
6682         * mini-s390.c: Correct checking for enum type in return value processing.
6683
6684 2007-04-14  Raja R Harinath  <rharinath@novell.com>
6685
6686         * Makefile.am (BUILT_SOURCES): Add 'version.h'.
6687         (version.h): Makefile is in the build directory.
6688
6689 2007-04-06  Andreas Faerber  <andreas.faerber@web.de>
6690
6691         * mini-amd64.h: fix for assertion failure on Solaris/amd64
6692
6693 2007-04-11  Martin Baulig  <martin@ximian.com>
6694
6695         * mini.c (can_access_member): Fix handling of generic classes;
6696         fixes #81259.
6697
6698 2007-04-10  Zoltan Varga  <vargaz@gmail.com>
6699
6700         * aot-runtime.c (mono_aot_plt_resolve): Fix disabling of AOT. Fixes #81316.
6701
6702 2007-04-05  Zoltan Varga  <vargaz@gmail.com>
6703
6704         * aot-runtime.c: Fix disabling of AOT. Fixes #81316.
6705
6706 Fri Mar 23 20:25:31 CET 2007 Paolo Molaro <lupus@ximian.com>
6707
6708         * mini-codegen.c: make sure the right spill amount is
6709         used for fp or integer registers (fixes the float_sub_spill() on ppc).
6710
6711 Fri Mar 23 19:43:35 CET 2007 Paolo Molaro <lupus@ximian.com>
6712
6713         * mini-ppc.c: fixes for the fp_branch_nan test.
6714
6715 2007-03-23  Zoltan Varga  <vargaz@gmail.com>
6716
6717         * basic.cs: Comment out new test which still fails on ia64.
6718
6719 Fri Mar 23 15:54:23 CET 2007 Paolo Molaro <lupus@ximian.com>
6720
6721         * mini.c: immediate shifted or fix (mono_metadata_user_string assert).
6722
6723 Fri Mar 23 12:53:28 CET 2007 Paolo Molaro <lupus@ximian.com>
6724
6725         * mini-ppc.c, mini-ppc.h: struct passing ABI fix (bug #77968).
6726
6727 2007-03-22  Zoltan Varga  <vargaz@gmail.com>
6728
6729         * cfold.c (FOLD_BINOP): Cast the result to gint32 to prevent overflow problems
6730         on 64 bit machines. Fixes part of #80738.
6731
6732         * basic.cs: Add regression test.
6733
6734 2007-03-17  Zoltan Varga  <vargaz@gmail.com>
6735
6736         * inssel.brg basic.cs: Revert previous change to fix build.
6737
6738         * inssel.brg (SWITCH): Clean out the upper word of the switch value on 64 bit
6739         platforms.
6740         
6741         * inssel.brg (SWITCH): Use an integer comparison. Fixes #80738.
6742
6743         * basic.cs: Add new regression test.
6744
6745 2007-03-17  Zoltan Varga  <vargaz@gmail.com>
6746
6747         * mini-ia64.c (mono_arch_emit_prolog): Fix an assert when a function has too
6748         many arguments.
6749
6750 2007-03-16  Neale Ferguson <neale@sinenomine.net>
6751
6752         * cpu-s390x.md: Correct length of break instruction.
6753
6754 2007-03-16  Neale Ferguson <neale@sinenomine.net>
6755
6756         * mini-s390x.c, cpu-s390x.md: Fix #80507 for s390x.
6757         * mini-s390.c, cpu-s390.md: Fix #80507 for s390.
6758
6759 2007-03-15  Jonathan Chambers  <joncham@gmail.com>
6760
6761         * *.c: Begin WIN64 port.
6762         * mini.c:  Use correct register in profiler.
6763         * mini-amd64.c: No inline assembly on Win64.
6764         * mini-amd64.h: Implement MONO_INIT_CONTEXT_FROM_FUNC for Win64.
6765         Only define MONO_ARCH_USE_SIGACTION on non-windows platforms.
6766         * exceptions-amd64.c: Only need gregs_from_ucontext if MONO_ARCH_USE_SIGACTION
6767         is defined. Implement mono_arch_sigctx_to_monoctx, mono_arch_monoctx_to_sigctx, and
6768         mono_arch_ip_from_context for Win64.
6769         
6770         Contributed under MIT/X11 license.
6771
6772 2007-03-15  Zoltan Varga  <vargaz@gmail.com>
6773
6774         * exceptions-amd64.c (seh_handler): Ditto.
6775
6776         * exceptions-x86.c (seh_handler): Fix a memory leak.
6777
6778 Thu Mar 15 13:47:59 CET 2007 Paolo Molaro <lupus@ximian.com>
6779
6780         * mini-arm.c, mini-mips.c, mini-ppc.c, mini-s390.c,
6781         mini-s390x.c: fixed peephole optimizations to deal
6782         correctly with 1 and 2 byte reload avoidance.
6783
6784 Thu Mar 15 10:17:54 CET 2007 Paolo Molaro <lupus@ximian.com>
6785
6786         * cpu-s390.md, cpu-s390x.md: update localloc length.
6787
6788 Wed Mar 14 21:00:19 CET 2007 Paolo Molaro <lupus@ximian.com>
6789
6790         * cpu-g4.md: added missing descriptions.
6791
6792 2007-03-14  Miguel de Icaza  <miguel@novell.com>
6793
6794         *  Makefile.am: Add support so the tail tests are not executed on
6795         PowerPC as that is a known limitation of the PowerPC port.
6796
6797 2007-03-13  Jonathan Chambers  <joncham@gmail.com>
6798
6799         * runmdesc.bat:  Move to msvc directory.
6800         
6801 2007-03-13  Jonathan Chambers  <joncham@gmail.com>
6802
6803         * runmdesc.bat:  Run executable that was produced by the current
6804         target and sent via an argument.
6805         
6806 2007-03-11  Zoltan Varga  <vargaz@gmail.com>
6807
6808         * mini.c (mono_method_to_ir): Fix box+brtrue optimization. Fixes
6809         #81102.
6810
6811         * generics.2.cs: Add regression test.
6812
6813 2007-03-09  Wade berrier  <wberrier@novell.com>
6814
6815         * mini-ppc.h: Undo typo of MONO_CONTEXT_SET_SP (ppc doesn't define this symbol)
6816
6817 2007-03-09  Zoltan Varga  <vargaz@gmail.com>
6818
6819         * aot-runtime.c (load_aot_module): Load all dependent assemblies eagerly since all
6820         AOT code depends on this.
6821
6822 Thu Mar 8 19:36:13 CET 2007 Paolo Molaro <lupus@ximian.com>
6823
6824         * mini.c: more precise tracking of types in the eval stack
6825         (part of fix for bug #81044).
6826
6827 2007-03-07  Zoltan Varga  <vargaz@gmail.com>
6828
6829         * aot-runtime.c (mono_aot_get_class_from_name): Add a cache.
6830
6831         * aot-compiler.c (encode_patch): Remove an obsolete comment.
6832
6833 2007-03-06  Zoltan Varga  <vargaz@gmail.com>
6834
6835         * mini-exceptions.c (mono_handle_native_sigsegv): Fix a warning.
6836
6837         * mini.c (mono_method_to_ir): Add a workaround for bug #80733.
6838
6839 2007-02-22  Zoltan Varga  <vargaz@gmail.com>
6840
6841         * mini.c (type_from_op): Convert CEE_CONV_U to OP_LCONV_TO_U when the argument is
6842         a pointer on 64 bit systems. Fixes #80190.
6843
6844         * iltests.il: Add new regression test.
6845
6846 Tue Feb 20 11:33:28 CET 2007 Paolo Molaro <lupus@ximian.com>
6847
6848         * mini.c: inline a constant for Environment.IsRunningOnWindows.
6849
6850 2007-02-19  Geoff Norton  <gnorton@customerdna.com>
6851
6852         * trace.c: Remove an erroneous alignemnt check when tracing.
6853           Fixes --trace on OSX86.
6854
6855 Wed Feb 14 19:45:56 CET 2007 Paolo Molaro <lupus@ximian.com>
6856
6857         * mini-$(arch).h: initialize SP in context for all the archs.
6858
6859 2007-02-14  Sebastien Pouliot  <sebastien@ximian.com>
6860
6861         * mini-x86.h: Initialize SP in MONO_INIT_CONTEXT_FROM_FUNC. Fix CAS
6862         regressions in the thread tests.
6863
6864 2007-02-14  Zoltan Varga  <vargaz@gmail.com>
6865
6866         * *-alpha.*: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>:
6867         - fixed implementation of LOCALLOC opcode
6868         - implemented non-un compare for floats
6869         - code cleanup
6870         - implementation of FDIV and CKFINITE opcodes
6871         - fixes for latest mono updates
6872         - additional arch opcodes
6873
6874 Mon Feb 12 11:54:16 CET 2007 Paolo Molaro <lupus@ximian.com>
6875
6876         * Makefile.am: simplify and merge rules for cross-compilation.
6877
6878 2007-02-07  Massimiliano Mantione  <massi@ximian.com>
6879
6880         * local-propagation.c: Actually *apply* the fix for bug 80591...
6881
6882 Tue Feb 6 19:03:19 CET 2007 Paolo Molaro <lupus@ximian.com>
6883
6884         * mini-exceptions.c: backuot part of the last change
6885         (fixes cas tests on amd64 related to GetExecutingAssembly ()).
6886
6887 2007-02-06  Massimiliano Mantione  <massi@ximian.com>
6888         * inssel.brg: Fix bug 59286.
6889
6890
6891 Tue Feb 6 12:23:50 CET 2007 Paolo Molaro <lupus@ximian.com>
6892
6893         * mini-exceptions.c: patch from Zoltan to correctly check for
6894         stack boundaries (using the stack register, not the frame register),
6895         fixes bugs #80724, #79717.
6896
6897 2007-02-03  Zoltan Varga  <vargaz@gmail.com>
6898
6899         * mini-ia64.c inssel-sparc.brg mini-sparc.c cpu-sparc.md: Get rid of OP_SETREG/
6900         OP_SETREGIMM, use OP_MOVE/OP_ICONST instead.
6901
6902         * mini-amd64.c (mono_arch_output_basic_block): Fix ATOMIC_EXCHANGE in the
6903         presence of frame pointer elimination.
6904
6905 2007-02-01  Geoff Norton  <gnorton@customerdna.com>
6906         
6907         * mini-x86.h: NetBSD UCONTEX_REG defines.
6908
6909 2007-02-01  Zoltan Varga  <vargaz@gmail.com>
6910
6911         * inssel-amd64.brg: Fix amd64 build.
6912
6913 Thu Feb 1 14:02:09 CET 2007 Paolo Molaro <lupus@ximian.com>
6914
6915         * mini.h: remove extern to workaround what looks likes gcc bug 26905
6916         on amd64.
6917
6918 2007-01-31  Zoltan Varga  <vargaz@gmail.com>
6919
6920         * mini-codegen.c (mono_is_regsize_var): New helper function usable by the back
6921         ends.
6922
6923         * mini-<ARCH>.c: Use mono_is_regsize_var ().
6924
6925 2007-01-30 Mark Mason <mason@broadcom.com>
6926
6927            * exceptions-mips.c: Lots of exception handling fixes, LMFs now work, some cleanups.
6928            * mini-mips.h: Add LMF magic numbers, and fix context set/get macros.
6929            * mini-mips.c: Cleanups, LMF handling now works, optimize store of zero, implement localloc
6930            beginning support for CEE_JMP [not quite working yet]
6931            * tramp-mips.c: LMF handling now works
6932         
6933 2007-01-30  Zoltan Varga  <vargaz@gmail.com>
6934
6935         * mini-amd64.c (peephole_pass): Optimize code common in initlocals blocks.
6936
6937         * mini.h (NULLIFY_INS): New macro.
6938
6939 Tue Jan 30 16:33:33 CET 2007 Paolo Molaro <lupus@ximian.com>
6940
6941         * mini.c: statistical profiler fix for windows, patch
6942         from Tor Lillqvist (tml@novell.com).
6943
6944 2007-01-30  Massimiliano Mantione  <massi@ximian.com>
6945         * local-propagation.c: Fix bug 80591.
6946
6947 Mon Jan 29 12:14:34 CET 2007 Paolo Molaro <lupus@ximian.com>
6948
6949         * Makefile.am: put back the --export-dynamic option as with
6950         the previous gmodule flags (thanks to Robert Jordan).
6951
6952 2007-01-28  Zoltan Varga  <vargaz@gmail.com>
6953
6954         * mini-sparc.c (peephole_pass): Fix #80622 for sparc as well.
6955
6956         mini.h *.c: Allocate fp vregs from the same pool as the int vregs. Use this to
6957         simplify and speed up the local register allocator. Also rename some fields
6958         like iassign->vassign.
6959         
6960         * regalloc.c: Remove some functions which are no longer used since their
6961         inlined version is in mini-codegen.c.
6962         
6963         * mini-codegen.c: Rename mono_regstate2_ functions to mono_regstate_.
6964
6965         * basic.cs objects.cs iltests.il: Merge tests from the linear IL branch.
6966
6967 2007-01-27  Zoltan Varga  <vargaz@gmail.com>
6968
6969         * mini-amd64.c (peephole_pass): Remove optimizations which omit a 
6970         narrowing. Fixes #80622.
6971
6972         * iltests.il: Add new regresssion test. 
6973
6974 Fri Jan 26 18:31:45 CET 2007 Paolo Molaro <lupus@ximian.com>
6975
6976         * mini.h, mini-trampolines.c, aliasing.c, mini-codegen.c,
6977         debug-debugger.c, debug-debugger.h: warning fixes.
6978         * driver.c: updated copyright year and made it fit in one line.
6979
6980 Fri Jan 26 12:48:39 CET 2007 Paolo Molaro <lupus@ximian.com>
6981
6982         * aot-runtime.c: updated to use mono-dl instead of gmodule.
6983
6984 2007-01-25  Zoltan Varga  <vargaz@gmail.com>
6985
6986         * mini-x86.c (mono_arch_output_basic_block): Fix #80507 for x86.
6987
6988         * mini-amd64.c (mono_arch_output_basic_block): Fix #80507 for amd64.
6989
6990         * iltests.il: Add new test for bug #80507.
6991
6992 Wed Jan 24 19:10:28 CET 2007 Paolo Molaro <lupus@ximian.com>
6993
6994         * mini-arm.h: use soft-float also on vfp for now.
6995
6996 Wed Jan 24 14:54:40 CET 2007 Paolo Molaro <lupus@ximian.com>
6997
6998         * mini.c: fix some more soft-float issues.
6999
7000 2007-01-24  Zoltan Varga  <vargaz@gmail.com>
7001
7002         * mini-sparc.h (MONO_ARCH_FRAME_ALIGNMENT): Fix sparc build.
7003
7004 2007-01-24  Massimiliano Mantione  <massi@ximian.com>
7005         * mini-arch.h, , inssel-amd64.brg, mini-x86.c, inssel-x86.brg,
7006         mini-ia64.c, mini-sparc.c, mini-alpha.c: Introduced
7007         MONO_ARCH_LOCALLOC_ALIGNMEENT to fix bug 80498.
7008
7009 Wed Jan 24 12:04:39 GMT 2007 Paolo Molaro <lupus@ximian.com>
7010
7011         * mini-arm.c: typo fix.
7012
7013 2007-01-23  Neale Ferguson <neale@sinenomine.net>
7014
7015         * mini-s390x.c: Use lgb instructions for I1 type variables instead of lb.
7016
7017 2007-01-21  Zoltan Varga  <vargaz@gmail.com>
7018
7019         * mini.c (mono_allocate_stack_slots_full): Allocate memory from the cfg mempool.
7020         Share stack slots for scalar types. Avoid expensive g_list_free () calls.
7021
7022         * mini-x86.c (mono_arch_allocate_vars): Don't free the result of allocate_stack_slots_full.
7023
7024         * mini-amd64.c mini-ia64.c mini-alpha.c: Ditto. 
7025
7026         * mini.h (MonoJitStats): Add a new JIT statistics: locals_stack_size.
7027         
7028         * inssel.brg: Fix a warning.
7029
7030         * mini.h (MonoBasicBlock): Make bb->dominated a GSList.
7031
7032         * abcremoval.c ssa.c ssapre.c: Update after this change.
7033         
7034         * dominators.c (compute_dominators): Allocate bb->dominated from the cfg mempool.
7035
7036         * dominators.c (df_set): Use mono_bitset_union_fast.    
7037
7038 Sat Jan 20 16:59:01 CET 2007 Paolo Molaro <lupus@ximian.com>
7039
7040         * mini.h, genmdesc.c, genmdesc.pl, mini-${arch}.c, cprop.c,
7041         mini-codegen.c: reduce relocations and memory usage for the cpu
7042         description.
7043
7044 2007-01-20  Zoltan Varga  <vargaz@gmail.com>
7045
7046         * mini-codegen.c (mono_regstate2_alloc_int): Optimize this using bsfq on amd64.
7047
7048         * genmdesc.c genmdesc.pl mini.h: Remove some unused fields from the mdesc tables
7049         to reduce their size.
7050
7051 2007-01-19 Mark Mason <mason@broadcom.com>
7052
7053         * exceptions-mips.c: fix mono_arch_ip_from_context(), increase exception debug support.
7054         * mini-mips.c: more configuration macros, support long conditional branches, additional
7055         asserts, fix epilog instrumentation.
7056         * mini-mips.h: use standard stack walk
7057         * cpu-mips.md: increase size of div, rem and conditional branches
7058         
7059 Fri Jan 19 17:23:32 CET 2007 Paolo Molaro <lupus@ximian.com>
7060
7061         * mini.h, mini-codegen.c, mini-$(arch).h: claenup references
7062         to cpu spec data.
7063
7064 2007-01-19  Zoltan Varga  <vargaz@gmail.com>
7065
7066         * aot-compiler.c (encode_klass_info): Allow classes of the form <Type>[][].
7067         (compile_method): Ditto.
7068
7069         * aot-runtime.c (decode_klass_info): Ditto.
7070
7071         * mini.c (mono_method_to_ir): Call mono_get_got_var () in a place where it is
7072         needed by the code generated by inssel.brg. Also fix a warning.
7073
7074 Thu Jan 18 17:55:22 CET 2007 Paolo Molaro <lupus@ximian.com>
7075
7076         * mini.c: deal with enums that become genericinsts by
7077         being nested in a generic class (bug #79956).
7078
7079 Thu Jan 18 16:52:56 CET 2007 Paolo Molaro <lupus@ximian.com>
7080
7081         * mini.c: match the generic definition to check for
7082         private access with generic types (bug #78431).
7083
7084 Thu Jan 18 11:50:13 CET 2007 Paolo Molaro <lupus@ximian.com>
7085
7086         * genmdesc.pl, Makefile.am: perl implementation of genmdesc,
7087         to make life easier for people cross-compiling that insist on not
7088         using scratchbox.
7089
7090 2007-01-17 Mark Mason <mason@broadcom.com>
7091
7092         * inssel-long.brg: patch to deal with mips missing flags
7093         * inssel-long32-mips.brg: implement overflow checks
7094         * insset-mips.brg: implement overflow checks
7095         * mini-mips.h: implement conditional exception handling
7096         * mini-mips.c: add mips_emit_exc_by_name(), implement conditional exception handling.
7097           Remove unused code, minor cleanups.
7098         * exceptions-mips.c: minor cleanups
7099         * mini-ops.h: add mips conditional exception ops
7100         * cpu-mips.md: add mips conditional exception ops
7101
7102         
7103 Wed Jan 17 19:22:34 CET 2007 Paolo Molaro <lupus@ximian.com>
7104
7105         * inssel.brg: patch from Mark Mason <mason@broadcom.com>
7106         to deal with mips missing of flags.
7107
7108 Tue Jan 16 20:01:01 CET 2007 Paolo Molaro <lupus@ximian.com>
7109
7110         * exceptions-ppc.c: execute fault handlers.
7111
7112 Tue Jan 16 19:54:44 CET 2007 Paolo Molaro <lupus@ximian.com>
7113
7114         * mini-ppc.c: handle missing call locationss with FORCE_INDIR_CALL.
7115
7116 Tue Jan 16 13:14:31 CET 2007 Paolo Molaro <lupus@ximian.com>
7117
7118         * mini.c: handle also floating point values in initialize_array.
7119
7120 Tue Jan 16 12:42:40 CET 2007 Paolo Molaro <lupus@ximian.com>
7121
7122         * mini.c, aot-runtime.c, aot-compiler.c: enable aot compilation of
7123         array initialization and make it conditional on the intrins option.
7124
7125 Tue Jan 16 11:28:45 CET 2007 Paolo Molaro <lupus@ximian.com>
7126
7127         * mini.h, patch-info.h, Makefile.am, aot-compiler.c: reduce
7128         relocations and put the patch info names close to the enum definition.
7129
7130 2007-01-15 Mark Mason <mason@broadcom.com>
7131
7132         * basic.cs, exceptions.cs: break up large tests to increase debugability.
7133
7134 Mon Jan 15 18:57:14 CET 2007 Paolo Molaro <lupus@ximian.com>
7135
7136         * mini.c: optimized RuntimeHelpers::InitializeArray () calls.
7137
7138 2007-01-12  Raja R Harinath  <rharinath@novell.com>
7139
7140         * mini.c (mono_method_to_ir): Use new MonoGenericContext accessor.
7141
7142 Thu Jan 11 11:16:42 CET 2007 Paolo Molaro <lupus@ximian.com>
7143
7144         * Makefile.am: distribute the mips sources.
7145
7146 Wed Jan 10 19:49:33 CET 2007 Paolo Molaro <lupus@ximian.com>
7147
7148         * mini-codegen.h: handle bug #80489 here, by excluding ecx
7149         directly.
7150
7151 Wed Jan 10 19:08:05 CET 2007 Paolo Molaro <lupus@ximian.com>
7152
7153         * cpu-x86.md: back out for now as this triggers other regressions.
7154
7155 Wed Jan 10 18:33:16 CET 2007 Paolo Molaro <lupus@ximian.com>
7156
7157         * cpu-x86.md: force src1 and dest regpair for long shift instructions
7158         to eax:edx, so ecx can't get allocated to them (bug #80489).
7159
7160 Tue Jan 9 12:36:11 CET 2007 Paolo Molaro <lupus@ximian.com>
7161
7162         * mini.c, mini-exceptions.c: enabled running fault handlers
7163         (bug #80469).
7164
7165 2007-01-03  Miguel de Icaza  <miguel@novell.com>
7166
7167         * driver.c: If nothing fail, do not use the string "failed",
7168         because it makes it very annoying to view test result logs on the
7169         web. 
7170
7171 2006-12-30  Miguel de Icaza  <miguel@novell.com>
7172
7173         * debug-debugger.c (mono_debugger_main): Rename "main" to
7174         "main_method" to prevent a warning.
7175
7176         Remove a warning for unused field.
7177
7178 2006-12-28  Martin Baulig  <martin@ximian.com>
7179
7180         * debug-debugger.c
7181         (MONO_DEBUGGER__debugger_info): Add `get_lmf_addr'.
7182
7183 2006-12-22  Martin Baulig  <martin@ximian.com>
7184
7185         * mdb-debug-info32.s, mdb-debug-info64.s: New files.
7186         Put a pointer to the `MONO_DEBUGGER__debugger_info' into a
7187         seperate `.mdb_debug_info' section, so we can access it from the
7188         debugger even if the binary is stripped.
7189
7190         * debug-debug.c: Reference the `MONO_DEBUGGER__debugger_info_ptr'
7191         from the `.mdb_debug_info' here to prevent the linker from
7192         removing that section.
7193
7194         * Makefile.am (mono_debugger_sources): Add mdb-debug-info32.s /
7195         mdb-debug-info64.s.
7196
7197 2006-12-19  Robert Jordan  <robertj@gmx.net>
7198
7199         * mini-x86: enable the code to return small structures in
7200         registers for FreeBSD as well. Fixes bug #80278.
7201         * aot-runtime.c: Include sys/wait.h for WEXITSTATUS/WIFEXITED.
7202
7203 Mon Dec 18 19:47:17 CET 2006 Paolo Molaro <lupus@ximian.com>
7204
7205         * mini-x86.c: align the stack when calling the profiler
7206         function instrumenting the prolog (on OSX).
7207
7208 Thu Dec 14 15:22:43 CET 2006 Paolo Molaro <lupus@ximian.com>
7209
7210         * mini.c: emit a break opcode where Debugger.Break () is called.
7211
7212 2006-12-13  Miguel de Icaza  <miguel@novell.com>
7213
7214         * mini.c (mono_method_to_ir): Provide useful information on this
7215         assert, to prevent others from debugging like I did.
7216
7217 Tue Dec 12 17:01:38 CET 2006 Paolo Molaro <lupus@ximian.com>
7218
7219         * mini.c: enable code which was incorrectly commented
7220         (bug #80235).
7221
7222 Tue Dec 12 16:28:15 CET 2006 Paolo Molaro <lupus@ximian.com>
7223
7224         * mini-x86.c: enable on OSX, too, the code to return small
7225         structures in registers.
7226
7227 Mon Dec 11 19:22:35 CET 2006 Paolo Molaro <lupus@ximian.com>
7228
7229         * mini-x86.c: remove the use of the dynamic code manager here, too.
7230
7231 Mon Dec 11 19:08:33 CET 2006 Paolo Molaro <lupus@ximian.com>
7232
7233         * mini.h, debug-debugger.c, tramp-*.c: fixed 
7234         mono_debugger_create_notification_function() to use
7235         mono_global_codeman_reserve () instead of a dynamic code manager.
7236
7237 Tue Dec 5 17:54:50 CET 2006 Paolo Molaro <lupus@ximian.com>
7238
7239         * mini.c, jit-icalls.h, jit-icalls.c: remove the 
7240         ves_array_element_address() jit icall and use a generated
7241         managed method instead (which is about 4 times faster for a rank 3
7242         array access).
7243
7244 2006-11-29  Mark Mason  <mason@broadcom.com>
7245
7246         * basic-calls.cs: additional tests for passing
7247         structures as function arguments.
7248
7249 2006-11-29  Mark Mason  <mason@broadcom.com>
7250
7251         * mini-mips.h: disable custom exception handling
7252         * mini-mips.c: throw/rethrow should use jalr to call
7253         exception stubs.  Fixed bug with passing structures
7254         by value. More support for tracing floating point
7255         functions.
7256
7257 Wed Nov 29 20:28:17 CET 2006 Paolo Molaro <lupus@ximian.com>
7258
7259         * mini.c: fixed typo in the soft-float ldind.r4 handling
7260         (bug #80086).
7261
7262 Wed Nov 29 11:33:03 CET 2006 Paolo Molaro <lupus@ximian.com>
7263
7264         * mini.c, mini.h, driver.c: added --runtime command line
7265         option to select a different runtime than the autodetected one.
7266         * jit.h: added API for embedders to initialize with a specific
7267         runtime version.
7268
7269 Tue Nov 28 21:24:55 CET 2006 Paolo Molaro <lupus@ximian.com>
7270
7271         * mini.c: handle also boxing of r4 values (bug #80024).
7272
7273 Tue Nov 28 19:45:44 CET 2006 Paolo Molaro <lupus@ximian.com>
7274
7275         * mini-ppc.c: force indirect calls until we reserve
7276         enough address space for all the generated code.
7277
7278 Tue Nov 28 20:04:34 GMT 2006 Paolo Molaro <lupus@ximian.com>
7279
7280         * exceptions-arm.c: workaround bugs in the libc definition
7281         of struct ucontext.
7282
7283 Mon Nov 27 15:13:41 CET 2006 Paolo Molaro <lupus@ximian.com>
7284
7285         * inssel.brg: fixes from me and Mark Mason.
7286
7287 2006-11-23  Dick Porter  <dick@ximian.com>
7288
7289         * wapihandles.c (mini_wapi_seminfo): No need to adjust the counter
7290         semaphore display now we've fixed the initial value
7291
7292 Wed Nov 22 11:04:37 CET 2006 Paolo Molaro <lupus@ximian.com>
7293
7294         * inssel.brg: partially revert the last change to fix the build.
7295
7296 2006-11-21  Mark Mason  <mason@broadcom.com>
7297
7298         * inssel.brg: Add and use compare-and-branch macros to support
7299         architectures that do not have condition code registers (ie. MIPS).
7300         * *-mips.{c,brg,md}: Fix copyright statements
7301
7302 2006-11-20  Mark Mason  <mason@broadcom.com>
7303
7304         * Makefile.am: remove mini-codegen.c from list of MIPS sources
7305         * mini.c: Allow GET_CONTEXT to be specified by the arch port
7306         * mini.h: Added declaration for mono_print_ins()
7307         * mini-codegen.c: added ins_spec initializer for MIPS
7308         * mini-codegen.c (mono_call_inst_add_outarg_reg): added asserts for
7309         vreg to be virtual and hreg to be non-virtual.
7310         * mini-codegen.c (mono_spillvar_offset): assert if MIPS - spilling
7311         is not yet working/implemented correctly.
7312         * mini-codegen.c (print_ins): rename to mono_print_ins(), make
7313         non-static, fixup calls to print_ins() from other parts in the file.
7314
7315 2006-11-20  Mark Mason  <mason@broadcom.com>
7316
7317         * basic-calls.cs: added tests for passing structures as arguments
7318         to calls.
7319
7320 Mon Nov 20 19:40:11 CET 2006 Paolo Molaro <lupus@ximian.com>
7321
7322         * inssel-long32.brg: optimize signed division by power of two.
7323
7324 Mon Nov 20 17:37:58 CET 2006 Paolo Molaro <lupus@ximian.com>
7325
7326         * mini-arm.c: added support for interworking with thumb code
7327         (mono must be still be built using the ARM instruction encoding).
7328
7329 2006-11-19  Miguel de Icaza  <miguel@novell.com>
7330
7331         * mini.c (type_from_op): Separate the conditions for OP_EQ as the
7332         verifier has different rules for it.   Fixes a few verifier issues
7333         in the test suite.
7334
7335         * mini-exceptions.c (mono_handle_native_sigsegv): Put the message
7336         at the end, so people know what happened.
7337
7338 Thu Nov 16 14:07:18 CET 2006 Paolo Molaro <lupus@ximian.com>
7339
7340         * brach-opts.c: in optimize_exception_target() make sure we
7341         are in a catch clause (fixes bug #79871).
7342
7343 Thu Nov 16 12:42:13 CET 2006 Paolo Molaro <lupus@ximian.com>
7344
7345         * jit-icalls.c, jit-icalls.h, mini-arm.c, mini.c:
7346         more soft-float support fixes.
7347
7348 Wed Nov 15 18:45:47 GMT 2006 Paolo Molaro <lupus@ximian.com>
7349
7350         * mini-arm.c, inssel-arm.brg: ABI fix for longs and doubles
7351         that are passed half on the stack and half in registers.
7352
7353 Wed Nov 15 17:00:27 CET 2006 Paolo Molaro <lupus@ximian.com>
7354
7355         * mini-ops.h, mini-arch.h, helpers.c, Makefile.am:
7356         more mips integration work from Mark E Mason 
7357         <mark.e.mason@broadcom.com>.
7358
7359 Wed Nov 15 16:34:03 CET 2006 Paolo Molaro <lupus@ximian.com>
7360
7361         * exceptions-mips.c, inssel-mips.brg, mini-mips.h,
7362         cpu-mips.md, inssel-long32-mips.brg, mini-mips.c,
7363         tramp-mips.c: added sources for the mips port, not
7364         integrated in the build yet. Contributed by
7365         Mark E Mason <mark.e.mason@broadcom.com>.
7366
7367 2006-11-14  Neale Ferguson <neale@sinenomine.net>
7368
7369         * mini-s390[x].c (is_regsize_var): Support PTR/FNPTR too.
7370
7371 Tue Nov 14 16:06:37 CET 2006 Paolo Molaro <lupus@ximian.com>
7372
7373         * Makefile.am, inssel-float.brg, inssel-softfloat.brg:
7374         put the soft-float rules in its own file since it seems to
7375         break s390 compilation.
7376
7377 Mon Nov 13 15:54:38 CET 2006 Paolo Molaro <lupus@ximian.com>
7378
7379         * mini-arm.c: fixed wrnings.
7380
7381 Fri Nov 10 19:18:32 CET 2006 Paolo Molaro <lupus@ximian.com>
7382
7383         * mini-arm.c, mini-arm.h, cpu-arm.md, inssel-float.brg,
7384         inssel-arm.brg: ARM support for soft-float.
7385
7386 Fri Nov 10 18:38:15 CET 2006 Paolo Molaro <lupus@ximian.com>
7387
7388         * mini.c, jit-icalls.c, jit-icalls.h: added first cut at handling
7389         loads and stores of 32 bit fp values.
7390
7391 2006-11-10  Zoltan Varga  <vargaz@gmail.com>
7392
7393         * mini-sparc.c (is_regsize_var): Support PTR/FNPTR too.
7394
7395         * tramp-sparc.c (mono_arch_patch_callsite): Fix this function so it actually
7396         works. Fixes #79852 and #79463.
7397
7398 Thu Nov 9 16:56:13 CET 2006 Paolo Molaro <lupus@ximian.com>
7399
7400         * mini.c, mini-codegen.c, jit-icalls.c, jit-icalls.h:
7401         more soft-float support WIP and fixes.
7402
7403 Wed Nov 8 16:40:02 CET 2006 Paolo Molaro <lupus@ximian.com>
7404
7405         * mini-arm.c: some VFP updates.
7406
7407 Tue Nov 7 19:45:51 CET 2006 Paolo Molaro <lupus@ximian.com>
7408
7409         * mini-exceptions.c: 0 is a valid local var offset in some
7410         architectures, don't assert (bug #78508).
7411
7412 Tue Nov 7 18:17:52 GMT 2006 Paolo Molaro <lupus@ximian.com>
7413
7414         * exceptions-arm.c: fixed off by one error in stack walk code.
7415
7416 Tue Nov 7 11:27:26 CET 2006 Paolo Molaro <lupus@ximian.com>
7417
7418         * mini.h, mini.c: more precise tracking of type load exceptions.
7419
7420 2006-11-03  Robert Jordan  <robertj@gmx.net>
7421
7422         * Makefile.am: [WIN32] Add monow.exe target.
7423         * driver.c: [WIN32] Don't detach the console when debugging.
7424         Fixes bug #79797.
7425         
7426 2006-10-30  Miguel de Icaza  <miguel@novell.com>
7427
7428         * tramp-x86.c (mono_arch_patch_delegate_trampoline): Eliminate warning.
7429
7430 2006-10-23  Zoltan Varga  <vargaz@gmail.com>
7431
7432         * aot-compiler.c (emit_method_info): Add a case missed earlier.
7433
7434         * driver.c (mini_regression): Fix --regression with AOT.
7435
7436         * aot-compiler.c (emit_method_info): Fix AOT on amd64.
7437
7438 2006-10-17  Zoltan Varga  <vargaz@gmail.com>
7439
7440         * mini.c (GET_CONTEXT): Correct the definition of this for sparc/linux.
7441
7442         * mini-sparc.h: Don't use sigaction on sparc/linux.
7443
7444         * exceptions-sparc.c: Call mono_arch_flush_icache () in a couple of places.
7445
7446         * mini-sparc.c (mono_sparc_flushw): Call mono_arch_flush_icache ().
7447
7448         * mini-exceptions.c: Add proper include files for getpid ().
7449
7450 2006-10-16  Zoltan Varga  <vargaz@gmail.com>
7451
7452         * aot-runtime.c (mono_aot_get_method): Change this to return the native code
7453         address instead of a MonoJitInfo* to avoid decoding the exception info for the
7454         method.
7455
7456         * aot-runtime.c aot-compiler.c: Use uint16 instead of uint32 entries in the
7457         name cache to reduce its size.
7458
7459         * mini.h (MONO_AOT_FILE_VERSION): Bump aot file format version.
7460
7461 2006-10-15  Zoltan Varga  <vargaz@gmail.com>
7462
7463         * mini-x86.c: Save/restore the current LMF structure more efficiently using
7464         the mono_lmf TLS variable.
7465
7466         * exceptions-x86.c (mono_arch_find_jit_info): Only access lmf->method in 
7467         trampoline lmf frames.  
7468
7469         * mini-sparc.h (MONO_ARCH_ENABLE_EMIT_STATE_OPT): Define this on sparc as well.
7470
7471 2006-10-14  Zoltan Varga  <vargaz@gmail.com>
7472
7473         * mini-amd64.c: Save/restore the current LMF structure more efficiently using
7474         the mono_lmf TLS variable.
7475
7476         * mini-exceptions.c: Access the LMF structure through accessors.
7477
7478         * mini.c: Allow the backends the option for storing the lmf in a dedicated TLS 
7479         variable instead of in jit_tls->lmf.
7480
7481         * mini-x86.c mini-amd64.c: Update after lmf->lmf_addr name change.
7482         
7483         * exceptions-amd64.c (mono_arch_find_jit_info): Only access lmf->method in 
7484         trampoline lmf frames.
7485
7486         * mini-amd64.c (mono_arch_emit_prolog): Do not set lmf->method as it is not needed.
7487
7488 2006-10-12  Zoltan Varga  <vargaz@gmail.com>
7489
7490        * mini.c trace.c mini-x86.c: Revert these too.
7491         
7492        * mini.c trace.c mini-x86.c: Remove warning workarounds after the mono_type_size ()
7493        signature change.
7494
7495 Tue Oct 10 11:35:20 CEST 2006 Paolo Molaro <lupus@ximian.com>
7496
7497         * genmdesc.c: removed now dead code.
7498
7499 2006-10-09  Robert Jordan <robertj@gmx.net>
7500
7501         * mini.c: Disable the CrashReporter on MacOS X; Fixes #74869
7502
7503 Mon Oct 9 17:06:41 CEST 2006 Paolo Molaro <lupus@ximian.com>
7504
7505         * mini.h: do not leave gaps in the opcode values.
7506
7507 Mon Oct 9 16:08:51 CEST 2006 Paolo Molaro <lupus@ximian.com>
7508
7509         * jit-icalls.h: flag functions as internal here, too.
7510
7511 Mon Oct 9 15:58:18 CEST 2006 Paolo Molaro <lupus@ximian.com>
7512
7513         * mini.h, aliasing.h, declsec.h, regalloc.h, trace.h: mark internal
7514         functions with the internal attribute.
7515
7516 Mon Oct 9 15:52:45 CEST 2006 Paolo Molaro <lupus@ximian.com>
7517
7518         * aot-compiler.c: fclose the file descriptor in the profile read loop.
7519
7520 Fri Oct 6 16:01:38 CEST 2006 Paolo Molaro <lupus@ximian.com>
7521
7522         * mini.c, jit-icalls.c, inssel-float.brg: beginnings of support
7523         for soft-float.
7524
7525 2006-10-05  Zoltan Varga  <vargaz@gmail.com>
7526
7527         * mini-x86.c (emit_load_volatile_arguments): New function to handle arguments of
7528         tail calls as on other platforms.
7529
7530         * mini.c (mono_method_to_ir): Fix a few tailcall problems. Fixes #79557.
7531
7532         * iltests.il: Add a few tailcall tests.
7533
7534 Tue Oct 3 16:33:08 CEST 2006 Paolo Molaro <lupus@ximian.com>
7535
7536         * driver.c: fix loop for old compilers (bug #79521).
7537
7538 2006-10-02  Zoltan Varga  <vargaz@gmail.com>
7539
7540         * mini-exceptions.c (ves_icall_get_trace): Remove debug printf.
7541
7542         * aot-runtime.c (mono_aot_get_class_from_name): Avoid a memory allocation.
7543
7544         * aot-compiler.c: Add a new option 'metadata-only' to only emit the cached
7545         metadata without any code.
7546
7547         * mini-exceptions.c (mono_handle_native_sigsegv): Add some code to print out
7548         more precise debugging information using gdb.
7549
7550 2006-09-30  Zoltan Varga  <vargaz@gmail.com>
7551
7552         * inssel-ia64.brg: Make the helper methods static.
7553
7554 Thu Sep 28 16:40:07 CEST 2006 Paolo Molaro <lupus@ximian.com>
7555
7556         * inssel-x86.brg: make the helper methods static.
7557
7558 Thu Sep 28 16:31:32 CEST 2006 Paolo Molaro <lupus@ximian.com>
7559
7560         * inssel-amd64.brg, mini-amd64.c: small cleanup, use inst_call.
7561
7562 Thu Sep 28 15:36:07 CEST 2006 Paolo Molaro <lupus@ximian.com>
7563
7564         * mini.c: updates for monoburg changes.
7565         * inssel.brg: make a few helper functions static as they should.
7566
7567 2006-09-27  Zoltan Varga  <vargaz@gmail.com>
7568
7569         * Makefile.am: Move mini-codegen.c to common_sources.
7570
7571 Wed Sep 27 15:07:08 CEST 2006 Paolo Molaro <lupus@ximian.com>
7572
7573         * mini.h: instroduce inst_call in MonoInst for use in OUTARG
7574         instructions.
7575         * Makefile.am, cpu-g4.md, inssel-ppc.brg, mini-codegen.c, mini-ppc.c,
7576         mini-ppc.h: port to use the common local register allocator.
7577
7578 2006-09-26  Zoltan Varga  <vargaz@gmail.com>
7579
7580         * mini.h: Remove the comment too then.
7581
7582 Tue Sep 26 14:02:58 CEST 2006 Paolo Molaro <lupus@ximian.com>
7583
7584         * mini.h: put back backend.data which is to be used shortly and
7585         doesn't increase the size of MonoInst. If any 64 bit arch aligned
7586         pointers on 4 byte boundaries it'd have much bigger issues running
7587         and you can ifdef it out anyway.
7588
7589 2006-09-26  Zoltan Varga  <vargaz@gmail.com>
7590
7591         * mini.h (MonoInst): Remove backend.data field since it is unused and increases
7592         MonoInst size by 4 bytes on 64 bit machines.
7593
7594 Tue Sep 26 11:57:26 CEST 2006 Paolo Molaro <lupus@ximian.com>
7595
7596         * *.{c,h,brg}: long due removal of the unused field in MonoInst and
7597         replacement with more meaningful field names. Arch maintainers, please
7598         check the assigned names are good enough for your arch.
7599
7600 2006-09-26  Zoltan Varga  <vargaz@gmail.com>
7601
7602         * cpu-ia64.md mini-ia64.c inssel-ia64.brg mini-ops.h: Get rid of the 
7603         OP_IA64_FETCHADD opcodes, use OP_ATOMIC_ADD_IMM_NEW opcodes instead.
7604
7605 Mon Sep 25 11:05:24 CEST 2006 Paolo Molaro <lupus@ximian.com>
7606
7607         * mini.h, driver.c, optflags-def.h, Makefile.am: reduce runtime
7608         relocations and memory requirements, put the optimization flags
7609         definitions in their own file.
7610
7611 2006-09-24  Zoltan Varga  <vargaz@gmail.com>
7612
7613         * jit-icalls.c (mono_helper_stelem_ref): Remove this unused helper function.
7614
7615         * mini.c (mini_init): Remove reference to mono_helper_stelem_ref.
7616
7617 2006-09-22  Zoltan Varga  <vargaz@gmail.com>
7618
7619         * mini-amd64.c (add_valuetype): Fix an uninitialized memory issue.
7620
7621 Thu Sep 21 19:06:09 CEST 2006 Paolo Molaro <lupus@ximian.com>
7622
7623         * inssel.brg: use the correct function to get the size of an item
7624         in an array, given an element class.
7625         * aot-compiler.c: do not access class->class_size directly.
7626
7627 Thu Sep 21 12:10:56 CEST 2006 Paolo Molaro <lupus@ximian.com>
7628
7629         * mini.h, debug-mini.c: added a debugging function to print
7630         info about local variables and arguments in a jitted method.
7631
7632 2006-09-20  Zoltan Varga  <vargaz@gmail.com>
7633
7634         * mini-alpha.c: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>.
7635
7636         * exceptions-ia64.c: Fix some problems reported by Bill Seurer <seurer@us.ibm.com>.
7637
7638 2006-09-19  Zoltan Varga  <vargaz@gmail.com>
7639
7640         * mini-ia64.c (mono_arch_call_opcode): Avoid using the same loop index in the
7641         inner and outer loops when passing vtypes.
7642
7643 Tue Sep 19 17:53:40 CEST 2006 Paolo Molaro <lupus@ximian.com>
7644
7645         * mini-ppc.c: take into account the cpu errata for cache flushing
7646         which caused some random errors (bug #79381).
7647
7648 2006-09-19  Zoltan Varga  <vargaz@gmail.com>
7649
7650         * mini-amd64.c (mono_arch_emit_exceptions): Emit the call to 
7651         mono_arch_throw_corlib_exception using emit_call () too. Fixes #79271.
7652
7653 2006-09-17  Zoltan Varga  <vargaz@gmail.com>
7654
7655         * aot-runtime.c (load_aot_module): Return immeditely if the AOT module was already
7656         loaded.
7657
7658         * exceptions-amd64.c (gregs_from_ucontext): Apply another patch from the
7659         freebsd ports tree.
7660
7661         * mini-amd64.c (emit_call): Avoid near calls on freebsd.
7662         (mono_arch_patch_code): Remove the unused handling of MONO_PATCH_INFO_CLASS_INIT.
7663
7664         * tramp-amd64.c (mono_arch_create_specific_trampoline): Fix check for 32 bitness of
7665         displacement.
7666
7667 2006-09-13  Zoltan Varga  <vargaz@gmail.com>
7668
7669         * aot-runtime.c (load_aot_module_from_cache): Fix PPC build.
7670
7671 2006-09-12  Zoltan Varga  <vargaz@gmail.com>
7672
7673         * mini.c (UNVERIFIED): Add a 'break-on-unverified' MONO_DEBUG option so this 
7674         macro does not have to be changed during debugging.
7675
7676         * 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>.
7677
7678         * cpu-pentium.md: Rename this to cpu-x86.md for consistency with other platforms.
7679
7680         * Makefile.am mini-x86.c mini-codegen.c: Rename pentium_desc to x86_desc.
7681         
7682         * mini.c (mini_get_ldelema_ins): Allow ldelema2d optimization if 
7683         MONO_ARCH_NO_EMULATE_MUL is defined.
7684
7685         * mini-ia64.h (MONO_ARCH_CALLEE_FREGS): Reserve f33 for use by instructions.
7686
7687         * mini-ia64.h: Define MONO_ARCH_NO_EMULATE_MUL.
7688
7689         * mini-ia64.c: Implement CEE_MUL based on gcc emitted code.
7690
7691         * mini-ia64.c (mono_arch_lowering_pass): Optimize store_membase_imm with offset==0.
7692         
7693 2006-09-11  Zoltan Varga  <vargaz@gmail.com>
7694
7695         * mini-x86.h mini-amd64.h mini-exceptions.c: Move the bsd specific MAP_ANON
7696         stuff to mini-exceptions.c where it is used.
7697
7698         * mini-sparc.c (mono_arch_setup_jit_tls_data): Remove the duplicate altstack
7699         setup code, the real one is in mini-exceptions.c.
7700
7701         * mini-amd64.h mini-amd64.c exceptions-amd64.c: Move all dependencies on the
7702         layout of ucontext_t to helper functions in exceptions-amd64.c, as on x86. Add
7703         some changes from the freebsd ports tree.
7704
7705         * mini-amd64.h exceptions-amd64.c: Fix the amd64 build. Get rid of the SC_
7706         constants.
7707         
7708         * mini-amd64.h: Freebsd has MAP_ANON instead of MAP_ANONYMOUS.
7709
7710 Mon Sep 11 13:18:55 CEST 2006 Paolo Molaro <lupus@ximian.com>
7711
7712         * mini.c: on Linux, check for /proc to be mounted
7713         (bug# 79351, novell bug#201204).
7714
7715 Mon Sep 11 13:10:12 CEST 2006 Paolo Molaro <lupus@ximian.com>
7716
7717         * mini.c: handle cases where pthread_attr_getstack() behaves
7718         incorrectly (bug #78096).
7719
7720 Mon Sep 11 11:31:10 BST 2006 Paolo Molaro <lupus@ximian.com>
7721
7722         * mini-arm.c: support larger stack frames (bug #79272).
7723
7724 2006-09-08  Zoltan Varga  <vargaz@gmail.com>
7725
7726         * aot-runtime.c (mono_aot_get_class_from_name): Remove a debug printf.
7727
7728         * aot-compiler.c: Add a hash table to the AOT file mapping class names to typedef 
7729         tokens.
7730
7731         * aot-runtime.c (mono_aot_get_class_from_name): New function used by 
7732         mono_class_from_name () to find a class from its name.
7733
7734         * mini.c (mini_init): Register mono_aot_get_class_from_name () with the runtime.
7735
7736 2006-09-07  Zoltan Varga  <vargaz@gmail.com>
7737
7738         * mini-amd64.c (emit_call): Avoid strstr () call if possible.
7739
7740 2006-09-05  Kornél Pál  <kornelpal@gmail.com>
7741
7742         * Makefile.am: Renamed mono-1.dll to mono.dll. (-avoid-version)
7743
7744 2006-09-04  Zoltan Varga  <vargaz@gmail.com>
7745
7746         * mini.c (mono_icall_get_wrapper): Fix a race condition on initializing
7747         callinfo->trampoline.
7748
7749         * mini-amd64.c (emit_call): Special case calls to the vararg array icalls. Hopefully
7750         fixes #79271.
7751         (mono_arch_patch_code): Add some debug code to help track down similar failures in the
7752         future.
7753
7754 2006-09-03  Zoltan Varga  <vargaz@gmail.com>
7755
7756         * aot-runtime.c (mono_aot_plt_resolve): Add an assert.
7757
7758 2006-09-02  Zoltan Varga  <vargaz@gmail.com>
7759
7760         * tramp-x86.c (mono_arch_create_specific_trampoline): Don't increase
7761         stats.method_trampolines, it is already done by the generic trampoline code.
7762
7763         * tramp-amd64.c (mono_arch_create_specific_trampoline): Ditto.
7764         
7765 2006-09-01  Zoltan Varga  <vargaz@gmail.com>
7766
7767         * mini.c: Remove some references to mono_compile_aot, and use cfg->compile_aot instead.
7768
7769         * aot-runtime.c: Add some tweaks to the MONO_AOT_CACHE functionality.
7770
7771         * tramp-amd64.c (mono_arch_create_specific_trampoline): Fix a FIXME.
7772
7773         * mini.c (print_jit_stats): Print mscorlib mempool size too.
7774         
7775         * mini.c (print_jit_stats): Print new stats.
7776
7777         * *-alpha.c: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>.
7778
7779 2006-08-31  Zoltan Varga  <vargaz@gmail.com>
7780
7781         * mini.c (mini_get_ldelema_ins): Fix verifier error when calling
7782         Address on two dimensional arrays. Fixes #78729.
7783
7784         * mini.h (MonoCompile): Add a 'skip_visibility' field.
7785
7786         * mini.c (method_to_ir): Disable visibility checks if skip_visibility is set on
7787         a method.
7788
7789         * mini-amd64.c (mono_arch_emit_exceptions): Fix assertion introduced by the last change.
7790
7791         * mini.c (mono_runtime_cleanup_handlers): Clean up signal handlers on unix. Fixes
7792         #79130.
7793         
7794         * mini.c (handle_array_new): Applied patch from "briaeros007". Fix
7795         a race condition.
7796         (mini_get_ldelema_ins): Ditto.
7797
7798 2006-08-30  Zoltan Varga  <vargaz@gmail.com>
7799
7800         * mini-amd64.c (mono_arch_emit_exceptions): Align fp constants to 16 bytes.
7801         (mono_arch_output_basic_block): Avoid unaligned accesses in FNEG implementation. 
7802         Fixes #79213.
7803
7804 2006-08-29 Neale Ferguson <neale@sinenomine.net>
7805
7806         * mini-s390.c, mini-s390x.c: Fix VARARG case processing with 0 arguments. Add
7807         mono_arch_get_patch_offset as a dummy entry point to allow successful link. 
7808
7809         * exceptions-s390x.c: Cosmetic change.
7810
7811         * tramp-s390.c: Fix warning.
7812
7813         * cpu-s390.md: Correct length of mul_imm.
7814
7815 Wed Aug 23 19:24:00 CEST 2006 Paolo Molaro <lupus@ximian.com>
7816
7817         * aot-compiler.c: added binary writer with ELF backend
7818         implementation (only on Linux/x86 for now).
7819
7820 2006-08-18  Zoltan Varga  <vargaz@gmail.com>
7821
7822         * Makefile.am: Don't run net 2.0 AOT tests.
7823
7824         * aot-compiler.c (compile_method): Skip methods with tail calls as well.
7825         (mono_compile_assembly): Skip net 2.0 assemblies as well.
7826
7827         * aot-runtime.c (load_patch_info): Fix an uninitialized memory error.
7828
7829 Fri Aug 18 19:38:28 CEST 2006 Paolo Molaro <lupus@ximian.com>
7830
7831         * aot-compiler.c: simplified and refactored the asm-writing code
7832         to allow different backends.
7833
7834 2006-08-18  Zoltan Varga  <vargaz@gmail.com>
7835
7836         * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file format version.
7837
7838         * aot-compiler.c aot-runtime.c: Reorg the GOT slot allocation code a 
7839         little. Share patches of type TYPE_FROM_HANDLE as well.
7840
7841         * mini.c (mono_patch_info_equal): New helper function.
7842         (mono_patch_info_hash): Ditto.
7843
7844         * aot-compiler.c (emit_method_code): Fix s390 build.
7845
7846         * mini.c (mono_allocate_stack_slots_full): Fix yet another place where byref
7847         is not handled because it is stored as a flag and not as a type ctor. Fixes
7848         #79016.
7849
7850 2006-08-17  Zoltan Varga  <vargaz@gmail.com>
7851
7852         * aot-compiler.c: Fix computation of GOT slot statistics.
7853         
7854         * aot-compiler.c aot-runtime.c: Implement sharing of GOT slots for classes/fields.
7855         Also remove support for not PIC AOT.
7856
7857         * mini.h: Bump AOT file format version.
7858
7859         * objects.cs: Add a test for #78990.
7860
7861         * mini-x86.c (mono_arch_output_basic_block): Applied patch from Peter Dettman
7862         (peter.dettman@iinet.net.au). Fixes #79087.
7863
7864         * basic-long.cs: Add a test for the above.
7865
7866 2006-08-16  Zoltan Varga  <vargaz@gmail.com>
7867
7868         * aot-compiler.c (get_got_offset): Add a cache for GOT entries, not yet used.
7869         
7870         * aot-compiler.c (get_plt_index): Add a cache for wrappers too. Simplify the
7871         code somewhat.
7872
7873 2006-08-15  Zoltan Varga  <vargaz@gmail.com>
7874
7875         * mini.c (mini_init): Fix registration of idiv/imul opcodes which can throw
7876         exceptions.
7877
7878 2006-08-10  Jonathan Chambers  <joncham@gmail.com>
7879
7880         * mini.c: Don't verify COM proxy invoke calls
7881         
7882
7883 2006-08-10  Dick Porter  <dick@ximian.com>
7884
7885         * wapihandles.c (mini_wapi_seminfo): More info, to help track down
7886         which process is holding semaphores locked.
7887
7888 2006-08-08  Zoltan Varga  <vargaz@gmail.com>
7889
7890         * mini-ia64.c mini-amd64.c: Fix #79027.
7891
7892         * mini-sparc.c (mono_arch_call_opcode): Fix the previous patch.
7893
7894         * mini-sparc.c (mono_arch_call_opcode): Fix #79027.
7895
7896         * mini-x86.c (mono_arch_call_opcode): Handle the case where there are no
7897         implicit arguments in a vararg call. Fixes #79027.
7898
7899 2006-08-07  Zoltan Varga  <vargaz@freemail.hu>
7900
7901         * mini.c (mono_get_element_address_signature): Use CDECL calling convention on windows. Fixes #78969.
7902         (mono_get_array_new_va_signature): Ditto.
7903
7904 2006-08-05  Zoltan Varga  <vargaz@gmail.com>
7905
7906         * aot-runtime.c: Call init_plt lazily.
7907
7908         * inssel-long.brg: Fix unsigned long->int conversion.
7909
7910         * aot-runtime.c (init_plt): Remove a redundant make_writable () call.
7911
7912         * aot-compiler.c aot-runtime.c: Reorganize the file structure in the amd64 case so
7913         that most data is now in the .rss/.data section.
7914
7915 2006-08-04  Zoltan Varga  <vargaz@gmail.com>
7916
7917         * aot-compiler.c: Correct the computation of the 'direct-calls' statistic.      
7918
7919         * aot-compiler.c: Print the number of methods without GOT slots as a statistics.
7920
7921         * aot-compiler.c aot-runtime.c tramp-amd64.c: Resurrect amd64 AOT support.
7922
7923         * tramp-amd64.c (mono_arch_patch_callsite): Fix a warning.
7924
7925         * jit-icalls.c (mono_helper_compile_generic_method): Unbox vtypes since this is a
7926         virtual call. Fixes #79010.
7927
7928         * mini.c (mono_method_to_ir): Pass an additional out arg to compile_generic_method 
7929         and use the result as the this argument in the real call.
7930
7931         * generics.2.cs: Add a new test for #79010.
7932         
7933 2006-08-03  Zoltan Varga  <vargaz@gmail.com>
7934
7935         * mini-x86.c: Fix a warning.
7936
7937         * aot-compiler.c: Add a bunch of statistics.
7938
7939         * mini.c (inline_method): Disable inlining in out-of-line bblocks.
7940
7941 2006-08-02  Zoltan Varga  <vargaz@gmail.com>
7942
7943         * mini-arch.h Makefile.am mini-ops.h mini-codegen.c: More alpha updates.
7944
7945 2006-08-01  Zoltan Varga  <vargaz@gmail.com>
7946
7947         * 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>.
7948
7949 2006-07-13  Miguel de Icaza  <miguel@novell.com>
7950
7951         * mini.c (mono_method_to_ir): Obtain the original method in the
7952         CIL stream and use this to perform validation.
7953
7954         Fixed: #78816
7955
7956 2006-07-19  Zoltan Varga  <vargaz@gmail.com>
7957
7958         * mini-x86.c (mono_arch_get_argument_info): Fix a warning.
7959         (mono_arch_call_opcode): Ditto.
7960
7961         * mini.c (mono_method_to_ir): Clear ins_flag at the end of CEE_CALL. Fixes
7962         #78826.
7963
7964         * mini.c (mono_patch_info_dup_mp): New helper function.
7965         
7966         * aot-compiler.c (compile_method): Fix some of the memory allocated during
7967         compilation. Fixes #78827.
7968
7969 2006-07-18  Kornél Pál  <kornelpal@gmail.com>
7970
7971         * declsec.c: Use original security informations for
7972           MONO_WRAPPER_MANAGED_TO_MANAGED.
7973
7974 2006-07-15  Jonathan Chambers  <joncham@gmail.com>
7975
7976         * mini.c: Allow Com Interop methods/classes and
7977         don't verify COM wrapper calls
7978         
7979
7980 2006-07-13  Zoltan Varga  <vargaz@gmail.com>
7981
7982         * inssel-long32.brg: Fix long->i4 checked conversion.
7983
7984         * exceptions.cs: Add a test for the above.
7985
7986 2006-07-08  Zoltan Varga  <vargaz@gmail.com>
7987
7988         * mini-exceptions.c (mono_setup_altstack): Fix a memory leak.
7989
7990         * mini.c: Applied patch from Joachim Ante (joe@otee.dk). Fix some shutdown 
7991         leaks.
7992
7993         * helpers.c (mono_disassemble_code): Avoid using fixed temporary files. Fixes
7994         #78775.
7995
7996 2006-07-03  Zoltan Varga  <vargaz@gmail.com>
7997
7998         * mini.c: Fix solaris/x86 exception handling.
7999
8000         * Makefile.am: Get rid of $(ICU_LIBS).
8001
8002 2006-07-02  Zoltan Varga  <vargaz@gmail.com>
8003
8004         * mini-exceptions.c: Fix handling of unhandled SIGSEGV exceptions on ia64.
8005         (ves_icall_System_Security_SecurityFrame_GetSecurityStack): Use MONO_INIT_CONTEXT_FROM_CURRENT.
8006         (ves_icall_System_Security_SecurityFrame_GetSecurityFrame): Ditto.
8007
8008         * mini-ia64.h (MONO_CONTEXT_SET_FUNC): New macro.
8009
8010         * mini-exceptions.c (mono_handle_native_sigsegv): Prevent infinite loops if
8011         this function causes a SIGSEGV.
8012
8013 2006-06-22  Zoltan Varga  <vargaz@gmail.com>
8014
8015         * mini.c: Remove unused solaris/x86 includes.
8016
8017 2006-06-21  Zoltan Varga  <vargaz@gmail.com>
8018
8019         * jit.h: Add G_BEGIN_DECLS/G_END_DECLS.
8020
8021 2006-06-20  Jb Evain  <jbevain@gmail.com>
8022
8023         * cpu-g4.md: fix max length of start_handler instruction.
8024
8025 2006-06-20  Massimiliano Mantione  <massi@ximian.com>
8026         * simple-cee-ops.h, simple-mini-ops.h: Fixed bug 78656.
8027
8028 2006-06-16  Massimiliano Mantione  <massi@ximian.com>
8029         * ssa.c: Fixed bug 78653 for SSA based deadce.
8030         * mini.h: added MONO_INST_DEFINITION_HAS_SIDE_EFFECTS flag go
8031         MonoInst.flags, used in SSA based deadce.
8032         * aliasing.c: Fixed bug 78653 for "fastpath" deadce.
8033         * simple-cee-ops.h, simple-mini-ops.h: Fixed bug 78653.
8034
8035 Thu Jun 15 16:52:46 CEST 2006 Paolo Molaro <lupus@ximian.com>
8036
8037         * tramp-ppc.c: don't use malloc () for trampoline code, sometimes
8038         it can end up using non executable memory on ppc64 systems
8039         running ppc32 userspace (fix from Johannes Berg).
8040
8041 2006-06-14  Dick Porter  <dick@ximian.com>
8042
8043         * wapihandles.c: Fix a bunch of signed/unsigned warnings from gcc
8044         4.1.1
8045
8046 2006-06-13  Massimiliano Mantione  <massi@ximian.com>
8047         * mini.c: Made so that inline is locally disabled if it would
8048         trigger a .cctor, because too many apps depend on this behavior
8049         (which seems to be also the one of the MS CLR).
8050
8051 2006-06-13  Zoltan Varga  <vargaz@gmail.com>
8052
8053         * mini-amd64.c (mono_emit_stack_alloc): Fix initialization of localloc'ed memory.
8054         No idea why this worked before.
8055
8056         * branch-opts.c (mono_branch_optimize_exception_target): Avoid branches
8057         which branch to outer exception clauses since they could skip the
8058         inner finally clauses. Fixes #78633.
8059
8060         * exceptions.cs: Add a test for the above.
8061
8062         * mini.c (merge_basic_blocks): Nullify the branch at the end of the first bb.
8063         Fixes #78629.
8064
8065         * iltests.il: Add a test for the above.
8066
8067 2006-06-12  Zoltan Varga  <vargaz@gmail.com>
8068
8069         * mini.c (remove_block_if_useless): Do not remove the bblock immediately
8070         after the end of a try bblock, to prevent asserts in mini_method_compile ().
8071
8072         * iltests.il: Add a test for the above.
8073
8074 2006-06-10  Zoltan Varga  <vargaz@gmail.com>
8075
8076         * mini-ia64.c (mono_arch_lowering_pass): Remove some code duplication.
8077         
8078         * mini-ia64.c inssel-ia64.brg: Implement the new net 2.0 Interlocked.Add
8079         methods as instrinsics.
8080
8081 2006-06-09  Wade Berrier <wberrier@novell.com>
8082
8083         * Makefile.am: Fix sources list for svn rename so that make dist succeeds
8084         (simple-cee-ops.h ssapre-mini-ops.h)
8085
8086 2006-06-09  Neale Ferguson <neale@sinenomine.net>
8087
8088         * mini-exceptions.c (ves_icall_get_frame_info): Fix this function on s390/s390x.
8089         * mini-s390x.c, mini-s390.c: Correct ATOMIC operations (incorrect register for CS
8090         instruction).
8091         * mini-s390x.h, mini-s390.h: Simplify MCONTEXT_GET_BP.
8092         * cpu-s390x.md: Fix max. length values for a couple of instructions.
8093
8094 2006-06-09  Jonathan Chambers  <jonathan.chambers@ansys.com>
8095
8096         * mini-exceptions.c: Minor fix for building mono in Visual Studio.
8097
8098 2006-06-08  Massimiliano Mantione  <massi@ximian.com>
8099
8100         * ssapre-cee-ops.h: Renamed as "simple-cee-ops.h"
8101         * simple-cee-ops.h: Was "ssapre-cee-ops.h" (renamed).
8102         * ssapre-mini-ops.h: Renamed as "simple-mini-ops.h"
8103         * simple-mini-ops.h: Was "ssapre-mini-ops.h" (renamed).
8104         * local-propagation.c: In mono_cprop_invalidate_values use a whitelist
8105         of opcodes, so that bug 78549 should not happen again.
8106         * ssapre.c: Updated to use the renamed files.
8107
8108 2006-06-08  Zoltan Varga  <vargaz@gmail.com>
8109
8110         * mini-amd64.c (mono_arch_output_basic_block): Fix a wrong reg-reg move 
8111         in OP_ATOMIC_EXCHANGE_I4.
8112
8113 2006-06-07  Wade Berrier <wberrier@novell.com>
8114
8115         * tramp-s390.c: Fix s390 build (add missing pointer declarations 
8116         in mono_debugger_create_notification_function)
8117
8118 2006-06-06  Zoltan Varga  <vargaz@gmail.com>
8119
8120         * mini.c (NEW_AOTCONST_TOKEN): Fix amd64 build.
8121         
8122         * mini.c (type_from_stack_type): Disable some changes which do not
8123         seem to work.
8124
8125         * driver.c: Reenable opts.
8126
8127         * mini.h (MonoStackSlot): New structure to keep track of the verification state
8128         of the evaluation stack.
8129         
8130         * mini.h (MonoBasicBlock): Add a 'stack_state' field to keep track of the
8131         evaluation stack trace at entry to the bblock.
8132
8133         * mini.c (merge_stacks): New function to perform verification of stack merges.
8134         Turned off by default.
8135
8136         * mini.c: Fill up ins->klass for instructions whose type is STACK_OBJ or
8137         STACK_MP.
8138         
8139 2006-06-06  Massimiliano Mantione  <massi@ximian.com>
8140
8141         * local-propagation.c: Fixed bug 78549.
8142
8143 2006-06-04  Zoltan Varga  <vargaz@gmail.com>
8144
8145         * mini-exceptions.c (ves_icall_get_frame_info): Fix this function on ia64.
8146
8147 2006-06-02  Miguel de Icaza  <miguel@novell.com>
8148
8149         * tramp-sparc.c, tramp-ppc.c, tramp-s390.c, tramp-s390x.c,
8150         tramp-arm.c, tramp-ia64.c
8151         (mono_debugger_create_notification_function): Update signature to
8152         new signature and use new protocol for creating the notification
8153         function.  
8154
8155         Should fix the build.
8156
8157 2006-06-02  Geoff Norton  <gnorton@customerdna.com>
8158
8159         * exceptions-ppc.c (mono_jit_walk_stack)
8160         (ves_icall_get_frame_info): Fix the build
8161
8162 2006-06-02  Zoltan Varga  <vargaz@gmail.com>
8163
8164         * mini.c (mono_set_defaults): Fix the handling of -O=-all.
8165
8166 2006-05-31  Raja R Harinath  <rharinath@novell.com>
8167
8168         * il2tests.2.il: New file for generics CIL tests.  Add test for
8169         #78019.
8170         * Makefile.am: Update.
8171
8172         Fix #78019
8173         * mini.c (mono_method_to_ir): Don't apply box+brtrue optimization
8174         to nullable types.
8175
8176 2006-05-30  Massimiliano Mantione  <massi@ximian.com>
8177
8178         * aliasing.c: Fixed bug 78311.
8179
8180 2006-05-29  Martin Baulig  <martin@ximian.com>
8181
8182         * mini-exceptions.c (mono_find_jit_info): When computing the
8183         native offset, check whether we're actually inside the method's
8184         code; call mono_debug_print_stack_frame() to format the frame.
8185         (ves_icall_System_Exception_get_trace): Call
8186         mono_debug_print_stack_frame() to format the stack frame.
8187         (ves_icall_get_trace): Update to the new debugging API.
8188         (mono_jit_walk_stack_from_ctx): Likewise.
8189         (ves_icall_get_frame_info): Likewise.
8190
8191         * mini.c (get_method_from_ip): Use the new debugging API.
8192         (mono_print_method_from_ip): Likewise.
8193
8194         * exceptions-ppc.c
8195         (mono_jit_walk_stack): Use the new debugging API.
8196         (ves_icall_get_frame_info): Likewise.   
8197
8198 2006-05-27  Zoltan Varga  <vargaz@gmail.com>
8199
8200         * mini-amd64.c (mono_arch_output_basic_block): Fix MONO_PROFILE_COVERAGE.
8201
8202 2006-05-25  Massimiliano Mantione  <massi@ximian.com>
8203
8204         * mini.c: Added "limitator" to inline for debugging.
8205
8206 2006-05-24  Martin Baulig  <martin@ximian.com>
8207
8208         * debug-debugger.c (mono_debugger_init): Create a private,
8209         malloc()-based code manager for the notification function and
8210         intentionally leak it on exit.  This fixes the crash-on-exit race
8211         condition.
8212
8213         * tramp-amd64.c
8214         (mono_debugger_create_notification_function): Added
8215         `MonoCodeManager *' argument.
8216
8217         * tramp-x86.c
8218         (mono_debugger_create_notification_function): Added
8219         `MonoCodeManager *' argument.
8220
8221 2006-05-23  Massimiliano Mantione  <massi@ximian.com>
8222
8223         * aliasing.c: Fixed 64 bit issue.
8224         * driver.c: Enabled inline,consprop,copyprop,treeprop,deadce by
8225         default since all known bugs are fixed (one more time!).
8226
8227 Tue May 23 13:47:28 CEST 2006 Paolo Molaro <lupus@ximian.com>
8228
8229         * mini.c: write barrier support.
8230
8231 2006-05-23  Martin Baulig  <martin@ximian.com>
8232
8233         * debug-debugger.c: Revert Paolo's change.  Add comment and #error
8234         check at the top of the file.
8235
8236 Sun May 21 12:22:29 CEST 2006 Paolo Molaro <lupus@ximian.com>
8237
8238         * debug-debugger.c: fix the build. Again. Hopefully Martin will stop
8239         reverting changes without reason and without changelog entries.
8240
8241 2006-05-18  Zoltan Varga  <vargaz@gmail.com>
8242
8243         * mini-sparc.c (mono_arch_output_basic_block): Add support for large stack offets
8244         to a few opcodes. Fixes #78439.
8245
8246         * mini-sparc.c: Rename mono_sparch_break () to mono_arch_break () to improve
8247         consistency with other archs.
8248
8249         * mini-ia64.c (mono_arch_emit_prolog): Remove debug stuff left in by mistake.
8250
8251 Wed May 17 18:07:33 CEST 2006 Paolo Molaro <lupus@ximian.com>
8252
8253         * debug-debugger.c: fix the build.
8254
8255 2006-05-17  Martin Baulig  <martin@ximian.com>
8256
8257         * debug-debugger.c
8258         (debugger_thread_vtable): Moved here from ../metadata/threads.c.
8259         (debugger_init_threads): Formerly known as mono_debugger_init_threads().
8260         (debugger_finalize_threads): Formaly known as mono_debugger_finalize_threads().
8261         (debugger_attach): Call GC_mono_debugger_add_all_threads().
8262
8263 2006-05-11  Zoltan Varga  <vargaz@gmail.com>
8264
8265         * mini.c (mini_init): Call pthread_attr_destroy () to fix a small memory leak.
8266
8267 2006-05-10  Zoltan Varga  <vargaz@gmail.com>
8268
8269         * mini-x86.c (mono_arch_instrument_epilog): Fix handling of 
8270         MONO_TYPE_GENERICINST.
8271         
8272         * mini-amd64.c (mono_arch_instrument_epilog): Fix handling of 
8273         MONO_TYPE_GENERICINST.
8274
8275 2006-05-09  Zoltan Varga  <vargaz@gmail.com>
8276
8277         * mini-x86.c (mono_arch_get_vcall_slot_addr): Add a missing call sequence. Fixes
8278         #78325.
8279
8280 2006-05-08  Zoltan Varga  <vargaz@gmail.com>
8281
8282         * mini.c (mono_create_jump_trampoline): Allocate MonoJitInfo from the domain
8283         mempool.
8284         (mono_jit_free_method): Remove the method from jump_trampoline_hash as well.
8285
8286 2006-05-06  Zoltan Varga  <vargaz@gmail.com>
8287
8288         * mini.c (mini_cleanup): Applied patch from Joachim Ante (joe@otee.dk). Call
8289         mono_trace_cleanup ().
8290
8291         * iltests.il: Fix problem with the newly added test.
8292
8293         * mini-codegen.c (mono_local_regalloc): When changing the dreg of an instruction
8294         due to register constraints, free up the previous hreg. Fixes #78314.
8295
8296         * iltests.il: Add new test for #78314.  
8297
8298         * mini-x86.c (mono_arch_get_inst_for_method): Use OP_ATOMIC_ADD_NEW_I4 for
8299         Interlocked.Add. Fixes #78312.
8300
8301         * mini-amd64.c (mono_arch_get_inst_for_method): Ditto.
8302         
8303 2006-05-05  Zoltan Varga  <vargaz@gmail.com>
8304
8305         * inssel.brg (mini_emit_virtual_call): Fix a warning.
8306
8307 2006-05-05  Martin Baulig  <martin@ximian.com>
8308
8309         * debug-mini.c (mono_debug_open_block): New method.
8310
8311         * mini-amd64.c
8312         (mono_arch_output_basic_block): Call mono_debug_open_block() at
8313         the beginning of each basic block.
8314
8315         * mini-x86.c
8316         (mono_arch_output_basic_block): Call mono_debug_open_block() at
8317         the beginning of each basic block.
8318
8319 2006-05-04  Massimiliano Mantione  <massi@ximian.com>
8320
8321         * driver.c: Disabled inline,consprop,copyprop,treeprop,deadce by
8322         default until I understand why they break the build on amd64.
8323
8324 2006-05-04  Zoltan Varga  <vargaz@gmail.com>
8325
8326         * mini.c (mini_cleanup): Call mono_cleanup ().
8327
8328         * mini.c (UNVERIFIED): New macro to make it easier to track down verification
8329         errors.
8330
8331 2006-05-04  Massimiliano Mantione  <massi@ximian.com>
8332
8333         * aliasing.c: Fixed shameful cut&paste error that caused JIT crashes.
8334         * driver.c: Enabled inline,consprop,copyprop,treeprop,deadce by
8335         default since all known bugs are fixed, and I cannot reproduce bug
8336         77944... I'm asking Matt Hargett to test again after this commit.
8337
8338 2006-04-28  Massimiliano Mantione  <massi@ximian.com>
8339
8340         * mini-codegen.c: Fixed typo that thrashed inline.
8341
8342 2006-04-28  Zoltan Varga  <vargaz@gmail.com>
8343
8344         * dominators.c (compute_dominators): Avoid using a worklist since
8345         it is not correct in some cases. Instead, iterate over all bblocks as
8346         in the original paper. Fixes --compile-all -O=all System.Xml.dll.
8347
8348 2006-04-28  Miguel de Icaza  <miguel@novell.com>
8349
8350         * mini.c (mono_jit_compile_method_inner): Use
8351         mono_prepare_exception_from_error that resets the value
8352         internally.
8353
8354 2006-04-27  Miguel de Icaza  <miguel@novell.com>
8355
8356         * mini.c: Move the mini_loader_error_to_exception to metadata. 
8357         
8358 2006-04-27  Massimiliano Mantione  <massi@ximian.com>
8359
8360         * aliasing.c: Fixed bug 78210.
8361
8362 2006-04-27  Massimiliano Mantione  <massi@ximian.com>
8363
8364         * driver.c: Disabled inline,consprop,copyprop,treeprop,deadce by
8365         default until all their problems (or the ones they trigger) are fixed.
8366
8367 2006-04-26  Zoltan Varga  <vargaz@gmail.com>
8368
8369         * aot-runtime.c (mono_aot_get_method_from_token_inner): Fix the previous patch.
8370         
8371         * aot-runtime.c (mono_aot_get_method_from_token_inner): Mark the method
8372         as loaded only after resolving patches since that could invoke the same method.
8373
8374         * aot-runtime.c (mono_aot_plt_resolve): Fix ppc etc. builds.
8375
8376         * aot-compiler.c: Refactor mono_aot_compile_aot () into a bunch of smaller
8377         functions.
8378
8379         * aot-runtime.c (init_plt): Use a normal trampoline to transfer code to the
8380         AOT loader.
8381
8382         * aot-compiler.c (emit_plt): Pass the plt offset in %eax instead of on the
8383         stack.
8384
8385         * mini-trampolines.c (mono_aot_plt_trampoline): New trampoline to handle calls
8386         made from AOT code through the PLT table.
8387
8388         * mini-x86.h mini-amd64.h: Define MONO_ARCH_AOT_PLT_OFFSET_REG to the register
8389         holding the plt offset when a call is made to the aot plt trampoline.
8390         
8391 2006-04-25  Zoltan Varga  <vargaz@gmail.com>
8392
8393         * aot-runtime.c aot-compiler.c cpu-amd64.md mini-amd64.c: Update parts of the 
8394         amd64 AOT support.
8395
8396         * Makefile.am (common_sources): Fix build breakage.
8397
8398         * aot-runtime.c aot-compiler.c: Reorganize the AOT code yet again: Make all
8399         calls through a jump table similar to the ELF PLT table. Avoid indirect calls for
8400         intra-assembly calls if possible.
8401         
8402         * tramp-*.c: Add new functions for patching/nullifying PLT entries.
8403
8404         * mini-trampolines.c: Handle PLT entries.
8405
8406         * mini.c: Avoid creating a GOT var for calls.
8407
8408         * jit-icalls.c (helper_ldstr_mscorlib): New helper function for loading strings
8409         from mscorlib code.
8410
8411         * jit-icalls.c (helper_newobj_mscorlib): New helper function to create objects
8412         from mscorlib code.
8413
8414         * mini.c (mono_method_to_ir): Use the new helper functions in throw bblocks in
8415         AOT code.       
8416
8417         * mini.h: Bump AOT file format version.
8418         
8419         * mini.c (get_basic_blocks): Fix the calculation of bb->out_of_line so it
8420         covers more cases.
8421
8422 2006-04-25  Martin Baulig  <martin@ximian.com>
8423
8424         * driver.c: Disable copyprop, consprop and inline when running
8425         inside the debugger.
8426
8427 2006-04-25  Martin Baulig  <martin@ximian.com>
8428
8429         * debug-debugger.h (MonoDebuggerInfo): Replaced `get_thread_id'
8430         with `get_current_thread' and added `detach'.
8431         (MonoDebuggerMetadataInfo): Added `thread_size',
8432         `thread_tid_offset', `thread_stack_ptr_offset' and
8433         `thread_end_stack_offset'.
8434
8435 2006-04-25  Zoltan Varga  <vargaz@gmail.com>
8436
8437         * aot.c Makefile.am: Split aot.c into two new files aot-compiler.c and 
8438         aot-runtime.c.
8439
8440         * inssel.brg (mini_emit_load_intf_reg_vtable): Use a new kind of AOT constant
8441         ADJUSTED_IID to avoid the need for adjusting the IID at runtime.
8442
8443         * mini.h (MonoJumpInfoType): Add MONO_PATCH_INFO_ADJUSTED_IID.
8444
8445         * mini.c (mono_resolve_patch_target): Handle ADJUSTED_IID.
8446
8447         * aot.c: Add support for ADJUSTED_IID.  
8448
8449 2006-04-24  Zoltan Varga  <vargaz@gmail.com>
8450
8451         * aot.c (emit_method_order): Don't align method_order_end.
8452
8453         * inssel.brg (stmt): Fix interface calls in AOT code which got broken by
8454         the interface ID changes.
8455
8456 2006-04-21  Dick Porter  <dick@ximian.com>
8457
8458         * mini.c (mini_thread_cleanup): Clear the JIT TLS data when
8459         cleaning up a thread.  Fixes the new part of bug 77470.
8460
8461 2006-04-20  Geoff Norton  <gnorton@customerdna.com>
8462
8463         * mini-ppc.c: Call mono_jit_thread_attach when transitioning a native
8464         to managed wrapper.
8465                      
8466 2006-04-19  Zoltan Varga  <vargaz@gmail.com>
8467
8468         * mini.h mini.c: Remove mono_type_to_ldind/stind () which are now in marshal.c.
8469         
8470         * mini.c (mono_runtime_install_handlers): Handle SIGABRT similarly to
8471         SIGSEGV. Fixes #78072.
8472
8473         * mini-exceptions.c (mono_handle_native_sigsegv): Add a 'signal' argument,
8474         unregister our SIGABRT handler.
8475
8476 2006-04-19  Massimiliano Mantione  <massi@ximian.com>
8477
8478         * mini.c: Disabled inline where it can alter the call stack in a
8479         way visible from managed code.
8480         * driver.c: enabled inline,consprop,copyprop,treeprop,deadce by
8481         default.
8482
8483 2006-04-16  Zoltan Varga  <vargaz@gmail.com>
8484
8485         * mini-amd64.c (mono_arch_emit_prolog): Attach the thread to the runtime as it is done
8486         on other platforms. Fixes #78089.
8487
8488 2006-04-13  Martin Baulig  <martin@ximian.com>
8489
8490         * driver.c: Also check a `MONO_INSIDE_MDB' environment variable to
8491         determine whether we're inside the debugger.
8492
8493         * debug-debugger.h
8494         (MonoDebuggerMetadataInfo): Added all offsets from `MonoDefaults'.
8495
8496 2006-04-12  Zoltan Varga  <vargaz@gmail.com>
8497
8498         * mini.c (mono_method_to_ir): Handle multiple LEAVE statements inside a single
8499         handler clauses. Fixes #78024.
8500
8501         * mini-sparc.c (mono_arch_output_basic_block): Handle large offsets
8502         in the CALL_MEMBASE opcodes. Fixes #78088.
8503         (mono_arch_get_vcall_slot_addr): Ditto.
8504
8505 2006-04-10  Martin Baulig  <martin@ximian.com>
8506
8507         * debug-debugger.c: The thread handling code has now been moved
8508         into ../metadata/threads.c.
8509
8510 2006-04-10  Zoltan Varga  <vargaz@gmail.com>
8511
8512         * driver.c (mono_main): Fix --with-gc=none build.
8513
8514         * mini-codegen.c (mono_spillvar_offset): Improve alignment.
8515         (mono_spillvar_offset_float): Ditto.
8516         (mono_local_regalloc): Only do the OP_MOVE optimization if ins->dreg is a local
8517         hreg, not when its !global, since on ia64, there is a third category: stacked
8518         registers.      
8519
8520 Mon Apr 10 14:39:49 CEST 2006 Paolo Molaro <lupus@ximian.com>
8521
8522         * mini.c: set MonoInst->klass for load field address and a few other
8523         places.
8524
8525 2006-04-10  Zoltan Varga  <vargaz@gmail.com>
8526
8527         * helpers.c (mono_disassemble_code): Emit debug info on amd64 as well.
8528
8529 2006-04-07  Zoltan Varga  <vargaz@gmail.com>
8530
8531         * dominators.c (compute_dominators): Fix yet another bug which surfaced after
8532         the branch opt changes.
8533
8534 2006-04-06  Dick Porter  <dick@ximian.com>
8535
8536         * wapihandles.c (mini_wapi_semdel): Fix parameters in semctl () call.
8537         
8538         * wapihandles.c (mini_wapi_seminfo): 
8539         * driver.c (mono_main): Add semaphore info option
8540
8541 2006-04-05  Zoltan Varga  <vargaz@gmail.com>
8542
8543         * dominators.c (compute_dominators): Fix a bug which surfaced after the recent
8544         branch optimization changes. Fixes #78009.
8545
8546 Wed Apr 5 16:40:33 CEST 2006 Paolo Molaro <lupus@ximian.com>
8547
8548         * mini.c: ignore accessibility of methods in managed->native wrappers.
8549
8550 2006-04-04  Zoltan Varga  <vargaz@gmail.com>
8551
8552         * mini.c (mini_cleanup): Call print_jit_stats () earlier since it accesses metadata.
8553         
8554         * mini.c (mini_cleanup): Free 'emul_opcode_map' as well.
8555
8556 2006-04-03  Zoltan Varga  <vargaz@gmail.com>
8557
8558         * mini.c: Modify the branch optimizations to preserve the invariant that
8559         the entries inside the in_bb and out_bb arrays are unique.
8560         (mono_unlink_bblock): Avoid creation of new arrays.
8561
8562 2006-04-02  Zoltan Varga  <vargaz@gmail.com>
8563
8564         * mini.c (mono_unlink_bblock): Fix regression caused by previous
8565         change (#77992).
8566
8567 2006-04-01  Zoltan Varga  <vargaz@gmail.com>
8568
8569         * mini.c (optimize_branches): Remove the "optimizations" in
8570         the cbranch1/cbranch2 -> branch cases which were causing several
8571         problems in the past. Fixes #77986.
8572
8573 2006-03-31  Chris Toshok  <toshok@ximian.com>
8574
8575         * driver.c (DEFAULT_OPTIMIZATIONS): back out the new set of
8576         default optimizations :(
8577
8578 2006-03-31  Zoltan Varga  <vargaz@gmail.com>
8579
8580         * inssel-x86.brg mini-codegen.c mini.c: Merge some changes/fixes from linear-il
8581         branch.
8582
8583 2006-03-31  Massimiliano Mantione  <massi@ximian.com>
8584
8585         * local-propagation.c: Added comments to structs and removed
8586         "Mono" prefixes from local tree mover types.
8587
8588 2006-03-30  Zoltan Varga  <vargaz@gmail.com>
8589
8590         * Makefile.am (arch_sources): Define this for each architecture so 
8591         libmono_la_SOURCES is defined in one place.
8592
8593 Wed Mar 29 20:51:14 CEST 2006 Paolo Molaro <lupus@ximian.com>
8594
8595         * driver.c, wapihandles.c, Makefile.am: integrate the io-layer utils
8596         from handles/.
8597
8598 Wed Mar 29 17:16:57 CEST 2006 Paolo Molaro <lupus@ximian.com>
8599
8600         * driver.c: print the GC name supplied by configure.
8601
8602 2006-03-29  Massimiliano Mantione  <massi@ximian.com>
8603
8604         * local-propagation.c: Added tree mover, and moved here all the
8605         local propagation code from mini.c
8606         * mini.c: Added support for treeprop, and moved all the local
8607         propagation code to local-propagation.c
8608         * mini.h: Added support for treeprop
8609         * driver.c: Added support for treeprop, enabled consprop, copyprop,
8610         treeprop, inline and deadce by default
8611         * Makefile.am: Added local-propagation.c
8612
8613 2006-03-25  Zoltan Varga  <vargaz@gmail.com>
8614
8615         * exceptions-sparc.c: Applied patch from David S. Miller  <davem@sunset.davemloft.net>: Implement correct support for sparc/linux.
8616
8617 Fri Mar 24 20:07:19 CET 2006 Paolo Molaro <lupus@ximian.com>
8618
8619         * debug-debugger.c: make it compile without the Boehm GC.
8620
8621 Wed Mar 22 18:25:18 CET 2006 Paolo Molaro <lupus@ximian.com>
8622
8623         * mini.c: fixed issue with mismatch when an icall is registered
8624         with multiple names but same address.
8625
8626 Tue Mar 21 15:59:57 CET 2006 Paolo Molaro <lupus@ximian.com>
8627
8628         * declsec.c, mini-exceptions.c: use write barrier to set reference
8629         fields of managed objects.
8630
8631 2006-03-19  Zoltan Varga  <vargaz@gmail.com>
8632
8633         * mini.c (mono_print_method_from_ip): Recognize JIT trampolines as well.
8634         (can_access_internals): Fix a warning.
8635
8636         * mini.c (print_method_from_ip): Rename this to 
8637         mono_print_method_from_ip so it gets exported.
8638
8639         * trace.c: Deal with strings inside StringBuilder's containing garbage
8640         and fix memory leaks. Fixes #77848.
8641
8642 2006-03-19  Zoltan Varga  <vargaz@gmail.com>
8643
8644         * mini.c (mini_init): Disable the setting of GC_stackbottom on ia64. Hopefully
8645         fixes #77787.
8646
8647 2006-03-16 Neale Ferguson <neale@sinenomine.net>
8648         
8649         * mini-s390.c: Remove OP_X86_TEST_NULL.
8650
8651 Thu Mar 16 17:19:04 CET 2006 Paolo Molaro <lupus@ximian.com>
8652
8653         * mini.c: use the correct GetHashCode() for the moving collector.
8654
8655 2006-03-16  Massimiliano Mantione  <massi@ximian.com>
8656
8657         * liveness.c: Regalloc spill cost tuning.
8658
8659 2006-03-15 Neale Ferguson <neale@sinenomine.net>
8660         
8661         * mini-s390x.h: Correct S390_LONG macro.
8662
8663         * mini-s390x.c: Cleanup unused code.
8664
8665 2006-03-15  Zoltan Varga  <vargaz@gmail.com>
8666
8667         * jit-icalls.h: New file.
8668
8669         * Makefile.am mini.c jit-icalls.c: Use a proper include file for the jit
8670         icalls and include that instead of including jit-icalls.c.
8671
8672         * mini-ppc.c (mono_arch_output_basic_block): Remove references to
8673         OP_X86 opcodes.
8674
8675 Tue Mar 14 20:23:53 CET 2006 Paolo Molaro <lupus@ximian.com>
8676
8677         * mini.c: when checking for member accessibility, also check for
8678         friend assemblies and for explicit interface implementations.
8679
8680 2006-03-14  Zoltan Varga  <vargaz@gmail.com>
8681
8682         * mini-codegen.c (mono_local_regalloc): Remove incorrect g_free () calls.
8683
8684         * cpu-arm.md cpu-g4.md: Remove x86_ opcodes.
8685
8686         * mini-x86.h (MONO_ARCH_INST_FIXED_REG): Reorganize the comparisons so
8687         common cases are done first.    
8688
8689         * mini-ops.h: Only define platform specific opcodes on the given platform.
8690
8691         * mini.h regalloc.h mini-codegen.c: Merge optimizations from the linear-il
8692         branch.
8693         
8694 2006-03-14  Martin Baulig  <martin@ximian.com>
8695
8696         Revert Paolo's change from r57348:
8697
8698         * mini.h: don't use gboolean for bitfields.
8699         * mini.c: verifier changes for fields and methods accessibility.
8700
8701 2006-03-13  Neale Ferguson <neale@sinenomine.net>
8702
8703         * mini-s390.h, mini-s390x.h: Fix calls to mono_call_inst_add_outarg_reg.
8704
8705         * mini-s390x.c: Fix conv_r_un.
8706
8707         * cpu-s390, cpu-s390x.md: Fix lengths.
8708
8709 Sun Mar 12 17:31:22 CET 2006 Paolo Molaro <lupus@ximian.com>
8710
8711         * mini.c: nested types have access to all the nesting
8712         levels, not just the enclosing types.
8713
8714 Sun Mar 12 16:23:11 CET 2006 Paolo Molaro <lupus@ximian.com>
8715
8716         * mini.c: added a few more verification checks.
8717
8718 2006-03-12  Zoltan Varga  <vargaz@gmail.com>
8719
8720         * liveness.c: Merge optimizations from the linear-il branch.
8721
8722 2006-03-11  Zoltan Varga  <vargaz@gmail.com>
8723
8724         * mini-ia64.c (emit_call): Add a comment.
8725
8726         * tramp-ia64.c (mono_arch_patch_callsite): Handle indirect calls as well.
8727
8728         * tramp-ia64.c: Fix some warnings.
8729
8730 Sat Mar 11 20:15:59 CET 2006 Paolo Molaro <lupus@ximian.com>
8731
8732         * mini.h: don't use gboolean for bitfields.
8733         * mini.c: verifier changes for fields and methods accessibility.
8734
8735 2006-03-11  Zoltan Varga  <vargaz@gmail.com>
8736
8737         * mini.c (mono_icall_get_wrapper): Fix an ia64 bug introduced by the
8738         lazy icall wrapper changes.
8739
8740         * dominators.c: Replace all the dominator algorithms with faster
8741         ones from the linear-il branch.
8742
8743         * inssel-*.brg: Allocate call->out_ireg_args and call->out_freg_args from
8744         the mempool.
8745
8746         * mini-amd64.h (MONO_ARCH_INST_FIXED_REG): Reorganize the comparisons so
8747         common cases are done first.
8748
8749         * mini-amd64.c: Fix some warnings.
8750
8751         * mini-codegen.c mini-*.c: Allocate call->out_ireg_args and call->out_freg_args
8752         from the mempool.
8753
8754         * mini.c (mono_jit_compile_method_with_opt): Fix a race in the newly
8755         added code.
8756
8757         * mini.h: Add a missing prototype.
8758
8759 2006-03-10  Zoltan Varga  <vargaz@gmail.com>
8760
8761         * mini.c: Compile icall wrappers lazily.
8762
8763         * mini-codegen.c: Use printf instead of g_print since its much faster.
8764
8765         * mini.h (mono_bitset_foreach_bit): Use the faster mono_bitset_find_start ()
8766         function.
8767
8768         * mini.c (optimize_branches): Cache the negative result from 
8769         remove_block_if_useless ().
8770
8771         * mini.c (optimize_branches): Avoid restarting the iteration after each change. 
8772         Also fix some bblock linking issues.
8773
8774         * helpers.c (mono_disassemble_code): Reduce the size of the temporary
8775         assembly files.
8776
8777         * mini.h: Define G_LIKELY/G_UNLIKELY macros for older glib versions.
8778
8779         * mini.h (MonoBasicBlock): Reorganize the fields, putting more frequently
8780         accessed fields first, for better cache behavior.
8781         
8782 Fri Mar 10 18:21:41 CET 2006 Paolo Molaro <lupus@ximian.com>
8783
8784         * mini.c: speedup IList<T> array accesses.
8785
8786 2006-03-09  Zoltan Varga  <vargaz@gmail.com>
8787
8788         * mini.c (mono_method_to_ir): Handle large methods overflowing the 
8789         inline_costs counter. Fixes #77190.
8790
8791 2006-03-06  Zoltan Varga  <vargaz@gmail.com>
8792
8793         * mini-exceptions.c: Call mono_trace_is_enabled () before printing
8794         trace messages. Fixes #77706.
8795
8796 2006-03-04  Martin Baulig  <martin@ximian.com>
8797
8798         * tramp-amd64.c, tramp-x86.c
8799         (mono_debugger_create_notification_function): Use
8800         mono_global_codeman_reserve() to allocate a buffer at runtime and
8801         return it.
8802
8803         * debug-debugger.h (MonoDebuggerInfo): Added `initialize'.
8804
8805         * debug-debugger.c (mono_debugger_init): Dynamically allocate the
8806         notification function at runtime and then call `initialize' in the
8807         `MONO_DEBUGGER__debugger_info' vtable.
8808
8809 2006-03-04  Zoltan Varga  <vargaz@gmail.com>
8810
8811         * iltests.il: Fix a visibility problem.
8812
8813 Wed Mar 1 15:55:25 CET 2006 Paolo Molaro <lupus@ximian.com>
8814
8815         * driver.c, mini.c: add hooks for the counters API.
8816
8817 Wed Mar 1 12:28:04 CET 2006 Paolo Molaro <lupus@ximian.com>
8818
8819         * driver.c: show disabled options.
8820
8821 Wed Mar 1 12:18:51 CET 2006 Paolo Molaro <lupus@ximian.com>
8822
8823         * linear-scan.c: always use cost-driven selection.
8824
8825 2006-02-28  Raja R Harinath  <rharinath@novell.com>
8826
8827         * jit-icalls.c (helper_compile_generic_method): Revert change from
8828         2006-02-24.
8829
8830 Mon Feb 27 18:58:19 GMT 2006 Paolo Molaro <lupus@ximian.com>
8831
8832         * cpu-arm.md, mini-arm.c: implemented MemoryBarrier.
8833
8834 Sat Feb 25 17:39:21 CET 2006 Paolo Molaro <lupus@ximian.com>
8835
8836         * inssel.brg: style fixes, mostly to force the updated monoburg
8837         to run for people using svn.
8838
8839 Sat Feb 25 17:07:42 CET 2006 Paolo Molaro <lupus@ximian.com>
8840
8841         * mini.c: match monoburg changes.
8842
8843 Sat Feb 25 16:04:33 CET 2006 Paolo Molaro <lupus@ximian.com>
8844
8845         * mini.h, mini.c, abcremoval.c, aliasing.c, liveness.c,
8846         ssapre.c, graph.c, ssa.c: put the mono_burg_arity[]
8847         declaration in the header file.
8848
8849 Sat Feb 25 14:19:31 CET 2006 Paolo Molaro <lupus@ximian.com>
8850
8851         * helpers.c: reduce relocations and mem usage.
8852
8853 Sat Feb 25 11:58:16 CET 2006 Paolo Molaro <lupus@ximian.com>
8854
8855         * mini.h, mini-codegen.c: disable logging features if
8856         requested by configure.
8857
8858 Sat Feb 25 11:54:49 CET 2006 Paolo Molaro <lupus@ximian.com>
8859
8860         * mini.c: tiny verifier changes.
8861
8862 Fri Feb 24 18:17:52 CET 2006 Paolo Molaro <lupus@ximian.com>
8863
8864         * mini-ops.h, inssel-x86.brg, tramp-x86.c, mini-x86.c,
8865         cpu-pentium.md: stack alignment changes for osx/x86,
8866         partially from Geoff Norton <gnorton@customerdna.com>.
8867
8868 2006-02-24  Raja R Harinath  <harinath@gmail.com>
8869
8870         * jit-icalls.c (helper_compile_generic_method): Update to changes
8871         in metadata/class.c.
8872
8873 2006-02-24  Zoltan Varga  <vargaz@gmail.com>
8874         
8875         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add a missing check.
8876         
8877         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add support for
8878         interface calls with large offsets.
8879
8880 2006-02-23  Raja R Harinath  <rharinath@novell.com>
8881
8882         * jit-icalls.c (helper_compile_generic_method): Document the
8883         special-case we depend on so that we can inflate the method twice
8884         with the same context with no bad side-effects.
8885
8886 Thu Feb 23 13:45:46 CET 2006 Paolo Molaro <lupus@ximian.com>
8887
8888         * mini-x86.c, mini-amd64.c: fix for case when xen support
8889         is disabled.
8890
8891 Wed Feb 22 19:38:40 CET 2006 Paolo Molaro <lupus@ximian.com>
8892
8893         * mini-x86.c, mini-amd64.c: generate code to access tls items
8894         in a faster way for Xen systems.
8895
8896 Wed Feb 22 10:31:25 CET 2006 Paolo Molaro <lupus@ximian.com>
8897
8898         * exceptions-x86.c, mini-x86.h, driver.c, mini-codegen.c:
8899         updates and compilation fixes for the OSX/x86 port, mostly from
8900         Geoff Norton <gnorton@customerdna.com>.
8901
8902 Tue Feb 21 19:56:55 CET 2006 Paolo Molaro <lupus@ximian.com>
8903
8904         * inssel.brg: faster interface call implementation
8905         to sync with the interface_offsets MonoVTable changes.
8906
8907 Mon Feb 20 10:37:57 CET 2006 Paolo Molaro <lupus@ximian.com>
8908
8909         * mini.c: more verification checks.
8910
8911 Fri Feb 17 19:47:29 CET 2006 Paolo Molaro <lupus@ximian.com>
8912
8913         * mini.c: added a few more verification checks.
8914
8915 2006-02-17      Neale Ferguson <neale@sinenomine.net>
8916
8917         * mini-s390x.c, mini-s390x.h: Check for presence of long displacement
8918         facility on the processor and use it if available.
8919
8920 Fri Feb 17 16:12:52 CET 2006 Paolo Molaro <lupus@ximian.com>
8921
8922         * driver.c, aot.c, mini.c: throw exception if the IL code is
8923         invalid or unverifiable.
8924
8925 2006-02-17  Raja R Harinath  <rharinath@novell.com>
8926
8927         * generics.2.cs (test_0_ldfld_stfld_mro): Use m.struct_field, not
8928         m.StructField.
8929
8930 2006-02-16  Zoltan Varga  <vargaz@gmail.com>
8931
8932         * generics.2.cs: Add some tests for generics ldfld/stfld wrappers.
8933
8934 Wed Feb 15 16:23:17 CET 2006 Paolo Molaro <lupus@ximian.com>
8935
8936         * mini-s390x.c, mini-s390.c, mini.c, mini-amd64.c, mini-arm.c,
8937         mini-ia64.c, mini-sparc.c, mini-x86.c, mini-ppc.c: fixed
8938         handling of instantiated generic valuetypes.
8939
8940 2006-02-11  Zoltan Varga  <vargaz@gmail.com>
8941
8942         * mini-exceptions.c mini-x86.h mini-x86.c: Get rid of 
8943         MONO_INIT_CONTEXT_FROM_CALLER, and use MONO_INIT_CONTEXT_FROM_FUNC
8944         instead.
8945
8946         * generics.2.cs: Revert the nullable reftypes tests.
8947
8948 2006-02-10  Zoltan Varga  <vargaz@gmail.com>
8949
8950         * mini-exceptions.c (MONO_INIT_CONTEXT_FROM_CALLER): Avoid
8951         using __builtin_frame_address (1) as it doesn't work in the presence
8952         of optimizations. Hopefully fixes #77273.
8953
8954         * Makefile.am generics.cs generics.2.cs: Revert the generics.2.cs
8955         -> generics.cs change as it doesn't work with some automake versions.
8956
8957 Thu Feb 9 16:24:44 CET 2006 Paolo Molaro <lupus@ximian.com>
8958
8959         * mini.c: handle systems that sue a different way to
8960         retrieve the stack address of the current thread.
8961
8962 2006-02-09  Zoltan Varga  <vargaz@gmail.com>
8963
8964         * Makefile.am generics.2.cs: Rename this to generics.cs and handle
8965         it specially in the makefile.
8966
8967         * generics.2.cs: Add tests for nullable reference types.
8968
8969 Wed Feb 8 19:33:17 CET 2006 Paolo Molaro <lupus@ximian.com>
8970
8971         * mini.c: always handle the case when mono_jit_init()
8972         is called in a thread different from the main thread,
8973         confusing libgc (bug #77309).
8974
8975 Mon Feb 6 09:01:24 EST 2006 Paolo Molaro <lupus@ximian.com>
8976
8977         * mini-ppc.c: fix handling of exceptions in large methods (bug #74932).
8978
8979 Fri Feb 3 18:51:35 CET 2006 Paolo Molaro <lupus@ximian.com>
8980
8981         * mini.c: change optimize_branches () to use a single loop
8982         and introduce a new optimization to simplify some range checks.
8983
8984 2006-02-03  Martin Baulig  <martin@ximian.com>
8985
8986         * debug-debugger.c (debugger_thread_manager_thread_created): Removed
8987         and merged with debugger_thread_manager_add_thread().
8988         (mono_debugger_main): Call debugger_thread_manager_add_thread() to
8989         inform the debugger about the main thread.
8990
8991 2006-02-03  Zoltan Varga  <vargaz@gmail.com>
8992
8993         * basic.cs: Add test for div.un/rem.un constant folding.
8994
8995 2006-02-03  Neale Ferguson <neale@sinenomine.net>
8996
8997         * cpu-s390x.md: correct int_xor_imm length
8998
8999 2006-02-03  Zoltan Varga  <vargaz@gmail.com>
9000
9001         * generics.2.cs: New test for #77442.
9002
9003         * jit-icalls.c (helper_compile_generic_method): Check for null. Fixes
9004         #77442.
9005
9006 2006-02-02  Martin Baulig  <martin@ximian.com>
9007
9008         * tramp-x86.c, tramp-amd64.c: It's now safe to #include
9009         <mono/metadata/mono-debug-debugger.h>   
9010
9011         * debug-mini.c: Don't #define _IN_THE_MONO_DEBUGGER.
9012
9013 2006-02-02  Martin Baulig  <martin@ximian.com>
9014
9015         * debug-debugger.h: New header file for debug-debugger.c.
9016
9017         * debug-debugger.c: Big API cleanup; don't run the managed Main()
9018         function is a separate thread anymore; add support for attaching.
9019
9020 2006-02-01  Zoltan Varga  <vargaz@gmail.com>
9021
9022         * tramp-x86.c: Fix a warning.
9023
9024 2006-01-31  Zoltan Varga  <vargaz@gmail.com>
9025
9026         * mini-amd64.c (mono_arch_compute_omit_fp): Avoid hitting an assertion
9027         on very large methods.
9028
9029         * aot.c (load_patch_info): Fix a warning.
9030
9031 Mon Jan 30 12:51:10 CET 2006 Paolo Molaro <lupus@ximian.com>
9032
9033         * cpu-pentium.md, mini-x86.c, inssel.brg, inssel-x86.brg,
9034         mini-ops.h: alu membase optimizations.
9035
9036 Fri Jan 27 21:11:08 CET 2006 Paolo Molaro <lupus@ximian.com>
9037
9038         * mini-ops.h, mini.c, inssel.brg, inssel-x86.brg: opcode
9039         to speedup StringBuilder.
9040
9041 2006-01-27  Zoltan Varga  <vargaz@gmail.com>
9042
9043         * dominators.c (mono_compute_natural_loops): Fix detection of
9044         loop body start blocks.
9045
9046         * mini-exceptions.c (mono_print_thread_dump): Fix non x86 builds.
9047
9048 2006-01-26  Zoltan Varga  <vargaz@gmail.com>
9049
9050         * mini.h mini.c mini-exceptions.c: Add thread dump support. Fixes
9051         #75145.
9052
9053 2006-01-25  Massimiliano Mantione  <massi@ximian.com>
9054
9055         * aliasing.c: Fixed aliasing issue on 64 bit archs.
9056
9057 2006-01-25  Martin Baulig  <martin@ximian.com>
9058
9059         * debug-debugger.c: Moved the `MonoDebuggerManager' and
9060         `MonoDebuggerThread' typedefs here from mono-debug-debugger.h and
9061         started to cleanup this file a little bit.
9062
9063 Tue Jan 24 18:20:48 CET 2006 Paolo Molaro <lupus@ximian.com>
9064
9065         * mini.c: optimize a codepath frequently happening in generics code.
9066
9067 2006-01-23  Martin Baulig  <martin@ximian.com>
9068
9069         * Makefile.am: Only compile debug-debugger.c on supported platforms.
9070
9071         * debug-debugger.c: Kill the IO_LAYER() hack and use the io-layer
9072         functions directly.
9073
9074         * driver.c: debug-debugger.c is only available if
9075         `MONO_DEBUGGER_SUPPORTED' is defined.   
9076
9077 2006-01-23  Martin Baulig  <martin@ximian.com>
9078
9079         * debug-debugger.c: Only enable this on platforms where the Mono
9080         Debugger is working (x86 and x86_64).
9081
9082 2006-01-21  Martin Baulig  <martin@ximian.com>
9083
9084         The Mono Debugger is now using the normal `mono' instead of the
9085         `mono-debugger-mini-wrapper' when executing managed code.
9086
9087         * debug-debugger.c: New file; previously known as
9088         debugger/wrapper/wrapper.c.
9089
9090         * debug-mini.c (mono_init_debugger): Removed.
9091
9092         * driver.c (mono_main): Added new `--inside-mdb' command line
9093         argument which is used when running inside the debugger.
9094
9095 2006-01-20  Zoltan Varga  <vargaz@gmail.com>
9096
9097         * liveness.c (mono_analyze_liveness): Remove some unused data
9098         structures.
9099
9100 2006-01-17  Zoltan Varga  <vargaz@gmail.com>
9101
9102         * mini.h: Move mono_bitset_test_fast macro to monobitset.h where it belongs.
9103
9104 2006-01-16  Zoltan Varga  <vargaz@gmail.com>
9105
9106         * mini.h (mono_bitset_test_fast): Disable the 'fast' implementation which
9107         depends on implementation details of monobitset.
9108
9109         * mini.c (mini_get_ldelema_ins): Fix handling of 1 dimensional arrays.
9110         Fixes #77271.
9111
9112 2006-01-15  Zoltan Varga  <vargaz@gmail.com>
9113
9114         * liveness.c: Update after monobitset changes.
9115
9116 2006-01-14  Zoltan Varga  <vargaz@gmail.com>
9117
9118         * mini-amd64.c (mono_arch_compute_omit_fp): Fix a leak.
9119
9120 2006-01-11 Neale Ferguson <neale@sinenomine.net>
9121
9122         * inssel-s390x.brg: Fix reg: OP_LDADDR(OP_S390_LOADARG) register setting.
9123
9124         * mini-s390x.c: Remove warning messages.
9125
9126 2006-01-11  Ben Maurer  <bmaurer@andrew.cmu.edu>
9127
9128         * mini.c: pass the jitinfo to mono_profiler_method_end_jit.
9129
9130 2006-01-10  Zoltan Varga  <vargaz@gmail.com>
9131
9132         * generics.2.cs: Add ldelem/stelem_any test.
9133
9134 2006-01-10 Neale Ferguson <neale@sinenomine.net>
9135
9136         * mini-s390.c: Fix ATOMIC_ADD_I4 operation.
9137
9138 2006-01-07  Zoltan Varga  <vargaz@gmail.com>
9139
9140         * inssel-long.brg: Fix int->long ovf conversion rules. Fixes #77172.
9141         
9142 2006-01-06  Zoltan Varga  <vargaz@gmail.com>
9143
9144         * generics.2.cs: Reenable vtype tests.
9145
9146         * inssel-x86.brg: Remove an icorrect valuetype rule.
9147
9148 2006-01-06 Neale Ferguson <neale@sinenomine.net>
9149
9150         * mini-s390x.c, inssel-s390x.brg, cpu-s390x.md: Fix ATOMIC_I8 operations. Provide
9151         initial support for OP_ABS.
9152
9153 2006-01-05 Neale Ferguson <neale@sinenomine.net>
9154
9155         * mini-s390x.c (emit_float_to_int): Correct r8 to unsigned int algorithm.
9156
9157 2006-01-05 Neale Ferguson <neale@sinenomine.net>
9158
9159         * mini-s390.c, mini-s390.h, inssel-s390.brg, cpu-s390.md: Fix r8 to unsigned int 
9160         conversion and implement LADD/LSUB.
9161
9162         * exceptions-s390.c: Standardize mono_arch_find_jit_info to match other
9163         architectures.
9164
9165 2006-01-05 Neale Ferguson <neale@sinenomine.net>
9166
9167         * mini-s390x.c, mini-s390x.h: Fix r8 to unsigned int conversion.
9168
9169         * exceptions-s390x.c: Standardize mono_arch_find_jit_info to match other
9170         architectures.
9171
9172 2006-01-05 Neale Ferguson <neale@sinenomine.net>
9173
9174         * mini-s390x.c, mini-s390x.h, mini-s390.c, mini-s390.h: Fix lmf handling when 
9175         localloc is encountered.  Fixes crash in test-183.cs when using gmcs 
9176         (stack walk problem).
9177
9178 2006-01-04  Zoltan Varga  <vargaz@gmail.com>
9179
9180         * aot.c (mono_aot_load_method): Fix a warning.
9181
9182 2006-01-03  Neale Ferguson <neale@sinenomine.net>
9183
9184         * mini-s390x.h, exceptions-s390x.c, inssel-s390x.brg: Fix compiler warnings
9185
9186 2006-01-03  Zoltan Varga  <vargaz@gmail.com>
9187
9188         * iltests.il: Add test for #77148.
9189
9190         * mini.c (mini_get_ldelema_ins): Handle arrays with rank 1 too. Fixes
9191         #77148.
9192
9193 2006-01-03  Neale Ferguson <neale@sinenomine.net>
9194
9195         * mini-s390x.c, inssel-s390x.brg: Remove debug statements
9196
9197 2006-01-03  Neale Ferguson <neale@sinenomine.net>
9198
9199         * mini-s390x.c, mini-s390x.h, exceptions-s390x.c, tramp-s390x.c, inssel-s390x.brg,
9200         cpu-s390x.md, mini-codegen.c, Makefile.am: add 64-bit s390 support to JIT.
9201
9202         * basic-long.cs: Add lconv-to-r4/r8 tests.
9203
9204 2006-01-03  Zoltan Varga  <vargaz@gmail.com>
9205
9206         * mini.c (mono_method_to_ir): Fix DynamicMethod support in some opcodes.
9207
9208         * mini-sparc.c (mono_arch_call_opcode): Use mono_class_value_size ()
9209         here as on other archs.
9210
9211 2005-12-29 Neale Ferguson <neale@sinenomine.net>
9212
9213         * mini-s390.c (mono_arch_get_inst_for_method): Add memory_barrier support.
9214
9215 2005-12-29 Neale Ferguson <neale@sinenomine.net>
9216
9217         * inssel-s390.brg: Correct register assignment; Rework L[ADD|SUB]_OVF[_UN] for s390.
9218         
9219         * cpu-s390.md: Fix lengths of a couple of long instructions; Add memory_barrier.
9220
9221         * mini-s390.c: Fix long add/sub overflow instructions; Fix displacement handling in
9222         instrument_prolog; Add memory_barrier instruction.
9223
9224 2005-12-26  Zoltan Varga  <vargaz@gmail.com>
9225
9226         * exceptions-x86.c mini-x86.h: Fix solaris/x86 exception handling.
9227
9228 2005-12-23  Zoltan Varga  <vargaz@gmail.com>
9229
9230         * tramp-ia64.c (mono_arch_get_unbox_trampoline): Flush icache.
9231
9232         * aliasing.c inssel.brg: Fix warnings.
9233
9234         * inssel-ia64.brg (OP_MEMSET): Fix an optimization which previously
9235         could skip initialization of some parts of memory.
9236
9237         * mini.c mini-ia64.c: Fix warnings.
9238
9239         * inssel-sparc.brg: Add an implementation of lneg which actually works.
9240
9241 2005-12-22  Zoltan Varga  <vargaz@gmail.com>
9242
9243         * aliasing.c (mono_build_aliasing_information): Add a workaround for
9244         a crash seen on sparc.
9245
9246         * mini-sparc.c: Add implementation of Thread.MemoryBarrier.
9247         
9248         * cpu-sparc.md: Add memory_barrier opcode. Remove unused opcodes.
9249
9250 2005-12-21 Neale Ferguson <neale@sinenomine.net>
9251
9252         * mini-ops.h: Add s390_backchain instruction
9253
9254         * inssel-s390.brg: Use backchaining instruction for LOADARG/STKARG operations.
9255
9256         * cpu-s390.md: Add s390_backchain instruction
9257
9258         * mini-s390.c: Significant ABI changes
9259
9260         * mini-s390.h: Cater for zero length structures
9261
9262 2005-12-20 Neale Ferguson <neale@sinenomine.net>
9263
9264         * mini-s390.c: ABI fixes
9265
9266         * inssel-s390.brg: Remove debug statements
9267
9268         * cpu-s390.md: Fix length of ATOMIC_xx operations
9269
9270 2005-12-19  Zoltan Varga  <vargaz@gmail.com>
9271
9272         * basic-float.cs: Add float<->long conversion tests.
9273
9274 2005-12-16 Neale Ferguson <neale@sinenomine.net>
9275
9276         * mini-s390.c: Fix LOCALLOC processing.
9277
9278         * tramp-s390.c (s390_magic_trampoline): Fix base calculation.
9279
9280 2005-12-15  Zoltan Varga  <vargaz@gmail.com>
9281
9282         * iltests.il: Add tests for some opcodes not covered by the other
9283         tests.
9284
9285 2005-12-15 Neale Ferguson <neale@sinenomine.net>
9286
9287         * mini-s390.c: Fix ADDCC/SBB bug revealed by test_0_ulong_regress; Correct 
9288         register loading for Tail processing; Correct trace output.
9289
9290         * inssel-s390.brg: Reimplement LSUB_OVF due to s390 implementation of signed math.
9291
9292         * cpu-s390.md: Correct size of jmp instruction. 
9293
9294 2005-12-13 Neale Ferguson <neale@sinenomine.net>
9295
9296         * mini-s390.c (mono_arch_emit_prolog): Remove some debugging bits.
9297
9298 2005-12-13 Neale Ferguson <neale@sinenomine.net>
9299
9300         * inssel-s390.brg tramp-s390.c cpu-s390.md mini-s390.c mini-s390.h:
9301           Bring s390 up to current level.
9302
9303 2005-12-12  Zltan Varga  <vargaz@gmail.com>
9304
9305         * generics.2.cs: Disable the newly added tests as they do not work yet.
9306         
9307         * generics.2.cs: Add valuetype tests.
9308
9309 2005-12-09  Zoltan Varga  <vargaz@gmail.com>
9310
9311         * basic-long.cs: Add i4->u8 test.
9312
9313         * objects.cs: Add tests for JIT intrinsic.
9314
9315         * mini.c (mini_get_inst_for_method): Resurrect the array Rank/Length
9316         optimizations lost by a mistake.
9317
9318 2005-12-07  Zoltan Varga  <vargaz@gmail.com>
9319
9320         * basic-long.cs: Remove a test moved to objects.cs.
9321
9322         * arrays.cs: Add more array tests.
9323
9324 2005-12-06  Zoltan Varga  <vargaz@gmail.com>
9325
9326         * arrays.cs: Add new tests for multi-dimensional arrays.
9327
9328 2005-12-06  Raja R Harinath  <rharinath@novell.com>
9329
9330         * Makefile.am (test_sources2): Add generics.2.cs.
9331         (EXTRA_DIST): Add test_sources2.
9332
9333 2005-12-05  Ben Maurer  <bmaurer@ximian.com>
9334
9335         Support for boxing and unboxing nullable types as well as the
9336         isinst operation on nullables, per the CLI ammendment.
9337
9338         * inssel.brg (CEE_ISINST): Special case for nullable
9339
9340         * mini.c (handle_unbox_nullable): new method
9341         (handle_box): Special case for nullable types
9342         (mono_method_to_ir): Call handle_unbox_nullable in correct
9343         places.
9344
9345         * generics.2.cs: New test suite
9346
9347         * Makefile.am: Support for regression tests with generics.
9348
9349 2005-12-03  Zoltan Varga  <vargaz@gmail.com>
9350
9351         * mini-amd64.c (emit_load_volatile_arguments): Add loading of arguments
9352         allocated to registers. Fixes #76800.
9353
9354 Thu Dec 1 12:59:40 EST 2005 Paolo Molaro <lupus@ximian.com>
9355
9356         * mini-ppc.c, inssel-ppc.brg: fix ABI issue (pinvoke3.cs).
9357
9358 2005-11-30  Zoltan Varga  <vargaz@gmail.com>
9359
9360         * exceptions.cs: Disable test_0_long_cast () test, since it fails on a lot 
9361         of platforms.
9362
9363 2005-11-29  Zoltan Varga  <vargaz@gmail.com>
9364
9365         * objects.cs basic-calls.cs: Move a test depending on valuetypes to
9366         objects.cs.
9367
9368         * inssel-long32.brg (CEE_CONV_I8): Remove unused labels.
9369         
9370         * inssel-long32.brg (CEE_CONV_I8): Convert this to a branchless version.
9371 Tue Nov 29 05:41:34 EST 2005 Paolo Molaro <lupus@ximian.com>
9372
9373         * mini-ppc.c, cpu-g4.md: ensure a fp register is converted to
9374         single precision before storing to a single precision location.
9375
9376 2005-11-28  Raja R Harinath  <rharinath@novell.com>
9377
9378         * Makefile.am (ILASM): Use profile-dependent location of ilasm.
9379
9380 2005-11-27  Zoltan Varga  <vargaz@gmail.com>
9381
9382         * basic-long.cs basic-calls.cs objects.cs: Move some tests to the
9383         correct files.
9384
9385         * basic.cs: Remove test_0_byte_compares test which was moved to
9386         objects.cs a long time ago.
9387
9388 2005-11-22  Massimiliano Mantione  <massi@ximian.com>
9389
9390         * aliasing.c: Fixed aliasing issue on 64 bit archs.
9391
9392 2005-11-20  Zoltan Varga  <vargaz@gmail.com>
9393
9394         * mini-ia64.c exceptions-ia64.c: Simplify the way filters/finally
9395         handlers are called.
9396
9397         * mini-ia64.c (mono_arch_emit_exceptions): Optimize size of exception
9398         throwing code.
9399
9400          * mini-ia64.c: Add support for the throw->branch exception 
9401         optimization.   
9402
9403         * driver.c (DEFAULT_OPTIMIZATIONS): Add MONO_OPT_EXCEPTION.
9404
9405 2005-11-18  Massimiliano Mantione  <massi@ximian.com>
9406
9407         * mini.c: Enabled "fastpath" deadce :-)
9408         
9409 2005-11-18  Massimiliano Mantione  <massi@ximian.com>
9410
9411         * mini.c: Added "fastpath" deadce (deadce without SSA), and a simple
9412         alias analysis pass to support it.
9413         * mini.h: Likewise.
9414         * ssa.c: Likewise.
9415         * liveness.c: Likewise (liveness computation can use aliasing
9416         information to be more accurate).
9417         * driver.c: Added an "ssa" option go tell the JIT to use SSA, and
9418         moreover made so that "--compile-all" uses the given optimization
9419         flags and not the default ones.
9420         * aliasing.c: Alias analysis (new file).
9421         * aliasing.h: Likewise.
9422         * Makefile.am: added "aliasing.c" and "aliasing.h".
9423         
9424 2005-11-17  Zoltan Varga  <vargaz@gmail.com>
9425
9426         * mini-ops.h: Add missing OP_I opcodes so it is in synch with the
9427         OP_L opcodes.
9428
9429 2005-11-13  Zoltan Varga  <vargaz@gmail.com>
9430
9431         * mini-exceptions.c (mono_handle_exception_internal): Remove the 
9432         fp >= end_of_stack exit condition, as it is not needed, and it might
9433         become true for fp eliminated frames.
9434
9435 2005-11-11  Zoltan Varga  <vargaz@gmail.com>
9436
9437         * mini-x86.c (mono_arch_emit_epilog): Use G_STRUCT_OFFSET instead of hard
9438         coded offsets.
9439
9440 Tue Nov 8 11:28:20 GMT 2005 Paolo Molaro <lupus@ximian.com>
9441
9442         * mini-arm.c: fixed alignment of doubles/longs to match
9443         the C ABI (bug #76635).
9444
9445 Mon Nov 7 16:13:21 CET 2005 Paolo Molaro <lupus@ximian.com>
9446
9447         * aot.c: fix compilation with --enable-minimal=aot.
9448
9449 Fri Nov 4 12:34:15 GMT 2005 Paolo Molaro <lupus@ximian.com>
9450
9451         * mini-arm.c: fixed compatibility with the new
9452         floating point emulator package for compares.
9453
9454 2005-11-03  Atsushi Enomoto  <atsushi@ximian.com?
9455
9456         * mini.c : reverted sig->pinvoke changes (r51396-51397).
9457
9458 2005-11-01  Zoltan Varga  <vargaz@freemail.hu>
9459
9460         * mini-exceptions.c (print_stack_frame): Output to stderr.
9461         (mono_handle_native_sigsegv): Ditto.
9462
9463 2005-10-30  Zoltan Varga  <vargaz@freemail.hu>
9464
9465         * mini-amd64.c (mono_arch_output_basic_block): Remove unused
9466         OP_LCONV_TO_OVF_I implementation.
9467
9468         * mini-amd64.c: Add support for the throw->branch exception 
9469         optimization.
9470
9471         * branch-opts.c (mono_branch_optimize_exception_target): Allow the case
9472         when the catch clause catches a more general exception, i.e. Object.
9473
9474 2005-10-30  Zoltan Varga  <vargaz@gmail.com>
9475
9476         * cpu-ia64.md: Remove unused opcodes.
9477
9478         * mini.c (GET_CONTEXT): Simplify this somewhat by removing arch
9479         specific defines for architectures defining USE_SIGACTION.
9480
9481         * mini-ia64.c: Fix some warnings.
9482
9483         * exceptions-ia64.c (mono_arch_ip_from_context): Fix this, the previous
9484         version seemed to skip a frame.
9485
9486 2005-10-30  Zoltan Varga  <vargaz@freemail.hu>
9487
9488         * mini.c: Clean up the usage of sig->pinvoke flag. Now
9489         only calls which are made to native code use this flag.
9490
9491 2005-10-29  Zoltan Varga  <vargaz@freemail.hu>
9492
9493         * mini-amd64.c (mono_arch_compute_omit_fp): Disable fp elimination for
9494         varargs methods as well.
9495         
9496         * mini-amd64.c exceptions-amd64.c: Allow fp elimination in methods
9497         which have save_lmf set. Reorganize methods prologs a bit.
9498
9499         * mini-amd64.c (mono_arch_compute_omit_fp): Move the check for the
9500         debugger to the proper place.
9501
9502 2005-10-29  Martin Baulig  <martin@ximian.com>
9503
9504         * mini-amd64.c (debug_omit_fp): Temporarily disable fp elimination
9505         when running inside the debugger until the debugger has support
9506         for it.
9507
9508 2005-10-26  Zoltan Varga  <vargaz@gmail.com>
9509
9510         * mini.h: Fix a warning.
9511
9512 2005-10-24  Miguel de Icaza  <miguel@novell.com>
9513
9514         * mini.c (mono_pmip): Just a wrapper for get_method_from_ip which
9515         we expose publicly, this returns the string.
9516
9517 2005-10-22  Zoltan Varga  <vargaz@freemail.hu>
9518
9519         * exceptions-amd64.c (mono_arch_find_jit_info): Fix some corner cases
9520         with fp elimination.
9521
9522 2005-10-21  Zoltan Varga  <vargaz@gmail.com>
9523
9524         * mini-exceptions.c (mono_handle_native_sigsegv): Try to print a
9525         native stacktrace using the glibc 'backtrace' function if available.
9526
9527 2005-10-20  Zoltan Varga  <vargaz@gmail.com>
9528
9529         * mini.h (MonoDebugOptions): Remove 'abort_on_sigsegv' option.
9530
9531         * mini-exceptions.c (mono_handle_native_sigsegv): New function to 
9532         handle SIGSEGVs received while in native code.
9533
9534         * mini.c (sigsegv_signal_handler): If the SIGSEGV happened in native
9535         code, call mono_handle_native_sigsegv which will abort the runtime
9536         after printing some diagnostics, instead of converting it into a
9537         confusing NullReferenceException.
9538
9539 2005-10-18  Zoltan Varga  <vargaz@gmail.com>
9540
9541         * cpu-pentium.md: Remove unused opcodes.
9542
9543 2005-10-18  Zoltan Varga  <vargaz@freemail.hu>
9544
9545         * mini-amd64.h (MonoLMF): Add rsp field.
9546
9547         * mini-amd64.c exceptions-amd64.c tramp-amd64.c: Save the sp reg into
9548         the lmf too.
9549
9550 2005-10-17  Zoltan Varga  <vargaz@gmail.com>
9551
9552         * mini-codegen.c (get_register_spilling): Fix some warnings.
9553
9554 2005-10-16  Zoltan Varga  <vargaz@freemail.hu>
9555
9556         * mini-amd64.h mini-amd64.c exceptions-amd64.c: Add support for fp
9557         elimination during exception handling. Enable fp elimination by
9558         default.
9559
9560         * mini-amd64.h mini-amd64.c: Add preliminary support for frame pointer
9561         elimination.
9562
9563 2005-10-16  Martin Baulig  <martin@ximian.com>
9564
9565         * mini-exceptions.c
9566         (mono_debugger_run_finally): New public method for the debugger.
9567
9568 2005-10-10  Zoltan Varga  <vargaz@gmail.com>
9569
9570         * debug-mini.c (mono_debug_init_method): Fix warning.
9571
9572         * mini.h branch-opts.c (mono_branch_optimize_exception_target): Make
9573         the 'exname' parameter const to fix some warnings.
9574
9575 2005-10-09  Zoltan Varga  <vargaz@freemail.hu>
9576
9577         * mini-exceptions.c (mono_handle_exception_internal): Fix another bug
9578         introduced by the previous patch.
9579
9580 2005-10-08  Zoltan Varga  <vargaz@gmail.com>
9581
9582         * basic-float.cs: Add test for precision of float arithmetic.
9583
9584         * mini-ia64.c (mono_arch_output_basic_block): Convert to/from doubles
9585         when loading/storing single values from/to memory.
9586
9587         * mini.c (mono_jit_compile_method_with_opt): Create the function
9588         pointers in the correct domain.
9589
9590 2005-10-08  Zoltan Varga  <vargaz@freemail.hu>
9591
9592         * mini-exceptions.c (mono_handle_exception_internal): Fix bug 
9593         introduced by previous patch.
9594         
9595         * mini-exceptions.c (mono_handle_exception_internal): Handle the case
9596         when out_filter_idx is NULL.
9597
9598         * mini-exceptions.c: Don't run filter clauses twice during exception
9599         handling. Fixes #75755.
9600
9601 2005-10-07  Zoltan Varga  <vargaz@gmail.com>
9602
9603         * aot.c: Add support for ldflda wrappers.
9604
9605         * mini.c (mono_method_to_ir): Use ldflda wrappers for CEE_LDFLDA. Fixes
9606         #75902.
9607
9608 Tue Oct 4 20:23:25 CEST 2005 Paolo Molaro <lupus@ximian.com>
9609
9610         * mini.c, mini.h: do not consider exception handlers blocks when
9611         setting up interface variables.
9612
9613 2005-10-04  Zoltan Varga  <vargaz@freemail.hu>
9614
9615         * aot.c (emit_section_change): Fix emitting of sections on win32. Fixes #76322.
9616
9617 2005-10-03  Zoltan Varga  <vargaz@gmail.com>
9618
9619         * liveness.c (mono_analyze_liveness): Revert parts of r51051 since it
9620         causes a regression.
9621
9622         * mini.c (mini_thread_cleanup): Fix reading of freed memory.
9623
9624 2005-10-02  Zoltan Varga  <vargaz@freemail.hu>
9625
9626         * mini.h (OP_PCONST): Move the definition of OP_PCONST into the rest
9627         of the OP_P definitions.
9628
9629         * TODO: Add a proposal for dealing with the CEE/OP mess.
9630
9631         * mini-amd64.c (mono_arch_output_basic_block): Merge mul_imm 
9632         optimizations from the x86 port.
9633
9634         * cpu-amd64.md: Ditto.
9635
9636         * basic.cs basic-long.cs: Add tests.
9637
9638 Fri Sep 30 20:07:20 CEST 2005 Paolo Molaro <lupus@ximian.com>
9639
9640         * Makefile.am, driver.c, mini-x86.c, mini.c, mini.h, branch-opts.c:
9641         Patrik Torstensson's implementation of my exception-handling
9642         optimization idea, when the exception object is not used
9643         (bug #62150).
9644
9645 Fri Sep 30 19:10:29 CEST 2005 Paolo Molaro <lupus@ximian.com>
9646
9647         * mini-x86.c, cpu-pentium.md: Patrik Torstensson's port
9648         of the mul_imm optimizations from the old jit.
9649
9650 Fri Sep 30 11:37:51 EDT 2005 Paolo Molaro <lupus@ximian.com>
9651
9652         * mini.c, liveness.c: patch by Patrik Torstensson and
9653         Zoltan Varga to improve performance in methods with
9654         exception clauses.
9655
9656 2005-09-30  Zoltan Varga  <vargaz@gmail.com>
9657
9658         * driver.c: Remove 'Globalization' entry from --version.
9659
9660 2005-09-28  Zoltan Varga  <vargaz@gmail.com>
9661
9662         * mini.c (mono_jit_compile_method_inner): Do not load AOT code when
9663         there is a profiler interested in JIT events.
9664
9665         * aot.c: Load profile files produced by the AOT profiling module, and
9666         reorder methods based on the profiling info. Add a 'method_order' table
9667         to the AOT file to make mono_aot_find_jit_info work with the reordered
9668         methods.
9669
9670         * mini.h: Bump AOT file version info.
9671
9672 Wed Sep 28 17:12:48 CEST 2005 Paolo Molaro <lupus@ximian.com>
9673
9674         * mini-arm.h: work around what looks like a gcc bug when optimizations
9675         are enabled.
9676
9677 2005-09-28  Raja R Harinath  <rharinath@novell.com>
9678
9679         * Makefile.am (AM_CFLAGS): Don't use += to append inside
9680         conditionals.  Use ...
9681         (PLATFORM_CFLAGS, ARCH_CFLAGS): ... these.
9682
9683 2005-09-27  Zoltan Varga  <vargaz@freemail.hu>
9684
9685         * mini-amd64.c (mono_arch_call_opcode): Use mono_class_value_size ()
9686         to determine the amount of memory to copy when passing valuetypes.
9687
9688         * inssel-amd64.brg: Remove PUSH(LDIND4) rules since they convert an
9689         4 byte load into a 8 byte load. Fix aligning of size in OP_OUTARG_VT.
9690
9691 2005-09-27  Zoltan Varga  <vargaz@gmail.com>
9692
9693         * mini.h mini.c aot.c: Add infrastructure to collect pagefault 
9694         information about aot.
9695
9696 2005-09-27  Ben Maurer  <bmaurer@ximian.com>
9697
9698         * *.c: Replace the use of {Enter,Leave}CriticalSection with
9699         macros. This will allow a deadlock debugger to easily be plugged
9700         in.
9701
9702 Tue Sep 27 09:32:11 EDT 2005 Paolo Molaro <lupus@ximian.com>
9703
9704         * mini-ppc.c, cpu-g4.md: added memory barrier instruction.
9705
9706 2005-09-27  Raja R Harinath  <rharinath@novell.com>
9707
9708         * Makefile.am (AM_CFLAGS): Rename from INCLUDES.
9709         (AM_CFLAGS) [PLATFORM_WIN32): Append to it, don't set it.
9710         (AM_CFLAGS) [ARM]: Add arch/arm directory from the build tree.
9711         ($(arch_built)) [CROSS_COMPILING]: Error out.
9712
9713 2005-09-26  Zoltan Varga  <vargaz@gmail.com>
9714
9715         * aot.c: Add support for the no_special_static flag for classes.
9716
9717 2005-09-24  Zoltan Varga  <vargaz@freemail.hu>
9718
9719         * Reapply reverted patches.
9720
9721         * *: Revert r50174 as well.
9722
9723         * mini-amd64.c cpu-amd64.md inssel-amd64.brg: Revert r50170 as well.
9724
9725 2005-09-24  Zoltan Varga  <vargaz@freemail.hu>
9726
9727         * mini-amd64.c: Revert r50342 to see if this fixed buildbot.
9728
9729 2005-09-23  Miguel de Icaza  <miguel@novell.com>
9730
9731         * mini.c (SIG_HANDLER_SIGNATURE): Only dereference info if it is
9732         part of the SIG_HANDLER_SIGNATURE.  
9733
9734 2005-09-23  Zoltan Varga  <vargaz@gmail.com>
9735
9736         * mini.h mini.c: Add a new MONO_DEBUG option to collect metadata pagefault
9737         statistics.
9738
9739         * mini-x86.c (mono_arch_call_opcode): Fix vararg calling convention 
9740         introduced by previous patch.
9741
9742 2005-09-21  Zoltan Varga  <vargaz@gmail.com>
9743
9744         * tramp-x86.c (mono_arch_create_trampoline_code): Restore caller
9745         saved registers too.
9746
9747         * mini-x86.c (mono_arch_allocate_vars): Rewrite this so it works based 
9748         upon the information returned by get_call_info ().
9749         
9750         * mini-x86.c (add_float): Fix stack size calculation.
9751         (mono_arch_call_opcode): Rewrite this so it works based up the
9752         information returned by get_call_info ().
9753         (mono_arch_get_this_vret_args): Ditto.
9754
9755 2005-09-21  Zoltan Varga  <vargaz@freemail.hu>
9756
9757         * mini-amd64.c (mono_arch_emit_this_vret_args): Use the information
9758         in cinfo to determine the registers which need to be used.
9759
9760 2005-09-20  Miguel de Icaza  <miguel@novell.com>
9761
9762         * driver.c (mono_main): Add --server and --desktop flags. 
9763
9764 2005-09-16  Zoltan Varga  <vargaz@gmail.com>
9765
9766         * mini-ia64.h: Make register masks 64 bit. Don't treat argument
9767         registers as global registers.
9768
9769         * inssel-ia64.brg (stmt): Remove OP_OUTARG_REG () rules which are no 
9770         longer needed with the new register allocator.
9771
9772         * mini-ia64.c: Use OP_MOVE instead of OP_SETREG for reg-reg moves.
9773
9774         * cpu-ia64.md: Remove unused opcodes.
9775         
9776         * regalloc.c mini-codegen.c: Make register masks 64 bit on ia64.
9777         
9778 2005-09-16  Zoltan Varga  <vargaz@freemail.hu>
9779
9780         * cpu-amd64.md: Remove unused opcodes.
9781
9782         * inssel-amd64.brg: Remove OP_OUTARG_REG () rules which are no longer
9783         needed with the new register allocator.
9784
9785         * inssel-amd64.brg mini-amd64.c: Use OP_MOVE instead of OP_SETREG for
9786         reg-reg moves.
9787
9788 2005-09-16  Raja R Harinath  <rharinath@novell.com>
9789
9790         * Makefile.am (check-local): Don't invoke semdel-wrapper.
9791
9792 2005-09-16  Martin Baulig  <martin@ximian.com>
9793
9794         * exceptions-amd64.c
9795         (throw_exception): Don't call mono_debugger_throw_exception() if
9796         we're a rethrow - see the FIXME in the code.
9797
9798 2005-09-15  Geoff Norton  <gnorton@customerdna.com>
9799
9800         * mini.c (mono_init_exceptions): This only works on some architectures.
9801         
9802 2005-09-15  Zoltan Varga  <vargaz@gmail.com>
9803
9804         * mini.c (mono_method_to_ir): Add OP_LMUL imm -> OP_LMUL_IMM conversion
9805         on ia64.
9806
9807         * inssel-long.brg mini-ia64.c: Add OP_LMUL_IMM rules.
9808
9809         * mini-ia64.h mini-ia64.c: Remove the altstack support code which is
9810         now in mini-exceptions.c.
9811
9812 2005-09-15  Zoltan Varga  <vargaz@freemail.hu>
9813
9814         * mini-amd64.h mini-am64.c: Remove the altstack support code which is
9815         now in mini-exceptions.c.
9816
9817 2005-09-15  Zoltan Varga  <vargaz@gmail.com>
9818
9819         * exceptions-x86.c: Applied patch from Patrik Torstensson 
9820         <patrik.torstensson@gmail.com>. Add stack overflow handling support for win32.
9821
9822         * mini-exceptions.c mini-x86.c mini.c: Move the altstack setup/teardown
9823         code into mini-exceptions.c. Add some assertions to it.
9824
9825 2005-09-12  Zoltan Varga  <vargaz@gmail.com>
9826
9827         * aot.c (emit_section_change): Applied patch from "The Software Team" 
9828         (<software@solmersa.com>). Fix as errors on windows.
9829
9830 2005-09-11  Zoltan Varga  <vargaz@freemail.hu>
9831
9832         * tramp-amd64.c (mono_arch_create_trampoline_code): Fix saving of
9833         method info into the LMF.
9834
9835 2005-09-11  Zoltan Varga  <vargaz@gmail.com>
9836         
9837         * mini-ia64.c: Add proper unwind info for method epilogs.
9838
9839         * exceptions-ia64.c: Add some code to help debugging.
9840         
9841         * mini-ia64.c mini-ia64.h: Add sigaltstack support.
9842
9843         * mini-exceptions.c: Fix warning.
9844
9845 2005-09-11  Zoltan Varga  <vargaz@freemail.hu>
9846
9847         * mini.c: Really fix build.
9848
9849         * mini-x86.c mini-amd64.c: Fix build.
9850
9851 2005-09-11  Zoltan Varga  <vargaz@gmail.com>
9852
9853         * mini-ia64.c inssel-ia64.brg: Add InterlockedExchange instrinsics.
9854
9855         * mini-ops.h cpu-ia64.md inssel-ia64.brg mini-ia64.c: Implement
9856         some Interlocked methods as intrinsics.
9857
9858         * mini.c (mini_get_inst_for_method): Call arch_get_inst_for_method
9859         for Thread methods as well.
9860
9861         * mini-ops.h: Add OP_MEMORY_BARRIER opcode.
9862
9863         * inssel.brg: Add rule for OP_MEMORY_BARRIER.
9864
9865         * mini-ia64.c mini-x86.c mini-amd64.c 
9866         cpu-ia64.md cpu-pentium.md cpu-amd64.md: Add implementation of 
9867         OP_MEMORY_BARRIER.
9868         
9869         * mini.c (mono_init_exceptions): Fix build breakage.
9870
9871 2005-09-10  Zoltan Varga  <vargaz@gmail.com>
9872
9873         * mini-ia64.c exceptions-ia64.c tramp-ia64.c: Remove 'manual' emitting
9874         of instructions. Use the new ia64_unw_op macros for emitting unwind
9875         info.
9876
9877         * mini.c (mono_init_exceptions): Initialize exception handling
9878         related trampolines at startup.
9879
9880 Fri Sep 9 19:30:37 BST 2005 Paolo Molaro <lupus@ximian.com>
9881
9882         * cpu-arm.md, mini-arm.c: fix for dynamic code (Gtk# apps).
9883
9884 2005-09-09  Zoltan Varga  <vargaz@gmail.com>
9885
9886         * mini.c: Handle type loading errors gracefully during compilation and
9887         throw the appropriate exception.
9888
9889 Fri Sep 9 09:49:14 CEST 2005 Paolo Molaro <lupus@ximian.com>
9890
9891         * ldscript.mono, Makefile.am: use anonymous versions in the ldscript
9892         for the mono binary.
9893
9894 2005-09-09  Martin Baulig  <martin@ximian.com>
9895
9896         * mini.c (mono_method_to_ir): Comment out the G_BREAKPOINT()'s for
9897         the release.
9898
9899 Thu Sep 8 14:53:45 BST 2005 Paolo Molaro <lupus@ximian.com>
9900
9901         * mini-arm.h: use emulation for conv.r.un for the release.
9902
9903 Thu Sep 8 11:28:45 BST 2005 Paolo Molaro <lupus@ximian.com>
9904
9905         * mini-arm.c, objects.cs: more fixes and tests for them.
9906
9907 Wed Sep 7 17:14:26 BST 2005 Paolo Molaro <lupus@ximian.com>
9908
9909         * mini-arm.c: align structures to at least 4 bytes to be able
9910         to keep our current optimized memcpy.
9911
9912 Tue Sep 6 22:51:08 BST 2005 Paolo Molaro <lupus@ximian.com>
9913
9914         * mini-arm.c, cpu-arm.md, inssel-arm.brg: bugfixes.
9915
9916 2005-09-05 Gonzalo Paniagua Javier <gonzalo@ximian.com>
9917
9918         * mini.c: ignore SIGPIPE.
9919
9920 2005-09-04  Zoltan Varga  <vargaz@gmail.com>
9921
9922         * mini-ia64.c (mono_arch_lowering_pass): Convert 'and_imm 255' to zext1.
9923
9924         * mini-ia64.h mini-ia64.c: Add some minor optimizations.
9925
9926 2005-09-02  Zoltan Varga  <vargaz@gmail.com>
9927
9928         * mini.h: Add prototype for mono_allocate_stack_slots_full.
9929
9930 Thu Sep 1 21:05:26 BST 2005 Paolo Molaro <lupus@ximian.com>
9931
9932         * exceptions-arm.c, mini.c, mini-arm.c, mini-arm.h:
9933         exception handling support.
9934         * mini-arm.c, mini-arm.h: bigendian fixes (partially from a
9935         patch by Brian Koropoff <briank@marakicorp.com>).
9936
9937 Thu Sep 1 10:22:44 EDT 2005 Paolo Molaro <lupus@ximian.com>
9938
9939         * mini.c: revert another 'optimization' which breaks when
9940         items on the eval stack need to be saved at a basic block end
9941         (bug #75940).
9942
9943 Wed Aug 31 17:29:32 CEST 2005 Paolo Molaro <lupus@ximian.com>
9944
9945         * jit-icalls.c: for arrays, ensure we always provide
9946         lower bounds.
9947
9948 2005-08-30  Zoltan Varga  <vargaz@gmail.com>
9949
9950         * mini.c (mono_allocate_stack_slots_full): Fix ia64 build.
9951         
9952         * mini.c (mini_get_inst_for_method): Special case Object:.ctor as well.
9953
9954 2005-08-29  Zoltan Varga  <vargaz@gmail.com>
9955
9956         * mini-ia64.h mini-ia64.c: Implement frame pointer elimination. Keep
9957         arguments in their original register.
9958
9959 2005-08-28  Zoltan Varga  <vargaz@gmail.com>
9960
9961         * mini-ops.h cpu-ia64.md inssel-ia64.brg mini-ia64.c: Optimize
9962         memset/memcpy.
9963
9964         * mini.c (mono_method_to_ir): Disable the MUL->MUL_IMM optimization
9965         when ssapre is enabled.
9966
9967         * inssel-long.brg: Fix bug in previous patch.
9968
9969         * mini-ia64.c mini-ia64.h mini.c inssel-long.brg: Optimize 
9970         multiplication by a constant.
9971
9972 2005-08-27  Zoltan Varga  <vargaz@gmail.com>
9973
9974         * mini-ia64.c (mono_arch_setup_jit_tls_data): Add support for intel
9975         icc.
9976
9977         * tramp-ia64.c (mono_arch_create_trampoline_code): Use st8.spill for
9978         saving registers.
9979
9980 Fri Aug 26 11:09:28 BST 2005 Paolo Molaro <lupus@ximian.com>
9981
9982         * inssel-arm.brg: apply changes tested by Brian Koropoff
9983         <briank@marakicorp.com>.
9984
9985 2005-08-25  Zoltan Varga  <vargaz@gmail.com>
9986
9987         * mini-x86.c (mono_arch_emit_prolog): Fix calling of mono_jit_thread_attach () under windows.
9988         
9989 2005-08-24  Zoltan Varga  <vargaz@gmail.com>
9990
9991         * mini-codegen.c (mono_local_regalloc): Avoid allocating dreg and sreg1/2
9992         to the same register if dreg is just a base register.
9993         (print_ins): Improve printing of membase opcodes.
9994
9995         * inssel-x86.brg: Add optimized ldind(reg) rules.
9996
9997         * mini-x86.c cpu-pentium.md: Changes required to support the new rules.
9998
9999 Wed Aug 24 19:39:36 CEST 2005 Paolo Molaro <lupus@ximian.com>
10000
10001         * mini.c: when running under valgrind, set the stack bottom for
10002         the GC at the actual approximate stack for the app (fixes running
10003         mono with valgrind).
10004
10005 Tue Aug 23 21:38:50 CEST 2005 Paolo Molaro <lupus@ximian.com>
10006
10007         * mini.c: do no break at the first valuetype to init found
10008         (fixes bug #75791).
10009
10010 Tue Aug 23 16:53:21 BST 2005 Paolo Molaro <lupus@ximian.com>
10011
10012         * cpu-arm.md, mini-arm.c: more fixes and LMF support.
10013
10014 Tue Aug 23 15:11:44 CEST 2005 Paolo Molaro <lupus@ximian.com>
10015
10016         * cpu-g4.md: fixed instruction length exposed by the nemerle compiler.
10017
10018 2005-08-23  Zoltan Varga  <vargaz@freemail.hu>
10019
10020         * inssel-amd64.brg inssel-x86.brg: Fix the fcall rules.
10021
10022 2005-08-22  Zoltan Varga  <vargaz@freemail.hu>
10023
10024         * inssel-x86.brg: Fix assert in patch_delegate_trampoline.
10025
10026         * tramp-x86.c (mono_arch_patch_delegate_trampoline): Add some debug
10027         code.
10028
10029         * tramp-amd64.c (mono_arch_patch_delegate_trampoline): Add some debug
10030         code.
10031
10032         * mini.c (optimize_branches): Don't quit after 1000 iterations on large
10033         methods.
10034
10035 Mon Aug 22 19:16:29 BST 2005 Paolo Molaro <lupus@ximian.com>
10036
10037         * tramp-arm.c: allocate less memory for the trampoline and fix typo.
10038
10039 2005-08-22  Zoltan Varga  <vargaz@freemail.hu>
10040
10041         * mini.c (mono_method_to_ir): Remove instructions inserted after a branch
10042         in the tail recursion optimization.
10043
10044         * mini.h helpers.c (mono_disassemble_code): Emit starts of basic blocks as 
10045         debug info into the assembly file.
10046
10047         * iltests.il: Add test for filter regions.
10048
10049         * mini.c (mono_method_to_ir): Fix handling of nested FILTER clauses. Fix
10050         initial stack of filter regions. Fixes #75755.
10051
10052 Mon Aug 22 17:49:16 BST 2005 Paolo Molaro <lupus@ximian.com>
10053
10054         * mini-arm.c, cpu-arm.c: fixes and support for methods with bigger
10055         stack requirements.
10056
10057 2005-08-22  Zoltan Varga  <vargaz@freemail.hu>
10058
10059         * mini.c (mono_create_delegate_trampoline): Fix memory leak. Put back
10060         the check for an already compiled method on non-ia64 platforms.
10061         (mono_create_jump_trampoline): Store the MonoJitInfo structure into the
10062         proper domain.
10063
10064         * mini-x86.h tramp-x86.c: Add support for delegate trampolines.
10065
10066         * inssel-x86.brg: Add some optimized call rules.
10067
10068 2005-08-21  Zoltan Varga  <vargaz@freemail.hu>
10069
10070         * mini.c (mono_create_delegate_trampoline): Do not return an already compiled
10071         method here.
10072
10073         * mini.h mini-trampolines.c: Pass the trampoline argument to 
10074         mono_arch_patch_delegate_trampoline.
10075
10076         * mini-ia64.h mini-ia64.c tramp-ia64.c: Add support for delegate trampolines.
10077
10078         * mini-trampolines.c: Fix build.
10079
10080         * mini-amd64.h: Add delegate trampolines.
10081
10082         * mini.h mini.c mini-trampolines.c tramp-amd64.c: Add delegate trampolines.
10083
10084         * inssel-amd64.brg: Add optimized call rules.
10085         
10086         * mini-ia64.c tramp-ia64.c: Improve instruction scheduling.
10087
10088         * inssel-ia64.brg: Add optimized ldind(reg) rules.
10089
10090 2005-08-20  Zoltan Varga  <vargaz@freemail.hu>
10091
10092         * mini.c (mono_create_class_init_trampoline): Fix bug caused by last
10093         change.
10094
10095         * mini-ia64.c: Remove LMF fixmes.
10096
10097         * mini-ia64.h: Remove most fields from LMF.
10098
10099         * inssel-ia64.brg (stmt): Fix unaligned access errors.
10100
10101         * mini-trampolines.c: Add support for IA64 function descriptors.
10102
10103         * mini.h mini.c jit-icalls.c exceptions-ia64.cdriver.c: Add support
10104         for IA64 function descriptors.
10105
10106 Sat Aug 20 16:51:44 BST 2005 Paolo Molaro <lupus@ximian.com>
10107
10108         * tramp-arm.c: patch the vtable for virtual calls. Added
10109         support code to register/unregister the LMF.
10110         * mini-arm.c, mini-arm.h: warning fixes, fixes, speedups,
10111         more LMF work.
10112
10113 2005-08-19  Dick Porter  <dick@ximian.com>
10114
10115         * mini.c: Use a gsize to store the thread ID, so it can hold a 64
10116         bit value if needed.
10117
10118 2005-08-19  Zoltan Varga  <vargaz@freemail.hu>
10119
10120         * mini.c (mini_get_method): Move handling of wrapper data here.
10121
10122         * mini.c (mono_method_to_ir): Add support for dynamic methods.
10123
10124         * mini.c (mono_method_to_ir): Convert nonvirtual calls to abstract methods into
10125         virtual.
10126
10127         * mini.c (mono_method_to_ir): Emit IR for CEE_NOP as well, so 
10128         bblock->code does not remain empty.
10129
10130 2005-08-17  Zoltan Varga  <vargaz@freemail.hu>
10131
10132         * arrays.cs: Add regression test for #75832.
10133
10134         * inssel-amd64.brg cpu-amd64.md mini-amd64.c: Fix LDELEMA optimization
10135         rules. Fixes #75832.
10136
10137         * mini-ia64.c tramp-ia64.c exceptions-ia64.c: Implement improved
10138         instruction scheduling.
10139
10140 2005-08-12  Zoltan Varga  <vargaz@freemail.hu>
10141
10142         * mini-exceptions.c (ves_icall_get_frame_info): Fix IA64 build.
10143
10144 2005-08-11  Zoltan Varga  <vargaz@freemail.hu>
10145
10146         * mini-exceptions.c mini-x86.h: Move VC stuff into macros in mini-x86.h.
10147
10148         * mini-codegen.c: Fix VC build.
10149
10150         * cpu-pentium.md: Increase length of atomic_exhange_i4.
10151
10152 2005-08-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
10153
10154         * mini.h: fix signature for mono_register_opcode_emulation.
10155
10156 2005-08-09  Zoltan Varga  <vargaz@freemail.hu>
10157
10158         * mini.c: Get rid of most of the helper_sig_... constants using
10159         mono_create_icall_signature ().
10160
10161 2005-08-08  Zoltan Varga  <vargaz@freemail.hu>
10162
10163         * jit-icalls.c (helper_ldstr): New helper function.
10164
10165         * mini.c (get_basic_blocks): Set out_of_line for bblocks containing a throw.
10166
10167         * mini.c (mono_method_to_ir): If an LDSTR instruction is in a bblock with a
10168         throw, load the string using a helper call instead of creating a string object.
10169
10170         * aot.c: Update after LDSTR changes.
10171
10172         * mini.h: Bump AOT file version.
10173         
10174         * aot.c: Save class size info into the AOT file. Print more statistics during
10175         compilation.
10176
10177         * mini.h: Bump AOT file version.
10178
10179         * tramp-amd64.c (mono_arch_nullify_class_init_trampoline): Fix
10180         ordering of disasm cases. Fixes #74957.
10181
10182 Thu Aug 4 19:47:24 BST 2005 Paolo Molaro <lupus@ximian.com>
10183
10184         * mini-ops.h, mini-arch.h, inssel.brg, mini.c, mini.h,
10185         jit-icalls.c, mini-codegen.c, Makefile.am: changes in
10186         the generic code needed for the ARM port.
10187
10188 Thu Aug 4 19:42:54 BST 2005 Paolo Molaro <lupus@ximian.com>
10189
10190         * exceptions-arm.c, tramp-arm.c, mini-arm.c, mini-arm.h, cpu-arm.md,
10191         inssel-arm.brg: more ARM features and fixes.
10192
10193 Mon Aug 1 18:37:38 BST 2005 Paolo Molaro <lupus@ximian.com>
10194
10195         * tramp-arm.c, mini-arm.c, cpu-arm.md, inssel-arm.brg: more
10196         ARM port work in progress.
10197
10198 2005-07-30  Zoltan Varga  <vargaz@freemail.hu>
10199
10200         * mini-ia64.c (mono_arch_call_opcode): Ongoing IA64 work.
10201
10202         * mini-exceptions.c mini-ia64.h: Ongoing IA64 work.
10203
10204         * mini-ia64.c (ia64_emit_bundle): Ongoing IA64 work.
10205
10206         * inssel.brg (mini_emit_memset): Add support for unaligned access.
10207
10208         * *-ia64.*: Ongoing IA64 work.
10209         
10210         * mini-ia64.c exceptions-ia64.c: Ongoing IA64 work.
10211
10212 2005-07-28  Zoltan Varga  <vargaz@freemail.hu>
10213
10214         * TODO: Remove out-of-data todo stuff.
10215
10216         * mini.h mini.c (mono_create_jit_trampoline_from_token): Remove some
10217         dead code.
10218
10219         * aot.c: Save/load MonoCachedClassInfo->has_nested_classes.
10220
10221         * mini.h: Bump corlib version.
10222
10223 2005-07-27  Martin Baulig  <martin@ximian.com>
10224
10225         * mini-codegen.c
10226         (create_copy_ins): Added `const unsigned char *ip' argument; set
10227         `copy->cil_code' from it.
10228
10229 2005-07-27  Martin Baulig  <martin@ximian.com>
10230
10231         * mini-exceptions.c (mono_handle_exception): Don't call
10232         mono_debugger_handle_exception() for filters.
10233
10234 2005-07-27  Zoltan Varga  <vargaz@freemail.hu>
10235
10236         * mini-trampolines.c (mono_aot_trampoline): Handle AppDomain:InvokeInDomain
10237         as well.
10238
10239 2005-07-26  Martin Baulig  <martin@ximian.com>
10240
10241         Committing a patch from Michal Moskal <michal.moskal@gmail.com>.
10242
10243         * mini.c (mono_method_to_ir): In `CEE_CALLI', only use
10244         helper_compile_generic_method() if the method is actually virtual
10245         and non-final.
10246
10247 2005-07-26  Martin Baulig  <martin@ximian.com>
10248
10249         * mini.c
10250         (trampoline_code): Renamed to `mono_trampoline_code' and made it
10251         public; this is now accessed directly by the debugger.
10252         (mono_generic_trampoline_code): Removed.
10253
10254         * debug-mini.c
10255         (mono_debug_init_method): Also add interncalls and wrappers.
10256
10257 2005-07-23  Zoltan Varga  <vargaz@freemail.hu>
10258
10259         * mini-ia64.c mini-ia64.h: Add support for tracing/profiling.
10260
10261 2005-07-22  Zoltan Varga  <vargaz@freemail.hu>
10262
10263         * aot.c (mono_aot_get_method_from_token): Fix a potential crash here.
10264
10265 2005-07-21  Zoltan Varga  <vargaz@freemail.hu>
10266
10267         * aot.c (load_patch_info): Fix handling of stfld_remote wrapper.
10268
10269 2005-07-20  Zoltan Varga  <vargaz@freemail.hu>
10270
10271         * mini-amd64.c (mono_arch_setup_jit_tls_data): Use the nice way of
10272         getting TLS offsets on AMD64 too.
10273
10274 2005-07-20  Kornél Pál <kornelpal@hotmail.com>
10275
10276         * driver.c: Detach console when executing IMAGE_SUBSYSTEM_WINDOWS_GUI on win32
10277
10278 Wed Jul 20 18:05:19 BST 2005 Paolo Molaro <lupus@ximian.com>
10279
10280         * exceptions-arm.c, mini-arm.c, tramp-arm.c, cpu-arm.md,
10281         inssel-arm.brg, mini-arm.h: ARM port work in progress.
10282
10283 2005-07-20  Zoltan Varga  <vargaz@freemail.hu>
10284
10285         * tramp-amd64.c (mono_arch_create_specific_trampoline): Fix build.
10286
10287         * mini.h mini.c mini-*.h tramp-*.c: Move more cross platform trampoline code
10288         to mini.c.
10289
10290         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Call 
10291         mono_sparc_is_virtual_call ().
10292         
10293         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Fix warning.
10294
10295         * tramp-sparc.c (mono_arch_create_trampoline_code): Fix order of
10296         trampoline parameters.
10297
10298         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Fix signature.
10299         
10300         * mini-sparc.c (mono_arch_get_vcall_slot_addr): Rename this
10301         to mono_arch_get_vcall_slot_addr.
10302
10303         * Makefile.am tramp-sparc.c: Update the sparc port to use the generic
10304         trampoline code.
10305
10306         * *-sparc.*: Merge the mini-xp-regalloc branch for sparc.
10307
10308 2005-07-19  Zoltan Varga  <vargaz@freemail.hu>
10309
10310         * mini-ia64.h mini-ia64.c: Finish pinvoke support.
10311
10312 2005-07-19  Martin Baulig  <martin@ximian.com>
10313
10314         * exceptions-amd64.c (throw_exception): Call
10315         mono_debugger_throw_exception() here like we're doing it on i386.
10316
10317 2005-07-19  Zoltan Varga  <vargaz@freemail.hu>
10318
10319         * mini-ia64.c: Add optimized TLS access support.
10320
10321 2005-07-18  Zoltan Varga  <vargaz@freemail.hu>
10322
10323         * mini-exceptions.c: Ongoing IA64 work.
10324
10325         * mini-ia64.c inssel-long.brg: Ongoing IA64 work.
10326
10327         * mini.c: Use the default optimization set when embedding. Fixes
10328         #75194.
10329
10330 2005-07-11  Zoltan Varga  <vargaz@freemail.hu>
10331
10332         * tramp-amd64.c tramp-ia64.c Makefile.am: Move arch independent parts 
10333         of trampolines to a separate file.
10334
10335         * mini-trampolines.c: New file.
10336
10337         * mini.h tramp-x86.c: Move arch independent parts of trampolines to a 
10338         separate file.
10339         
10340         * tramp-x86.c: Reorganize the trampoline code to be similar to the 
10341         amd64/ia64 code.
10342
10343         * mini-codegen.c: Fix cygwin build.
10344
10345 2005-07-10  Zoltan Varga  <vargaz@freemail.hu>
10346
10347         * mini.c: Add some minor changes needed by the IA64 port.
10348
10349         * *-ia64.*: Ongoing IA64 work.
10350
10351 2005-07-09  Zoltan Varga  <vargaz@freemail.hu>
10352
10353         * tramp-amd64.c mini-amd64.c: Update after latest AOT changes. Split 
10354         trampolines into arch-independent and arch-dependent parts.
10355
10356         * mini-amd64.c (mono_arch_lowering_pass): Fix store_membase_imm -> store_membase_reg rule.
10357
10358 2005-07-08  Zoltan Varga  <vargaz@freemail.hu>
10359
10360         * cpu-amd64.md: Merge the xp-regalloc-branch for amd64.
10361
10362         * mini-ops.h mini-amd64.h mini-amd64.c inssel-amd64.brg Makefile.am: Merge
10363         the xp-regalloc-branch for amd64.
10364
10365         * mini-x86.h mini-x86.c cpu-pentium.md Makefile.am: Merge the
10366         xp-regalloc-branch for x86.
10367
10368 2005-07-07  Zoltan Varga  <vargaz@freemail.hu>
10369
10370         * inssel.brg (OP_THROW_OR_NULL): Allways rethrow the abort exception.
10371
10372 2005-07-06  Martin Baulig  <martin@ximian.com>
10373
10374         * mini.c
10375         (mono_jit_compile_method_inner): Call mono_get_inflated_method().
10376         (mono_jit_runtime_invoke): Likewise.
10377
10378 2005-07-05  Zoltan Varga  <vargaz@freemail.hu>
10379
10380         * aot.c (mono_compile_assembly): Allocate the GOT in the .bss segment
10381         on x86 too.
10382         
10383         * aot.c: Add new mono_aot_get_method_from_token () function to load AOT methods
10384         without loading their metadata. Reorganize the file format so exception handling+
10385         debug info is kept separate from normal method info. Create MonoJitInfo 
10386         structures for methods lazily.
10387
10388         * tramp-x86.c (x86_aot_trampoline): Use the new from_token method to avoid
10389         loading metadata.
10390         (x86_class_init_trampoline): Patch AOT class init trampolines too.
10391
10392         * mini.c (mini_init): Install the new mono_aot_find_jit_info hook.
10393
10394         * mini.c (mono_method_to_ir): Reduce the number of class init trampoline calls
10395         in AOT code.
10396
10397         * mini.h: Bump AOT file version.
10398
10399 2005-07-04  Zoltan Varga  <vargaz@freemail.hu>
10400
10401         * mini-x86.c (peephole_pass): Fix the loadi1/loadi2 rules.
10402
10403 2005-07-01  Raja R Harinath  <rharinath@novell.com>
10404
10405         * Makefile.am (check-local): Call semdel-wrapper.
10406
10407 2005-06-29  Zoltan Varga  <vargaz@freemail.hu>
10408
10409         * mini-x86.c: Revert the last change as it seems to break the build..
10410
10411 2005-06-28  Zoltan Varga  <vargaz@freemail.hu>
10412
10413         * mini-x86.c (peephole_pass): Fix the loadi1/loadi2 rules.
10414         
10415         * mini-x86.c (mono_arch_cpu_init): Fix setting of fp precision in the VC build.
10416
10417 2005-06-27  Ben Maurer  <bmaurer@ximian.com>
10418
10419         * mini.c (NEW_AOTCONST): make sure to call mono_get_got_var
10420         outside of the macro, so strange stuff doesn't happen with gcc4
10421         (NEW_AOTCONST_TOKEN): Likewise.
10422
10423 2005-06-28  Martin Baulig  <martin@ximian.com>
10424
10425         * mini.c (mini_class_is_system_array): New static method; use this
10426         instead of `klass->parent == mono_defaults.array_class' everywhere
10427         since this also works for the new generic array class.
10428
10429 2005-06-26  Ben Maurer  <bmaurer@ximian.com>
10430
10431         * inssel.brg: Remove warnings.
10432
10433 2005-06-24  Zoltan Varga  <vargaz@freemail.hu>
10434
10435         * mini-ia64.c: Ongoing IA64 work.
10436
10437         * basic-float.cs: Add float->i1 conversion test.
10438
10439         * iltests.il: Add conv.u4 test.
10440
10441 2005-06-23  Zoltan Varga  <vargaz@freemail.hu>
10442
10443         * inssel-long.brg: Fix bug caused by last change.
10444
10445 2005-06-23  Geoff Norton  <gnorton@customerdna.com>
10446
10447         * mini-x86.h: Add __APPLE__ to the SC_* redefines with the other 
10448         BSDs.  Allows the x86 JIT to work on OSX86
10449
10450 2005-06-22  Zoltan Varga  <vargaz@freemail.hu>
10451
10452         * inssel-long.brg: Use OP_LSHR_UN_IMM instead of OP_SHR_UN_IMM in
10453         u4->i8 conversion.
10454
10455         * mini-ia64.c: Ongoing IA64 work.
10456
10457 2005-06-19  Zoltan Varga  <vargaz@freemail.hu>
10458
10459         * mini-ia64.c: Ongoing IA64 work.
10460
10461         * driver.c: Clean up jit_code_hash as well when using --regression.
10462
10463         * inssel-long.brg: Fix long->i4/u4 conversion rules.
10464
10465         * basic-long.cs: Add tests for long->u4 conversion.
10466
10467 2005-06-18  Ben Maurer  <bmaurer@ximian.com>
10468
10469         * mini.c: Take mono_get_domainvar out of macros. This makes sure
10470         that we do not depend on undefined C behavior: the order stuff
10471         gets evaluated within an expression. Fixes mono when compiled on
10472         GCC 4.
10473
10474 2005-06-18  Zoltan Varga  <vargaz@freemail.hu>
10475
10476         * *-ia64.*: Ongoing IA64 work.
10477
10478         * aot.c: Lower memory usage while loading AOT methods.
10479
10480         * tramp-x86.c: Avoid allocating+freeing MonoJitInfo structures.
10481
10482         * mini.h: Bump AOT file format version.
10483
10484 2005-06-17  Zoltan Varga  <vargaz@freemail.hu>
10485
10486         * mini.c (mono_method_to_ir): Allow STACK_PTR as input to SWITCH.
10487
10488 2005-06-16  Sebastien Pouliot  <sebastien@ximian.com>
10489
10490         * declsec.c: Fixed APTC to check for FullTrust on caller assembly (and
10491         not on callee assembly). Fixed some comments.
10492
10493 2005-06-16  Zoltan Varga  <vargaz@freemail.hu>
10494
10495         * aot.c (mono_compile_assembly): Mark the "methods" symbol as a function so
10496         it gets proper disassembly.
10497         (emit_method_info): Remove some dead code.
10498
10499         * mini.c (mini_method_compile): Allways allocate the GOT var in
10500         mono_method_to_ir for emulating opcodes.
10501
10502 2005-06-13  Zoltan Varga  <vargaz@freemail.hu>
10503
10504         * mini.c (mono_jit_free_method): Remove the method from the JitInfo table
10505         before freeing the code memory. Fixes #74990.
10506
10507         * objects.cs: Add regression test for #74992.
10508
10509         * liveness.c: Extend live ranges of arguments to the beginning of the
10510         method. Fixes #74992.
10511
10512         * exceptions-ia64.c mini-ia64.h: Modify ip during exception handling
10513         so it points into the faulting instruction.
10514
10515 2005-06-12  Zoltan Varga  <vargaz@freemail.hu>
10516
10517         * jit-icalls.c (mono_imul_ovf): Add exception handling.
10518
10519         * *-ia64.*: Ongoing IA64 work.
10520
10521         * mini.c (mini_init): Fix signature of mono_delegate_ctor.
10522
10523 2005-06-11  Zoltan Varga  <vargaz@freemail.hu>
10524
10525         * mini-ia64.h exceptions-ia64.c: Ongoing IA64 work.
10526
10527         * *-ia64.*: Ongoing IA64 work.
10528
10529 2005-06-10  Zoltan Varga  <vargaz@freemail.hu>
10530
10531         * basic-long.cs: Add tests for add/sub.ovf.
10532
10533         * basic.cs: Add tests for sub.ovf.
10534
10535         * *-ia64.*: Ongoing IA64 work.
10536
10537 2005-06-09  Zoltan Varga  <vargaz@freemail.hu>
10538
10539         * *-ia64.*: Ongoing IA64 work.
10540
10541         * basic.cs: Add conv.ovf.i4.un test.
10542
10543 2005-06-09  Massimiliano Mantione  <massi@ximian.com>
10544
10545         * mini.c: (remove_block_if_useless) Fixed bug 75061.
10546         
10547 2005-06-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
10548
10549         * mini.c: no SIGUSR2 on windows. Remove it for PLATFORM_WIN32.
10550
10551 2005-06-07  Zoltan Varga  <vargaz@freemail.hu>
10552
10553         * *-ia64.*: Ongoing IA64 work.
10554
10555 2005-06-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
10556
10557         * trace.[ch]:
10558         * mini.c: added the ability to toggle trace on/off using SIGUSR2.
10559
10560 2005-06-04  Zoltan Varga  <vargaz@freemail.hu>
10561
10562         * mini-ia64.c mini-ia64.h: Fix cleanup of memory stack.
10563
10564 2005-06-03  Zoltan Varga  <vargaz@freemail.hu>
10565
10566         * mini-amd64.c (emit_call): Fix yet another bug in the near call optimization.
10567
10568         * mini-amd64.c (amd64_patch): Add an assert to check that the destination
10569         of a call is callable by a near call.
10570
10571 2005-05-31  Zoltan Varga  <vargaz@freemail.hu>
10572
10573         * mini-ia64.c: Ongoing IA64 work.
10574
10575 2005-05-29  Zoltan Varga  <vargaz@freemail.hu>
10576
10577         * genmdesc.c: Make the generated array non-static.
10578
10579         * inssel-long.brg: Fix LSHR_IMM rule.
10580
10581         * *-ia64.*: Ongoing IA64 work.
10582
10583         * *-ia64.*: Ongoing IA64 work.
10584
10585 2005-05-28  Zoltan Varga  <vargaz@freemail.hu>
10586
10587         * *-ia64.*: Ongoing IA64 work.
10588
10589         * *-ia64.*: Ongoing IA64 work.
10590         
10591         * mini-ia64.c: Ongoing IA64 work.
10592
10593         * *-ia64.* jit-icalls.c mini-codegen.c: Ongoing IA64 work.
10594
10595 2005-05-28  Zoltan Varga  <vargaz@freemail.hu>
10596
10597         * objects.cs basic-calls.cs: Move some tests to objects.cs.
10598         
10599         * objects.cs basic-long.cs: Move some tests to objects.cs.
10600
10601 2005-05-26  Zoltan Varga  <vargaz@freemail.hu>
10602
10603         * *-ia64.*: Ongoing IA64 work.
10604
10605         * iltests.il: Add a new test.
10606
10607         * mini.c (mono_method_to_ir): Initialize valuetypes when created using
10608         newobj. Fixes #75042.
10609
10610 2005-05-22  Zoltan Varga  <vargaz@freemail.hu>
10611
10612         * *-ia64.*: Ongoing IA64 work.
10613         
10614         * *-ia64.*: Ongoing IA64 work.
10615         
10616         * *-ia64.*: Ongoing IA64 work.
10617
10618         * basic.cs objects.cs: Move tests accessing static variables as well.
10619
10620         * basic.cs objects.cs: Move test_0_pin_string to objects.cs.
10621
10622 2005-05-21  Zoltan Varga  <vargaz@freemail.hu>
10623
10624         * mini.c (SIG_HANDLER_SIGNATURE): Fix warning.
10625
10626         * driver.c: Always print failed tests.
10627
10628         * mini-codegen.c: Use cfg->frame_reg instead of a macro for the
10629         frame pointer.
10630
10631         * *ia64*: Ongoing IA64 work.
10632
10633 2005-05-20  Zoltan Varga  <vargaz@freemail.hu>
10634
10635         * basic.cs: Add tests for add.ovf. Fix warnings.
10636
10637 2005-05-18  Miguel de Icaza  <miguel@novell.com>
10638
10639         * driver.c (mono_main): Avoid crash if no argument is passed to
10640         --break;  Do not use g_error, but f_printf.   And fix all other
10641         ocurrences of the same crash.
10642
10643 2005-05-17  Zoltan Varga  <vargaz@freemail.hu>
10644
10645         * mini.h mini.c: Generalize the existing uses of the MONO_DEBUG env variable
10646         and add a new one: aborting when a SIGSEGV is raised while in unmanaged code.
10647         Fixes #74742.
10648
10649 2005-05-14  Zoltan Varga  <vargaz@freemail.hu>
10650
10651         * *-ia64.*: Add beginnings of IA64 backend.
10652
10653         * Makefile.am mini-arch.h mini-codegen.c: Add IA64 support.     
10654
10655 2005-05-13  Zoltan Varga  <vargaz@freemail.hu>
10656
10657         * inssel-long.brg: Add missing ulong->{i1, i2} checked conversions.
10658         Fixes #74925.
10659
10660         * basic-long.cs exceptions.cs: Add new tests. Fix some warnings.
10661
10662         * mini-amd64.c: Fix a warning.
10663
10664 2005-05-10  Zoltan Varga  <vargaz@freemail.hu>
10665
10666         * mini-amd64.c (mono_arch_output_basic_block): Fix stack space leakage
10667         in float_neg. Fixes #74897.
10668
10669         * mini-amd64.c (emit_call): Fix another near call bug.
10670
10671 2005-05-06  Sebastien Pouliot  <sebastien@ximian.com>
10672
10673         * declsec.c: Keep the appdomain information in the structure. Added a 
10674         missing "return FALSE" for Unmanaged if FullTrust is set (or else the
10675         value gets overwritten).
10676         * declsec.h: Set the default MonoArray for the the stack to 6. Added
10677         an MonoAppDomain member to MonoSecurityFrame.
10678         * mini-exceptions.c: Do not use a glist to keep GC allocated objects
10679         used in the stack walk. Now use a MonoArray which grow (double) when
10680         it gets full.
10681
10682 2005-05-05  Lluis Sanchez Gual  <lluis@novell.com>
10683
10684         * mini.c: Re-enabled runtime cleanup, since running threads should
10685         now properly stop when exiting.
10686
10687 2005-05-05  Zoltan Varga  <vargaz@freemail.hu>
10688
10689         * mini-codegen.c: New file contaning the arch-independent local
10690         register allocator. Not used by any architectures yet.
10691
10692         * mini.h linear-scan.c: Merge some changes from the 
10693         mini-xp-local-regalloc branch.
10694
10695 2005-04-28  Zoltan Varga  <vargaz@freemail.hu>
10696
10697         * mini-amd64.c (emit_call): Fix calls to native functions when the
10698         runtime is compiled as a shared library. Fixes #74756.
10699
10700         * mini.c (mono_method_to_ir): Assert if ldsfld and friends are used
10701         on a literal field. Fixes #74751.
10702
10703 2005-04-25  Raja R Harinath  <rharinath@novell.com>
10704
10705         * Makefile.am (RUNTIME): Add MONO_CFG_DIR.
10706
10707 2005-04-23  Zoltan Varga  <vargaz@freemail.hu>
10708
10709         * objects.cs: Add missing null casting test.
10710
10711 2005-04-22  Zoltan Varga  <vargaz@freemail.hu>
10712
10713         * mini-exceptions.c (mono_find_jit_info): Fix native offset calculation
10714         in wrapper methods. Also rename 'address' variable to 'offset'.
10715
10716 2005-04-20  Zoltan Varga  <vargaz@freemail.hu>
10717
10718         * mini.c debug-mini.c aot.c tramp-x86.c driver.c: Fix some gcc 4.0
10719         warnings.
10720         
10721         * Makefile.am (MCS): Use -unsafe instead of --unsafe.
10722
10723         * aot.c: Applied patch from "The Software Team" <software@solmersa.com>. Make AOT compilation
10724         work on windows.
10725
10726 Mon Apr 18 16:20:32 CEST 2005 Paolo Molaro <lupus@ximian.com>
10727
10728         * exceptions-ppc.c: update code to handle stack traces (fixes bug #74452).
10729
10730 2005-04-17  Zoltan Varga  <vargaz@freemail.hu>
10731
10732         * mini-x86.c (mono_emit_stack_alloc): Initialize the whole allocated area not
10733         just the last bytes.
10734
10735 2005-04-17  Zoltan Varga  <vargaz@freemail.hu>
10736
10737         * aot.c (mono_compile_assembly): Fix warning.
10738
10739         * mini-exceptions.c (ves_icall_get_frame_info): Fix bug introduced
10740         by the _MSC_VER stuff.
10741
10742 2005-04-16  Zoltan Varga  <vargaz@freemail.hu>
10743
10744         * inssel-long.brg: Fix #74588.
10745
10746         * cpu-amd64.md: Fix #74591.
10747
10748         * iltests.il: Add new regression tests.
10749
10750 2005-04-13  Zoltan Varga  <vargaz@freemail.hu>
10751
10752         * trace.c (mono_trace_enter_method): Print enums as an int, not as a
10753         valuetype.
10754
10755 2005-04-11  Zoltan Varga  <vargaz@freemail.hu>
10756
10757         * mini-x86.c (setup_stack): Unconditionally call pthread_attr_init ().
10758
10759         * exceptions-x86.c mini-x86.h mini-x86.c: Applied some freebsd patches 
10760         from Bill Middleton <flashdict@gmail.com>.
10761
10762 2005-04-10  Zoltan Varga  <vargaz@freemail.hu>
10763
10764         * arrays.cs: Add new regression test. Fix warnings.
10765
10766 2005-04-09  Zoltan Varga  <vargaz@freemail.hu>
10767
10768         * mini-amd64.c (mono_arch_output_basic_block): Fix stack alignment
10769         and leakage in CKFINITE.
10770
10771         * exceptions-amd64.c (mono_arch_get_throw_exception_by_name): Change
10772         this to a null op since it is called on amd64 too.
10773
10774         * exceptions-amd64.c (get_throw_trampoline): Align stack.
10775
10776         * exceptions-amd64.c (mono_arch_get_throw_exception_by_name): Remove
10777         body since this is not used on amd64.
10778         
10779         * mini-amd64.h (MONO_ARCH_NO_EMULATE_LONG_SHIFT_OPS): Remove duplicate define.
10780
10781         * mini-amd64.c: Remove obsolete fixmes.
10782
10783         * mini.c (print_method_from_ip): Fix debugging support.
10784
10785 2005-2-1  Massimiliano Mantione  <massi@ximian.com>
10786
10787         * ssapre.c: Fix a subtle bug about availability, and limit SSAPRE
10788         so that expressions that don't give much gain are not reduced.
10789         * ssapre.h: Likewise.
10790
10791 2005-04-04  Zoltan Varga  <vargaz@freemail.hu>
10792
10793         * exceptions-x86.c (mono_arch_find_jit_info): Remove last SC_EBP reference.
10794
10795         * mini-x86.c (mono_emit_stack_alloc): Fix localloc under windows.
10796
10797         * mini-x86.h exceptions-x86.c: Hopefully fix compilation on *BSD.
10798
10799 2005-04-01  Zoltan Varga  <vargaz@freemail.hu>
10800
10801         * mini-sparc.c mini-sparc.h: Add asserts when running with sigaltstack.
10802
10803         * exceptions-x86.c (mono_arch_monoctx_to_sigctx): Fix cygwin build.
10804
10805 2005-03-31  Zoltan Varga  <vargaz@freemail.hu>
10806
10807         * mini-x86.c: If sigaltstack support is enabled, perform win32 style
10808         stack touching.
10809
10810         * mini.h (mono_arch_sigctx_to_monoctx): New arch-specific function.
10811
10812         * mini.h (mono_arch_monoctx_to_sigctx): New arch-specific function.
10813
10814         * mini.c: sigaltstack support requires MONO_ARCH_USE_SIGACTION.
10815
10816         * mini-x86.h mini-x86.c exceptions-x86.c: Add support for 
10817         MONO_ARCH_USE_SIGACTION. Fixes #74252.
10818
10819         * mini-x86.h: Enable MONO_ARCH_USE_SIGACTION on linux.
10820
10821         * mini-x86.c: Fix up stack overflow handling.   
10822
10823         * exceptions.cs: Add new regression test.
10824
10825 2005-03-30  Zoltan Varga  <vargaz@freemail.hu>
10826
10827         * mini-x86.c (mono_arch_emit_prolog): Adjust stack after calls to
10828         mono_jit_thread_attach.
10829
10830         * mini.c (mono_method_to_ir): Verify called method is not abstract.
10831
10832 2005-03-29  Zoltan Varga  <vargaz@freemail.hu>
10833
10834         * mini.c (mono_method_to_ir): Applied Ben's patch from bug #61441 to
10835         avoid calling constructors using callvirt.
10836
10837         * inssel.brg: Fix #74073.
10838
10839 2005-03-29  Sebastien Pouliot  <sebastien@ximian.com>
10840
10841         * aot.c, mini.h: Added mono-compiler.h header to allow/ease 
10842         compilation with non-GCC compilers.
10843         * mini-exceptions.c, mini-x86.c|h: Patches to make compilation of mono
10844         possible using VS.NET. Adapted from the work of J Lothian (for VC6).
10845
10846 Tue Mar 29 11:43:01 CEST 2005 Paolo Molaro <lupus@ximian.com>
10847
10848         * inssel.brg, arrays.cs: fix long standing 64 bit issue in access to
10849         klass->interface_offsets (will likely fix bug#74073).
10850
10851 2005-03-29  Zoltan Varga  <vargaz@freemail.hu>
10852
10853         * mini-amd64.c (mono_arch_is_int_overflow): Fix rex handling.
10854
10855 2005-03-28  Zoltan Varga  <vargaz@freemail.hu>
10856
10857         * mini-amd64.c (mono_arch_output_basic_block): Fix order of parameters
10858         to amd64_div_reg_size ().
10859         
10860         * mini-amd64.c (mono_arch_emit_exceptions): Emit a near call here too.
10861
10862 2005-03-27  Zoltan Varga  <vargaz@freemail.hu>
10863
10864         * cpu-amd64.md (store_membase_reg): Fix length of storer8 opcodes.
10865
10866 2005-03-24  Zoltan Varga  <vargaz@freemail.hu>
10867
10868         * driver.c: Turn off automatic command line globbing under windows. Fixes #73763.
10869
10870 2005-03-24  Zoltan Varga  <vargaz@freemail.hu>
10871
10872         * mini.c (mono_method_to_ir): Remove debugging stuff left in by mistake.
10873         
10874         * mini.c (mono_precompile_assembly): Load and precompile referenced
10875         assemblies as well. Fixes #74015.
10876
10877 2005-03-23  Zoltan Varga  <vargaz@freemail.hu>
10878
10879         * cpu-amd64.md (sin): Fix up maximum lengths of some opcodes.
10880
10881 2005-03-23  Sebastien Pouliot  <sebastien@ximian.com>
10882
10883         * declsec.c: Skip linkdemand checks for intra-corlib calls. This skips
10884         a lot of checks and (anyway) permissions cannot work until corlib is 
10885         loaded.
10886
10887 Wed Mar 23 14:29:49 CET 2005 Paolo Molaro <lupus@ximian.com>
10888
10889         * mini-ppc.c: fixed ABI issue on sysv/ppc.
10890
10891 Tue Mar 22 19:03:17 CET 2005 Paolo Molaro <lupus@ximian.com>
10892
10893         * tramp-ppc.c, exceptions-ppc.c: added missing icache flush
10894         calls (fixes bug#72824).
10895
10896 Tue Mar 22 16:28:48 CET 2005 Paolo Molaro <lupus@ximian.com>
10897
10898         * mini.c: fix tail recursion elimination (see test in bug#73936).
10899
10900 2005-03-21  Zoltan Varga  <vargaz@freemail.hu>
10901
10902         * mini-amd64.c (mono_arch_output_basic_block): Add inline versions of
10903         some fp functions in sse2 mode.
10904
10905 2005-03-20  Zoltan Varga  <vargaz@freemail.hu>
10906
10907         * mini-x86.c (emit_tls_get): Move tls handling into a separate helper function.
10908
10909 2005-03-19  Zoltan Varga  <vargaz@freemail.hu>
10910
10911         * mini.h mini.c: Add mono_get_jit_tls_key ().
10912
10913         * mini-x86.c: Enable fast TLS support on windows.
10914
10915 2005-03-17  Sebastien Pouliot  <sebastien@ximian.com>
10916
10917         * declsec.c: Renamed aptc to allowpartiallytrustedcallers.
10918         * mini.c: Check for p/invoke method when generating code. If a
10919         p/invoke method, or it's class, isn't decorated with [Suppress
10920         UnmanagedCodeSecurity] then generate code to call System.Security.
10921         UnmanagedDemand (only if the security manager is active).
10922
10923 2005-03-16  Zoltan Varga  <vargaz@freemail.hu>
10924
10925         * tramp-amd64.c (create_specific_trampoline): Revert parts of the 
10926         last change as it seems to cause strange crashes.
10927         
10928 Wed Mar 16 16:24:11 CET 2005 Paolo Molaro <lupus@ximian.com>
10929
10930         * *.c: handle unsafe function pointers where needed.
10931
10932 2005-03-16  Zoltan Varga  <vargaz@freemail.hu>
10933
10934         * mini.c (mono_jit_free_method): Remove the fixme too.
10935
10936 2005-03-15  Miguel de Icaza  <miguel@novell.com>
10937
10938         * mini.c: As discussed, make the code actually free the delegate
10939         thunk now, to enable the debugging of delegate problems, use
10940         MONO_DEBUG=1 when running Mono. 
10941
10942         This takes also care of parts of the leaks as seen by Joe.
10943
10944 2005-03-15  Zoltan Varga  <vargaz@freemail.hu>
10945
10946         * mini-amd64.c (mono_arch_setup_jit_tls_data): Enable 
10947         thread_tls_offset calculation.
10948
10949 2005-03-14  Sebastien Pouliot  <sebastien@ximian.com>
10950
10951         * declsec.c: Reworked linkdemand checks for icall. The previous code
10952         was using the declaration code (untrusted) and didn't work as expected
10953         with the CLR 2.0. We're now more compatible with 2.0 than 1.x for this
10954         specific case.
10955
10956 2005-03-13  Zoltan Varga  <vargaz@freemail.hu>
10957
10958         * iltests.il: Add new localloc test.
10959
10960         * mini-amd64.c: Handle large stack allocations the same way as on
10961         windows if stack overflow handling is working.
10962         
10963         * mini-amd64.c: Allocate the signal stack using mmap.
10964
10965         * mini.c (sigsegv_signal_handler): Fix reading of context.
10966
10967         * mini-exceptions.c: Fix up stack overflow handling.
10968
10969         * mini-amd64.h mini-amd64.c: Fix up stack overflow handling.
10970
10971         * tramp-amd64.c (create_specific_trampoline): Optimize trampoline size.
10972
10973         * exceptions-amd64.c (mono_amd64_exceptions_init): Remove this.
10974
10975         * mini.h mini.c tramp-*.c: Move common trampoline code to mini.c.
10976
10977         * mini-x86.h mini-x86.c mini-amd64.h mini-amd64.c: Get rid of the
10978         tramp_init functions as they are no longer needed.
10979
10980 2005-03-12  Zoltan Varga  <vargaz@freemail.hu>
10981
10982         * tramp-amd64.c (mono_amd64_tramp_init): Fix typo.
10983         
10984         * tramp-amd64.c (mono_amd64_tramp_init): Init AOT trampoline as well.
10985
10986         * mini-amd64.h mini-amd64.c (mono_amd64_exceptions_init): Remove this.
10987         
10988         * mini.c mini-*.h: Remove OUT_OF_LINE_BBLOCK defines since all arches
10989         support that now.
10990
10991         * mini-ops.h: Add OP_LMUL_IMM.
10992
10993         * mini.c jit-icalls.cmini-amd64.h mini-amd64.c cpu-amd64.md: Implement
10994         long mul/div opcodes as intrinsic.
10995
10996         * mini-amd64.c (emit_call): Handle the case when the callee might be
10997         an AOT method.
10998
10999 2005-03-11  Zoltan Varga  <vargaz@freemail.hu>
11000
11001         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Reorder cases to be
11002         extra safe.
11003         
11004         * mini-amd64.c (mono_arch_get_vcall_slot_addr): Fix ordering of cases.
11005
11006         * aot.c (mono_aot_load_method): Get rid of bogus make_writable call.
11007
11008 2005-03-09  Ben Maurer  <bmaurer@ximian.com>
11009
11010         * mini.c (mono_codegen): Don't leak here, to help people running
11011         monogrind.
11012
11013 2005-03-08  Zoltan Varga  <vargaz@freemail.hu>
11014
11015         * mini-amd64.c (mono_arch_output_basic_block): Fix int->float 
11016         conversions in sse2 mode.
11017
11018         * basic-float.cs: Add regression test.
11019         
11020         * mini-amd64.c: Reenable sse2.
11021
11022 2005-03-07  Zoltan Varga  <vargaz@freemail.hu>
11023
11024         * mini-amd64.c: Disable sse2 until some regressions are fixed.
11025
11026 2005-03-07      Joerg Rosenkranz <joergr@voelcker.com>
11027
11028         * driver.c: Copyright text should include 2005.
11029         
11030 2005-03-07  Zoltan Varga  <vargaz@freemail.hu>
11031
11032         * cpu-amd64.md (load_membase): Fix more max lengths.
11033
11034 2005-03-06  Zoltan Varga  <vargaz@freemail.hu>
11035
11036         * cpu-amd64.md (load_membase): Fix max length.
11037
11038         * mini-ops.h: Add OP_F<xx>_MEMBASE opcodes.
11039
11040         * inssel.brg: Add MONO_EMIT_BIALU_MEMBASE macro.
11041
11042         * cpu-amd64.md inssel-amd64.brg mini-amd64.h mini-amd64.brg: Finish SSE2
11043         support and enable it by default. Also add OP_F<xxx>_MEMBASE opcodes.
11044
11045         * basic-float.cs: Add rounding regression test.
11046
11047         * mini-amd64.c (INST_IGNORES_CFLAGS): Add more instructions.
11048
11049 2005-03-04  Neale Ferguson <NealeFerguson@earthlink.net>
11050
11051         * inssel-s390.brg, mini-s390.c: Add support for passing/returning small
11052         structures in registers for pinvoke wrappers.
11053
11054 2005-03-04  Zoltan Varga  <vargaz@freemail.hu>
11055
11056         * mini-exceptions.c (ves_icall_get_trace): Return wrapper info as well.
11057
11058 2005-03-03  Zoltan Varga  <vargaz@freemail.hu>
11059
11060         * mini.h mini.c mini-x86.c: Pass the domain of the native->managed
11061         wrapper to mono_jit_thread_attach.
11062
11063         * mini.c (mini_jit_thread_attach): New jit icall.
11064
11065         * mini-x86.c (mono_arch_emit_prolog): Attach to the VM in 
11066         native->managed wrappers.
11067
11068         * exceptions.cs: Add new regression test.
11069
11070         * mini.c (optimize_branches): Check regions in the cbranch to throw
11071         block case as well. Fixes #73242.
11072
11073 Tue Mar 1 18:35:27 CET 2005 Paolo Molaro <lupus@ximian.com>
11074
11075         * mini.c: thread safety fixes.
11076
11077 2005-02-27  Zoltan Varga  <vargaz@freemail.hu>
11078
11079         * tramp-amd64.c (amd64_magic_trampoline): Disable the method_ptr
11080         patching stuff, since delegates use jump trampolines so there is
11081         no caller.
11082
11083         * tramp-amd64.c (create_trampoline_code): Pass NULL as 'code' in 
11084         jump trampolines.
11085         
11086         * tramp-amd64.c: Fix build.
11087
11088         * mini-x86.c tramp-x86.c: Moved get_vtable_slot_addr into mini-x86.c and rename
11089         it to mono_arch_.... Add get_delegate_method_ptr implementation for x86.
11090
11091         * mini-amd64.h mini.h mini-amd64.c tramp-amd64.c (mono_amd64_get_vcall_slot_addr):
11092         Rename this to mono_arch....
11093         (mono_amd64_get_delegate_method_ptr_addr): Ditto.
11094
11095         * mini-amd64.c (mono_amd64_get_delegate_method_ptr_addr): New helper function.
11096
11097         * mini-amd64.c (emit_call): If both the caller and the callee is
11098         guaranteed to have 32 bit addresses, emit a normal call.
11099
11100         * tramp-amd64.c: Adapt to changes in mini-amd64.c.
11101
11102         * tramp-amd64.c (amd64_magic_trampoline): Remove patching of trampolines. 
11103         * tramp-amd64.c (amd64_magic_trampoline): Add support for patching the
11104         method_ptr inside delegates.
11105
11106 2005-02-26  Zoltan Varga  <vargaz@freemail.hu>
11107
11108         * mini.c (mono_jit_free_method): Free the method info even if the native code is
11109         invalidated. Fixes #73001.
11110
11111         * mini.c: Add a proper icall wrapper for mono_delegate_ctor.
11112
11113         * mini-x86.c: Only use stdcall for pinvokes on windows.
11114
11115 Thu Feb 24 15:22:30 CET 2005 Paolo Molaro <lupus@ximian.com>
11116
11117         * mini.c, mini.h: make mono_lmf_addr a fast-access thread var.
11118         * mini-x86.c: remove unreliable __thread var offset detection,
11119         use the correct accessors and enable by default.
11120
11121 2005-02-23  Zoltan Varga  <vargaz@freemail.hu>
11122
11123         * mini.c (mono_jit_free_method): Fix memory leak.
11124
11125 2005-02-22  Zoltan Varga  <vargaz@freemail.hu>
11126
11127         * mini.c (mono_method_to_ir): Allocate a GOT var for THROW and RETHROW. 
11128
11129 2005-02-21  Zoltan Varga  <vargaz@freemail.hu>
11130
11131         * cpu-amd64.md: Fix lengths of atomic opcodes.
11132
11133 Mon Feb 21 16:52:20 CET 2005 Paolo Molaro <lupus@ximian.com>
11134
11135         * driver.c: try to not imply using ICU is any good.
11136
11137 2005-02-20  Zoltan Varga  <vargaz@freemail.hu>
11138
11139         * mini-amd64.c (mono_arch_get_inst_for_method): Implement more 
11140         functions as inline ops.
11141
11142         * mini-ops.h inssel-amd64.brg cpu-amd64.md mini-amd64.c: Implement
11143         some Interlocked functions as inline ops.
11144
11145         * mini.c (move_basic_block_to_end): Fix bug in last patch.
11146
11147         * mini.h (MonoBasicBlock): Reorganize fields a bit.
11148
11149         * mini-ops.h inssel.brg: Add OP_NOT_REACHED.
11150
11151         * mini.c: Add support for OP_NOT_TAKEN.
11152
11153         * mini-amd64.h mini-amd64.c: Add support for passing/returning small 
11154         structures in registers for pinvoke wrappers.
11155
11156         * mini-amd64.c: Fix warnings.
11157
11158 2005-02-19  Zoltan Varga  <vargaz@freemail.hu>
11159
11160         * mini.h (MonoCompile): Add 'ret_var_is_local' field.
11161
11162         * mini.h mini.c (mono_arch_create_vars): Add new arch specific hook.
11163
11164         * mini.c (NEW_RETLOADA): If the ret variable is a local, use its 
11165         address instead of loading the address from it.
11166
11167         * mini-x86.c: Add support for returning small structs in registers
11168         on Win32. Fixes part of #70864.
11169         
11170 2005-02-18  Zoltan Varga  <vargaz@freemail.hu>
11171
11172         * trace.c (get_token): Improve error checking.
11173
11174 2005-02-17  Zoltan Varga  <vargaz@freemail.hu>
11175
11176         * jit-icalls.c (mono_ldvirtfn): Explicitly check for a NULL obj here.
11177
11178 2005-02-17  Sebastien Pouliot  <sebastien@ximian.com> 
11179  
11180         * mini.h: Moved MONO_EXCEPTION_* enum to metadata/class-internals.h so
11181         it can be reused for MonoClass.
11182         * mini.c: Renamed MONO_EXCEPTION_SECURITY to MONO_EXCEPTION_SECURITY
11183         _LINKDEMAND.
11184
11185 2005-02-15  Sebastien Pouliot  <sebastien@ximian.com>
11186
11187         * mini.c: Fixed 2 cases where I sent a MonoMethod to managed code 
11188         instead of a MonoReflectionMethod. The method information wasn't used
11189         when displaying SecurityException details (but will be now).
11190
11191 2005-02-15  Atsushi Enomoto  <atsushi@ximian.com>
11192
11193         * Makefile.am : windows build fix.
11194
11195 2005-02-14  Zoltan Varga  <vargaz@freemail.hu>
11196
11197         * iltests.il: Add new regression test.
11198
11199         * mini.c (mono_method_to_ir): Allocate a GOT var in CEE_NEWOBJ. Fixes
11200         #72522.
11201
11202 2004-02-13  Sebastien Pouliot  <sebastien@ximian.com> 
11203  
11204         * mini.c: Moved linkdemand check into helper function check_linkdemand
11205         to allow reuse for all intructions (CALL, CALLVIRT, NEWOBJ, JMP, 
11206         LDFTN, LDVIRTFTN).
11207
11208 2004-02-13  Sebastien Pouliot  <sebastien@ximian.com>
11209
11210         * declsec.c: Added statistics counter for different kinds of 
11211         LinkDemands.
11212         * mini.h: Added CAS statistic counters to MonoJitStats. Removed unused
11213         (and commented) declaration.
11214         * mini.c: Added statistics counter for security Demand code 
11215         generation. Added display of security statistics.
11216
11217 2005-02-13  Zoltan Varga  <vargaz@freemail.hu>
11218
11219         * declsec.c (mono_declsec_linkdemand_aptc): Applied patch from Robert Jordan (robertj@gmx.net).
11220         Fix compilation errors under gcc-2.95.
11221
11222 2005-02-12  Ben Maurer  <bmaurer@ximian.com>
11223
11224         * mini.c, driver.c: Use the new jit trampoline hashtable
11225
11226 Fri Feb 11 18:47:11 CET 2005 Paolo Molaro <lupus@ximian.com>
11227
11228         * mini.c, jit-icalls.c: use the managed implementation of memcpy, too.
11229
11230 2005-02-11  Martin Baulig  <martin@ximian.com>
11231
11232         * debug-mini.c (mono_debug_close_method): Free the line number array.
11233
11234 2005-02-10  Zoltan Varga  <vargaz@freemail.hu>
11235
11236         * aot.c: Break up large methods into smaller ones. Share GOT slots for
11237         icalls.
11238
11239         * mini.h: Bump AOT file format version. 
11240
11241 2005-02-10  Sebastien Pouliot  <sebastien@ximian.com>
11242
11243         * declsec.c: Added LinkDemand support and it's special cases for ECMA,
11244         APTC and P/Invoke.
11245         * declsec.h: Added macros to get/set lazyly initialized security 
11246         informations about assemblies. Added new enum for different type of
11247         possible LinkDemand violation. Added function to check LinkDemands.
11248         * mini.h: Added a field to MonoCompile to hold any security violation
11249         detected when JITting a method (so it can be thrown later).
11250         * mini.c: Added LinkDemand checks in mono_method_to_ir for CEE_CALL 
11251         and CEE_CALLVIRT. Added code to throw exception at the end of
11252         mini_method_compile (note: the exception is unhandled right now).
11253
11254 Thu Feb 10 15:49:44 CET 2005 Paolo Molaro <lupus@ximian.com>
11255
11256         * mini.c, jit-icalls.c: use the managed implementation of
11257         memset for initobj and memset, to avoid managed <-> unmanaged
11258         transitions.
11259
11260 2005-02-10  Zoltan Varga  <vargaz@freemail.hu>
11261
11262         * inssel.brg (mini_emit_virtual_call): Disable the virtual->nonvirtual
11263         optimization if it would need a GOT var.
11264
11265         * basic.cs: Add tests for constant propagation and switch statements.
11266
11267         * ssa.c: Fix out-of-range constant propagation and switch statements.
11268
11269 2005-02-09    <vargaz@freemail.hu>
11270
11271         * inssel-x86.brg (reg): Align the allocation size in the localloc(imm) case too.
11272
11273 2005-02-08  Zoltan Varga  <vargaz@freemail.hu>
11274
11275         * cpu-amd64.md (load_membase): Fix max length of load_membase.
11276
11277 Tue Feb 8 18:21:11 CET 2005 Paolo Molaro <lupus@ximian.com>
11278
11279         * mini.c: update to new signature of mono_class_get_allocation_ftn().
11280
11281 2005-02-06  Neale Ferguson <NealeFerguson@earthlink.net>
11282
11283         * cpu-s390.md,  mini-s390.c: Correct bug with register usage on certain 
11284         arithmetic operations.
11285
11286 Sun Feb 6 07:10:12 EST 2005 Paolo Molaro <lupus@ximian.com>
11287
11288         * mini-ppc.c: add a workaround for broken user code that
11289         DllImports vararg functions with non-vararg signatures.
11290
11291 2005-02-05  Zoltan Varga  <vargaz@freemail.hu>
11292
11293         * mini.c (mono_jit_compile_method_inner): Add detection and a 
11294         meaningfull error message for assemblies written in Managed C++.
11295
11296         * tramp-amd64.c mini-amd64.h: Add support for 
11297         create_trampoline_from_token ().
11298
11299         * aot.c mini-x86.c abcremoval.c: Applied patch from
11300         Robert Jordan (robertj@gmx.net). Fix compilation errors under gcc-2.95.
11301
11302 2005-02-04  Zoltan Varga  <vargaz@freemail.hu>
11303
11304         * mini.h mini.c mini-x86.h tramp-x86.c: Add a new kind of trampoline 
11305         which takes a MonoImage/token as parameter instead of a MonoMethod.
11306
11307         * aot.c: Use the new trampoline for initializing vtables.
11308
11309         * aot.c: Add support for ldfld/stfld_remote wrappers.
11310
11311         * mini-ops.h cpu-pentium.md inssel-x86.brg mini-x86.c: Add optimized
11312         rules for compare <MEM>, IMM.
11313
11314         * mini.h (MONO_AOT_FILE_VERSION): Bump it.
11315
11316         * aot.c: Handle inherited finalizers correctly.
11317
11318 2005-02-03  Zoltan Varga  <vargaz@freemail.hu>
11319
11320         * inssel.brg (stmt): Add a missing _setup_... ().
11321
11322         * aot.c: Save some parts of the class state to the AOT file and use it
11323         to recompute that state when a class is initialized.
11324
11325         * mini.c: Install AOT hooks into the runtime.
11326
11327         * mini.h: Bump AOT file format version.
11328         
11329         * mini.c (mono_method_to_ir): Initialize pointer type locals correctly.
11330         Fixes #72148.
11331
11332         * iltests.il: Add new test.
11333
11334 Wed Feb 2 16:53:59 CET 2005 Paolo Molaro <lupus@ximian.com>
11335
11336         * mini.c: fix typo.
11337
11338 Wed Feb 2 16:37:13 CET 2005 Paolo Molaro <lupus@ximian.com>
11339
11340         * mini.c: setup the statistical profiler in the thread attach
11341         callback to cope with the new single thread code.
11342
11343 Wed Feb 2 15:43:58 CET 2005 Paolo Molaro <lupus@ximian.com>
11344
11345         * mini-ppc.c: ensure we have enough room for the profiler
11346         calls (fixed bug#72084).
11347
11348 2005-02-02  Zoltan Varga  <vargaz@freemail.hu>
11349
11350         * aot.c: Get rid of the MonoAotMethod structure and the hashtable holding 
11351         it.
11352
11353 2005-2-1  Massimiliano Mantione  <massi@ximian.com>
11354
11355         * driver.c: Re-enabled SSAPRE (two commits, I was just dumb).
11356
11357 2005-2-1  Massimiliano Mantione  <massi@ximian.com>
11358
11359         * ssapre.c: Fixed an issue with down safety (this allows IronPython
11360         to succesfully execute parrotbench).
11361         * ssapre.h: Likewise.
11362
11363 2005-2-1  Massimiliano Mantione  <massi@ximian.com>
11364
11365         * ssa.c: In mono_ssa_rename_vars, forced the creation of a new SSA
11366         variable for stores to method arguments (fixes a SSAPRE issue).
11367
11368 Tue Feb 1 15:52:26 CET 2005 Paolo Molaro <lupus@ximian.com>
11369
11370         * mini.c: handle value types in dup, fixes gen-112.cs.
11371
11372 Tue Feb 1 11:45:19 CET 2005 Paolo Molaro <lupus@ximian.com>
11373
11374         * mini-ppc.c, cpu-g4.md, tramp-ppc.c: use a slower code
11375         sequence for calls in dynamic methods to avoid thunks.
11376
11377 Tue Feb 1 11:44:01 CET 2005 Paolo Molaro <lupus@ximian.com>
11378
11379         * mini.c: correctly remove dynamic methods from the hashtable.
11380
11381 2005-1-20  Massimiliano Mantione  <massi@ximian.com>
11382
11383         * driver.c: Disabled SSAPRE until fix the bug that appears
11384         in IronPython's parrotbench.
11385
11386 2005-01-31  Zoltan Varga  <vargaz@freemail.hu>
11387
11388         * aot.c (mono_compile_assembly): Get rid of Skip (other) messages.
11389
11390         * mini.c (mono_method_to_ir): Revert the previous change.
11391         
11392         * mini.c (mono_method_to_ir): Do not inline ldfld and stfld wrappers
11393         when AOT compiling.
11394
11395         * tramp-x86.c (x86_magic_trampoline): Avoid calls to 
11396         mono_jit_info_table_find () etc. when running under valgrind.
11397
11398         * inssel.brg: Fix warnings.
11399
11400         * mini-exceptions.c: Fix warnings.
11401
11402 2005-01-31  Martin Baulig  <martin@ximian.com>
11403
11404         * driver.c (compile_all_methods_thread_main): Don't try to compile
11405         generic methods or anything which has type parameters.
11406
11407 2005-01-30  Zoltan Varga  <vargaz@freemail.hu>
11408
11409         * aot.c: Avoid costly calls to mono_method_full_name in tracing code and fix memory leaks.
11410
11411         * TestDriver.cs: Add --verbose flags.
11412
11413         * graph.c ssa.c: Fix 64 bit warnings.
11414         
11415         * abcremoval.h ssapre.h abcremoval.c ssapre.c mini.c tramp-amd64.c 
11416         trace.c mini-exceptions.c linear-scan.c inssel-amd64.brg inssel.brg:
11417         Fix 64 bit warnings.
11418
11419         * mini-amd64.c (mono_arch_output_basic_block): Fix uninitialized
11420         variable not spotted by gcc.
11421         
11422         * mini-amd64.c inssel-amd64.brg: Applied patch from  
11423         Willibald Krenn <Willibald.Krenn@gmx.at>. Clean up usage of 
11424         X86_COMPARE_MEMBASE opcodes.
11425
11426         * exceptions-amd64.c (mono_arch_find_jit_info): Fix AMD64 build.
11427
11428 2005-01-29  Ben Maurer  <bmaurer@ximian.com>
11429
11430         * *: MonoMethod->signature might be NULL now. You *MUST* use
11431         mono_method_signature.
11432
11433 2005-01-28  Zoltan Varga  <vargaz@freemail.hu>
11434
11435         * driver.c (compile_all_methods_thread_main): Compile the methods
11436         without invoking cctors.
11437
11438 Fri Jan 28 18:28:26 CET 2005 Paolo Molaro <lupus@ximian.com>
11439
11440         * mini.c: remove ben's "optimizations" to dup+stloc (bug #71905).
11441         * basic-calls.cs: test for the above.
11442
11443 2005-01-28  Zoltan Varga  <vargaz@freemail.hu>
11444
11445         * mini.c mini-exceptions.c aot.c exceptions-*.c: Update after 
11446         MonoJitInfo changes.
11447
11448 2005-01-27  Zoltan Varga  <vargaz@freemail.hu>
11449
11450         * mini-exceptions.c (mono_handle_exception): Compute the stack trace
11451         eagerly if it contains dynamic methods.
11452         
11453         * mini-exceptions.c (ves_icall_System_Exception_get_trace): New icall.
11454
11455         * mini-exceptions.c (mono_handle_exception): Avoid computing the stack
11456         trace, it is now computed by an icall from trace_ips.
11457         
11458         * mini-exceptions.c: Fix a warning.
11459
11460 Thu Jan 27 13:38:34 CET 2005 Paolo Molaro <lupus@ximian.com>
11461
11462         * mini-exceptions.c: don't bother getting stack trace info if
11463         it's not going to be used.
11464
11465 2005-01-27  Raja R Harinath  <rharinath@novell.com>
11466
11467         * Makefile.am (common_sources): Add ssapre-cee-ops.h and
11468         ssapre-mini-ops.h.
11469
11470 2005-01-26  Zoltan Varga  <vargaz@freemail.hu>
11471
11472         * mini.c (remove_block_if_useless): Only print debug stuff with -v -v.
11473
11474         * aot.c: Avoid calling mono_method_get_header () if not needed.
11475
11476         * mini.h: Bump AOT file format version.
11477         
11478         * mini.c (mono_emit_native_call): Allocate a GOT var here.
11479
11480         * mini.c (mono_print_tree): Print more info for calls.
11481
11482 2005-01-26  Sebastien Pouliot  <sebastien@ximian.com>
11483
11484         * declsec.h: Remove warning by adding missing include for marshal.h
11485
11486 2005-01-26  Martin Baulig  <martin@ximian.com>
11487
11488         * mini.c (mono_method_to_ir): In CEE_UNBOX_ANY, don't increase
11489         `ip' twice.
11490
11491 2005-01-25  Zoltan Varga  <vargaz@freemail.hu>
11492
11493         * mini-amd64.c (mono_arch_call_opcode): Add missing MONO_SSA_LOAD/STORE
11494         flags.
11495
11496         * ssa.c (mono_ssa_compute): Fix crashes when using AOT.
11497
11498         * aot.c (mono_compile_assembly): Fix a warning.
11499
11500 2005-01-25  Sebastien Pouliot  <sebastien@ximian.com>
11501
11502         * declsec.c: Look for security attributes on the original MonoMethod 
11503         (and not the wrapped one). This fix permissions on icalls.
11504
11505 2005-01-23  Zoltan Varga  <vargaz@freemail.hu>
11506
11507         * mini-amd64.c (mono_arch_allocate_vars): Use mono_allocate_stack_slots ().
11508
11509         * mini.c (mono_allocate_stack_slots): Add a fixme.
11510
11511         * mini-x86.c (mono_arch_allocate_vars): Use mono_allocate_stack_slots ().
11512
11513 Sun Jan 23 16:16:48 CET 2005 Paolo Molaro <lupus@ximian.com>
11514
11515         * inssel.brg: optimize casts of sealed types (more
11516         optimizations waiting for fixes in remoting).
11517
11518 2005-01-23  Zoltan Varga  <vargaz@freemail.hu>
11519
11520         * inssel.brg (stmt): Add another dummy rule.
11521
11522         * driver.c: Fix warnings.
11523
11524         * driver.c (mono_main): If running under valgrind, instruct glib to use
11525         the system allocation functions so valgrind can track the memory
11526         allocated by the g_... functions.
11527
11528         * inssel.brg (stmt): Add DUMMY rule for OP_DUMMY_STORE.
11529
11530         * mini-ops.h: Add OP_DUMMY_STORE opcode.
11531
11532         * mini.h (MONO_BBLOCK_IS_IN_REGION): New helper macro.
11533
11534         * liveness.c: Handle OP_DUMMY_STORE. Enable register allocation for
11535         variables in try regions.
11536
11537         * mini.c (mini_method_compile): Don't disable optimizations on large
11538         methods when AOT compiling.
11539
11540         * mini.c (mono_allocate_stack_slots): New arch independent method to 
11541         allocate stack slots. Not yet used.
11542
11543 2005-01-22  Ben Maurer  <bmaurer@ximian.com>
11544
11545         * debug-mini.c (mono_debug_close_method): Plug some leaks.
11546
11547 Sat Jan 22 13:41:51 EST 2005 Paolo Molaro <lupus@ximian.com>
11548
11549         * mini-ppc.c: make the branch info relative as the code
11550         buffer can be reallocated.
11551
11552 2005-01-22  Sebastien Pouliot  <sebastien@ximian.com>
11553
11554         * aot.c: Allow decoding of the new  MONO_PATCH_INFO_DECLSEC.
11555         * driver.c: Removed the AOT/security restriction. Now initialize the
11556         security manager (in metadata) if --security is used.
11557         * mini.c|h: Add the MONO_PATCH_INFO_DECLSEC code to use the index,
11558         rather than the pointer to declarative security, when AOT is used.
11559
11560 Sat Jan 22 09:35:19 EST 2005 Paolo Molaro <lupus@ximian.com>
11561
11562         * mini.h, mini-ppc.h, mini-ppc.c: updated to use out of line
11563         basic blocks, reduced intrinsic exception throwing code size.
11564
11565 2005-01-22  Miguel de Icaza  <miguel@ximian.com>
11566
11567         * driver.c (mini_usage): Reorder the usage screen.
11568
11569 2005-01-21  Zoltan Varga  <vargaz@freemail.hu>
11570
11571         * mini.c (mono_resolve_patch_target): Fix warning.
11572
11573 2005-01-20  Zoltan Varga  <vargaz@freemail.hu>
11574
11575         * mini-x86.c (mono_arch_local_regalloc): Fix bug introduced by
11576         previous patch.
11577
11578         * mini-amd64.c (mono_arch_local_regalloc): Ditto.       
11579
11580         * mini-amd64.c (mono_arch_local_regalloc): Revert last patch as it
11581         breaks the amd64 build.
11582
11583         * mini-x86.c (mono_arch_local_regalloc): Fix bug in div/rem 
11584         register allocation. Fixes #71454.
11585
11586         * mini-amd64.c (mono_arch_local_regalloc): Ditto.       
11587
11588         * arrays.cs: Add new regression test.   
11589
11590 2005-1-20  Massimiliano Mantione  <massi@ximian.com>
11591
11592         * ssapre.c: Turned usage of snprintf to GString.
11593         * ssapre.h: disabled MONO_APPLY_SSAPRE_TO_SINGLE_METHOD
11594         (I left it on by mistake in my previous commit).
11595
11596 Thu Jan 20 12:00:45 CET 2005 Paolo Molaro <lupus@ximian.com>
11597
11598         * mini.c, cfold.c, basic-calls.cs: preserve side effects
11599         on cond branch optimization (fixes bug# 71515).
11600
11601 2005-1-20  Massimiliano Mantione  <massi@ximian.com>
11602
11603         * abcremoval.c: Fixed bug 71062.
11604         * abcremoval.h: Likewise.
11605
11606 2005-1-20  Massimiliano Mantione  <massi@ximian.com>
11607
11608         * mini.c: Added a new functionality to optimize_branches, the removal
11609         of useless basic blocks, and fixed some problem in the removal of
11610         critical edges; some utility functions added for both purposes.
11611         * ssapre.c: Added complex expression support, and fixed bug 70637.
11612         * ssapre.h: Likewise.
11613         * ssapre-cee-ops.h: Added file with list of "CEE_*" opcodes
11614         enabled in SSAPRE.
11615         * ssapre-mini-ops.h: Likewise, but for "OP_*" opcodes.
11616         * driver.c: Re-enabled SSAPRE.
11617
11618 2005-01-19  Martin Baulig  <martin@ximian.com>
11619
11620         * mini.c (mono_method_to_ir): Call mono_get_inflated_method() on
11621         the result of mono_get_method_constrained().
11622
11623 2005-01-18  Neale Ferguson <NealeFerguson@earthlink.net>
11624
11625         * exceptions-s390.c tramp-s390.c: Allocate code using the global code
11626         manager.
11627
11628 2005-01-18  Geoff Norton  <gnorton@customerdna.com>
11629
11630         * jit-icalls.c (mono_llmult_ovf): Fix other overflow conditions to
11631         be detected.  Fixes #59296.
11632
11633 2005-01-18  Zoltan Varga  <vargaz@freemail.hu>
11634
11635         * mini-amd64.c (mono_arch_output_basic_block): Remove some assertions
11636         which can happen. Fixes #71361.
11637
11638 2005-01-18  Zoltan Varga  <vargaz@freemail.hu>
11639
11640         * exceptions-sparc.c tramp-sparc.c: Allocate code using the global code
11641         manager.
11642
11643 2005-01-17  Zoltan Varga  <vargaz@freemail.hu>
11644
11645         * mini.c (mono_create_jump_trampoline): Revert last change as it causes
11646         appdomain-unload.exe to fail.
11647         
11648         * mini.c: Fix some memory leaks.
11649
11650 Mon Jan 17 16:16:23 CET 2005 Paolo Molaro <lupus@ximian.com>
11651
11652         * inssel.brg: handle the new size of rank, idepth, max_interface_id.
11653         Fixed bug and sped up some codepaths.
11654
11655 2005-01-17  Zoltan Varga  <vargaz@freemail.hu>
11656
11657         * mini.c: Fix some memory leaks.
11658
11659         * exceptions.cs basic-long.cs: Add test for checked ulong->int 
11660         conversion.
11661
11662         * inssel-long.brg: Implement long_conv_to_ovf_i4_un. Fixes #71319.
11663
11664         * inssel-long.brg: Fix conv.ovf.i8 when run on an int32. Fixes
11665         #71320.
11666
11667         * iltests.il: Add regression test for #71320.
11668
11669 2005-01-16  Zoltan Varga  <vargaz@freemail.hu>
11670
11671         * mini.c (mono_codegen): Fix installation of profiler hooks.
11672
11673         * mini-sparc.c mini-amd64.c: Don't allocate stack space for dead vars.
11674
11675 Sun Jan 16 12:19:35 CET 2005 Paolo Molaro <lupus@ximian.com>
11676
11677         * mini.h, mini.c, cfold.c: optimize access to enum
11678         readonly fields, too. Eval conditional branches if possible
11679         to perform unreachable code removal in more cases.
11680
11681 2005-01-15  Zoltan Varga  <vargaz@freemail.hu>
11682
11683         * tramp-amd64.c exceptions-amd64.c: Use the new global code manager.
11684
11685         * mini.c (mono_global_codeman_reserve): New function to allocate code memory from a global
11686         code manager.
11687
11688         * tramp-x86.c mini-x86.c exceptions-x86.c: Allocate all code memory so mono works with
11689         WinXP DEP. Fixes #71244.
11690
11691 2005-01-14  Zoltan Varga  <vargaz@freemail.hu>
11692
11693         * inssel.brg: Allways convert CEE_CONV_OVF_I4 to a move on 64 bit platforms. Fixes #71236.
11694
11695 2005-01-13  Zoltan Varga  <vargaz@freemail.hu>
11696
11697         * mini-x86.c (mono_arch_output_basic_block): Fix OP_ATOMIC_ADD_NEW_I4.
11698
11699 2005-01-11  Zoltan Varga  <vargaz@freemail.hu>
11700
11701         * mini-exceptions.c exceptions-ppc.c aot.c: Cope with MonoJitInfo 
11702         changes.
11703
11704         * mini.h: Bump AOT version.
11705
11706         * mini.h (MonoCompile): Change exvar to a hash table.
11707
11708         * mini.c: Allocate a separate exvar for each handler block.
11709
11710         * mini.c: Get rid of the computation of filter_lengths, its not needed.
11711
11712         * mini.c inssel.brg: Change OP_THROW_OR_NULL to compare the current
11713         ex var with the pending exception and only throw if the two are equal.
11714         Fixes #68552.
11715         
11716         * exceptions.cs: Add tests for rethrow and nested catch clauses.
11717
11718         * mini-x86.c: Fix warnings.
11719
11720         * Makefile.am (common_sources): Move mini-exceptions.c here as it is
11721         used by all the ports now.
11722
11723         * aot.c: Add write-symbols and save-temps options.
11724
11725 2005-01-10  Zoltan Varga  <vargaz@freemail.hu>
11726
11727         * mini-x86.c: Add support for returning structs in registers from pinvoke functions on WIN32.
11728
11729 Mon Jan 10 16:11:16 EST 2005 Neale Ferguson <nealeferguson@earthlink.net>
11730
11731         * mini-ops.h, inssel-s390.brg, cpu-s390.md: Support OP_ATOMIC__xxx 
11732         operations.
11733
11734         * tramp-s390.c: Check vtable slot belongs to the domain.
11735
11736         * mini-exceptions.c, exceptions-s390.c: Standardize exception handling
11737         as per other platforms.
11738
11739         * mini-s390.c, mini-s390.h: Enable out-of-line bblock support.
11740
11741 Mon Jan 10 18:53:05 CET 2005 Paolo Molaro <lupus@ximian.com>
11742
11743         * driver.c: we don't run the Main() code in a subthread anymore.
11744
11745 Mon Jan 10 17:54:16 CET 2005 Paolo Molaro <lupus@ximian.com>
11746
11747         * mini.c: added experimental rtc support in the statistical
11748         profiler: if the user has the permission, more accurate statistics
11749         are gathered. Run with: MONO_RTC=4096 mono --profiler=default:stat ....
11750         The MONO_RTC value must be restricted to what the linux rtc allows:
11751         power of two from 64 to 8192 Hz.
11752
11753 2005-01-10  Zoltan Varga  <vargaz@freemail.hu>
11754
11755         * mini-x86.c (mono_arch_emit_exceptions): Fix #71121.
11756
11757 Mon Jan 10 05:20:49 EST 2005 Paolo Molaro <lupus@ximian.com>
11758
11759         * mini-ppc.c: better icache flush for smp.
11760
11761 2005-01-09  Zoltan Varga  <vargaz@freemail.hu>
11762
11763         * mini-amd64.c (emit_move_return_value): Fix memory leak.
11764
11765         * mini-x86.c (get_call_info): Add the get_call_info () code from the
11766         amd64 port, not yet used.
11767
11768 2005-01-07  Zoltan Varga  <vargaz@freemail.hu>
11769
11770         * mini.c (mono_method_to_ir): Disable inlining of ldfld wrappers with
11771         a struct type.
11772
11773 2005-01-07  Sebastien Pouliot  <sebastien@ximian.com>
11774
11775         * driver.c: Added --security option to activate the security manager.
11776         Right now this will allow code generation for declarative demands and
11777         is disabled when AOT is specified.
11778         * mini.c: Add code generation for declarative security demands.
11779         * mini.h: Add mono_use_security_manager as an extern gboolean.
11780
11781 2005-01-07  Zoltan Varga  <vargaz@freemail.hu>
11782
11783         * aot.c (mono_compile_assembly): Speed up compilation a bit by
11784         emitting more dense assembly code.
11785
11786         * mini-sparc.c mini-sparc.h exceptions-sparc.c: Enable optimized corlib
11787         exception throwing stuff.
11788
11789 2005-01-06  Zoltan Varga  <vargaz@freemail.hu>
11790
11791         * mini-sparc.c (mono_arch_emit_exceptions): Fix typo in previous patch. Remove
11792         dead code.
11793
11794         * mini-amd64.c (mono_arch_emit_exceptions): Remove duplicate epilog stuff
11795         left in by mistake.
11796
11797         * driver.c (EXCLUDED_FROM_ALL): Disable SSAPRE until bug #70637 is 
11798         fixed.
11799
11800         * mini-sparc.h mini-sparc.c: Enable out-of-line bblock support.
11801
11802         * tramp-*.c: Only patch vtable slots if the object is in the current
11803         domain. Fixes appdomain-unload.exe.
11804
11805         * mini-amd64.c mini-amd64.h: Enable out-of-line bblock support.
11806         
11807         * mini-amd64.c (mono_arch_local_regalloc): Port regalloc fix from
11808         x86 branch.
11809
11810 2005-01-05  Zoltan Varga  <vargaz@freemail.hu>
11811
11812         * mini.c (reverse_branch_op): New helper function.
11813
11814         * mini.c (optimize_branches): Run the new optimization only on 
11815         platforms which support it. Also reverse all kinds of branches.
11816
11817         * mini.h (MonoBasicBlock): Add 'out_of_line' field.
11818
11819         * mini.c (mono_method_to_ir): Set 'out_of_line' for bblocks which have
11820         a throw statement.
11821
11822         * mini.c (optimize_branches): Reverse not-equals branches if the false
11823         bblock is a throw. This happens a lot of time with argument checking in
11824         corlib.
11825
11826         * mini.c (mono_codegen): Add support for placing basic blocks after
11827         the function epilogue.
11828
11829         * mini-x86.c mini-x86.h: Add support for placing basic blocks after the
11830         function epilogue.
11831         
11832 2005-01-05  Miguel de Icaza  <miguel@ximian.com>
11833
11834         * mini.c (setup_stat_profiler): Only set this up if the platform
11835         supports ITIMER_PROF.
11836
11837 2005-01-05  Zoltan Varga  <vargaz@freemail.hu>
11838
11839         * mini-x86.c (mono_arch_local_regalloc): Fix a bug introduced by the
11840         previous patch.
11841
11842         * inssel.brg: Fix a warning.
11843
11844 Wed Jan 5 16:40:18 CET 2005 Paolo Molaro <lupus@ximian.com>
11845
11846         * mini.c: added support for statistical profiler 
11847         (run with: --profile=default:stat).
11848
11849 2005-01-04  Zoltan Varga  <vargaz@freemail.hu>
11850
11851         * mini-x86.h (MONO_ARCH_ENABLE_EMIT_STATE_OPT): Enable this on x86.
11852
11853         * mini-x86.c cpu-pentium.md: More fixes for usage of global registers.
11854
11855         * mini-amd64.c (mono_arch_local_regalloc): Port some regalloc fixes 
11856         related to global registers from the amd64 port.
11857
11858 2005-01-03  Zoltan Varga  <vargaz@freemail.hu>
11859
11860         * mini.c (mono_method_to_ir): Handle MONO_CLASSCONST.
11861
11862         * mini-amd64.c (mono_arch_local_regalloc): Fix some regalloc problems
11863         with global registers.
11864         (mono_arch_output_basic_block): Fix SWITCH in the AOT case.
11865
11866         * aot.c (emit_method_code): Fix the 'method emitted as' messages.
11867
11868 2004-12-31  Zoltan Varga  <vargaz@freemail.hu>
11869
11870         * debug-mini.c (encode_value): Fix off-by-one.
11871
11872         * aot.c (encode_value): Likewise.
11873
11874         * mini.c (mono_method_to_ir): Disable AOT for methods containing LDPTR.
11875
11876 2004-12-30  Zoltan Varga  <vargaz@freemail.hu>
11877
11878         * mini.c linear-scan.c: Add a workaround for the mcs crash when using 
11879         AOT.
11880
11881         * aot.c (mono_aot_load_method): Free up patch info if no longer needed.
11882         
11883         * aot.c (emit_method_info): Increase size of temp buffer.
11884
11885         * mini-x86.c cpu-pentium.md mini.c: Load fp constants differently in 
11886         the AOT case.
11887
11888 2004-12-28  Zoltan Varga  <vargaz@freemail.hu>
11889
11890         * aot.c (emit_method_info): Fix build.
11891         
11892         * aot.c: Further rework of the AOT file format to reduce the size of
11893         the method info data.
11894
11895         * mini.h: Bump AOT file format version.
11896
11897 2004-12-27  Martin Baulig  <martin@ximian.com>
11898
11899         * mini.c (mini_get_method): New static method; call
11900         mono_get_method_full() and mono_get_inflated_method().
11901         (mono_method_to_ir): Use mini_get_method() instead of
11902         mono_get_method_full(). 
11903
11904 2004-12-26  Patrik Torstensson  <patrik.torstensson@gmail.com>
11905
11906         * mini-x86.c (atomic ops): fixed bug interlocked bug #70784. 
11907
11908 2004-12-25  Zoltan Varga  <vargaz@freemail.hu>
11909
11910         * inssel.brg (ldind_to_load_membase): Handle CEE_LDIND_I8.
11911
11912         * inssel-amd64.brg: Add some optimization rules.
11913
11914 2004-12-24  Ben Maurer  <bmaurer@ximian.com>
11915
11916         * aot.c: Remove the use of MonoGHashTable and other GC stuff. The
11917         standard not GC'd stuff is fine.
11918
11919 2004-12-24  Zoltan Varga  <vargaz@freemail.hu>
11920
11921         * aot.c: Rework the AOT file format to get rid of most of the global
11922         symbols. This reduces the size of the mscorlib.dll.so by 1MB.
11923
11924         * mini.h: Bump AOT file format version.
11925         
11926 2004-12-23  Zoltan Varga  <vargaz@freemail.hu>
11927
11928         * mini.h: Bump AOT file format version.
11929
11930         * aot.c (mono_aot_is_got_entry): New function to determine if an 
11931         address is inside a GOT.
11932
11933         * aot.c mini-x86.c tramp-x86.c: Make all patches use the GOT.
11934
11935         * cpu-pentium.md: Increase the maximum size of some instructions which
11936         might involve a got access.
11937         
11938         * mini.c (get_method_from_ip): Another debug helper function.
11939
11940         * mini.c: Call mono_get_got_var () in a couple places. Handle the case
11941         when got var accesses are created during the decompose phase.
11942
11943         * mini-sparc.c: Change mono_compile_aot to cfg->compile_aot.
11944
11945         * mini.h mini.c mini-x86.c aot.c mini-sparc.c: Add a 'compile_corlib'
11946         argument mini_compile_method and to MonoCompile, and use this to
11947         determine whenever a given method is compiled for AOT. This allows the
11948         other methods compiled during AOT compilation to be free of AOT stuff,
11949         so the backends does not need to add special support for them by
11950         creating a fake GOT etc.
11951
11952         * mini-x86.c (mono_arch_patch_code): Remove fake got stuff as it is no
11953         longer needed.
11954
11955 2004-12-21  Ben Maurer  <bmaurer@ximian.com>
11956
11957         * mini.c (mono_method_to_ir): It turns out that some of the
11958         x-appdomain wrappers are lax with types, so just ignore this for
11959         all wrappers.
11960
11961         * inssel.brg (OP_CHECK_ARRAY_TYPE): Optimize this by only looking
11962         at the vtable->klass. If it is non-shared code we can just use the
11963         vtable.
11964
11965 Tue Dec 21 17:43:06 CET 2004 Paolo Molaro <lupus@ximian.com>
11966
11967         * mini-ppc.c: access MonoDomain from tls, too.
11968
11969 2004-12-21  Sebastien Pouliot  <sebastien@ximian.com>
11970
11971         * declsec.c: Removed unused variable (and related warning ;-)
11972
11973 2004-12-21  Ben Maurer  <bmaurer@ximian.com>
11974
11975         * iltests.il: New test for LDELEMA on an array of ref types.
11976
11977         * mini.c (CEE_LDELEMA): We need to emit OP_CHECK_ARRAY_TYPE for
11978         all ldelema's on reftypes.
11979         (check_call_signature): Remove the OP_CHECK_ARRAY_TYPE from here,
11980         it was the wrong place to put it.
11981
11982         * mini-x86.c (mono_arch_output_basic_block): Just use ecx as the
11983         register to pop to make this cleaner, at the request of Paolo.
11984
11985 2004-12-20  Ben Maurer  <bmaurer@ximian.com>
11986
11987         * mini-ops.h (OP_GETHASHCODE): New op.
11988
11989         * inssel.brg (OP_GETHASHCODE): Emit code for the new opcode
11990
11991         * mini.c (mini_get_inst_for_method): Create the intrinsic hash
11992         operation.
11993
11994         For a microbenchmark, this reduces the cost of Hashtable.get_Item
11995         by 25%.
11996         
11997         * mini-x86.c (mono_arch_output_basic_block): Rather than
11998
11999         add ebp, 4
12000
12001         Emit
12002
12003         pop edx
12004
12005         The first is 3 bytes while the second is 1. This saves 36 kb on
12006         mscorlib, quite a big saving. When bootstraping mcs, I was able to
12007         see a small boost because of icache locality.
12008
12009         * cfold.c (FOLD_BINOPCOMM): Kill add foo, 0
12010
12011 Mon Dec 20 12:19:40 EST 2004 Paolo Molaro <lupus@ximian.com>
12012
12013         * Makefile.am, mini-ppc.h, mini-exceptions.c, exceptions-ppc.c:
12014         started code sharing with the generic code.
12015
12016 Mon Dec 20 11:08:06 EST 2004 Paolo Molaro <lupus@ximian.com>
12017
12018         * mini-ppc.c, cpu-g4.md: added code for direct access to
12019         tls data slots.
12020
12021 Mon Dec 20 10:58:28 EST 2004 Paolo Molaro <lupus@ximian.com>
12022
12023         * mini-ops.h, inssel-x86.brg, cpu-amd64.md, inssel.brg, inssel-amd64.brg,
12024          mini-amd64.c, mini-x86.c, cpu-pentium.md: renamed OP_X86_TLS_GET
12025         to OP_TLS_GET.
12026
12027 2004-12-20  Sebastien Pouliot  <sebastien@ximian.com>
12028
12029         * declsec.c|h: Added functions to cache the declarative stack modifiers
12030         in MonoJitInfo and to create a security frame from a MonoJitInfo 
12031         structure.
12032         * mini.c: Initialize jinfo->cas_inited to FALSE when MonoJitInfo is
12033         created. Register internal calls for System.Security.SecurityFrame::
12034         _GetSecurityFrame and _GetSecurityStack.
12035         * mini.h: Added definition for new icalls (in mini-exceptions.c) and
12036         the definitions for the new stack walk/callback mechanism.
12037         * mini-exceptions.c: Added internal call GetSecurityFrame (to get the 
12038         first security frame for LinkDemands and InheritanceDemands) and
12039         GetSecurityStack for Demands. Both use the new mono_walk_stack code
12040         from lupus.
12041         * mini-x86.h, mini-amd64.h, mini-sparc.h: Architecture specific stack
12042         walk initialization (lupus).
12043
12044 2004-12-20  Ben Maurer  <bmaurer@ximian.com>
12045
12046         * mini.c (mono_method_to_ir): In CEE_DUP, handle the dup / stloc
12047         idiom.
12048         (handle_loaded_temps): Do not create a temporary variable for
12049         things that we know are temps. They will never be modified.
12050         (mono_spill_call): Set MONO_INST_IS_TEMP
12051         (mono_emulate_opcode): ditto
12052         (emit_tree): ditto
12053         (mono_method_to_ir.CEE_DUP): ditto
12054
12055 2004-12-19  Ben Maurer  <bmaurer@ximian.com>
12056
12057         * mini.c (type_to_eval_stack_type): Make this handle the void type
12058         (mono_emit_call_args): set the call->type with type_to_eval_stack_type
12059         (emit_tree): use ip_in_bb to special case some common idioms
12060         Update all callers to pass in the IP.
12061         (mono_method_to_ir): Make CEE_CALL* do the above as well.
12062
12063         This gives us a nice 2% speedup in mcs bootstrap.
12064
12065         * mini-x86.c (peephole_pass): Peephole pass to make
12066         mov  [foo], eax
12067         push [foo]
12068
12069         into
12070
12071         mov [foo], eax
12072         push eax
12073
12074         * mini.c (ip_in_bb): new method.
12075         (mono_method_to_ir): use this method rather than doing the hash
12076         lookup ourselves.
12077
12078         * linear-scan.c (mono_linear_scan): When expiring actives, you
12079         don't need to keep around variables that expire on this
12080         instruction. This makes it so that:
12081              a = b + 1
12082         will turn into:
12083              store (ebx add (ebx, 1))
12084         which will become
12085              add ebx, 1
12086
12087 2004-12-19  Zoltan Varga  <vargaz@freemail.hu>
12088
12089         * mini.c (mono_method_to_ir): Optimize the common ldobj+stloc 
12090         combination to avoid doing two copies. Fix up problems with previous
12091         patch.
12092
12093         * mini.c: Fix 64 bit warnings.
12094
12095         * mini-x86.c (INST_IGNORES_CFLAGS): Add OP_STOREI4_MEMBASE_REG.
12096
12097 2004-12-17  Zoltan Varga  <vargaz@freemail.hu>
12098
12099         * mini-amd64.h mini-amd64.c exceptions-amd64.c: Port exception handling
12100         changes from the x86 code.
12101
12102         * mini.h: Add prototype for mono_arch_get_throw_corlib_exception ().
12103
12104 2004-12-16  Zoltan Varga  <vargaz@freemail.hu>
12105
12106         * mini-x86.c (mono_arch_emit_epilog): Optimize the corlib exception
12107         throwing code to reduce its size, unify the AOT and non-aot code and 
12108         get rid of relocations in the AOT case.
12109
12110         * mini-x86.h mini.c exceptions-x86.c 
12111         (mono_arch_get_throw_corlib_exception): New arch specific function to 
12112         raise corlib exceptions which doesn't require relocations in the 
12113         caller.
12114
12115         * aot.c (emit_method): Handle PATCH_INFO_NONE as well.
12116
12117 2004-12-15  Zoltan Varga  <vargaz@freemail.hu>
12118
12119         * mini.c (mono_emit_method_call): Only allocate the got var when it is
12120         needed.
12121
12122         * mini-x86.c (mono_arch_patch_code): Add missing PATCH_INFO_METHOD_REL
12123         in the AOT case.
12124
12125 2004-12-14  Patrik Torstensson  <patrik.torstensson@gmail.com>
12126
12127         * mini-x86.c, cpu-pentium.md, inssel-x86.brg: Fixed bug
12128         with add function when used from Inc/dec atomic 
12129         functions. Re-enabled optimization on x86.
12130         * mini-ops.h: renamed atomic_add functions to
12131         allow _add to match the Interlocked::Add and
12132         _add_next to match Interlocked::Inc/Dec.
12133
12134 2004-12-15  Massimiliano Mantione  <massi@ximian.com>
12135
12136         * mini.c: Fixed a subtle bug in mono_method_to_ir, about the
12137         linking of BBs to the end BB, and enabled SSAPRE also with
12138         consprop and copyprop (which was prevented by that bug).
12139
12140 2004-12-14  Patrik Torstensson  <patrik.torstensson@gmail.com>
12141
12142         * mini-x86.c: disabling the Interlocked optimizing code. 
12143
12144 2004-12-14  Zoltan Varga  <vargaz@freemail.hu>
12145
12146         * aot.c (load_aot_module): Move reading of got_addr after the AOT
12147         file version check.
12148         
12149 2004-12-14  Patrik Torstensson  <patrik.torstensson@gmail.com>
12150
12151         * mini-x86.c, inssel-x86.brg, cpu-pentium.md: removed _imm 
12152         interlocked optimization due lack of support on x86, rewrote 
12153         exchange to take into account that base may be in eax.
12154         
12155         xsp works again; activated Interlocked optimizing code.
12156         
12157 2004-12-14  Zoltan Varga  <vargaz@freemail.hu>
12158
12159         * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file version.
12160
12161 2004-12-13  Zoltan Varga  <vargaz@freemail.hu>
12162
12163         * mini-ops.h: Add new opcodes.
12164
12165         * mini.h: Add new patch types. Add got_var to MonoCompile.
12166
12167         * mini.h mini-x86.c mini-amd64.c aot.c: Rename 
12168         mono_arch_get_aot_patch_offset () to mono_arch_get_patch_offset () and
12169         make it work with all kinds of patchable code.
12170
12171         * inssel.brg inssel-x86.brg: Add new rules dealing with computing the
12172         address of the GOT, and referencing entries in the GOT.
12173
12174         * mini.c: Add code to load the GOT address if needed by an opcode.
12175
12176         * aot.c mini-x86.h mini-x86.c cpu-pentium.md: Add support for position 
12177         independent AOT code on the x86 using an elf-style Global Offset Table.
12178
12179 2004-12-14  Raja R Harinath  <rharinath@novell.com>
12180
12181         * Makefile.am (RUNTIME): Set MONO_SHARED_DIR.
12182
12183 2004-12-13 Gonzalo Paniagua Javier <gonzalo@ximian.com>
12184
12185         * mini-x86.c: disabling the Interlocked optimizing code. It segfaults
12186         when running xsp.
12187
12188 2004-12-13  Patrik Torstensson  <patrik.torstensson@gmail.com>
12189
12190         * mini-x86.c,mini-ops.h,inssel-x86.brg,cpu-pentium.md: Implementation
12191         of Interlocked:Increment/Decrement/Add as inline ops.
12192         (mini-x86.c (mono_arch_get_inst_for_method and mono_arch_output_basic_block))
12193
12194 2004-12-12  Geoff Norton  <gnorton@customerdna.com>
12195
12196         * exceptions-ppc.c: Reorder code so gcc3.4 can compile it
12197         * mini-ppc.c: Unify mono_arch_patch_code with changes in r37636.
12198
12199 2004-12-12  Duncan Mak  <duncan@ximian.com>
12200
12201         * mini-ppc.c (mono_arch_patch_code): Hopefully made this build
12202         again. `patch_info->table_size' is no longer valid after Zoltan's
12203         commit #37636.
12204
12205 2004-12-12  Martin Baulig  <martin@ximian.com>
12206
12207         * mini.c (mono_method_to_ir): Only call mono_debug_init_method()
12208         if we are the "real" method, ie. not an inlined method inside it.
12209
12210 2004-12-11  Ben Maurer  <bmaurer@ximian.com>
12211
12212         * mini.c (CEE_LDSFLD): Make sure that the vtable has been init'd
12213         before we look in the special fields table. This fixes
12214         ../tests/thread-static-init.cs.
12215
12216 2004-12-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
12217
12218         * mini.c: return immediately after setting OP_ARRAY_RANK or CEE_LDLEN
12219         for Array get_Rank and get_Length. Fixes bug #70465.
12220
12221 2004-12-11  Zoltan Varga  <vargaz@freemail.hu>
12222
12223         * mini.h mini.c aot.c: Put the bblock table for a SWITCH patch into a
12224         separate structure to reduce the size of MonoJumpInfo.
12225
12226 Fri Dec 10 18:09:22 CET 2004 Paolo Molaro <lupus@ximian.com>
12227
12228         * mini.c, mini.h, aot.c, driver.c: allow disabling the aot code.
12229
12230 2004-12-10  Patrik Torstensson  <patrik.torstensson@gmail.com>
12231
12232         * mini.c (mini_get_inst_for_method): Changed to allow ports
12233         to return a MonoInst instead of opcode 
12234         (renamed mini_get_opcode_for_method to better reflect the new functionality)
12235         
12236         * mini-[x86|s390|s390x|ppc|sparc].c (mono_arch_get_inst_for_method): 
12237         Allow ports to return a created MonoInst instead of op-code, will enable
12238         new optimizations.
12239         (renamed mini_get_opcode_for_method to better reflected the functionality)
12240
12241 2004-12-09  Zoltan Varga  <vargaz@freemail.hu>
12242
12243         * mini.c (NEW_AOTCONST): Share some code between the different NEW_AOTCONST macros.
12244
12245 2004-12-08  Zoltan Varga  <vargaz@freemail.hu>
12246
12247         * mini.c jit-icalls.c: Pass generic_context to mono_ldtoken_wrapper.
12248         Fixes #69985.
12249
12250 2004-12-08  Martin Baulig  <martin@ximian.com>
12251
12252         * mini.c (mono_method_to_ir): In CEE_CALLVIRT, use `fsig->signature'
12253         if we're a CEE_CONSTRAINED call.  Fixes gen-118.cs.
12254
12255 2004-12-08  Zoltan Varga  <vargaz@freemail.hu>
12256
12257         * mini-sparc.c (mono_arch_output_basic_block): Implement OP_FCONV_TO_<X>
12258         correctly.
12259
12260         * exceptions.cs: Disable some tests which depend on properties of x86 fp
12261         arithmetic.
12262
12263 2004-12-08  Raja R Harinath  <rharinath@novell.com>
12264
12265         * Makefile.am (CLEANFILES): Add *.exe, *.dll.
12266
12267 2004-12-07  Zoltan Varga  <vargaz@freemail.hu>
12268
12269         * mini-sparc.c (mono_arch_output_basic_block): Fix LOCALLOC_IMM
12270         bug introduced by the previous patch.
12271
12272 Tue Dec 7 11:44:39 CET 2004 Paolo Molaro <lupus@ximian.com>
12273
12274         * mini-ppc.c, objectc.cs: handle large structs passed by value
12275         (fixes bug #69972).
12276
12277 Tue Dec 7 10:43:31 CET 2004 Paolo Molaro <lupus@ximian.com>
12278
12279         * mini-ppc.c: OP_ARGLIST implementation from
12280         Geoff Norton  <gnorton@customerdna.com>.
12281
12282 Tue Dec 7 10:14:25 CET 2004 Paolo Molaro <lupus@ximian.com>
12283
12284         * inssel-x86.brg, inssel-ppc.brg: fix reference to register
12285         in stmt: OP_OUTARG_VT (reg) (should fix bug #69785).
12286
12287 Tue Dec 7 10:06:39 CET 2004 Paolo Molaro <lupus@ximian.com>
12288
12289         * exceptions-ppc.c: avoid calling ppc_patch in exception trampolines.
12290
12291 2004-12-01  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
12292
12293         * inssel-s390.brgi, mini-ops.h, mini-s390.c : Add stubs for support of tls offset
12294         support.
12295
12296 2004-12-06  Zoltan Varga  <vargaz@freemail.hu>
12297
12298         * mini-sparc.c: Zero out localled-ed memory.
12299
12300         * iltests.il: Add tests for zeroing out localloc-ed memory.
12301
12302 2004-12-04  Martin Baulig  <martin@ximian.com>
12303
12304         * mini.c (mono_method_to_ir): In CEE_CALLVIRT, use the new
12305         mono_method_get_signature_full().       
12306
12307 2004-12-03  Massimiliano Mantione  <massi@ximian.com>
12308
12309         * mini.c: Added removal of critical edges (prerequisite for SSAPRE),
12310         and some utility functions (always for SSAPRE), integrated SSAPRE.
12311         * mini.h: Likewise.
12312         * driver.c: Added ssapre option.
12313         * ssa.c: Small fix on OP_ARG handling.
12314         * ssapre.c, ssapre.h: Added files containing SSAPRE implementation.
12315         * Makefile.am: Likewise.
12316
12317 2004-12-02  Zoltan Varga  <vargaz@freemail.hu>
12318
12319         * tramp-x86.c (mono_arch_create_jit_trampoline): Remove code which is
12320         now in the xp code.
12321
12322         * mini.c (mini_init): Register mono_thread_force_interruption_checkpoint
12323         icall.
12324
12325 2004-12-01  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
12326
12327         * inssel-s390.brg : Add OP_OUTARG_VT (OP_REFANYTYPE (reg)) rule.
12328         
12329         * cpu-s390.md : Increase instruction length of oparglist.
12330
12331         * mini-s390.c : Implement vararg and TYPEDEBYREF support.
12332
12333 2004-11-30  Martin Baulig  <martin@ximian.com>
12334
12335         * mini.c (mono_method_to_ir): In CEE_CALLVIRT, added support for
12336         virtual generic methods.  We call a special helper_compile_generic_method()
12337         icall to retrieve the method from the vtable, inflate and compile
12338         it and then do a CEE_CALLI.  Thanks a lot to Paolo for this idea.
12339
12340         * jit-icalls.c (helper_compile_generic_method): New JIT icall.
12341
12342 2004-11-30  Zoltan Varga  <vargaz@freemail.hu>
12343
12344         * mini-sparc.c: Fix up vararg corner cases. Fixes #70019.
12345
12346 2004-11-29  Zoltan Varga  <vargaz@freemail.hu>
12347
12348         * cpu-sparc.md mini-sparc.c (long_conv_to_ovf_i): Fill missing delay slot.
12349         Fixes #69929.
12350
12351 2004-11-27  Ben Maurer  <bmaurer@ximian.com>
12352
12353         * inssel.brg (CEE_SWITCH): The AOT stuff Zoltan added is only for
12354         platforms with PIC aot.
12355
12356 2004-11-28  Martin Baulig  <martin@ximian.com>
12357
12358         * mini.c (mono_method_to_ir): In CEE_DUP, added handle_stobj().
12359         Fixes gen-112.cs.
12360
12361 2004-11-28  Martin Baulig  <martin@ximian.com>
12362
12363         * mini-x86.c (mono_arch_call_opcode): Use the original type, not
12364         the result of mono_type_get_underlying_type() to check whether
12365         we're byref.
12366
12367 2004-11-26  Martin Baulig  <martin@ximian.com>
12368
12369         * mini.c
12370         (mono_method_to_ir): Use `!method->signature->has_type_parameters'
12371         in the g_assert().
12372
12373 2004-11-26  Zoltan Varga  <vargaz@freemail.hu>
12374
12375         * mini-amd64.c (mono_arch_emit_this_vret_args): Handle this and vret
12376         the same way as the other arguments so they won't get clobbered.
12377
12378         * mini-amd64.c (mono_arch_output_basic_block): Avoid doing virtual 
12379         calls through R11 since it is clobbered by the trampoline code.
12380
12381 2004-11-26  Raja R Harinath  <rharinath@novell.com>
12382
12383         * Makefile.am: Consistently use $(RUNTIME) rather than ./mono to
12384         pick up in-tree mscorlib.dll.
12385
12386 2004-11-25  Zoltan Varga  <vargaz@freemail.hu>
12387
12388         * aot.c: Rename MonoAOTModule->cleanup to out_of_date.
12389
12390         * mini-amd64.c aot.c: Switch to PIC relative AOT code. References to 
12391         runtime data/code are now stored in a table similar to the GOT in ELF. 
12392         This allows the code itself to be position independent.
12393
12394         * aot.c: Fix loading of referenced assemblies after the lazy assembly
12395         loading changes.
12396
12397         * aot.c: Attach ELF type (object/function) directives to all global
12398         symbols.
12399
12400         * tramp-amd64.c (amd64_magic_trampoline): Patch RIP relative calls too.
12401
12402         * inssel.brg (SWITCH): Emit an AOT_CONST in the aot case.
12403
12404         * mini-amd64.h: Turn on PIC AOT code.
12405
12406         * mini.h (mono_arch_get_aot_patch_offset): New arch specific function
12407         returning the offset within an OP_AOTCONST instruction where the GOT
12408         offset needs to be added.
12409
12410         * mini.h: Bump AOT file format version.
12411
12412 2004-11-25  Martin Baulig  <martin@ximian.com>
12413
12414         * mini.c (mono_method_to_ir): In CEE_CALL, don't allow calling any
12415         uninflated generic methods.
12416
12417 2004-11-25  Martin Baulig  <martin@ximian.com>
12418
12419         * mini.c (mono_method_to_ir): Don't allow any uninflated generic methods.
12420
12421 2004-11-24  Martin Baulig  <martin@ximian.com>
12422
12423         * minit.c (type_to_eval_stack_type): Set `inst->klass' to the
12424         original klass (this only applies for generic instances).
12425
12426 2004-11-24  Martin Baulig  <martin@ximian.com>
12427
12428         * mini.c (mono_method_to_ir): Use `STACK_OBJ' instead of
12429         `ldind_type [CEE_LDIND_REF]' (which would be beyond the end of
12430         that array).
12431
12432 2004-11-24  Zoltan Varga  <vargaz@freemail.hu>
12433
12434         * mini.c (mono_method_to_ir): Disable inlining for methods containing
12435         localloc. Fixes #69678.
12436
12437         * iltests.il (test_0_localloc_inline): Add regression test for #69678.
12438         
12439 2004-11-23  Zoltan Varga  <vargaz@freemail.hu>
12440
12441         * mini-amd64.c (mono_arch_output_basic_block): Set %al to the number of
12442         used SSE registers on pinvoke calls. Fixes #69774.
12443
12444 2004-11-23  Geoff Norton  <gnorton@customerdna.com>
12445
12446         * inssel-ppc.brg, mini-ppc.c: Use mono_class_from_mono_type instead of
12447         vt->inst_vtype->data.klass.  This fixes generic structs and bug #69766
12448
12449 2004-11-23  Raja R Harinath  <rharinath@novell.com>
12450
12451         * Makefile.am (MCS,ILASM): Don't refer to runtime/ directory.
12452         Refer directly to the mcs/ tree.
12453
12454 2004-11-19  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
12455
12456         * mini-s390.c, tramp-s390.c, mini-s390.h: Add LMF processing for trampolines.
12457         Check if a trampoline for a synchronized method is required. 
12458
12459 Fri Nov 19 17:34:21 CET 2004 Paolo Molaro <lupus@ximian.com>
12460
12461         * mini-ppc.c, cpu-g4.md: set to zero the memory allocated
12462         with localloc if needed. Throe arithmetric exception in
12463         div an rem if needed. Implement ovf checks in OP_LCONV_TO_OVF_I.
12464         Adapted from a patch by Geoff Norton  <gnorton@customerdna.com>.
12465
12466 2004-11-19  Geoff Norton  <gnorton@customerdna.com>
12467
12468         * mini-ppc.c: Call mono_type_get_underlying_type to unwrap generic
12469         types before switching on type.  Fixes #69622.
12470
12471 2004-11-19  Raja R Harinath  <rharinath@novell.com>
12472
12473         * Makefile.am (check-local): New.  Integrate into 'make check'.
12474         (MCS,RUNTIME): Define using in-tree mono and mcs.
12475         (ILASM): New.
12476         (%.exe): Use $(ILASM).
12477
12478 Fri Nov 19 14:54:07 CET 2004 Paolo Molaro <lupus@ximian.com>
12479
12480         * mini-ppc.c: adjust initial prolog size (bug #69691).
12481
12482 2004-11-18  Zoltan Varga  <vargaz@freemail.hu>
12483
12484         * cpu-pentium.md (localloc): Increase max instruction len. Fixes
12485         #69664.
12486
12487 2004-11-17  Raja R Harinath  <rharinath@novell.com>
12488
12489         * Makefile.am (clean-local): Rename from 'clean'.
12490
12491 2004-11-15  Nelae Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
12492
12493         * mini.c, mini-x86.c, mini-amd64.c, exceptions-s390.c: Add siginfo_t parameter
12494         to mono_arch_is_int_overflow. 
12495         * exceptions-s390.c: Add mono_arch_is_int_overflow routine to discern between
12496         SIGFPE events.
12497
12498 2004-11-15  Sebastien Pouliot  <sebastien@ximian.com>
12499
12500         * declsec.c|h: New files to support declarative security attributes.
12501         Added function to check if a method has (applicable) security.
12502         * mini.c|h: Add check for declarative security attributes in
12503         mono_method_check_inlining.
12504         * Makefile.am: Added declsec.c and declsec.h to the build.
12505
12506 Mon Nov 15 11:53:46 CET 2004 Paolo Molaro <lupus@ximian.com>
12507
12508         * mini.c, mini.h: update to keep dynamic code info per-domain.
12509
12510 2004-11-12  Zoltan Varga  <vargaz@freemail.hu>
12511
12512         * mini.c mini-*.h: Get rid of MONO_ARCH_HAVE_RETHROW since all architectures support it now.
12513         (mini_init): Get rid of it from here too.
12514
12515 Thu Nov 11 20:17:17 CET 2004 Paolo Molaro <lupus@ximian.com>
12516
12517         * mini-ppc.c, mini-ppc,h, cpu-g5.md, exceptions-ppc.c:
12518         implemented OP_RETHROW (patch by Geoff Norton
12519         <gnorton@customerdna.com>).
12520
12521 2004-11-10  Geoff Norton  <gnorton@customerdna.com>
12522
12523         * tramp-ppc.c (ppc_magic_trampoline): Don't trampoline methods
12524         between appdomains.  Fixes appdomain-unload on PPC.
12525
12526 2004-10-26  Lluis Sanchez Gual  <lluis@novell.com>
12527
12528         * exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
12529         mini-exceptions.c: handle the new wrapper types.
12530         * mini.c: The CEE_ISINST and CEE_CASTCLASS opcodes now take the
12531         token value as a MonoClass* when compiling a wrapper.
12532         mono_jit_create_remoting_trampoline now takes an additional
12533         MonoRemotingTarget parameter.
12534         
12535 2004-11-10  Martin Baulig  <martin@localhost>
12536
12537         * mini.c (mono_method_to_ir): Use `generic_container->context'
12538         rather than creating a new one.
12539
12540 2004-11-09  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
12541
12542         * exceptions-s390.c, mini-s390, cpu-s390.md: Add support for OP_RETHROW.
12543
12544         * inssel-390.md, mini-s390.c: Correct register allocation for globals.
12545
12546 2004-11-09  Zoltan Varga  <vargaz@freemail.hu>
12547
12548         * aot.c (mono_aot_init): Add MONO_AOT_CACHE env variable to turn on
12549         the experimental aot cache stuff.
12550
12551 Tue Nov 9 17:30:20 CET 2004 Paolo Molaro <lupus@ximian.com>
12552
12553         * aot.c, mini.c, exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
12554         mini-exceptions.c: update to exception clause structure changes.
12555
12556 2004-11-08  Zoltan Varga  <vargaz@freemail.hu>
12557
12558         * exceptions-x86.c (throw_exception): Fix warnings.
12559
12560         * mini-x86.h mini-x86.c cpu-pentium.md exceptions-x86.c: Add support 
12561         for OP_RETHROW.
12562
12563 2004-11-08  Zoltan Varga  <vargaz@freemail.hu>
12564
12565         * exceptions-sparc.c (get_throw_exception): Really fix this.
12566
12567 2004-11-07  Ben Maurer  <bmaurer@ximian.com>
12568
12569         * tramp-*.c: we no longer support icalls without wrappers, so
12570         a bit of code can be removed here
12571
12572 2004-11-07  Zoltan Varga  <vargaz@freemail.hu>
12573
12574         * exceptions-sparc.c (get_throw_exception): Fix more bugs in previous
12575         patch.
12576
12577         * cpu-sparc.md: Add op_rethrow.
12578
12579         * exceptions-sparc.c (get_throw_exception): Fix bug in previous patch.
12580
12581         * mini-sparc.h mini-sparc.c exceptions-sparc.c: Add support for OP_RETHROW.
12582
12583         * mini.h: Add mono_arch_get_rethrow_exception () arch specific function.
12584         * mini-ops.h: Add OP_RETHROW.
12585
12586         * mini.c inssel.brg: Distinguish between THROW and RETHROW.
12587
12588         * cpu-amd64.c mini-amd64.c exceptions-amd64.c: Add support for OP_RETHROW.
12589
12590 2004-11-05  Geoff Norton  <gnorton@customerdna.com>
12591         
12592         * helpers.c: Change otool arguments from -V -v -t to -v -t on Darwin
12593         Makes the output much easier to read
12594
12595 2004-11-05  Ben Maurer  <bmaurer@ximian.com>
12596
12597         * ssa.c: allocate MonoMethodVar.uses from the mempool. First, this
12598         prevents another huge leak when compiling with ssa. Secondly, the
12599         performance of doing this rather than freeing the lists is much
12600         better. GList does a lock every time you allocate a list link,
12601         so that it can use a memory pool. So, it is better to just use
12602         a memory pool of our own.
12603         
12604         * ssa.c, linear-scan.c: replace g_list_remove_link with
12605         g_list_delete.  The remove one does not free the GList, so we were
12606         leaking memory. On -O=all --compile-all with corlib, this cut down
12607         3 MB of allocations.
12608
12609 2004-11-05  Zoltan Varga  <vargaz@freemail.hu>
12610
12611         * tramp-sparc.c (mono_arch_create_jit_trampoline): Fix sparc build.
12612
12613         * tramp-amd64.c (mono_arch_create_jit_trampoline): Fix amd64 build.
12614
12615         * mini.h mini.c tramp-*.c: Moved xp parts of JIT trampoline creation
12616         into a new function mono_create_jit_trampoline ().
12617
12618 2004-11-02  Zoltan Varga  <vargaz@freemail.hu>
12619
12620         * trace.c (get_spec): Allow tracing of classes without a namespace.
12621
12622 2004-11-02  Sebastien Pouliot  <sebastien@ximian.com>
12623
12624         * mini.c: Fix pointer overwrite in mini_method_compile.
12625
12626 2004-11-2  Geoff Norton  <gnorton@customerdna.com>
12627
12628         * inssel-ppc.brg (OP_OUTARG_VT (CEE_LDOBJ (base))):
12629         The darwin ABI needs some special handling for 1 and 2 byte structs
12630         Lets use lbz/lhz instead of lwz everywhere.
12631         * mini-ppc.c (calculate_sizes):  The Darwin ABI needs from special handling
12632         for 1 and 2 byte structs and struct which are size >= 3 || size % 4 != 0.
12633         Use stb/sth for the former, and put the latter always on stack instead of in
12634         argument registers.
12635
12636 2004-10-30  Zoltan Varga  <vargaz@freemail.hu>
12637
12638         * trace.c (is_filenamechar): Add '_'.
12639
12640 2004-10-29  Neale Ferguson  <Neale.Ferguson@SoftwareAG-usa.com>
12641
12642         * mini-s390.c: Fix prolog length to allow for large trace requirements.
12643
12644         * exceptions-s390.c: Remove dwarf unwinding stuff that was unused.
12645
12646 2004-10-29  Zoltan Varga  <vargaz@freemail.hu>
12647
12648         * Makefile.am (libgc_libs): Do some automake magic so libmono/mono
12649         depends on libmonogc. Fixes #68805.
12650
12651 2004-10-26  Miguel de Icaza  <miguel@ximian.com>
12652
12653         * mini.c (mono_jit_free_method): Provide extra information for
12654         this error.  Currently this leaks, but will be turned into a
12655         developer option in the future.
12656
12657 2004-10-26  Zoltan Varga  <vargaz@freemail.hu>
12658
12659         * driver.c (mono_main): Applied patch from Willibald Krenn <willibald.krenn@gmx.at>. Make --graph work for icalls and pinvoke methods.
12660
12661 2004-10-25  Zoltan Varga  <vargaz@freemail.hu>
12662
12663         * aot.c (mono_aot_load_method): Align PATCH_INFO_R8 on an 8 byte 
12664         boundary. Fixes reading of PATCH_INFO_R4 and R8.
12665         (mono_aot_load_method): Do not allocate MonoAotMethod in the GC heap.
12666
12667 2004-10-24  Zoltan Varga  <vargaz@freemail.hu>
12668
12669         * mini-amd64.c (mono_arch_patch_code): Fix patching of class init
12670         trampolines for AOT code.
12671
12672 2004-10-22    <vargaz@freemail.hu>
12673
12674         * aot.c (mono_compile_assembly): Disable AOT for methods containing calls to methods of
12675         constructed types. Fixes #68136.
12676
12677 2004-10-21  Martin Baulig  <martin@ximian.com>
12678
12679         * exceptions-x86.c (throw_exception): Call mono_debugger_throw_exception();
12680         if it returns true, unwind the stack to the call instruction.
12681
12682 2004-10-21    <vargaz@freemail.hu>
12683
12684         * aot.c: Reorganize the AOT file format to avoid relocations. Fix warnings.
12685
12686         * mini.h: Bump AOT version number.
12687
12688         * objects.cs: Add another test for unbox trampolines.
12689
12690         * tramp-amd64.c (amd64_magic_trampoline): Disable patching of trampolines for 
12691         valuetype methods.
12692
12693 2004-10-20    <vargaz@freemail.hu>
12694
12695         * driver.c: Add SHARED to the set of optimizations tested.
12696
12697         * tramp-amd64.c (amd64_magic_trampoline): Patch trampoline code as well.
12698
12699         * mini.c (mono_method_to_ir): Mark the domainvar as volatile when it is implicitly
12700         used by CEE_NEWARR.
12701
12702         * ssa.c (mono_ssa_deadce): Do not optimize away accesses to volatile variables.
12703
12704 2004-10-20  Martin Baulig  <martin@ximian.com>
12705
12706         * mini-exceptions.c (mono_handle_exception): Call
12707         mono_debugger_handle_exception() to tell the debugger about
12708         catch/finally clauses.
12709
12710 2004-10-18  Zoltan Varga  <vargaz@freemail.hu>
12711
12712         * exceptions-amd64.c (mono_arch_find_jit_info): Pop arguments of the stack.
12713
12714         * mini-amd64.c (mono_amd64_get_vcall_slot_addr): Handle extended registers. Fixes
12715         #68447.
12716
12717 2004-10-15  Geoff Norton  <gnorton@customerdna.com>
12718
12719         * mini-ppc.c (calculate_sizes): Marshal valuetypes for pinvoke
12720         methods as their native size, fixed bug #57543, #57545.
12721         * mini-ppc.c (mono_arch_output_basic_block): Use mulli for imm16 types
12722         This saves a temporary register and mullw call down into 1 (minor perf
12723         increase for cases like sum = sum * 5;  This use to translate into:
12724             li r11,5
12725             mullw r28,r28,r11
12726         It now translates to
12727             mulli r28,r28,5
12728
12729 2004-10-15  Zoltan Varga  <vargaz@freemail.hu>
12730
12731         * trace.c (mono_trace_eval): Use mono_method_desc_full_match. Fixes
12732         #68388.
12733
12734 2004-10-11  Martin Baulig  <martin@ximian.com>
12735
12736         * mini.c (mono_method_to_ir): If we're a generic method, get the
12737         MonoGenericContainer from our MonoMethodNormal and create a
12738         MonoGenericContext from it.
12739
12740 2004-10-08  Zoltan Varga  <vargaz@freemail.hu>
12741
12742         * inssel-long32.brg (OP_LCONV_TO_OVF_I2): Fix CONV_I1 -> CONV_I2.
12743
12744         * basic-long.cs: Add test for checked i8->i2 cast.
12745
12746 Wed Oct 6 12:40:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
12747
12748         * inssel-ppc.brg: added a couple of speedup rules.
12749
12750 2004-10-05  Zoltan Varga  <vargaz@freemail.hu>
12751
12752         * Makefile.am (genmdesc_LDADD): Don't link this against libmetadata
12753         to speed up rebuilds.
12754
12755 2004-10-04  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
12756
12757         * mini-s390.c: Minor fix to OP_OR_IMM.
12758
12759 2004-10-03  Zoltan Varga  <vargaz@freemail.hu>
12760
12761         * tramp-sparc.c (sparc_magic_trampoline): Handle appdomain stuff
12762         better. Fixes appdomain-unload.exe on sparc.
12763
12764 2004-10-02  Massimiliano Mantione  <massi@ximian.com>
12765
12766         * ssa.c: Fixed casts to unsigned where the value was of 64 bits in
12767         simulate_long_compare, patch by will@exomi.com (Ville-Pertti Keinonen),
12768         see bug 67324.
12769
12770 2004-10-02  Zoltan Varga  <vargaz@freemail.hu>
12771
12772         * jit-icalls.c: Handle a nonexisting trunc function more correctly.
12773
12774 2004-09-30  Lluis Sanchez Gual  <lluis@novell.com>
12775
12776         * mini.c: Always generate a field read/write wrapper for members
12777         of the class MarshalByRefObject since the actual instance could
12778         be a CBO.
12779
12780 2004-09-28  Lluis Sanchez Gual  <lluis@novell.com>
12781
12782         * mini.c: Use mono_thread_exit() to stop threads, instead of ExitThread.
12783
12784 2004-09-28  Zoltan Varga  <vargaz@freemail.hu>
12785
12786         * driver.c mini.h trace.c: Move the setting of the main assembly into
12787         a separate function called mono_trace_set_assembly () and call it after
12788         actually loading the main assembly. Fixes #66872.
12789
12790 2004-09-25  Zoltan Varga  <vargaz@freemail.hu>
12791
12792         * mini-amd64.h mini-amd64.c tramp-amd64.c: Allocate trampoline memory
12793         using the code manager.
12794
12795 2004-09-24  Zoltan Varga  <vargaz@freemail.hu>
12796
12797         * tramp-amd64.c mini-amd64.h: Add support for MONO_ARCH_HAVE_INVALIDATE_METHOD.
12798
12799 2004-09-23  Zoltan Varga  <vargaz@freemail.hu>
12800
12801         * cpu-amd64.md: Fix bug in previous patch.
12802         
12803         * cpu-amd64.md: Fix instruction lengths of membase opcodes. Fixes
12804         #66650.
12805
12806 Wed Sep 22 19:03:20 CEST 2004 Paolo Molaro <lupus@ximian.com>
12807
12808         * mini.h, exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
12809         mini-exceptions.c: updates for changed stack walk interface.
12810
12811 2004-09-21  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
12812
12813         * mini-s390.c, cpu-s390.md: Minor changes to OP_ARGLIST handling
12814
12815 2004-09-17  Zoltan Varga  <vargaz@freemail.hu>
12816
12817         * mini.c (mono_method_to_ir): Fix LDSTR in dynamic methods. Fixes #66132.
12818
12819 2004-09-13  Zoltan Varga  <vargaz@freemail.hu>
12820
12821         * driver.c (mini_regression_list): Do not call mono_assembly_close 
12822         since assemblies can't be unloaded.
12823         
12824 2004-09-11  Zoltan Varga  <vargaz@freemail.hu>
12825
12826         * cpu-amd64.md: Fix more instruction lengths.
12827
12828         * cpu-amd64.md: Fix lengths of some instructions.
12829
12830 2004-09-11 Ben Maurer  <bmaurer@users.sourceforge.net>
12831
12832         * inssel.brg: Make the array ldelema check aot friendly.
12833
12834 2004-09-11  Zoltan Varga  <vargaz@freemail.hu>
12835
12836         * mini-amd64.c (mono_arch_get_argument_info): Fix stack_unwind test.
12837
12838         * cpu-amd64.md inssel-long.brg inssel-amd64.brg: Small optimizations.
12839
12840 2004-09-10  Zoltan Varga  <vargaz@freemail.hu>
12841
12842         * mini-x86.c: Fix build.
12843
12844         * mini-sparc.c mini-x86.c mini-amd64.c: Use the new 
12845         mono_type_get_underlying_type () helper function to simplify code.
12846         
12847 2004-09-09  Martin Baulig  <martin@ximian.com>
12848
12849         * mini-amd64.c: Don't access `type->data.klass' directly, call
12850         mono_class_from_mono_type() instead since the type may be a
12851         generic instance.
12852
12853 2004-09-09  Martin Baulig  <martin@ximian.com>
12854
12855         * mini-amd64.c (get_call_info): Fix support for generic instances.
12856         (add_valuetype): Use mono_class_from_mono_type() to get the class
12857         since we can be a generic instance.
12858
12859 Thu Sep 9 01:43:53 PDT 2004 Paolo Molaro <lupus@ximian.com>
12860
12861         * mini-ppc.c, mini.h, regalloc.c, regalloc.h: powerpc speedups.
12862
12863 2004-09-07 Ben Maurer  <bmaurer@users.sourceforge.net>
12864
12865         * liveness.c: reset spill costs on each scan: bug 62107
12866
12867 2004-09-07  Bernie Solomon  <bernard@ugsolutions.com>
12868
12869         * exceptions-sparc.c (mono_arch_find_jit_info): remove
12870         unnecessary line that doesn't compile
12871
12872 2004-09-07  Zoltan Varga  <vargaz@freemail.hu>
12873
12874         * mini.c mini.h mini-x86.h tramp-x86.c: Instead of freeing delegate
12875         trampolines, make them call an error function so people can fix their
12876         code.
12877
12878 2004-09-06  Martin Baulig  <martin@ximian.com>
12879
12880         * mini.c (mono_method_to_ir): When initializing locals, handle a
12881         generic instances like a valuetype if it's a valuetype and like a
12882         class if it's a class.
12883
12884 2004-09-06  Zoltan Varga  <vargaz@freemail.hu>
12885
12886         * exceptions-x86.c (mono_arch_find_jit_info): Pop arguments off the
12887         stack. Fixes #64674.
12888
12889         * exceptions.cs: Add test for unwinding of call arguments.
12890
12891 Mon Sep 6 05:50:02 PDT 2004 Paolo Molaro <lupus@ximian.com>
12892
12893         * mini-*.c, mini-ops.h, inssel-long32.brg: introduced
12894         OP_ADDCC_IMM and OP_SUBCC_IMM (add/sub immediate that will
12895         set the carry/borrow flag). The sparc and s390 implementations
12896         can now use optimized versions (and simplify the code). ppc bugfixes.
12897
12898 2004-09-06  Zoltan Varga  <vargaz@freemail.hu>
12899
12900         * exceptions-ppc.c (mono_arch_find_jit_info): Fix memory leak.
12901
12902 2004-09-05  Zoltan Varga  <vargaz@freemail.hu>
12903
12904         * inssel-amd64.brg: Remove leftover 32 bit rule.
12905
12906         * mini-amd64.c (mono_arch_instrument_prolog): Fix tracing support.
12907
12908 2004-09-04  Zoltan Varga  <vargaz@freemail.hu>
12909
12910         * mini-exceptions.c (mono_find_jit_info): Refactor common code from
12911         mono_arch_find_jit_info functions into a new function. Fix a memory
12912         leak.
12913
12914         * exceptions-x86.c exceptions-amd64.c exceptions-sparc.c: Remove
12915         refactored code.
12916         
12917 2004-09-02  Zoltan Varga  <vargaz@freemail.hu>
12918
12919         * exceptions.cs inssel-long32.brg: Handle the OP_LCONV_TO_OVF_I2 case
12920         as well.
12921         
12922         * exceptions.cs: Add array size tests.
12923
12924         * mini.c: Allocate a separate icall wrapper for each arity of 
12925         mono_array_new_va. Fixes #59509.
12926
12927         * exceptions.cs: Add testcase for 64578.
12928
12929         * inssel-long32.brg: Fix OP_LCONV_TO_OVF_I1 rule. Fixes #64578.
12930
12931         * trace.c (is_filenamechar): Allow 0..9 in strings. Fixes #65094.
12932         
12933 2004-09-02  Martin Baulig  <martin@ximian.com>
12934
12935         * mini.c (mono_method_to_ir): When initializing the locals, call
12936         handle_initobj() on the generic instance itself, not its
12937         underlying type.
12938
12939 2004-09-02  Zoltan Varga  <vargaz@freemail.hu>
12940
12941         * mini.h (MonoJitDynamicMethodInfo): New structure, extension of 
12942         MonoJitInfo for dynamic methods.
12943
12944         * mini.c: Rename trampoline_hash_mutex to jit_mutex.
12945
12946         * mini.c: Add support for freeing JIT data for dynamic methods.
12947         
12948 2004-09-01  Martin Baulig  <martin@ximian.com>
12949
12950         * mini-x86.c (is_regsize_var): Added support for generic
12951         instances.
12952         (mono_arch_emit_prolog): Make this compile again, use
12953         `x86_push_imm_template (code)'.
12954
12955 2004-08-30 Ben Maurer  <bmaurer@users.sourceforge.net>
12956
12957         * mini-x86.c: make all push_imm instructions that get
12958         patched always emit the long form
12959
12960 2004-08-30  Zoltan Varga  <vargaz@freemail.hu>
12961
12962         * mini.c (mono_create_jump_trampoline): Store the jump trampolines 
12963         in a per-domain hash.
12964
12965         * mini-amd64.c (merge_argument_class_from_type): Handle generic
12966         types.
12967
12968 2004-08-29  Zoltan Varga  <vargaz@freemail.hu>
12969
12970         * mini-amd64.c cpu-amd64.md inssel-amd64.brg mini-amd64.h: Ongoing SSE
12971         work.
12972         
12973         * mini-amd64.c cpu-amd64.md inssel-amd64.brg mini-amd64.h: More SSE
12974         work.
12975
12976         * mini-amd64.c cpu-amd64.md: Implement checked int<->uint casts.
12977         Beginnings of SSE2 support.
12978
12979         * exceptions.cs: Add more tests for checked int<->uint casts.
12980
12981 2004-08-28  Martin Baulig  <martin@ximian.com>
12982
12983         * mini-x86.c (mono_arch_instrument_epilog): Added support for
12984         generic instances.
12985
12986         * mini.c
12987         (mono_type_to_ldind, mono_type_to_stind, type_to_eval_stack_type):
12988         Handle generic instances recursively.
12989
12990 2004-08-27 Ben Maurer  <bmaurer@users.sourceforge.net>
12991
12992         * iltests.il: test for conv.u8 on a constant
12993
12994 2004-08-27 Ben Maurer  <bmaurer@users.sourceforge.net>
12995
12996         * inssel-long32.brg: c&p rules for LCONV_x4 (membase) and
12997         LCONV_x4 (shrun_32 (membase)).
12998
12999 2004-08-27 Ben Maurer  <bmaurer@users.sourceforge.net>
13000
13001         * inssel-x86.brg: c&p rules for push/setret of long
13002
13003 2004-08-26 Ben Maurer  <bmaurer@users.sourceforge.net>
13004
13005         * inssel-x86.brg: c&p rules for compare (base, regvar) and
13006         compare (regvar, base)
13007
13008         * inssel-x86.brg: more burg love
13009
13010         * inssel.brg: more cleanup
13011
13012         * inssel-x86.brg, inssel-long32.brg: burg cleanup.
13013
13014 2004-08-26 Ben Maurer  <bmaurer@users.sourceforge.net>
13015
13016         * basic-long.cs, basic-calls.cs: new tests for optimization.
13017
13018 2004-08-26  Zoltan Varga  <vargaz@freemail.hu>
13019
13020         * mini-amd64.c (read_tls_offset_from_method): Fix typo in previous
13021         patch.
13022
13023 2004-08-25  Zoltan Varga  <vargaz@freemail.hu>
13024
13025         * mini-amd64.c (read_tls_offset_from_method): Add another case.
13026         
13027 2004-08-25  Bernie Solomon  <bernard@ugsolutions.com>
13028
13029         * inssel.brg (mini_emit_memcpy): use 
13030         NO_UNALIGNED_ACCESS to disable memcpy optimization
13031
13032 2004-08-25  Zoltan Varga  <vargaz@freemail.hu>
13033
13034         * mini-amd64.c: Handle generic types in various places.
13035
13036         * mini.c (mono_method_to_ir): Handle generic types in init locals.
13037
13038 2004-08-24  Zoltan Varga  <vargaz@freemail.hu>
13039
13040         * mini.c (handle_box): Fix warning.
13041
13042         * mini-amd64.c (mono_arch_local_regalloc): Fix regalloc problem.
13043
13044         * mini-amd64.h: Enable the emit_state optimization.
13045
13046         * mini-ops.h cpu-amd64.md: Add new amd64_test_null opcode.
13047
13048         * mini-amd64.c: Add some new 64 bit peephole opts.
13049
13050         * inssel.brg (mini_emit_memcpy): Optimize for 64 bit architectures.
13051
13052         * cpu-amd64.md: sreg1 of div instructions must be %rax.
13053
13054         * mini-amd64.c: Register allocator fixes.
13055
13056         * mini.c: Add an optimization to emit_state to avoid allocation of new
13057         registers on some platforms.
13058
13059 2004-08-23  Zoltan Varga  <vargaz@freemail.hu>
13060
13061         * inssel-x86.brg inssel-amd64: Add yet another missing tree->dreg assignment.
13062
13063         * mini-x86.c (mono_arch_local_regalloc): Fix bug in long register
13064         allocation. Fixes #63085.
13065
13066         * basic-long.cs: Add new regression test.
13067
13068         * mini-amd64.c: Register allocator improvements.
13069
13070 2004-08-21  Zoltan Varga  <vargaz@freemail.hu>
13071
13072         * mini-amd64.c (read_tls_offset_from_method): Add another code
13073         sequence.
13074
13075         * tramp-amd64.c (amd64_class_init_trampoline): Use a more efficient
13076         instruction sequence for nullifying class init trampolines.
13077
13078         * objects.cs: Add new regalloc test.
13079
13080         * mini-amd64.c inssel-amd64.brg: Optimize parameter passing.
13081
13082 2004-08-20  Zoltan Varga  <vargaz@freemail.hu>
13083
13084         * mini-amd64.c (mono_arch_call_opcode): Refactor this a little.
13085         
13086         * mini-amd64.c (mono_arch_regalloc_cost): Adjust regalloc costs for
13087         arguments.
13088
13089         * driver.c: Fix profiling after TLS changes.
13090         
13091         * driver.c (mono_main): Set mono_stats.enabled if needed.
13092
13093         * mini.c (handle_alloc): New helper function used by CEE_NEWOBJ and
13094         CEE_BOX.
13095
13096 2004-08-20 Ben Maurer  <bmaurer@users.sourceforge.net>
13097
13098         * mini-x86.c: use a 1 op rather than a 2 op tls access
13099         instruction -> faster.
13100
13101 2004-08-20  Zoltan Varga  <vargaz@freemail.hu>
13102
13103         * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Merge changes from
13104         x86 backend.
13105
13106 2004-08-19 Bernie Solomon <bernard@ugsolutions.com>
13107
13108         * exceptions-sparc.c (throw_exception): fix typo
13109
13110 2004-08-19 Ben Maurer  <bmaurer@users.sourceforge.net>
13111
13112         * mini-x86.c, cpu-pentium.md, inssel-x86.brg:
13113         set tree->dreg correctly with tls. Allow any
13114         register to be used.
13115
13116         * mini-x86.c (read_tls_offset_from_method): add new code
13117         generation pattern seen with GCC.
13118
13119
13120 Thu Aug 19 17:26:55 CEST 2004 Paolo Molaro <lupus@ximian.com>
13121
13122         * mini-exceptions.c, exceptions-x86.c, exceptions-amd64.c,
13123         exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
13124         exceptions-sparc.c: fix some performance issues in exception
13125         handling and setting of the stack trace for exceptions that were
13126         already thrown.
13127
13128 2004-08-18  Zoltan Varga  <vargaz@freemail.hu>
13129
13130         * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Merge changes from 
13131         x86 backend.
13132         
13133         * mini-amd64.c (mono_arch_is_int_overflow): Handle all possible 
13134         registers.
13135
13136 2004-08-18 Ben Maurer  <bmaurer@users.sourceforge.net>
13137
13138         This patch inlines tls access, when possible.
13139         
13140         * mini.h: new arch functions for TLS intrinsics.
13141         All platforms updated with a stub.
13142
13143         * mini.c: use the new intrinsics
13144
13145         * mini-x86.c, cpu-pentium.md, inssel-x86.brg, mini-ops.h:
13146         arch specific intrinsic for tls variables
13147
13148 2004-08-18  Zoltan Varga  <vargaz@freemail.hu>
13149
13150         * Makefile.am (libmono_la_LDFLAGS): Enable creating of libmono dll
13151         under windows.
13152
13153 2004-08-17 Ben Maurer  <bmaurer@users.sourceforge.net>
13154
13155         * mini.c: thread local allocation
13156
13157 2004-08-16  Zoltan Varga  <vargaz@freemail.hu>
13158
13159         * mini-amd64.h (MONO_ARCH_NO_EMULATE_LONG_SHIFT_OPS): Enable.
13160
13161         * Makefile.am: Link against the static version of libmonogc.
13162         
13163         * Makefile.am: Link the static versions of the convenience libraries
13164         into the mono executable.
13165
13166         * mini-x86.h mini-x86.c: Throw the correct exception on integer overflow.
13167
13168 2004-08-15  Zoltan Varga  <vargaz@freemail.hu>
13169
13170         * mini.h mini.c mini-amd64.h mini-amd64.c: Throw the correct exception
13171         on integer overflow.
13172
13173         * mini-amd64.c: Reorganize function call code.
13174
13175         * mini-amd64.c (peephole_pass): Merge changes from mini-x86.c.
13176
13177 2004-08-14 Ben Maurer  <bmaurer@ximian.com>
13178
13179         * inssel-x86.brg: use xor eax,eax.
13180         
13181         * basic.cs: new tests
13182
13183 2004-08-14  Zoltan Varga  <vargaz@freemail.hu>
13184
13185         * mini-amd64.c (mono_arch_emit_epilog): Use RIP relative addressing
13186         in exception throwing code.
13187         
13188 2004-08-14 Ben Maurer  <bmaurer@ximian.com>
13189
13190         * inssel-x86.brg: use xor esi,esi.
13191
13192 2004-08-14  Zoltan Varga  <vargaz@freemail.hu>
13193
13194         * driver.c (mono_main): Call mono_trace_parse_options earlier so it
13195         can trace methods compiled during mini_init () too.
13196
13197         * cpu-amd64.md mini-amd64.c (mono_arch_output_basic_block): Handle 
13198         CEE_CONV_U4.
13199
13200 2004-08-14 Ben Maurer  <bmaurer@ximian.com>
13201
13202         * Makefile.am: static link on x86 (r=zoltan)
13203
13204 2004-08-14  Zoltan Varga  <vargaz@freemail.hu>
13205
13206         * tramp-amd64.c (amd64_magic_trampoline): Avoid patching the trampoline
13207         code since it causes some programs to fail.
13208
13209 2004-08-12  Zoltan Varga  <vargaz@freemail.hu>
13210
13211         * mini-amd64.c (bb_is_loop_start): Merge changes from mini-x86.c.
13212
13213 2004-08-11  Bernie Solomon <bernard@ugsolutions.com>
13214
13215         * mini.c: ovfops_op_map - add STACK_OBJ case for
13216         CONV_I 
13217         * basic.cs: add test_0_pin_string as test
13218         case for above.
13219
13220 2004-08-11  Bernie Solomon <bernard@ugsolutions.com>
13221
13222         * Makefile.am: build C# if srcdir != builddir
13223
13224 Tue Aug 10 19:23:47 CEST 2004 Paolo Molaro <lupus@ximian.com>
13225
13226         * dominators.c, mini.h, mini-x86.c: fix loop alignment with
13227         fall-through blocks.
13228
13229 Tue Aug 10 16:18:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
13230
13231         * driver.c: enable loop by default again and include abcrem in -O=all.
13232
13233 2004-08-08  Zoltan Varga  <vargaz@freemail.hu>
13234
13235         * iltests.il: Add some localloc tests.
13236
13237         * mini.c (mono_method_to_ir): Set stack type of LOCALLOC correctly.
13238
13239         * inssel-amd64.brg inssel-x86.brg: Set dreg of LOCALLOC correctly. 
13240         Fixes #62574.
13241
13242         * inssel-amd64.brg: Add some optimizations.
13243
13244         * mini-amd64.c (mono_arch_setup_jit_tls_data): Add tls offset detection
13245         for gcc-3.4.
13246
13247         * Makefile.am: Statically link mono against libmono on AMD64.
13248         
13249         * mini-amd64.c inssel-amd64.brg: Optimizations.
13250
13251 2004-08-07  Zoltan Varga  <vargaz@freemail.hu>
13252
13253         * mini-amd64.c (mono_arch_emit_prolog): Optimize lmf saving a bit.
13254
13255         * tramp-amd64.c: Patch calling code in trampolines.
13256
13257 2004-08-06  Zoltan Varga  <vargaz@freemail.hu>
13258
13259         * mini-amd64.c: pinvoke struct passing fixes.
13260
13261 2004-08-05  Bernie Solomon  <bernard@ugsolutions.com>
13262
13263         * mini-sparc.c: redo change, make mono_arch_cpu_init call
13264         mono_arch_cpu_optimizazions so sparcv9 is initialized when embedded
13265
13266 2004-08-05  Duncan Mak  <duncan@ximian.com>
13267
13268         * mini.c: Renamed CEE_STELEM to CEE_STELEM_ANY and CEE_LDELEM to
13269         CEE_LDELEM_ANY.
13270
13271 2004-08-05  Zoltan Varga  <vargaz@freemail.hu>
13272
13273         * mini-amd64.c (emit_move_return_value): Move return value for normal
13274         calls too.
13275
13276 2004-08-05  Martin Baulig  <martin@ximian.com>
13277
13278         * mini.c (ret_type_to_call_opcode): Don't use a `t' variable for
13279         `type->type'; just modify `type' itself when dealing with enums
13280         and generic instances.
13281         (check_call_signature): Make `simple_type' a `MonoType *'.
13282
13283 2004-08-05  Zoltan Varga  <vargaz@freemail.hu>
13284
13285         * mini.c: Use OP_PADD to add offsets to addresses.
13286
13287         * mini-amd64.h: Disable SIGSEGV_ON_ALTSTACK.
13288
13289 2004-08-04  Bernie Solomon  <bernard@ugsolutions.com>
13290
13291         * mini-sparc.c (mono_arch_emit_epilog): fix check
13292         for folding last op into restore instruction
13293
13294 2004-08-05  Zoltan Varga  <vargaz@freemail.hu>
13295
13296         * exceptions-amd64.c (mono_arch_get_throw_exception_by_name): Allocate
13297         helper methods using the code manager.
13298         
13299         * exceptions-amd64.c (mono_arch_get_throw_exception): Fix maximum length.
13300
13301         * mini-amd64.c (mono_arch_allocate_vars): Fix tls offset detection.
13302
13303 Tue Aug 3 23:50:00 EST 2004 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
13304         
13305         * mini-s390x.c mini-s390x.h tramp-s390x.c inssel-s390x.brg
13306           cpu-s390x.md exceptions-s390x.c Makefile.am: S/390 64-bit JIT
13307
13308         * mini-s390.c: fix tail processing
13309
13310 Tue Aug 3 01:35:44 PDT 2004 Paolo Molaro <lupus@ximian.com>
13311
13312         * mini-ppc.c: mul.ovf.un exception name fix.
13313
13314 2004-08-03  Martin Baulig  <martin@ximian.com>
13315
13316         * mini-x86.c (mono_arch_call_opcode): Correctly handle generic
13317         instances; before jumping to `handle_enum', also modify `ptype'.
13318
13319 2004-08-02  Bernie Solomon  <bernard@ugsolutions.com>
13320
13321         * cpu-sparc.md: fcall maximal length too small.
13322
13323 2004-08-02  Zoltan Varga  <vargaz@freemail.hu>
13324
13325         * mini-amd64.c mini.h: Add initial support for passing/returning 
13326         structures to/from pinvoked methods.
13327
13328 Mon Aug 2 11:59:35 PDT 2004 Paolo Molaro <lupus@ximian.com>
13329
13330         * mini-ppc.c: reg allocator fix.
13331
13332 2004-07-31  Zoltan Varga  <vargaz@freemail.hu>
13333
13334         * mini-amd64.c (mono_arch_output_basic_block): Fix OP_X86_PUSH_OBJ.
13335
13336         * inssel.brg: Optimize memset on 64 bit machines.
13337
13338         * mini-amd64.c: Fix some vararg cases.
13339
13340 2004-07-30  Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
13341
13342         * mini-s390.c: Corrected macro in emit_float_to_int
13343
13344         * s390-abi.cs: Tests to exercise the s390 ABI
13345
13346 2004-07-30  Zoltan Varga  <vargaz@freemail.hu>
13347
13348         * exceptions-amd64.c (mono_arch_find_jit_info): Fix restoring of
13349         caller saved regs.
13350
13351         * basic.cs: Add a test for add.ovf.un.
13352
13353 2004-07-30  Bernie Solomon  <bernard@ugsolutions.com>
13354
13355         * mini-sparc.c: add case for OP_IDIV_UN
13356
13357 2004-07-30  Zoltan Varga  <vargaz@freemail.hu>
13358
13359         * mini-amd64.c mini-amd64.h mini.c: Add support for vararg pinvoke calls.
13360         
13361         * mini-amd64.c cpu-amd64.md: Ongoing JIT work.
13362
13363 2004-07-30  Ben Maurer  <bmaurer@ximian.com>
13364
13365         * basic.cs: regression tests.
13366
13367         * inssel-x86.brg: Disable cmp BYTE PTR [eax], imm, it causes various
13368         regressions.
13369
13370 2004-07-30  Zoltan Varga  <vargaz@freemail.hu>
13371
13372         * basic.cs: Add a new test.
13373
13374         * mini-amd64.c aot.c cpu-amd64.md: Add support for tracing, profiling 
13375         and AOT. Various fixes and optimizations.
13376
13377         * inssel.brg (CALL_REG): Add 64 bit versions of call_reg rules.
13378
13379 Fri Jul 30 15:49:26 CEST 2004 Paolo Molaro <lupus@ximian.com>
13380
13381         * mini-ppc.c: make sure temp regs are not used for global reg
13382         allocation.
13383
13384 2004-07-29  Bernie Solomon  <bernard@ugsolutions.com>
13385
13386         * cpu-sparc.md: conv_i8 fix for 64bits
13387
13388         * mini-sparc.c: add cases for OP_IXXX codes for 64bits
13389
13390 2004-07-29  Ben Maurer  <bmaurer@ximian.com>
13391         
13392         * cpu-pentium.md, mini-x86.c, inssel-x86.brg, mini-ops.h:
13393         add opcode for cmp BYTE PTR [eax], imm.
13394
13395         * inssel.brg: Make memcpy and memset takes bases.
13396
13397 2004-07-28  Zoltan Varga  <vargaz@freemail.hu>
13398
13399         * *-amd64.*: More AMD64 work.
13400         
13401 2004-07-28  Ben Maurer  <bmaurer@ximian.com>
13402
13403         * cpu-pentium.md, inssel-x86.brg, mini-ops.h, mini-x86.c:
13404         add a compare-not-equal opcode.
13405         
13406 2004-07-28  Lluis Sanchez Gual  <lluis@novell.com>
13407
13408         * mini.c: Use mono_init_from_assembly instead of mono_init.
13409         
13410 2004-07-28  Zoltan Varga  <vargaz@freemail.hu>
13411
13412         * mini.c: Fix opcode mapping for STACK_MP on 64 bit platforms.
13413
13414         * mini.c (CEE_NEWOBJ): Call mono_array_new_va using the correct signature.
13415
13416         * mini.c: Use MONO_ARCH_SIGACTION on AMD64 as well.
13417
13418         * inssel.brg: 64 bit fixes.
13419
13420         * mini.h (MonoCallInst): Add some AMD64 specific data.
13421
13422         * mini.h: Add some OP_P opcodes.
13423
13424 2004-07-28  Ben Maurer  <bmaurer@ximian.com>
13425
13426         * basic.cs: tests for 61797 and 61740
13427
13428 Tue Jul 27 16:05:19 CEST 2004 Paolo Molaro <lupus@ximian.com>
13429
13430         * mini-ppc.c, mini-sparc.c, mini-s390.c: keep track of line
13431         numbers in the debug info (spotted by Geoff Norton, <gnorton@customerdna.com>).
13432
13433 2004-07-24  Zoltan Varga  <vargaz@freemail.hu>
13434
13435         * mini-sparc.c (mono_arch_output_basic_block): Add CEE_CONV_U8/I8.
13436
13437         * *-amd64*.*: Ongoing AMD64 work.
13438
13439 2004-07-23 Zoltan Varga <vargaz@freemail.hu>
13440
13441         * inssel-long.brg: Implement CONV_I8/CONV_U8 in the backends.
13442
13443         * *-amd64*: Ongoing AMD64 work.
13444
13445         * mini-arch.h: Add AMD64 support.
13446
13447         * mini-sparc.c (mono_arch_is_inst_imm): New arch dependent function.
13448
13449         * mini.h: Add new arch dependent function mono_arch_is_inst_imm.
13450
13451         * mini-ops.h: Add new opcodes.
13452
13453         * Makefile.am: Add AMD64 support.
13454
13455         * inssel.brg inssel-long32.brg inssel-long.brg: Move mul/div and shift
13456         rules into the inssel-long*.brg files.
13457
13458         * *-amd64.*: Add beginnings of AMD64 backend.
13459
13460 2004-07-22  Ben Maurer  <bmaurer@ximian.com>
13461
13462         * mini.c (print_dfn): commenting out the code that prints
13463         the cil. With -O=deadce, this makes -v -v crash.
13464         
13465         * cpu-pentium.md: make checkthis have a length of 2
13466
13467 2004-04-21  Bernie Solomon  <bernard@ugsolutions.com>
13468
13469         * mini-sparc.h: fix implementations of __builtin
13470         functions for Sun compiler for V9.
13471
13472 2004-07-16  Ben Maurer  <bmaurer@ximain.com>
13473
13474         * mini.c: use the new stelem.ref wrapper
13475         * exceptions.cs, arrays.cs: new stelem.ref tests
13476
13477 Wed Jul 14 19:08:41 CEST 2004 Paolo Molaro <lupus@ximian.com>
13478
13479         * mini-ppc.c, exceptions-ppc.c: cleanups and fixes (the
13480         new XSP should work with these changes).
13481
13482 2004-07-14  Ben Maurer  <bmaurer@ximain.com>
13483         
13484         * inssel-{long32,x86,}.brg: trivial optimizations.
13485         
13486 Mon Jul 12 20:25:57 CEST 2004 Paolo Molaro <lupus@ximian.com>
13487
13488         * mini.c: load value when emitting box operation in
13489         constrained calls.
13490
13491 2004-07-12  Ben Maurer  <bmaurer@ximian.com>
13492
13493         * mini-x86.c (OP_CHECK_THIS): cmp DWORD PTR [eax], eax
13494         is one byte shorter than cmp DWORD PTR [eax], 0.
13495
13496 Mon Jul 12 17:47:00 CEST 2004 Paolo Molaro <lupus@ximian.com>
13497
13498         * inssel-ppc.brg: arguments on the stack are always
13499         relative to the stack pointer (spotted by Neale Ferguson).
13500
13501 2004-07-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
13502
13503         * exceptions-x86.c: delay appending the method name to the trace until
13504         after mono_jit_info_table_find is called, as this gets the real
13505         MonoMethod.
13506
13507 2004-07-09  Ben Maurer  <bmaurer@ximian.com>
13508
13509         * aot.c: register roots
13510
13511 2004-07-09  Atsushi Enomoto  <atsushi@ximian.com>
13512
13513         * aot.c : I could just use PLATFORM_WIN32 flag.
13514
13515 2004-07-09  Atsushi Enomoto  <atsushi@ximian.com>
13516
13517         * aot.c : Reverting the previous fix. This time it broke linux build.
13518
13519 2004-07-09  Atsushi Enomoto  <atsushi@ximian.com>
13520
13521         * aot.c : quick cygwin build fix. mkdir() with two args does not exist.
13522
13523 2004-07-08  Zoltan Varga  <vargaz@freemail.hu>
13524
13525         * mini.c (handle_stack_args): Remove some more debugging code.
13526         
13527         * mini.c (handle_stack_args): Remove debug output left in by mistake.
13528
13529         * driver.c mini.h aot.c: Allow additional options to be specified with
13530         --aot and pass them to mono_compile_assembly.
13531
13532         * aot.c: Add experimental code to AOT compile all loaded assemblies
13533         on demand and save the code into a cache in the filesystem.
13534
13535         * aot.c: Add support for more wrapper methods.
13536         
13537         * mini.c (handle_stack_args): Handle some corner cases. Fixes 
13538         58863.
13539
13540         * cpu-*.md: Remove removed opcodes.
13541
13542         * mini.h mini.c: Move JIT icall handling to icall.c. Replace usage of
13543         CEE_MONO_PROC<x> with CEE_MONO_ICALL. Move registration of marshalling
13544         related icalls to marshal.c.
13545
13546 2004-07-06  Zoltan Varga  <vargaz@freemail.hu>
13547
13548         * mini-ops.h: Add OP_SAVE_LMF and OP_RESTORE_LMF.
13549
13550         * Makefile.am (EXTRA_DIST): Add inssel-long[32].brg.
13551
13552         * inssel.brg: Fix warning. Add rules for SAVE_LMF and RESTORE_LMF.
13553
13554 2004-07-06  Ben Maurer  <bmaurer@ximian.com>
13555         * liveness.c: If liveness is recomputated we need to reset the information
13556         for each variable. This way, if the liveness range has been narrowed
13557         by optimizations that happened after the last computation, we can return
13558         a smaller range.
13559         
13560         For example, if you have
13561         
13562         {
13563                 int i = 0;
13564                 
13565                 // Tons of code that does not affect i
13566                 
13567                 i = foo ();
13568                 ...
13569         }
13570         
13571         i = 0 is dead code and will be removed by SSA. However, when
13572         linear scan gets to the code, i will still appear to be live
13573         throughout the entire block. This prevents good register allocation.
13574
13575 2004-07-06  Martin Baulig  <martin@ximian.com>
13576
13577         * debug-mini.c (mono_debug_init_method): Allow
13578         MONO_WRAPPER_MANAGED_TO_NATIVE wrappers.
13579         (mono_debug_add_icall_wrapper): New method.
13580
13581         * mini.c (mono_icall_get_wrapper): Call mono_debug_add_icall_wrapper().
13582
13583 2004-07-05  Zoltan Varga  <vargaz@freemail.hu>
13584
13585         * mini.c (optimize_branches): Fix linking of bblocks in branch->branch
13586         optimization.
13587
13588 2004-07-03  Zoltan Varga  <vargaz@freemail.hu>
13589
13590         * aot.c (mono_aot_load_method): Fix loading of debug info.
13591
13592 2004-07-02  Zoltan Varga  <vargaz@freemail.hu>
13593
13594         * aot.c: Add logging support.
13595
13596 2004-07-01  Zoltan Varga  <vargaz@freemail.hu>
13597
13598         * mini.h: Add prototype for mono_print_method_from_ip.
13599
13600         * mini.c: 64 bit fixes. Use LCOMPARE for comparing longs.
13601
13602         * inssel.brg: 64 bit fixes.
13603
13604         * inssel.brg inssel-long32.brg: Move 32 bit arithmetic rules to 
13605         inssel-long32.brg.
13606
13607         * Makefile.am: Add SPARC64 support.
13608
13609 2004-07-02  Zoltan Varga  <vargaz@freemail.hu>
13610
13611         * aot.c: Fix alignment problems on 32 bit platforms.
13612
13613 2004-07-01  Zoltan Varga  <vargaz@freemail.hu>
13614
13615         * helpers.c (mono_disassemble_code): Pass -xarch=v9 to assembler on
13616         SPARC64.
13617
13618         * aot.c: Add SPARC64 support. Reorganize patch table to fix alignment
13619         problems.
13620
13621         * mini.h: Bump AOT file version. Some 64 bit fixes.
13622
13623 2004-06-30  Zoltan Varga  <vargaz@freemail.hu>
13624
13625         * inssel-sparc.brg: Add new rule to avoid register moves.
13626
13627         * inssel.brg: Add ldind_to_load_membase helper function.
13628
13629 2004-06-30  Ben Maurer  <bmaurer@ximian.com>
13630
13631         * mini.c: OffsetToStringData intrinsic.
13632         
13633 2004-06-30  Zoltan Varga  <vargaz@freemail.hu>
13634
13635         * ssa.c: Handle OP_LCOMPARE the same as OP_COMPARE.
13636
13637         * objects.cs exceptions.cs basic.cs basic-long.cs basic-calls.cs: New
13638         regression tests.
13639
13640         * mini-ops.h cpu-sparc.md mini-sparc.h mini-sparc.c exceptions-sparc.c tramp-sparc.c inssel-long.brg: Add SPARC64 support.
13641 Mon Jun 28 18:05:09 CEST 2004 Paolo Molaro <lupus@ximian.com>
13642
13643         * mini.c: reinstated mono_compile_get_interface_var()
13644         on x86, too, since the change breaks the Gtk# build there as well.
13645
13646 Fri Jun 25 17:36:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
13647
13648         * driver.c: remove loop from the default optimizations: it seems to
13649         interact badly with some of the other options (see bug #60613).
13650
13651 2004-06-25  Zoltan Varga  <vargaz@freemail.hu>
13652
13653         * mini.c mini-x86.h mini-x86.c: Applied patch from Guenter Feldmann 
13654         (fld@informatik.uni-bremen.de): Add Solaris x86 support.
13655
13656 Tue Jun 22 21:29:11 CEST 2004 Paolo Molaro <lupus@ximian.com>
13657
13658         * mini-ppc.c, cpu-g4.md: small updates to be able to compile
13659         vararg-using methods.
13660
13661 2004-06-21  Martin Baulig  <martin@ximian.com>
13662
13663         * mini/mini-exceptions.c
13664         (mono_handle_exception): Added `gpointer original_ip' argument.
13665         After calling mono_unhandled_exception(), call
13666         mono_debugger_unhandled_exception() and if that returns true,
13667         restore the context and return.
13668
13669 Mon Jun 21 19:26:40 CEST 2004 Paolo Molaro <lupus@ximian.com>
13670
13671         * mini-ppc.c: prefer the use of relative branches so
13672         they won't need to be patched in aot code (patch from Patrick Beard).
13673
13674 Mon Jun 21 19:03:18 CEST 2004 Paolo Molaro <lupus@ximian.com>
13675
13676         * aot.c: patch from Patrick Beard to make the output assembly
13677         more correct for the MacOSX assembler. Small tweak to
13678         generate sane images on Linux/PPC, too.
13679
13680 Fri Jun 18 18:24:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
13681
13682         * mini.c, mini.h, mini-ppc.c: handle varargs methods with a special
13683         case until bug #59509 is fixed (shows up in #60332).
13684
13685 Tue Jun 15 16:36:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
13686
13687         * mini.c: make sure the needed wrappers are compiled, too, with
13688         precomp.
13689
13690 Mon Jun 14 18:36:08 CEST 2004 Paolo Molaro <lupus@ximian.com>
13691
13692         * driver.c: remove NPTL reference in --version output.
13693
13694 Sun Jun 13 17:25:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
13695
13696         * aot.c: patch from Patrick Beard (pcbeard@mac.com) to
13697         generate valid assembly for the Mach-O assembler.
13698
13699 Sun Jun 13 15:59:38 CEST 2004 Paolo Molaro <lupus@ximian.com>
13700
13701         * driver.c: don't include abcrem in the all optimization specifier
13702         since it slows down jit compilation too much for now.
13703
13704 2004-06-12 Ben Maurer  <bmaurer@users.sourceforge.net>
13705
13706         * mini.c: use BIGMUL only if both operands have the same signage.
13707         * iltests.il: Test for bug 60056. (errors related to signage in
13708         BIGMUL).
13709
13710         r=lupus.
13711
13712 Thu Jun 10 16:06:42 CEST 2004 Paolo Molaro <lupus@ximian.com>
13713
13714         * mini.c, aot.c: memory leak fixes.
13715
13716 Tue Jun 8 16:37:15 CEST 2004 Paolo Molaro <lupus@ximian.com>
13717
13718         * inssel-long32.brg: implemented a few missing ulong cast opcodes.
13719
13720 Tue Jun 8 15:36:30 CEST 2004 Paolo Molaro <lupus@ximian.com>
13721
13722         * Makefile.am: remove the -static hack completely, it links in
13723         statically glib as well.
13724
13725 Sat Jun 5 16:32:33 CEST 2004 Paolo Molaro <lupus@ximian.com>
13726
13727         * iltests.il, mini.c: fixed bug#59580 in branch optimization.
13728         * exceptions.cs: make it compile with new mcs/csc.
13729
13730 2004-06-03 Massimiliano Mantione <massi@ximian.com>
13731         * cpu-pentium.md basic-float.cs Fixed bug on fpu spills (see bug 54467),
13732         and added relevant test case.
13733
13734 Mon May 31 19:41:46 CEST 2004 Paolo Molaro <lupus@ximian.com>
13735
13736         * mini.c revert Zoltan's fix to bug#58863 on ppc, since it causes
13737         regressions in gtk-sharp.
13738
13739 2004-05-29  Zoltan Varga  <vargaz@freemail.hu>
13740
13741         * exceptions.cs: New regression tests.
13742
13743         * jit-icalls.c (mono_llmult_ovf): Fix some boundary conditions.
13744
13745 Sat May 29 10:45:58 CEST 2004 Paolo Molaro <lupus@ximian.com>
13746
13747         * mini.c: emit castclass/isinst in their own trees (bug #54209/59057).
13748
13749 2004-05-28  Zoltan Varga  <vargaz@freemail.hu>
13750
13751         * mini-sparc.h (MONO_ARCH_NEED_DIV_CHECK): Define this.
13752
13753         * cpu-sparc.md mini-sparc.c: Add overflow detection to div opcodes.
13754
13755 2004-05-28      Patrik Torstensson <totte@hiddenpeaks.com>
13756
13757         * mini.c (mono_jit_runtime_invoke): Init class in this
13758         method instead of trusting mono_jit_compile_method to
13759         do the work (because wrappers can be in object class)
13760
13761 2004-05-27  Zoltan Varga  <vargaz@freemail.hu>
13762
13763         * mini-sparc.c (mono_arch_output_basic_block): Fix sub.imm.
13764
13765         * basic-long.cs: New regression test.
13766
13767 Thu May 27 15:50:52 CEST 2004 Paolo Molaro <lupus@ximian.com>
13768
13769         * cpu-g4.md, mini-ppc.c: fixes to long add/sub ovf opcodes
13770         and div/rem checks.
13771
13772 Thu May 27 12:36:53 CEST 2004 Paolo Molaro <lupus@ximian.com>
13773
13774         * Makefile.am: fix miguel's change to build mono statically against
13775         libmono (track build dependencies).
13776
13777 2004-05-26  Zoltan Varga  <vargaz@freemail.hu>
13778
13779         * cfold.c: Some glib versions do not have G_MININT32.
13780
13781 2004-05-26  Massimiliano Mantione  <massi@ximian.com>
13782
13783         * mini-x86.c cpu-pentium.md Makefile.am basic-math.cs: Fixed problem
13784         with precision of tan, atan, sin and cos, and implemented related
13785         regressions tests (fixes bug 54467, but one new problem appeared and
13786         is not fixed yet).
13787
13788 2004-05-26  Zoltan Varga  <vargaz@freemail.hu>
13789
13790         * cfold.c (FOLD_BINOPZ): Avoid division by zero.
13791
13792         * exceptions.cs: Add test for constant folding && division by zero.
13793
13794         * driver.c mini.h mini.c mini-x86.c: Revert most of the previous patch
13795         since driver.c is in libmono too, so the optimization was useless.
13796
13797         * driver.c mini.h mini.c mini-x86.c: Moved the mono_lmf_addr TLS 
13798         variable to driver.c so the compiler can emit more efficient code to
13799         access them.
13800
13801 2004-05-26  Gonzalo Paniagua Javier <gonzalo@ximian.com>
13802
13803         * Makefile.am: don't distribute generated inssel.[ch] files.
13804
13805 2004-05-25  Zoltan Varga  <vargaz@freemail.hu>
13806
13807         * mini.c (mono_jit_compile_method_with_opt): Really emit icall wrappers
13808         into the default appdomain. Fixes #58707.
13809
13810         * jit-icalls.c: Remove the broken approximation for truncl, doing
13811         no conversion is better.
13812
13813         * mini.c (handle_stack_args): Avoid reusing variables for stack slots.
13814         Fixes #58863.
13815
13816 Tue May 25 14:33:56 CEST 2004 Paolo Molaro <lupus@ximian.com>
13817
13818         * mini-ops.h, mini-ppc.c, cpu-g4.md, inssel-ppc.brg: eliminate the use
13819         of the mcrxr instruction which is not available on some processors
13820         even if it's documented to be. Implement add and sub overflow correctly
13821         (still not complete for long unsigned). Speed up icalls a bit.
13822
13823 2004-05-25 13:01 CET Patrik Torstenson <totte@hiddenpeaks.com>
13824
13825         * mini.c (mono_jit_compile_method_with_opt): Make sure that
13826         we run .cctor in the current domain instead of target_domain.
13827         
13828         Fixes bug #58558, .cctor not being called in -O=shared.
13829
13830 Tue May 25 12:46:50 CEST 2004 Paolo Molaro <lupus@ximian.com>
13831
13832         * mini-ppc.h, jit-icalls.c: added explicit checks for divide by zero.
13833
13834 2004-05-24 Ben Maurer  <bmaurer@users.sourceforge.net>
13835
13836         * mini-x86.c (EMIT_COND_BRANCH): If an OP_LABEL has an offset
13837         which can be done with an imm8, do it that way.
13838         (mono_arch_output_basic_block): ditto for a jmp
13839         (mono_arch_emit_prolog): Computate maximum offset of a label.
13840
13841 2004-05-24 18:18 CET Patrik Torstenson <totte@hiddenpeaks.com>
13842
13843         * mini-x86.c (mono_arch_local_regalloc): the reg allocator
13844         now tries to allocate prefered physical reg's for virtual
13845         regs. This reduces the number of emited spills/loads with
13846         20-30% on our core assemblies.
13847
13848 Mon May 24 18:21:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
13849
13850         * jit-icalls.c: truncl() is not needed and trunc() is
13851         the correct thing to do anyway (bug #58287).
13852
13853 2004-05-24  Zoltan Varga  <vargaz@freemail.hu>
13854
13855         * mini-sparc.c (mono_arch_flush_icache): Call sync_instruction_memory
13856         if available.
13857
13858 Mon May 24 12:49:45 CEST 2004 Paolo Molaro <lupus@ximian.com>
13859
13860         * driver.c: enable loop optimizations by default.
13861
13862 Mon May 24 11:13:46 CEST 2004 Paolo Molaro <lupus@ximian.com>
13863
13864         * mini-x86.c: fix calc of max loop size when aligning loops start.
13865
13866 2004-05-23  Zoltan Varga  <vargaz@freemail.hu>
13867
13868         * ssa.c (mono_ssa_cprop): Allocate carray dynamically instead of on
13869         the stack.
13870
13871 2004-05-22  Zoltan Varga  <vargaz@freemail.hu>
13872
13873         * mini-sparc.c (mono_arch_output_basic_block): ADD_IMM and SUB_IMM
13874         should set carry.
13875
13876         * basic-long.cs: Add tests for add/subtract of immediates with carry.
13877
13878         * mini.c exceptions-x86.c: Remove MONO_USE_EXC_TABLES stuff.
13879         
13880         * mini.c (inline_method): Allways inline some wrappers even if the cost
13881         is too large. Fixes #58785.
13882
13883         * mini.c: Add support for MARSHAL_CONV_FTN_DEL.
13884         
13885 2004-05-21  Zoltan Varga  <vargaz@freemail.hu>
13886
13887         * mini-sparc.c exceptions-sparc.c: Applied patch from Mark Crichton
13888         (crichton@gimp.org). Beginning of support for sparc/linux.
13889
13890         * mini-sparc.c: Optimize retrieval of LMF address.
13891
13892 Fri May 21 08:00:12 EDT 2004 Paolo Molaro <lupus@ximian.com>
13893
13894         * exceptions-ppc.c:  handle alloca in methods with clauses.
13895
13896 Fri May 21 07:35:30 EDT 2004 Paolo Molaro <lupus@ximian.com>
13897
13898         * mini-ppc.c: cleanups, off-by-one fixes, avoid recursive thunks.
13899
13900 2004-05-20  Lluis Sanchez Gual  <lluis@ximian.com>
13901
13902         * mini.c: Delegate most of the abort signal work to 
13903           mono_thread_request_interruption, which also handles Stop and Suspend
13904           states.
13905
13906 2004-05-20  Zoltan Varga  <vargaz@freemail.hu>
13907
13908         * mini.c mini.h: Allow inlining of icall wrappers if the backend 
13909         supports the save/restore lmf opcodes.
13910
13911 2004-05-19  Zoltan Varga  <vargaz@freemail.hu>
13912
13913         * mini-x86.c (mono_arch_setup_jit_tls_data): Handle code generated
13914         by gcc-3.4 as well.
13915
13916         * mini-x86.h mini-x86.c tramp-x86.c: Optimize lmf restoring code.
13917
13918 2004-05-18  Zoltan Varga  <vargaz@freemail.hu>
13919
13920         * mini.h mini.c (mini_method_compile): Only run abc removal pass on 
13921         methods which contain array accesses.
13922
13923         * mini.c (CEE_LDTOKEN): Handle this instruction correctly on bb
13924         boundaries. Fixes #58537.
13925
13926         * iltests.il: Add regression test for #58537.
13927
13928 2004-05-18  Patrik Torstensson <totte@hiddenpeaks.com>
13929
13930         * mini-x86.c (mono_arch_local_regalloc): Last part of
13931         fix for bug #58633 (releasing register to early).
13932
13933 2004-05-18  Miguel de Icaza  <miguel@ximian.com>
13934
13935         * basic-long.cs: Add new regression test.
13936
13937 2004-05-18  Patrik Torstensson <totte@hiddenpeaks.com>
13938
13939         * mini-x86.c (mono_arch_local_regalloc): Avoid releasing a
13940         register too early on the chain.
13941
13942 2004-05-18  Zoltan Varga  <vargaz@freemail.hu>
13943
13944         * mini.c (create_helper_signature): Use a helper function to reduce
13945         the code which needs to be written. Also set the calling convention of
13946         icalls on windows. Fixes #57840.
13947
13948 Tue May 18 11:05:18 CEST 2004 Paolo Molaro <lupus@ximian.com>
13949
13950         * mini.h, exceptions-x86.c, exceptions-sparc.c, exceptions-s390.c,
13951         exceptions-ppc.c: added helper function to get the instruction address
13952         from a signal handler context.
13953
13954 2004-05-17 Ben Maurer  <bmaurer@users.sourceforge.net>
13955
13956         * helpers.c: use g_get_tmp_dir. Invokes happyness 
13957         from gonzalo.
13958
13959 2004-05-17 Ben Maurer  <bmaurer@users.sourceforge.net>
13960
13961         * helpers.c: Add new env variable to pass args to objdump.
13962         Specifically for those of us who love -Mintel. r=miguel, gonzalo.
13963
13964 2004-05-17  Radek Doulik  <rodo@ximian.com>
13965
13966         * Makefile.am (common_sources): added abcremoval.h so it get
13967         disted and daily mono packages on go-mono.com will build again
13968
13969 2004-05-17  Massimiliano Mantione  <massi@ximian.com>
13970
13971         * abcremoval.c: Fixed coding style, added copyright header.
13972
13973         * abcremoval.h: Fixed style and moved prototype to mini.h, added copyright header.
13974
13975         * mini.h: Added prototype for abc removal main function.
13976
13977         * build_relations_propagation_table.pl: Added copyright header.
13978
13979 2004-05-16      Patrik Torstensson <totte@hiddenpeaks.com>
13980
13981         * basic-long.cs: reg test for complex ceq_long bug.
13982
13983 2004-05-16      Patrik Torstensson <totte@hiddenpeaks.com>
13984
13985         * mini-x86.c (mono_arch_local_regalloc): Correctly free 
13986         reg in long and clob case (bug #58343). Fixed/added comments.
13987
13988 2004-05-14 Ben Maurer  <bmaurer@users.sourceforge.net>
13989
13990         * mini.c (mono_jit_runtime_invoke): Follow new convention
13991         of calling the invoke method with an function pointer.
13992
13993 2004-05-14  Zoltan Varga  <vargaz@freemail.hu>
13994
13995         * ChangeLog: Fix author of memory leak patch.
13996
13997 Fri May 14 15:13:06 CEST 2004 Paolo Molaro <lupus@ximian.com>
13998
13999         * Makefile.am: fix make dist as well...
14000
14001
14002 2004-05-14  Massimiliano Mantione  <massi@ximian.com>
14003
14004         * cfold.c: Made so that conversions from pointer to int4 are no-ops
14005         on archs where pointers are 4 bytes long.
14006
14007         * Makefile.am: Added abcremoval.c source file.
14008
14009         * abcremoval.c: Added abcremoval.c.
14010
14011         * abcremoval.h: Added abcremoval.h.
14012
14013         * build_relations_propagation_table.pl: Added build_relations_propagation_table.pl.
14014
14015         * inssel.brg: Enabled bounds check removal.
14016
14017         * mini.c: Added support for abcrem optimization.
14018
14019         * mini.h: Added abcrem optimization label.
14020
14021         * driver.c: Added support for abcrem optimization.
14022
14023         * propagated_relations_table.def: Added propagated_relations_table.def.
14024
14025 Fri May 14 14:30:13 CEST 2004 Paolo Molaro <lupus@ximian.com>
14026
14027         * mini.c, cfold.c: fix style.
14028
14029 Fri May 14 14:28:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
14030
14031         * mini.c: handle issue with the low-level implementation of
14032         some long opcodes (bug #54209).
14033
14034 2004-05-13 Ben Maurer  <bmaurer@users.sourceforge.net>
14035
14036         * basic.cs: test for my new cmov stuff.
14037
14038 2004-05-13      Patrik Torstensson
14039
14040         * mini-x86.c: added OP_X86_COMPARE_MEMBASE_IMM peephole
14041         opt and added peephole documentation.
14042
14043 Thu May 13 11:41:49 CEST 2004 Paolo Molaro <lupus@ximian.com>
14044
14045         * tramp-ppc.c: rewrote the generic trampoline code.
14046
14047 2004-05-11      Patrik Torstensson
14048
14049         * mini-x86.c: optimize long shl/shr asm code (one less branch)
14050
14051 2004-05-11  Zoltan Varga  <vargaz@freemail.hu>
14052
14053         * basic.cs basic-long.cs objects.cs: Make these compile under MS csc.
14054
14055         * mini.h mini.c dominators.c: Applied patch from Derek Woo
14056         (derek@eecg.toronto.edu): Fix memory leaks in loop optimizations.
14057
14058         * mini.c: Add new icalls for AsAny marshalling.
14059
14060 Tue May 11 16:00:38 CEST 2004 Paolo Molaro <lupus@ximian.com>
14061
14062         * tramp-ppc.c, mini-ppc.c: more cleanups.
14063
14064 2004-05-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
14065
14066         * mini.c: no warnings.
14067
14068 Tue May 11 13:59:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
14069
14070         * mini-ppc.c, mini.c: use mono_resolve_patch_target ().
14071
14072 2004-05-11  Lluis Sanchez Gual  <lluis@ximian.com>
14073
14074         * mini.c: In the thread abort signal handler, if the thread is in the
14075         process of being stoped, don't throw the Abort exception, just stop the
14076         thread.
14077
14078 Tue May 11 12:15:24 CEST 2004 Paolo Molaro <lupus@ximian.com>
14079
14080         * tramp-ppc.c: removed old code.
14081
14082 Tue May 11 12:02:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
14083
14084         * mini.h, mini-ppc.c, cfold.c: export mono_is_power_of_two().
14085         do some simple speed optimizations on ppc.
14086
14087 Mon May 10 17:21:00 CEST 2004 Paolo Molaro <lupus@ximian.com>
14088
14089         * mini-ppc.c, cpu-g4.md: fixes to handle large stack frames
14090         and large offsets in load/store.
14091
14092 2004-05-07  Zoltan Varga  <vargaz@freemail.hu>
14093
14094         * mini-x86.c (mono_arch_local_regalloc): Remove the previous fix, since
14095         it causes regressions.
14096
14097 2004-05-07  Zoltan Varga  <vargaz@freemail.hu>
14098
14099         * mini-sparc.c: Fix vararg support + add beginnings of sigaltstack
14100         support.
14101
14102 Fri May 7 13:25:50 CEST 2004 Paolo Molaro <lupus@ximian.com>
14103
14104         * jit-icalls.c: remove warnings.
14105         * inssel-x86.brg, inssel.brg, mini-x86.c, cfold.c: some simple
14106         speedups for unsafe code.
14107
14108 2004-05-07 Ben Maurer  <bmaurer@users.sourceforge.net>
14109
14110         * inssel.brg: Optimize Stind.[ui][12]. r=zoltan.
14111
14112 2004-05-06  Zoltan Varga  <vargaz@freemail.hu>
14113
14114         * basic-calls.cs: Add new regression test.
14115
14116         * mini.c (mono_runtime_install_handlers): Use SA_ONSTACK since it is
14117         more portable.
14118
14119         * mini.c (mono_method_to_ir): Handle opcode emulation for *_OVF opcodes.
14120
14121         * mini-x86.c (mono_arch_local_regalloc): Free new_dest register when it
14122         is no longer used.
14123
14124 2004-05-06      Patrik Torstensson
14125
14126         * mini-x86.[c|h], inssel-x86.brg, cpu-pentium.md, mini.c: enabled
14127         long reg allocation in any reg (not only eax:edx) and implemented 
14128         long shl/shr ops in asm instead of helpers.
14129
14130 2004-05-05  Zoltan Varga  <vargaz@freemail.hu>
14131
14132         * mini-sparc.h: Fix warnings.
14133
14134         * exceptions-sparc.c (mono_arch_find_jit_info): Pop unused lfm off the
14135         stack.
14136
14137         * mini-exceptions.c (mono_handle_exception): Call the filter in a
14138         separate statement for clarity.
14139
14140         * mini-sparc.c: Update status.
14141
14142 2004-05-04  Zoltan Varga  <vargaz@freemail.hu>
14143
14144         * mini-exceptions.c (ves_icall_get_frame_info): Flush register windows
14145         here.
14146
14147 Mon May 3 22:58:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
14148
14149         * inssel-ppc.brg: another small pre-release workaround:
14150         we don't do overflow detection for long_sub_un.
14151
14152 Sun May 2 20:12:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
14153
14154         * mini.c, mini-ops, inssel-long32.brg: speedup ulong >> 32
14155         (also works around a weird ppc bug: 57957).
14156
14157 Sat May 1 16:56:10 EDT 2004 Paolo Molaro <lupus@ximian.com>
14158
14159         * tramp-ppc.c: trampoline fixes.
14160
14161 Fri Apr 30 15:54:26 EDT 2004    Paolo Molaro <lupus@ximian.com>
14162
14163         * mini-ppc.c: fixed typos.
14164
14165 Thu Apr 29 20:15:41 CEST 2004 Paolo Molaro <lupus@ximian.com>
14166
14167         * mini-ppc.c, exceptions-ppc.c: more code saves registers
14168         at the top of the stack. Fixed typos. Use a frame registers
14169         for all the methods with exception clauses.
14170
14171 Thu Apr 29 18:52:09 CEST 2004 Paolo Molaro <lupus@ximian.com>
14172
14173         * exceptions-ppc.c: restore fp registers.
14174
14175 Thu Apr 29 18:26:56 CEST 2004 Paolo Molaro <lupus@ximian.com>
14176
14177         * mini-ppc.c, exceptions-ppc.c: save the registers in reverse
14178         order from the stack top (moved the stack room to save the
14179         return value for trace after the param area). Fixed corruption
14180         in restoring registers on unwind.
14181
14182 Thu Apr 29 16:47:15 CEST 2004 Paolo Molaro <lupus@ximian.com>
14183
14184         * mini-ppc.c, cpu-g4.md: fixed unisgned -> double conversion.
14185
14186 Thu Apr 29 13:50:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
14187
14188         * exceptions-ppc.c, mini-ppc.h, mini-ppc.c: fixed localloc
14189         and prolog/epilog for methods that use it. Allow
14190         enough param area room for varargs methods. Fix miguel's
14191         breakage in exception handling.
14192
14193 Thu Apr 29 12:06:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
14194
14195         * Makefile.am: run genmdesc only on current arch.
14196
14197 2004-04-29  Gonzalo Paniagua Javier <gonzalo@ximian.com>
14198
14199         * exceptions-x86.c:
14200         * mini-x86.h: fix the build on windows.
14201
14202 2004-04-28  Zoltan Varga  <vargaz@freemail.hu>
14203
14204         * 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.
14205
14206         * exceptions-sparc.c exceptions-ppc.c exceptions-s390.c mini-ppc.h mini-s390.h mini-sparc.h: Fix up ports after changes.
14207
14208         * mini-exceptions.c: New file.
14209         
14210         * mini.c mini-exceptions.c mini-x86.h exceptions-x86.c Makefile.am:
14211         Move some parts of the x86 exception handling code to an 
14212         arch-independent file so it can be shared with other ports.
14213
14214 Tue Apr 27 12:15:59 CEST 2004 Paolo Molaro <lupus@ximian.com>
14215
14216         * trace.c, cpu-g4.md, inssel-ppc.brg, mini-ppc.c: some fixes for FP code.
14217
14218 2004-04-26  David Waite  <mass@akuma.org>
14219
14220         * driver.c: remove comma from end of enumeration declaration
14221
14222 2004-04-26  Jackson Harper  <jackson@ximian.com>
14223
14224         * driver.c: parse config file before loading first assembly. This
14225         allows the user gac to be enabled/disabled. 
14226         
14227 2004-04-23  Miguel de Icaza  <miguel@ximian.com>
14228
14229         * mini-ppc.c (ppc_patch): Replaced the branch code patching with a
14230         simpler mechanism: we do not care what is encoded initially
14231         (branch absolute or relative), we care about the code and its
14232         target.  I kept the old code for reference for now.
14233
14234         The new code tries first to determine if the jump is anywhere in
14235         the -/+32 absolute meg range, if it succeeds, it encodes using the
14236         absolute branch;  If not, it tried to find something in the
14237         relative range, if not, it uses the handle_thunk code. 
14238
14239 Fri Apr 23 14:20:40 EDT 2004 Paolo Molaro <lupus@ximian.com>
14240
14241         * exceptions-ppc.c: use the correct ip register on macosx.
14242
14243 Thu Apr 22 13:23:16 EDT 2004 Paolo Molaro <lupus@ximian.com>
14244
14245         * exceptions.c, mini.c, mini-ppc.h: adapt code to macosx.
14246
14247 Thu Apr 22 18:08:37 CEST 2004 Paolo Molaro <lupus@ximian.com>
14248
14249         * mini-ppc.c, cpu-g4.md: made the branch macros more flexible.
14250         Raise exception on integer divide by zero by hand since the hw
14251         doesn't support it. Handle NaNs in FP compares.
14252
14253 Thu Apr 22 16:10:31 CEST 2004 Paolo Molaro <lupus@ximian.com>
14254
14255         * exceptions-ppc.c, mini-ppc.h, mini.c: simplified some
14256         code reducing duplication between the platforms and enabled
14257         signal exception handling (on linux for now).
14258
14259 Wed Apr 21 12:27:48 EDT 2004 Paolo Molaro <lupus@ximian.com>
14260
14261         * exceptions-ppc.c: more macosx support.
14262
14263 Wed Apr 21 16:38:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
14264
14265         * mini-ppc.h, mini-ppc.c, cpu-g4.md: enable bigmul optimization.
14266
14267 Wed Apr 21 16:20:32 CEST 2004 Paolo Molaro <lupus@ximian.com>
14268
14269         * mini.h, mini-ppc.c, cpu-g4.md: support for implicit exceptions.
14270
14271 2004-04-19 Ben Maurer  <bmaurer@users.sourceforge.net>
14272
14273         * iltests.il: more tests.
14274
14275 2004-04-19  Zoltan Varga  <vargaz@freemail.hu>
14276
14277         * mini-*.c (mono_arch_get_allocatable_int_vars): Skip written-only
14278         vars as well.
14279
14280 Mon Apr 19 19:39:47 CEST 2004 Paolo Molaro <lupus@ximian.com>
14281
14282         * mini-ppc.c: some fixes to bootstrap mcs/corlib/etc.
14283
14284 2004-04-19  Zoltan Varga  <vargaz@freemail.hu>
14285
14286         * liveness.c: Mark variables as volatile in all basic blocks reachable
14287         from exception clauses.
14288
14289 2004-04-18  Zoltan Varga  <vargaz@freemail.hu>
14290
14291         * exceptions.cs (test_0_rethow_stacktrace): Make this work with
14292         inlining.
14293
14294 2004-04-18 Ben Maurer  <bmaurer@users.sourceforge.net>
14295
14296         * iltests.il, basic.cs: more tests for regalloc.
14297
14298 2004-04-17 Ben Maurer  <bmaurer@users.sourceforge.net>
14299
14300         * iltests.il: Some tests for register allocation modifications
14301         I have locally.
14302
14303 2004-04-16  Zoltan Varga  <vargaz@freemail.hu>
14304
14305         * exceptions.cs: Add regression test for bug #56782.
14306
14307         * exceptions-*.c (mono_arch_handle_exception): Do not overwrite the
14308         original stack trace if an exception is rethrown. Fixes #56782. Oh,
14309         the beauty of fixing the same thing in 5 different files...
14310
14311 2004-04-15  Zoltan Varga  <vargaz@freemail.hu>
14312
14313         * mini.c (mono_method_to_ir): Do not compute coverage for inlined
14314         methods.
14315
14316 2004-04-14  Zoltan Varga  <vargaz@freemail.hu>
14317
14318         * mini.c: Add support for STRWLPARRAY marshalling convention.
14319
14320 Wed Apr 14 18:15:55 CEST 2004 Paolo Molaro <lupus@ximian.com>
14321
14322         * exceptions-ppc.c: missing fixes in mono_jit_walk_stack (need
14323         to init the context to setup the regs pointer).
14324
14325 Wed Apr 14 17:59:09 CEST 2004 Paolo Molaro <lupus@ximian.com>
14326
14327         * exceptions-ppc.c: more exceptions work.
14328
14329 Wed Apr 14 17:46:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
14330
14331         * mini.c: avoid reusing the same MonoInst on multiple trees: this is
14332         not allowed.
14333
14334 2004-04-13  Miguel de Icaza  <miguel@ximian.com>
14335
14336         * inssel-x86.brg (reg): Add new rules for add, sub and mul that
14337         can use the memory directly.
14338
14339         * cpu-pentium.md: Update documentation from a post from Zoltan. 
14340
14341         add x86_add_membase, x86_sub_membase, x86_mul_membase
14342
14343 2004-04-13  Miguel de Icaza  <miguel@ximian.com>
14344
14345         * mini-ppc.c: Remove unused definitions FLOAT_REGS and
14346         GENERAL_REGS they were also hardcoded for all PPC ports.
14347
14348         (add_general): Use PPC_NUM_REG_ARGS instead of GENERAL_REGS.
14349
14350         Remove hard-coded limit for floating point registers, use
14351         PPC_LAST_FPARG_REG instead in MONO_TYPE_R4 and MONO_TYPE_R8.
14352
14353         Notice that in MacOS X calling conventions you can fit a lot more
14354         floating point values in registers, so I should update the PInvoke
14355         test to excercise the passing of floating point values on the
14356         stack (currently broken).
14357         
14358 2004-04-06  Miguel de Icaza  <miguel@ximian.com>
14359
14360         * tramp-ppc.c (create_trampoline_code): Added
14361         JUMP_TRAMPOLINE_SIZE. 
14362         (ppc_magic_trampoline): Follow the pattern from
14363         x86_magic_trampoline: if code is set to zero, return. 
14364         (create_trampoline_code): Always pass MonoMethod to the jump
14365         trampoline, before it was passing a null.
14366         (mono_arch_create_jump_trampoline): Implement the jump stub, could
14367         share the code with mono_arch_create_jit_trampoline. 
14368
14369         * mini-ppc.c (mono_arch_output_basic_block): CEE_JMP opcode
14370         implemented.
14371         (mono_arch_patch_code): MONO_PATCH_INFO_METHOD_JUMP patch type
14372         implemented.  
14373
14374         * cpu-g4.md: Added length for jmp instruction, the worst case
14375         scenario is 92 bytes (4 mandatory bytes, potential 19 registers
14376         for save_lmf).
14377
14378 2004-04-08  Zoltan Varga  <vargaz@freemail.hu>
14379
14380         * aot.c (mono_compile_assembly): Add back unlink removed by mistake.
14381
14382 2004-04-07  Zoltan Varga  <vargaz@freemail.hu>
14383
14384         * mini.c: Only set bblock->real_offset when adding a new bblock, and
14385         before each IL instruction.
14386
14387         * mini.c (CEE_BOX): Fix warnings.
14388
14389 2004-04-07  Gonzalo Paniagua Javier <gonzalo@ximian.com>
14390
14391         * mini.c: removed a few unused vars and extra whitespace.
14392
14393 2004-04-05 Ben Maurer  <bmaurer@users.sourceforge.net>
14394
14395         * inssel.brg (MONO_EMIT_BOUNDS_CHECK): a new macro to emit bounds
14396         checks.
14397         (MONO_EMIT_BOUNDS_CHECK_IMM): the above, but when you know the
14398         index.
14399         (OP_GETCHR): use the above
14400         (CEE_LDELEMA): use the above.
14401
14402         * inseel-x86.brg (MONO_EMIT_BOUNDS_CHECK): a faster and smaller
14403         version of the generic impl.
14404         (MONO_EMIT_BOUNDS_CHECK_IMM): the same
14405         (CEE_LDELEMA): use the above.
14406
14407 2004-04-05  Zoltan Varga  <vargaz@freemail.hu>
14408
14409         * inssel-long32.brg (CEE_CONV_OVF_I8): Sign extend the i4 value to i8.
14410         Fixes #56317.
14411
14412         * iltests.il: Added new regression test for #56317.
14413
14414 2004-04-05  Zoltan Varga  <vargaz@freemail.hu>
14415
14416         * mini-x86.c (mono_arch_setup_jit_tls_data): Use pthread_attr_get_np
14417         under NetBSD. Fixes #56450.
14418
14419         * liveness.c (update_gen_kill_set): Fix previous patch.
14420
14421 2004-04-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
14422
14423         * mini-x86.h: SA_STACK defined as SA_ONSTACK. Fixed build under NetBSD.
14424
14425 2004-04-02  Zoltan Varga  <vargaz@freemail.hu>
14426
14427         * mini.c (mono_method_to_ir): Avoid handle_loaded_temps in
14428         ldsfld and ldsflda.
14429
14430         * inssel-sparc.brg: Add more optimizations.
14431
14432         * mini-sparc.c: Replace multiply/divide with shifts if possible.
14433
14434 2004-04-01  Martin Baulig  <martin@ximian.com>
14435
14436         * mini.c (handle_box): New static function; moved the
14437         implementation of CEE_BOX here.
14438         (mono_method_to_ir): Added `constrained_call' variable.
14439         (mono_method_to_ir:CEE_CONSTRAINED_): Set it.
14440         (mono_method_to_ir:CEE_CALL): If `constrained_call' is set, use
14441         mono_method_get_constrained() to get the method.
14442
14443 2004-04-01  Martin Baulig  <martin@ximian.com>
14444
14445         * mini.c (TYPE_PARAM_TO_TYPE, TYPE_PARAM_TO_CLASS): Removed.
14446         (MTYPE_PARAM_TO_TYPE, MTYPE_PARAM_TO_CLASS): Removed.
14447         (mono_method_to_ir): We don't need these macros anymore since
14448         mono_class_get_full() already takes care of it. 
14449
14450 2004-03-31  Gonzalo Paniagua Javier <gonzalo@ximian.com>
14451
14452         * aot.c: set aot_verbose to 0, fixed format string that caused sigsegv,
14453         use @function (as doesn't accept #function here) and check the return
14454         value of system and stop if fails.
14455
14456 2004-03-31  Gonzalo Paniagua Javier <gonzalo@ximian.com>
14457
14458         * mini.c: set the timeout to 2s when calling mono_domain_finalize.
14459
14460 2004-03-31  Zoltan Varga  <vargaz@freemail.hu>
14461
14462         * mini-ppc.c (mono_arch_patch_code): Fix ppc build.
14463
14464         * inssel-sparc.brg mini-sparc.c aot.c: Implement AOT support.
14465
14466         * inssel-long32.brg (OP_LNEG): Use ADC instead of ADD here. Fixes
14467         #56223.
14468
14469         * basic-long.cs: Add test for negation of Int64.MinValue.
14470
14471 2004-03-30  Zoltan Varga  <vargaz@freemail.hu>
14472
14473         * mini-sparc.c: Update status.
14474
14475         * mini-sparc.c tramp-sparc.c: Save lmf in trampolines.
14476
14477         * exceptions-sparc.c: Fix return value in filters.
14478
14479         * inssel-sparc.brg: Fix register allocation in some rules.
14480
14481 2004-03-28  Martin Baulig  <martin@ximian.com>
14482
14483         * mini.c (mmono_method_to_ir): In CEE_STELEM, do a handle_stobj()
14484         if neccessary.  
14485
14486 2004-03-28  Zoltan Varga  <vargaz@freemail.hu>
14487
14488         * mini-x86.c (mono_arch_patch_code): Fix warnings.
14489         
14490         * mini-x86.c (mono_arch_output_basic_block): Fix CEE_MUL_OVF_UN if 
14491         dreg is not EAX. Thanks to Willibard Krenn for spotting this. Also
14492         remove unused conv_u4 opcode.
14493
14494         * mini-x86.c: Remove valgrind workaround since it slows down things
14495         even when mono is not run under valgrind.
14496
14497 2004-03-26  Zoltan Varga  <vargaz@freemail.hu>
14498
14499         * mini-sparc.c: Update status.
14500
14501         * inssel-sparc.brg: Add some optimizations.
14502
14503         * inssel-sparc.brg mini-sparc.c: Rework branch instructions to allow
14504         future delay slot filling. Add support for varargs, tail calls and JMP.
14505
14506         * inssel.brg mini-ops.h mini.c: Use OP_REFANYTYPE instead of 
14507         CEE_REFANYTYPE, since CEE_REFANYTYPE needs a prefix to be unique.
14508
14509         * inssel.brg: Fix register allocation in OP_ARGLIST.
14510
14511         * inssel.brg: Fix warnings.
14512
14513 2004-03-25  Martin Baulig  <martin@ximian.com>
14514
14515         * mini.c (inflate_generic_field): Removed.
14516         (mini_get_method): Removed, use mono_get_method_full(),
14517         (mini_get_class): Removed, use mono_class_get_full().
14518         (mono_method_to_ir): Pass our generic context to
14519         mono_field_from_token().        
14520
14521 2004-03-25  Martin Baulig  <martin@ximian.com>
14522
14523         * mini.c (mini_get_class): Take a `MonoGenericContext *' instead
14524         of a `MonoMethod *'.
14525         (mini_get_method): Take a `MonoGenericContext *' instead
14526         of a `MonoMethod *'.
14527         (TYPE_PARAM_TO_TYPE, MTYPE_PARAM_TO_TYPE): mono_method_to_ir() has
14528         a new local variable called `generic_context' which holds the
14529         current `MonoGenericContext *'; use it to lookup things.
14530
14531 2004-03-24  Martin Baulig  <martin@ximian.com>
14532
14533         * mini.c (mini_get_class): New static method; if we're inside a
14534         generic instance, inflate the class if neccessary.
14535         (mono_method_to_ir): Use mini_get_class() instead of mono_class_get().
14536
14537 2004-03-24  Zoltan Varga  <vargaz@freemail.hu>
14538
14539         * iltests.il: New regression test for #55976.
14540
14541         * mini.c (mono_method_to_ir): Empty the stack in endfinally. Fixes
14542         #55976.
14543
14544 2004-03-23  Zoltan Varga  <vargaz@freemail.hu>
14545
14546         * exceptions-sparc.c (mono_sparc_handle_exception): Remove debugging
14547         output.
14548
14549 2004-03-23  Zoltan Varga  <vargaz@freemail.hu>
14550
14551         * liveness.c: Consider SSA stores as well as loads when making vars
14552         volatile.
14553
14554         * exceptions.cs: New regression tests for register allocation.
14555         
14556 2004-03-22  Lluis Sanchez Gual  <lluis@ximian.com>
14557
14558         * mini-ppc.c, tramp-ppc.c: Added lock for accessing the domain code manager.
14559         * mini.c: Removed domain lock from mono_jit_compile_method_with_opt. Use
14560           domain lock only to protect puntual access to data structures.
14561           Added access lock for sighash, jit_icall_hash_name, 
14562           jit_icall_hash_addr and domain->code_mp.
14563
14564 2004-03-20  Zoltan Varga  <vargaz@freemail.hu>
14565
14566         * driver.c: Print SIGSEGV handling method.
14567
14568         * mini-x86.c (mono_arch_free_jit_tls_data): Add missing ifdef.
14569
14570         * mini.c (setup_jit_tls_data): Handle case when this is called
14571         multiple times for a thread.
14572
14573         * mini-x86.c cpu-pentium.md: Fix floating point branch opcodes so fbxx 
14574         is different from fbxx_un. Fixes #54303. Also use constants instead of
14575         magic numbers in a lot of places.
14576
14577 2004-03-19  Zoltan Varga  <vargaz@freemail.hu>
14578
14579         * exceptions.cs: Fix cctor test when --regression is used.
14580
14581 Thu Mar 18 19:57:56 CET 2004 Paolo Molaro <lupus@ximian.com>
14582
14583         * mini-ppc.c, exceptions-ppc.c: basic exceptions support 
14584         for Linux/ppc.
14585
14586 Thu Mar 18 19:56:19 CET 2004 Paolo Molaro <lupus@ximian.com>
14587
14588         * inssel-ppc.brg: fixed register assignments for some rules.
14589
14590 2004-03-17  Zoltan Varga  <vargaz@freemail.hu>
14591
14592         * exceptions.cs: Add test for exceptions in static constructors.
14593
14594         * mini.c (mono_jit_compile_method_with_out): Move the calling of
14595         static constructors outside the domain lock. Fixes #55720.
14596
14597 2004-03-17  Martin Baulig  <martin@ximian.com>
14598
14599         * mini.c (get_generic_field_inst): Removed, this'll never happen.
14600         (inflate_generic_field): Take the `MonoMethod *' instead of the
14601         `MonoClass *' and added support for generic method.
14602         (mono_method_to_ir): In CEE_LDSFLD and CEE_STSFLD, assert we never
14603         have a `field->parent->gen_params', only inflate the field if it's
14604         an open constructed type.
14605
14606 2004-03-17  Zoltan Varga  <vargaz@freemail.hu>
14607
14608         * exceptions-x86.c (mono_arch_handle_exception): Allocate a new
14609         exception object instead of the preconstructed ones.
14610
14611 2004-03-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
14612
14613         * mini.c: reverted changed to sigsegv_signal_handler commited
14614         accidentally in the previous patch.
14615
14616 2004-03-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
14617
14618         * mini.c:
14619         (mono_method_to_ir): CEE_CALLVIRT, abort if no method. It hanged when
14620         running --aot with an old assembly.
14621
14622 2004-03-16  Zoltan Varga  <vargaz@freemail.hu>
14623
14624         * mini-sparc.c (mono_arch_instrument_epilog): Fix handling of floating
14625         point values.
14626
14627         * mini-sparc.c: Add support for v9 branches with prediction.
14628
14629 2004-03-15  Bernie Solomon  <bernard@ugsolutions.com>
14630
14631         * mini.c (mini_init): #warning is GNUC only
14632
14633         * mini-sparc.h: implement __builtin_frame_address
14634         and __builtin_return_address for Sun C compiler
14635
14636 2004-03-15  Zoltan Varga  <vargaz@freemail.hu>
14637
14638         * exceptions-sparc.c (mono_arch_has_unwind_info): Add missing function.
14639
14640 2004-03-14  Zoltan Varga  <vargaz@freemail.hu>
14641
14642         * basic-calls.cs: Add test for unaligned byref long argument passing.
14643
14644         * mini-ops.h: Add sparcv9 compare and branch instructions.
14645
14646         * inssel-sparc.brg mini-sparc.h mini-sparc.c cpu-sparc.md: Use some
14647         v9 instructions if we have a v9 cpu.
14648
14649         * mini-sparc.c (mono_arch_get_global_int_regs): Use unused input
14650         registers for global allocation.
14651
14652         * exceptions-sparc.c: Fixes.
14653         
14654 2004-03-11  Zoltan Varga  <vargaz@freemail.hu>
14655
14656         * liveness.c (mono_analyze_liveness): Optimized version.
14657
14658         * inssel-sparc.brg cpu-sparc.md: Ongoing sparc work.
14659
14660         * mini-sparc.h mini-sparc.c tramp-sparc.c exceptions-sparc.c: Ongoing
14661         sparc work.
14662
14663         * basic-float.cs basic-calls.cs: New regression tests.
14664
14665 2004-03-10  Zoltan Varga  <vargaz@freemail.hu>
14666
14667         * mini-x86.h: Define SIGSEGV_ON_ALTSTACK only if we have a working
14668         sigaltstack implementation.
14669
14670         * mini-x86.c (mono_arch_setup_jit_tls_data): Fix previous patch.
14671         
14672         * mini-x86.c (mono_arch_setup_jit_tls_data): Turn off the sigaltstack
14673         stuff if SIGSEGV_ON_ALTSTACK is not defined.
14674
14675 2004-03-09  Zoltan Varga  <vargaz@freemail.hu>
14676
14677         * mini.c: Fix warnings.
14678         
14679         * mini.c (mono_resolve_patch_target): New function which contains the
14680         arch independent part of the patching process.
14681
14682         * mini-x86.c (mono_arch_patch_code): Move arch independent parts of the
14683         patching code to a separate function.
14684
14685 2004-03-09  Bernie Solomon  <bernard@ugsolutions.com>
14686
14687         * mini.c (add_signal_handler): ifdef out on Windows
14688
14689 2004-03-08  Zoltan Varga  <vargaz@freemail.hu>
14690
14691         * mini-sparc.h mini-sparc.c inssel-sparc.brg exceptions-sparc.c 
14692         cpu-sparc.md: Add exception handling support + other fixes.
14693
14694         * driver.c: Print --help output to stdout. Fixes #55261. Also fix
14695         typed GC detection in --version.
14696
14697         * basic.cs exceptions.cs: New regression tests.
14698
14699         * mini.h mini-x86.h mini-ppc.h: Add MonoCompileArch structure where
14700         the arch specific code can store data during a compilation.
14701
14702         * mini-ops.h: Add OP_SETFRET.
14703
14704         * mini.c (mini_get_ldelema_ins): Instead of allways calling the same
14705         function, register a separate icall for each arity, so the icalls can
14706         get a wrapper.
14707         
14708         * mini.c (mono_print_tree): Print negative offsets in a more readable
14709         form.
14710         
14711         * mini.c: Make signal handling work on sparc.
14712         
14713         * mini.c (mini_init): Add emulation for lconv_to_r8_un.
14714
14715         * inssel-long32.brg: Fix OP_LSUB_OVF_UN rule.
14716
14717         * jit-icalls.c: Emulate truncl by aintl on solaris.
14718
14719         * jit-icalls.c (mono_lconv_to_r8_un): New icall emulation function.
14720
14721 2004-03-05  Zoltan Varga  <vargaz@freemail.hu>
14722
14723         * mini.c (mini_init): fconv_to_ovf can raise exceptions.
14724
14725 2004-03-04  Lluis Sanchez Gual  <lluis@ximian.com>
14726
14727         * mini.c: In CEE_ISINST and CEE_CASTCLASS, if the type is an interface or
14728         a MarshalByRef type, inline a method that performs the check, taking into
14729         account that the object can be a proxy. Also implemented tow new opcodes:
14730         CEE_MONO_CISINST and CEE_MONO_CCASTCLASS.
14731         * inssel.brg: Implemented two new opcodes, mini-ops.h: OP_CISINST and 
14732         OP_CCASTCLASS, which implement CEE_MONO_CISINST and CEE_MONO_CCASTCLASS.
14733
14734 Tue Mar 2 17:23:48 CET 2004 Paolo Molaro <lupus@ximian.com>
14735
14736         * mini-ppc.c: if a relative branch displacement is too big
14737         but it points to and area reachable with an absolute branch, 
14738         avoid the thunks.
14739
14740 Tue Mar 2 16:59:40 CET 2004 Paolo Molaro <lupus@ximian.com>
14741
14742         * mini.c: optimize small copies in cpblk.
14743
14744 2004-03-01  Zoltan Varga  <vargaz@freemail.hu>
14745
14746         * basic-calls.cs basic-float.cs: New regression tests.
14747
14748         * mini-sparc.c inssel-sparc.brg mini-ops.h: Access local variables at 
14749         negative offsets from %fp. Implement localloc. Fix local register 
14750         allocation. Fix the case when the this argument needs to be saved to
14751         the stack. Implement some missing opcodes.
14752
14753 2004-02-26  Zoltan Varga  <vargaz@freemail.hu>
14754
14755         * mini.c (mini_method_compile): Reenable global regalloc in methods
14756         with exception handlers.
14757
14758         * linear-scan.c (mono_varlist_sort): Fix warning.
14759
14760         * linear-scan.c (mono_linear_scan): Fix computation of used_regs.
14761
14762         * mini-x86.c (mono_arch_regalloc_cost): Reenable precise computation of
14763         regalloc costs.
14764
14765         * liveness.c: Make all variables uses in exception clauses volatile, to
14766         prevent them from being allocated to registers. Fixes #42136.
14767
14768 2004-02-25  Zoltan Varga  <vargaz@freemail.hu>
14769
14770         * mini-x86.c (mono_arch_regalloc_cost): Revert this change since it
14771         causes regressions.
14772
14773         * mini.h linear-scan.c mini-x86.c mini-sparc.c mini-ppc.c: Add 'cfg'
14774         argument to mono_arch_regalloc_cost.
14775
14776         * mini-x86.c (mono_arch_regalloc_cost): Compute regalloc costs 
14777         precisely.
14778
14779 2004-02-24  Zoltan Varga  <vargaz@freemail.hu>
14780
14781         * mini.h mini-x86.c mini-ppc.c mini-sparc.c linear-scan.c: 
14782         Make the cost of allocating a variable to a register arch dependent.
14783
14784         * basic-calls.cs: Fix compilation of tests.
14785         
14786         * mini.h mini.c tramp-x86.c mini-x86.c: Add mono_running_on_valgrind ()
14787         helper function to cut back on the number of #ifdefs needed.
14788
14789         * mini-ppc.c: Fix compilation.
14790
14791         * basic-calls.cs: New regression tests.
14792
14793         * mini-sparc.c (mono_sparc_is_virtual_call): New helper function.
14794
14795         * tramp-sparc.c (create_specific_trampoline): Use g5 register instead
14796         of l0 since that is callee saved.
14797
14798         * tramp-sparc.c (sparc_magic_trampoline): Apply unbox trampoline only
14799         to virtual calls.
14800
14801         * mini-sparc.c: Ongoing work + flag virtual calls with a special kind 
14802         of delay instruction.
14803
14804         * inssel.brg (OP_CHECK_THIS): Set tree->sreg1 and dreg correctly.
14805
14806         * mini.h (MonoCallInst): Add 'virtual' flag.
14807
14808         * inssel.brg (mini_emit_virtual_call): Set 'virtual' flag.
14809
14810 2004-02-23  Zoltan Varga  <vargaz@freemail.hu>
14811
14812         * *.cs: New regression tests.
14813
14814         * mini-sparc.c inssel-sparc.brg: Update after latest changes. Ongoing sparc 
14815         work.
14816
14817         * mini.c (mono_runtime_install_handlers): Fix build.
14818
14819         * mini.h (MonoJitTlsData): Add 'stack_size', 'signal_stack' and
14820         'signal_stack_size' members.
14821
14822         * mini.h mini.c mini-x86.h mini-x86.c: Run sigsegv handlers on an 
14823         alternate signal stack.
14824
14825         * exceptions-x86.c: Add stack overflow handling.
14826
14827         * mini.h mini.c mini-x86.c mini-ppc.c trace.h trace.c: Move tracing 
14828         functions to arch independent code.
14829
14830         * mini.c (mono_print_tree): Print more detailed info for load_membase
14831         opcodes.
14832         
14833 2004-02-23  Martin Baulig  <martin@ximian.com>
14834
14835         * mini.c (mini_get_method): Set `gmethod->generic_inst'.
14836
14837 Sun Feb 22 22:25:19 CET 2004 Paolo Molaro <lupus@ximian.com>
14838
14839         * mini-x86.c: fixed reg allocation for div/rem.
14840
14841 2004-02-22  Miguel de Icaza  <miguel@ximian.com>
14842
14843         * driver.c (mono_main): Report some configuratio options on --version.
14844
14845 Fri Feb 20 11:01:44 PST 2004 Paolo Molaro <lupus@ximian.com>
14846
14847         * mini-ppc.c: fixed clt.un, cgt.un. Optimized calls to functions
14848         low in the address space. Correctly flush memory in thunks where we
14849         output native code.
14850
14851 2004-02-20  Martin Baulig  <martin@ximian.com>
14852
14853         * mini.c (mini_get_method): New static method; inflate all generic
14854         methods and methods in open generic instances.
14855         (mono_method_to_ir): Use mini_get_method() instead of mono_get_method().
14856         (ret_type_to_call_opcode): Added support for MONO_TYPE_GENERICINST.
14857
14858 2004-02-19  Zoltan Varga  <vargaz@freemail.hu>
14859
14860         * mini-sparc.c (mono_arch_patch_code): Update after domain->code_mp changes.
14861
14862         * tramp-sparc.c (mono_arch_create_jump_trampoline): Set ji->method.
14863
14864 2004-02-19  Bernie Solomon  <bernard@ugsolutions.com>
14865
14866         * helpers.c (mono_disassemble_code): use Sun's dis if not using gcc
14867
14868         * mini-sparc.c (flushi mono_arch_output_basic_block): make
14869         it compile using Sun's compiler.
14870
14871 2004-02-19  Zoltan Varga  <vargaz@freemail.hu>
14872
14873         * 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.
14874
14875         * basic-calls.cs basic-float.cs basic-long.cs objects.cs: New regression tests.
14876
14877 Tue Feb 17 21:41:20 CET 2004 Paolo Molaro <lupus@ximian.com>
14878
14879         * aot.c, mini-x86.c, mini.c: use the code manager instead of a mempool to hold native
14880         code.
14881         * mini-ppc.c: handle calls outside of the allowed range with thunks
14882         allocated using the code manager.
14883         * tramp-ppc.c: use the code manager to hold generated native code.
14884         Fixed the magic trampoline to just patch vtable entries.
14885
14886 2004-02-17  Zoltan Varga  <vargaz@freemail.hu>
14887
14888         * inssel.brg inssel-x86.brg: Move call(immediate) rules to the platform
14889         independent file.
14890
14891 2004-02-16  Zoltan Varga  <vargaz@freemail.hu>
14892
14893         * tramp-ppc.c (mono_arch_create_jump_trampoline): Fix compilation on
14894         PPC.
14895
14896         * mini-x86.c: Call mono_arch_get_lmf_addr instead of mono_get_lmf_addr
14897         if we have a working __thread implementation.
14898
14899         * mini-ops.h cpu-pentium.md mini-x86.c inssel-x86.brg: Remove 
14900         OP_CALL_IMM opcodes, since the CALL opcodes handles immediates as well.
14901
14902 2004-02-15  Zoltan Varga  <vargaz@freemail.hu>
14903
14904         * mini-x86.c: Fix compilation under gcc 2.
14905         
14906 2004-02-14  Zoltan Varga  <vargaz@freemail.hu>
14907
14908         * mini.c (mono_codegen): Avoid infinite loop when an icall wrapper
14909         contains a call to the wrapped function.
14910
14911         * mini-ops.h cpu-pentium.md mini-x86.c inssel-x86.brg: Add 
14912         OP_<CALL>_IMM opcodes, and use them under X86.
14913         
14914         * mini.c (mono_jit_find_compiled_method): Fix warning.
14915
14916         * cpu-pentium.md: Fix length of opcodes which use x86_alu_membase_imm.
14917
14918         * jit-icalls.c (mono_ldftn_nosync): New JIT icall.
14919
14920         * tramp-x86.c (mono_arch_create_jump_trampoline): Move arch independent
14921         functionality to mini.c.
14922
14923         * mini.c (mono_create_jump_trampoline): New function to create a jump
14924         trampoline. Return a compiled method instead of a trampoline if it
14925         exists. Add a cache for jump trampolines.
14926
14927         * mini.c (mono_jit_find_compiled_method): New function to return a
14928         compiled method if it exists.
14929
14930         * mini-x86.c: Call mono_create_jump_trampoline instead of 
14931         mono_arch_create_jit_trampoline.
14932
14933         * jit-icalls.c (mono_ldftn): Do not compile the method. Instead, return
14934         a jump trampoline. Fixes #52092.
14935         
14936 2004-02-11  Zoltan Varga  <vargaz@freemail.hu>
14937
14938         * debug-mini.c (mono_init_debugger): Remove call to mono_verify_corlib,
14939         which is not up-to-date. Add check_corlib_version () instead.
14940
14941         * mini.c (mini_init): Call mono_thread_attach () so embedders do not 
14942         have to call it.
14943         
14944         * mini.c (mono_runtime_install_handlers): Remove check for valgrind
14945         since newer valgrind versions do not need it.
14946
14947         * mini.c (mono_jit_compile_method_with_opt): New helper function to
14948         compile a method with a given set of optimizations.
14949
14950         * mini.c: Compile icall wrappers on-demand instead of at startup.
14951
14952         * mini-sparc.c mini-ppc.c: Call mono_icall_get_wrapper to obtain the
14953         wrapper for an icall.
14954
14955 2004-02-10  Zoltan Varga  <vargaz@freemail.hu>
14956
14957         * mini.c (mono_method_to_ir): Handle switch with non-empty stack. Fixes
14958         #54063.
14959
14960         * iltests.il: Add test for non-empty stack before switch instruction.
14961
14962 2004-02-02  Zoltan Varga  <vargaz@freemail.hu>
14963
14964         * mini.c: Add support for new stringbuilder marshalling conventions.
14965
14966         * mini.c (mono_method_to_ir): Fix stack management of generic CEE_BOX.
14967
14968 2004-02-01  Martin Baulig  <martin@ximian.com>
14969
14970         * mini.c (MTYPE_PARAM_TO_TYPE): Method type arguments are stored
14971         in `ginst->mtype_argv'.
14972
14973 2004-01-31  Miguel de Icaza  <miguel@ximian.com>
14974
14975         * mini.c: Add comments, replace CEE_XXX+128 with OP_XXX to
14976         facilitate grepping.
14977
14978 Wed Jan 28 14:04:58 CET 2004 Paolo Molaro <lupus@ximian.com>
14979
14980         * mini.c: fixed buglet in initobj generic implementation for references.
14981
14982 Fri Jan 23 16:10:44 EST 2004 Paolo Molaro <lupus@ximian.com>
14983
14984         * Makefile.am: make the version script conditional.
14985         * jit-icalls.c: handle missing truncl().
14986
14987 2004-01-23  Zoltan Varga  <vargaz@freemail.hu>
14988
14989         * exceptions.cs: Add more tests for double->int conversion.
14990
14991         * jit-icalls.c (mono_fconv_ovf_i8): Call truncl before comparison, so
14992         we don't throw exceptions when converting 1.1 to a long. Fixes #53250.
14993
14994 Fri Jan 23 17:12:08 CET 2004 Paolo Molaro <lupus@ximian.com>
14995
14996         * driver.c: make --verbose --version emit an error
14997         if the loaded corlib doesn't match the runtime version.
14998
14999 Mon Jan 19 17:44:50 CET 2004 Paolo Molaro <lupus@ximian.com>
15000
15001         * mini-ppc.h: export ppc_patch().
15002         * mini-ppc.c: call convention fixes. Added assert in ppc_patch().
15003         * tramp-ppc.c: call convention fixes: Linux/PPC support should be
15004         on par or better than on MacOSX.
15005
15006 2004-01-19  Zoltan Varga  <vargaz@freemail.hu>
15007
15008         * mini.c tramp-x86.c tramp-sparc.c: Updated after changes to
15009         mono_lookup_pinvoke_call.
15010
15011         * mini-x86.c: Under windows, the default pinvoke calling convention is
15012         stdcall. Fixes #52834.
15013
15014         * mini.c (optimize_branches): Add an upper bound to the number of
15015         iterations to prevent infinite loops on strange loops. Fixes #53003.
15016
15017 2004-01-16  Zoltan Varga  <vargaz@freemail.hu>
15018
15019         * inssel.brg: Add vectors<->one dimensional array checking to CASTCLASS
15020         and ISINST. Fixes #52093.
15021
15022         * objects.cs (test_0_vector_array_cast): New tests.
15023         
15024 2004-01-15  Zoltan Varga  <vargaz@freemail.hu>
15025
15026         * jit-icalls.c (helper_stelem_ref_check): New jit icall for array type
15027         checking in Array.Set ().
15028
15029         * mini.c (method_to_ir): Add array type checking in Array.Set (). Fixes
15030         #52590.
15031
15032         * object.cs (test_0_multi_array_cast): New regression test.
15033
15034 Thu Jan 15 16:30:24 CET 2004 Paolo Molaro <lupus@ximian.com>
15035
15036         * exceptions-ppc.c: fix build on Linux/PPC.
15037
15038 2004-01-14  Zoltan Varga  <vargaz@freemail.hu>
15039
15040         * tramp-x86.c (x86_magic_trampoline): Disable code patching when
15041         running under valgrind.
15042         (x86_magic_trampoline): Fix build bustage.
15043
15044         * debug-mini.c: Modify the debug info serialize/deserialize code so it handles
15045         negative values as well. This is needed for the encoding of the line number
15046         info, since sometimes the line numbers are not in increasing order.
15047
15048 2004-01-13  Zoltan Varga  <vargaz@freemail.hu>
15049
15050         * cpu-pentium.md (localloc): Increase the size of the localloc 
15051         instruction since it is a loop under Win32.
15052
15053         * debug-mini.c (record_line_number): Get rid of unneccesary memory
15054         allocation.
15055
15056 2004-01-09  Zoltan Varga  <vargaz@freemail.hu>
15057
15058         * exceptions-ppc.c exceptions-x86.c exceptions-sparc.c 
15059         tramp-x86.c tramp-ppc.c tramp-sparc.c: Applied patch from 
15060         Max Horn (max@quendi.de). Fix file names in comments.
15061
15062 2004-01-03  Zoltan Varga  <vargaz@freemail.hu>
15063
15064         * ssa.c (mono_ssa_rename_vars): Allocate new_stack on the heap to
15065         avoid stack overflow.
15066         (replace_usage): Avoid uninitialized variable warnings.
15067
15068         * mini.c (mono_method_to_ir): Avoid disabling SSA for array operations
15069         and taking the address of valuetype variables.
15070
15071 2004-01-03  Patrik Torstensson
15072
15073         * mini-x86.c: renamed fpflags to flags in RegTrack, going to be used
15074         for other purposes than FP later on.
15075
15076 2004-01-02  Zoltan Varga  <vargaz@freemail.hu>
15077
15078         * mini.c (mono_method_to_ir): Prevent register allocation for arguments
15079         of tail calls.
15080
15081 Fri Jan 2 13:37:25 CET 2004 Paolo Molaro <lupus@ximian.com>
15082
15083         * mini-ops.h, mini.c, inssel.brg: Object.GetType () speedup.
15084
15085 2003-12-30  Patrik Torstensson <p@rxc.se>
15086
15087         * mini-x86.h: Decreased number of availiable fp regs.
15088         Solves corner cases with FP spilling.
15089
15090 2003-12-23  Patrik Torstensson <p@rxc.se>
15091
15092         * mini-x86.c, mini-ops.h, cpu-pentium.md: Added support
15093         for floating point stack tracking / spilling on x86. 
15094         Fixes bug #49012.
15095         
15096         * basic-float.cs: added float mul overflow test.
15097
15098 2003-12-23  Zoltan Varga  <vargaz@freemail.hu>
15099
15100         * mini.c (mono_method_to_ir): Add workaround for bug #51126.
15101
15102 Sun Dec 21 19:53:16 CET 2003 Paolo Molaro <lupus@ximian.com>
15103
15104         * mini.h, mini-ppc.c, mini-ppc.h: small cleanups and
15105         supports for cond branches that overflow the immediate
15106         overflow offset. mcs can compile simple programs.
15107
15108 Fri Dec 19 21:17:16 CET 2003 Paolo Molaro <lupus@ximian.com>
15109
15110         * exceptions-ppc.c: exception handling support wip:
15111         finally handlers get run on exception.
15112
15113 2003-12-19  Zoltan Varga  <vargaz@freemail.hu>
15114
15115         * aot.c (mono_aot_get_method_inner): Avoid loading AOT code while 
15116         profiling.
15117
15118 Fri Dec 19 17:58:28 CET 2003 Paolo Molaro <lupus@ximian.com>
15119
15120         * cpu-g4.md, mini-ppc.c, exceptions-ppc.c, mini-ppc.h:
15121         initial support for stack walking and unwinding.
15122
15123 2003-12-18  Zoltan Varga  <vargaz@freemail.hu>
15124
15125         * driver.c (mono_main): Make corlib-out-of-sync message more 
15126         descriptive. Also remove verify_corlib call.
15127
15128 Wed Dec 17 15:31:41 CET 2003 Paolo Molaro <lupus@ximian.com>
15129
15130         * mini.c: make CEE_NEWARR calls and other emulated opcodes 
15131         not overlap with other call's arguments, too.
15132
15133 Wed Dec 17 12:49:23 CET 2003 Paolo Molaro <lupus@ximian.com>
15134
15135         * mini.h, mini.c, mini-ppc.c, mini-sparc.c, mini-x86.c: 
15136         move to arch-specific code the choice of arch-specific
15137         intrinsics (from Laurent Morichetti (l_m@pacbell.net)).
15138         * mini.c: ensure emulation calls will not interleave
15139         with other calls.
15140
15141 Wed Dec 17 12:27:26 CET 2003 Paolo Molaro <lupus@ximian.com>
15142
15143         * tramp-ppc.c, basic-calls.cs: rework trampolines so that
15144         the magic trampoline stack frame is dropped before executing
15145         the new method.
15146
15147 Mon Dec 15 18:13:57 CET 2003 Paolo Molaro <lupus@ximian.com>
15148
15149         * mini-ppc.c, cpu-g4.md, inssel-ppc.brg: fixed some opcode lengths
15150         and integer to fp conversions. Added support for overflowing
15151         arguments on the stack. Reserve a couple more registers as temps.
15152         Added support for aot compilation (as output still needs to be
15153         tweaked, though).
15154
15155 Sat Dec 13 17:49:10 CET 2003 Paolo Molaro <lupus@ximian.com>
15156
15157         * mini-ppc.c, basic-long.cs: fix jumps to known labels.
15158         Don't overwrite return register in some corner cases.
15159
15160 2003-12-13  Zoltan Varga  <vargaz@freemail.hu>
15161
15162         * mini.h mini.c driver.c mini-x86.c mini-ppc.c aot.c: Do not run
15163         static constructors when AOT compiling.
15164
15165         * driver.c (mono_main): Call mono_check_corlib_version.
15166
15167 Sat Dec 13 10:31:12 CET 2003 Paolo Molaro <lupus@ximian.com>
15168
15169         * cpu-g4.md, basic.cs: fixed div target register.
15170
15171 Sat Dec 13 09:45:56 CET 2003 Paolo Molaro <lupus@ximian.com>
15172
15173         * mini-ppc.c, basic.cs: shl_imm fix with test.
15174
15175 Fri Dec 12 21:25:14 CET 2003 Paolo Molaro <lupus@ximian.com>
15176
15177         * inssel-ppc.brg, mini-ppc.h, mini-ppc.c: support for passing 
15178         structures by value. Misc fixes.
15179         * objects.cs: more tests.
15180
15181 Fri Dec 12 10:11:49 CET 2003 Paolo Molaro <lupus@ximian.com>
15182
15183         * mini-ppc.c: lconv.ovf.i implemented.
15184
15185 2003-12-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
15186
15187         * mini.c:
15188         (mini_init): don't error out if someone already called g_thread_init.
15189
15190 Tue Dec 9 17:27:14 CET 2003 Paolo Molaro <lupus@ximian.com>
15191
15192         * exceptions-x86.c, exceptions-ppc.c: allow the exception object
15193         to be any type per the spec. Fix abnormal memory usage when
15194         the same object is repeatedly thrown.
15195
15196 Tue Dec 9 15:39:54 CET 2003 Paolo Molaro <lupus@ximian.com>
15197
15198         * mini.c: check for overruns in IL code.
15199
15200 2003-12-09  Zoltan Varga  <vargaz@freemail.hu>
15201
15202         * TODO: Add/remove some todo entries.
15203
15204 2003-12-08  Zoltan Varga  <vargaz@freemail.hu>
15205
15206         * driver.c (mono_main): Call mono_verify_corlib.
15207
15208 2003-12-07  Lluis Sanchez Gual  <lluis@ximian.com>
15209
15210         * inssel.brg: In CEE_ISINST and CEE_CASTCLASS, removed check for proxy. 
15211         This has been moved to mini.c
15212         * mini.c: in mono_method_to_ir, CEE_ISINST and CEE_CASTCLASS cases, if the
15213         type being casted is marshalbyref it could be a proxy, so instead of
15214         emitting the type check code, emit a call to a runtime method that will
15215         perform the check by calling CanCastTo if needed.
15216
15217 2003-12-06  Zoltan Varga  <vargaz@freemail.hu>
15218
15219         * mini-x86.c (mono_arch_emit_prolog): Fix stack space allocation for
15220         methods with large stack frames under Win32.
15221
15222 2003-12-04  Zoltan Varga  <vargaz@freemail.hu>
15223
15224         * Makefile.am: Distribute regression tests.
15225
15226         * mini-x86.c (mono_arch_get_allocatable_int_vars): Sort the var list
15227         at the end instead of inserting each variable into the sorted list.
15228
15229         * linear-scan.c (mono_varlist_sort): New helper function.
15230         
15231 Wed Dec 3 20:46:28 CET 2003 Paolo Molaro <lupus@ximian.com>
15232
15233         * mini.c: ensure arguments and locals are within bounds.
15234
15235 Wed Dec 3 17:59:10 CET 2003 Paolo Molaro <lupus@ximian.com>
15236
15237         * mini-ppc.c, cpu-g4.md, basic.cs, basic-long.cs: more tests and 
15238         related fixes.
15239
15240 2003-12-03  Zoltan Varga  <vargaz@freemail.hu>
15241
15242         * mini.c (mono_cprop_copy_values): Fix crash.
15243
15244         * aot.c: Set verbosity back to 0.
15245         
15246 Wed Dec 3 15:42:27 CET 2003 Paolo Molaro <lupus@ximian.com>
15247
15248         * regalloc.c: complete memory leak fix by Laurent Morichetti
15249         (l_m@pacbell.net).
15250
15251 2003-12-03  Zoltan Varga  <vargaz@freemail.hu>
15252
15253         * driver.c (main_thread_handler): Revert the previous patch.
15254
15255         * tramp-x86.c (x86_class_init_trampoline): Avoid patching when running
15256         under valgrind.
15257
15258         * mini-x86.c (mono_arch_local_regalloc): Do not allocate transient
15259         memory from the memory pool.
15260
15261         * driver.c (main_thread_handler): Turn on all optimizations when
15262         --aot is used.
15263
15264         * mini.c (mono_find_jit_opcode_emulation): Turn emul_opcode_hash into
15265         an array for better performance.
15266
15267         * regalloc.c (mono_regstate_assign): Fix memory leak.
15268
15269         * debug-mini.c (mono_debug_serialize_debug_info): New function to
15270         serialize the debug info.
15271
15272         * debug-mini.c (mono_debug_add_aot_method): New function to load the
15273         debug info from the serialized representation.
15274
15275         * aot.c: Save debug info into the generated file and load it when 
15276         loading a method.
15277
15278         * mini.h (MONO_AOT_FILE_VERSION): Bump version number.
15279
15280 Mon Dec 1 16:54:05 CET 2003 Paolo Molaro <lupus@ximian.com>
15281
15282         * mini-ppc.c, tramp-ppc.c: save FP arguments in the trampoline.
15283         More FP-related fixes.
15284
15285 Sun Nov 30 19:13:52 CET 2003 Paolo Molaro <lupus@ximian.com>
15286
15287         * mini-ppc.c, cpu-g4.md, inssel-ppc.brg: fixed finally handlers
15288         and register allocation buglet. Hello world now runs.
15289
15290 Fri Nov 28 23:03:05 CET 2003 Paolo Molaro <lupus@ximian.com>
15291
15292         * cpu-g4.md, inssel-ppc.brg, mini-ppc.c: better long return support.
15293         * tramp-ppc.c: fixed class init trampoline.
15294         * inssel-ppc.brg, mini.c, jit-icalls.c, mini-ppc.h: more emulation.
15295
15296 Fri Nov 28 16:36:29 CET 2003 Paolo Molaro <lupus@ximian.com>
15297
15298         * cpu-g4.md, inssel-ppc.brg, jit-icalls.c, mini-ppc.c, mini-ppc.h,
15299         mini.c: more ppc changes/fixes.
15300
15301 2003-11-27  Zoltan Varga  <vargaz@freemail.hu>
15302
15303         * mini.c (mono_method_to_ir): Fix tail calls with valuetype arguments.
15304         Also optimize the case when the arguments are the same in the caller 
15305         and in the callee.
15306
15307         * iltests.il: Add tests for tail calls with valuetype arguments.
15308
15309 Thu Nov 27 21:06:37 CET 2003 Paolo Molaro <lupus@ximian.com>
15310
15311         * mini-ppc.c: fixes for struct return type.
15312
15313 Thu Nov 27 19:02:07 CET 2003 Paolo Molaro <lupus@ximian.com>
15314
15315         * mini.h, mini.c, mini-x86.c, mini-ppc.c, mini-sparc.c: move 
15316         mono_spillvar_offset() to arch-specific code.
15317
15318 Thu Nov 27 18:30:42 CET 2003 Paolo Molaro <lupus@ximian.com>
15319
15320         * mini-ppc.h, mini-ppc.c: handle some different ABI call convention issues.
15321
15322 2003-11-27  Zoltan Varga  <vargaz@freemail.hu>
15323
15324         * exceptions-x86.c: Fix stack space leaks.
15325         
15326         * exceptions-x86.c (mono_arch_find_jit_info): Restore callee saved
15327         registers from the lmf if the method has save_lmf set.
15328
15329 2003-11-26  Zoltan Varga  <vargaz@freemail.hu>
15330
15331         * tramp-x86.c (x86_magic_trampoline): Avoid patching in the addresses
15332         of icall wrappers into InvokeInDomain, since these are now per-domain.
15333
15334 Wed Nov 26 20:15:04 CET 2003 Paolo Molaro <lupus@ximian.com>
15335
15336         * mini-ppc.h, mini-x86.h, mini.c, inssel-ppc.brg, jit-icalls.c:
15337         make some opcode emulation and intrinsic ops enabled/disabled 
15338         according to the architecture. More fixes.
15339
15340 Wed Nov 26 19:59:09 CET 2003 Paolo Molaro <lupus@ximian.com>
15341
15342         * mini-ppc.c, mini-sparc.c, cpu-g4.md: more bug fixes.
15343
15344 Wed Nov 26 19:18:29 CET 2003 Paolo Molaro <lupus@ximian.com>
15345
15346         * mini.h, inssel.brg, mini-x86.c, mini-ppc.c, mini-sparc.c: move
15347         arch-specific handling for 'this' and struct return type to
15348         arch-specific code.
15349
15350 2003-11-26  Gonzalo Paniagua Javier <gonzalo@ximian.com>
15351
15352         * aot.c: prevent divide by zero error when reporting (it happened with
15353         Accessibility.dll).
15354
15355 2003-11-25  Zoltan Varga  <vargaz@freemail.hu>
15356
15357         * mini.h (inst_switch): Remove unused macro.
15358
15359 2003-11-25  Gonzalo Paniagua Javier <gonzalo@ximian.com>
15360
15361         * aot.c:
15362         (load_aot_module): free 'info->methods' and 'info' properly. No more
15363         "free(): invalid pointer blah" messages when you have an old aot
15364         compiled assembly.
15365
15366 2003-11-21  Lluis Sanchez Gual <lluis@ximian.com>
15367
15368         * jit-icalls.c, mini.c: Added support for context static fields.
15369
15370 2003-11-18  Zoltan Varga  <vargaz@freemail.hu>
15371
15372         * mini.c (mono_method_blittable): Methods which set LastError are not 
15373         blittable either. Fixes #51108.
15374         
15375 Tue Nov 18 16:41:37 CET 2003 Paolo Molaro <lupus@ximian.com>
15376
15377         * mini.c: flush icache.
15378         * cpu-g4.md, mini-ppc.c, inssel.brg: more fixes. Trace support.
15379
15380 2003-11-18  Zoltan Varga  <vargaz@freemail.hu>
15381
15382         * mini.c (mono_type_blittable): OBJECT is not blittable. Fixes #47842.
15383
15384 2003-11-17  Zoltan Varga  <vargaz@freemail.hu>
15385
15386         * tramp-x86.c (x86_class_init_trampoline): Make code patching thread
15387         safe on IA32.
15388
15389         * mini-x86.c (mono_arch_call_opcode): Disable AOT for methods with 
15390         vararg calls.
15391
15392         * inssel.brg (CEE_MKREFANY): Fix AOT case.
15393
15394 2003-11-16  Zoltan Varga  <vargaz@freemail.hu>
15395
15396         * mini-x86.c (mono_arch_local_regalloc): Fix regalloc for div 
15397         instruction when the result is discarded.
15398
15399         * iltests.il (test_0_div_regalloc): New regression test.
15400
15401         * arrays.cs: Fix compilation error.
15402
15403 Fri Nov 14 21:34:06 CET 2003 Paolo Molaro <lupus@ximian.com>
15404
15405         * inssel-x86.brg, inssel-float.brg, mini-ops.h: move x86-specific
15406         float rules to inssel-x86.brg: sane architectures with FP registers
15407         don't need to implement these rules.
15408
15409 Fri Nov 14 20:52:12 CET 2003 Paolo Molaro <lupus@ximian.com>
15410
15411         * mini-ppc.c, cpu-g4.md, inssel-ppc.brg: updates and fixes to the ppc port.
15412
15413 Fri Nov 14 17:58:27 CET 2003 Paolo Molaro <lupus@ximian.com>
15414
15415         * mini.h, inssel-long32.brg: fixed endianess issues in int64
15416         implementation of 32 bit systems.
15417
15418 Thu Nov 13 16:14:41 CET 2003 Paolo Molaro <lupus@ximian.com>
15419
15420         * exceptions-ppc.c: fix build on Linux/ppc from Jeroen@xs4all.nl
15421         (Jeroen Zwartepoorte).
15422
15423 2003-11-12  Zoltan Varga  <vargaz@freemail.hu>
15424
15425         * mini.c (mono_method_to_ir): Use CEE_JMP only if the signature of
15426         the caller and the callee matches.
15427         
15428         * mini.c (mono_method_to_ir): Add comment.
15429
15430         * mini-x86.c (mono_arch_output_basic_block): Use mono_signbit, since
15431         signbit is missing on some platforms.
15432
15433 2003-11-06  Zoltan Varga  <vargaz@freemail.hu>
15434
15435         * mini.h (mono_arch_setup_jit_tls_data): New arch specific function.
15436
15437         * mini.c (setup_jit_tls_data): Call the new function.
15438         
15439         * mini-x86.c mini-ppc.c mini-sparc.c: Define the new function.
15440
15441         * mini-x86.c: Add experimental support for fast access to the lmf
15442         structure under NPTL/Linux 2.6.x.
15443
15444 2003-11-06  Martin Baulig  <martin@ximian.com>
15445
15446         * ldscript: Make `GC_push_all_stack', `GC_start_blocking',
15447         `GC_end_blocking' and 'gc_thread_vtable' public; they're used by
15448         the debugger.
15449
15450 2003-11-02  Martin Baulig  <martin@ximian.com>
15451
15452         * mini.c (inflate_generic_field): New static method.
15453         (mono_method_to_ir): In CEE_LDFLD and CEE_LDSFLD: if we're a
15454         generic instance and the field is declared in a generic type, call
15455         inflate_generic_field() to inflate it.  Fixes gen-28.cs.
15456
15457 2003-10-31  Zoltan Varga  <vargaz@freemail.hu>
15458
15459         * mini.h mini.c (mono_method_same_domain): New function to return
15460         whenever the caller and the callee are in the same domain.
15461
15462         * tramp-x86.c (x86_magic_trampoline): Use the new function.     
15463
15464 2003-10-30  Martin Baulig  <martin@ximian.com>
15465
15466         * mini.c (MTYPE_PARAM_TO_TYPE, MTYPE_PARAM_TO_CLASS): New macros;
15467         similar to TYPE_PARAM_TO_TYPE and TYPE_PARAM_TO_CLASS, but for
15468         method parameters.
15469         (mono_method_to_ir): Added support for MONO_TYPE_MVAR; similar to
15470         MONO_TYPE_VAR, we the actual types from MTYPE_PARAM_TO_CLASS(). 
15471
15472 2003-10-29  Zoltan Varga  <vargaz@freemail.hu>
15473
15474         * mini.c mini-ops.h inssel.brg: Implement undeniable exception 
15475         propagation.
15476
15477         * mini.c (sigusr1_signal_handler): Move creation of the thread abort
15478         object here, so it is in the correct appdomain etc.
15479
15480 2003-10-27  Zoltan Varga  <vargaz@freemail.hu>
15481
15482         * mini.c (mono_jit_compile_method_inner): Lookup icalls here if not
15483         already done.
15484         (mono_method_to_ir): Avoid freeing the type created returned from
15485         mono_type_create_from_typespec, since it is put into an internal cache
15486         by the function. Fixes pointer.exe.
15487
15488         * mini.c tramp-x86.c tramp-sparc.c tramp-ppc.c: Use the normal 
15489         trampolines for icalls and pinvokes as well. Fixes #33569.
15490
15491 2003-10-24  Zoltan Varga  <vargaz@freemail.hu>
15492
15493         * mini.c: Update after appdomain changes.
15494
15495         * mini.c (mono_jit_compile_method_inner): Allways compile native
15496         method wrappers in the root domain, since there can only be one
15497         instance of them, whose address is stored in method->info.
15498
15499 2003-10-16  Zoltan Varga  <vargaz@freemail.hu>
15500
15501         * mini.c (mono_runtime_install_handlers): Get rid of the MONO_VALGRIND
15502         environment variable. Instead detect automatically whenever running
15503         under valgrind using the magic macro RUNNING_ON_VALGRIND from
15504         valgrind.h.
15505
15506 2003-10-16  Miguel de Icaza  <miguel@ximian.com>
15507
15508         * trace.c, trace.h: New files that implement the new trace option
15509         parsing. 
15510
15511         * driver.c: Document new --trace options.
15512
15513         * exceptions-ppc.c, exceptions-x86.c, mini-ppc.c, mini-sparc.c,
15514         mini-x86.c: Apply:
15515
15516         -       if (mono_jit_trace_calls)
15517         +       if (mono_jit_trace_calls != NULL && mono_trace_eval (method))
15518
15519         * mini.h: prototypes.
15520         
15521 2003-10-15  Zoltan Varga  <vargaz@freemail.hu>
15522
15523         * mini.c (mono_method_to_ir): Fix initialization of typedbyref locals.
15524
15525         * mini.c inssel.brg: Implement typedefbyref opcodes.
15526
15527         * mini.c (mono_jit_compile_method): Remove unused local variable.
15528
15529         * mini.c (mono_jit_compile_method_inner): Ditto.
15530         
15531 2003-10-12  Zoltan Varga  <vargaz@freemail.hu>
15532
15533         * tramp-x86.c (x86_class_init_trampoline): Fix build.
15534         
15535         * tramp-x86.c (x86_class_init_trampoline): Thread safety fixes.
15536
15537 2003-10-10  Zoltan Varga  <vargaz@freemail.hu>
15538
15539         * mini.c (mono_no_aot): Remove unused global variable.
15540
15541         * mini.c: Thread safety fixes.
15542
15543 2003-10-09  Zoltan Varga  <vargaz@freemail.hu>
15544
15545         * mini.c (mono_create_class_init_trampoline): Add a lock around
15546         class_init_hash_addr.
15547
15548         * arrays.cs (test_0_newarr_emulation): Add new regression test for
15549         #30073.
15550
15551         * mini.c: Decompose the NEWARR instruction before decomposing its
15552         arguments. Fixes #30073.
15553
15554 2003-10-08  Zoltan Varga  <vargaz@freemail.hu>
15555
15556         * mini-x86.c (mono_arch_emit_epilog): Add support for stdcall calling
15557         convention.
15558
15559 2003-10-06  Zoltan Varga  <vargaz@freemail.hu>
15560
15561         * mini.c (mono_method_to_ir): Allow wrapper data for CEE_LDELEMA.
15562
15563         * inssel-x86.brg (OP_LOCALLOC): Fix register assignment for localloc.
15564
15565         * driver.c: Add support for compiling icall wrappers to --compile.
15566
15567 2003-10-05  Zoltan Varga  <vargaz@freemail.hu>
15568
15569         * inssel.brg: The empty value in class->interface_offsets is -1, not
15570         0. Fixes #49287.
15571
15572 2003-10-03  Zoltan Varga  <vargaz@freemail.hu>
15573
15574         * objects.cs: New test for 'is' operator on an array of interfaces.
15575
15576 Wed Oct 1 19:40:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
15577
15578         * tramp-ppc.c: update trampoline code to support jumps
15579         and class initialization.
15580
15581 2003-09-30  Zoltan Varga  <vargaz@freemail.hu>
15582
15583         * mini.c (mono_jit_compile_method): Fix reading of freed memory.
15584
15585         * inssel.brg (OP_UNBOXCAST): Fix #46027.
15586
15587         * inssel.brg (OP_UNBOX): Remove unused rule.
15588
15589         * mini.h mini.c inssel-x86.brg: Allocate one SP variable for each
15590         region instead of one for each method. Fixes #47813.
15591
15592 2003-09-29  Zoltan Varga  <vargaz@freemail.hu>
15593
15594         * exceptions.cs (test_0_nested_finally): New regression test for
15595         nested exception handlers.
15596
15597         * mini.c (mono_jit_runtime_invoke): Fix for the previous fix.
15598
15599         * mini.c (mono_method_to_ir): Avoid inlining tail calls.
15600
15601         * mini.c (mono_method_to_ir): Fix tail recursion in the presence of 
15602         inlining.
15603
15604         * mini.c (mono_method_check_inlining): Make the inlining limit 
15605         configurable by an environment variable.
15606         
15607         * mini.c (mono_jit_runtime_invoke): Add Gonzalo's fix for #36545.
15608
15609         * mini.h: Bump AOT file version.
15610
15611         * mini.h mini.c aot.c mini-x86.c: For relocations which refer to a 
15612         token, store the image along with the token, since the token might not 
15613         refer to the same image as the method containing the relocation, 
15614         because of inlining.
15615
15616 2003-09-27  Zoltan Varga  <vargaz@freemail.hu>
15617
15618         * mini.c (mono_precompile_assemblies): New function to compile
15619         all methods in all loaded assemblies.
15620
15621         * mini.h driver.c: Added new optimization flag MONO_OPT_PRECOMP.
15622
15623         * regalloc.h regalloc.c (MonoRegState): Change the type of 
15624         iassign and fassign to int*, since they can contain large negative
15625         values if the register is spilled. Also added some comments. Fixes
15626         #45817.
15627
15628         * exceptions-x86.c (seh_handler): Fix handling of system exceptions
15629         under Win32. Fixes #42964.
15630
15631 2003-09-26  Zoltan Varga  <vargaz@freemail.hu>
15632
15633         * mini.h (MONO_PATCH_INFO_WRAPPER): New patch type.
15634
15635         * aot.c: Added support for AOT compiling methods which contain calls
15636         to wrappers. Currently, only remoting-invoke-with-check wrappers are
15637         handled.
15638         
15639         * driver.c (compile_all_methods): Run the compilation in a thread
15640         managed by mono. Fixes #44023.
15641
15642         * mini.c (mono_codegen): Print full method name in verbose output.
15643
15644         * mini-x86.c (mono_arch_patch_code): Fix warning.
15645         
15646         * mini-x86.c (mono_arch_patch_code): Allways create a trampoline for
15647         jumps, since the method we are jumping to might be domain-specific.
15648
15649         * aot.c: Added support for MONO_PATCH_INFO_METHOD_JUMP.
15650
15651 Tue Sep 23 10:50:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
15652
15653         * inssel.brg: string chars are unsigned.
15654
15655 2003-09-15  Zoltan Varga  <vargaz@freemail.hu>
15656
15657         * TODO: New todo item.
15658
15659         * tramp-x86.c (x86_class_init_trampoline): New trampoline function
15660         which calls mono_runtime_class_init and patches the call site to
15661         avoid further calls.
15662         (mono_arch_create_class_init_trampoline): New arch specific function 
15663         to create a class init trampoline.
15664         (create_trampoline_code): Generalized so it can create
15665         class init trampolines as well.
15666
15667         * mini.c (helper_sig_class_init_trampoline): New helper variable.
15668         (mono_create_class_init_trampoline): New function to create and cache
15669         class init trampolines.
15670         (mono_find_class_init_trampoline_by_addr): New function to lookup the
15671         vtable given the address of a class init trampoline. Used by the
15672         patching process.
15673         (mono_codegen): Generate a call to a trampoline instead of
15674         mono_runtime_class_init in LDSFLD[A].
15675         (mono_codegen): Add relocations for the new trampoline.
15676         
15677         * mini.h mini-x86.c aot.c: Added a new relocation type: 
15678         MONO_PATCH_INFO_CLASS_INIT.
15679
15680         * mini.h: Bump AOT version number.
15681
15682         * aot.c: Create a copy of the loaded code instead of using the original
15683         so methods which call each other will be close in memory, improving
15684         cache behaviour.
15685         
15686         * exceptions-x86.c (mono_arch_has_unwind_info): Back out the previous
15687         patch since it breaks the regression tests.
15688         
15689         * exceptions-x86.c (mono_arch_has_unwind_info): Added explicit check
15690         for the register saving instruction sequence since the 
15691         frame_state_for function in glibc 2.3.2 don't seem to detect it.
15692
15693 2003-09-14  Zoltan Varga  <vargaz@freemail.hu>
15694
15695         * TODO: Fix todo item && remove another.
15696
15697 2003-09-12  Zoltan Varga  <vargaz@freemail.hu>
15698
15699         * mini-x86.c (mono_arch_patch_code): Fix tail calls broken by a
15700         previous checkin.
15701
15702         * aot.c: Moved the check for MONO_LASTAOT into the initialization
15703         function of the module.
15704
15705         * mini.h mini.c aot.c: Added a new optimization flag OPT_AOT for
15706         turning on/off the usage of AOT code. Got rid of mono_no_aot and the
15707         --no-aot command line option.
15708
15709 2003-09-11  Zoltan Varga  <vargaz@freemail.hu>
15710
15711         * helpers.c (mono_disassemble_code): Make this work under cygwin. Patch
15712         by Bernie Solomon (bernard@ugsolutions.com).
15713
15714         * inssel.brg: Refactor the interface offset table related code into
15715         its separate functions and add support for the AOT case.
15716
15717 2003-09-10  Zoltan Varga  <vargaz@freemail.hu>
15718
15719         * aot.c (mono_aot_get_method_inner): Fix memory leak.
15720         
15721         * aot.c: Added mono_aot_verbose variable and made all debugging
15722         output depend on the value of this variable.
15723
15724         * aot.c (mono_aot_get_method_inner): Avoid dynamic allocation of
15725         method_label and info_label.
15726
15727         * mini.h mini-x86.c aot.c: Added a new relocation type 
15728         MONO_PATCH_INFO_IID for klass->interface_id.
15729
15730         * mini.h mini.c driver.c aot.c: Changed mono_aot_get_method to return
15731         the MonoJitInfo structure.
15732
15733         * mini.c (mono_jit_compile_method): Avoid using non-shared AOT in
15734         a non-root appdomain in shared mode.
15735
15736 Tue Sep 9 16:33:07 CEST 2003 Paolo Molaro <lupus@ximian.com>
15737
15738         * aot.c: make aot loader less verbose. Remove free of unused variable.
15739
15740 2003-09-08  Zoltan Varga  <vargaz@freemail.hu>
15741
15742         * aot.c (mono_aot_get_method_inner): Fix MONO_PATCH_INFO_IMAGE.
15743
15744         * .cvsignore: Added *.dll.
15745
15746         * mini.c (mono_print_tree_nl): New function callable while debugging.
15747
15748         * mini.c (mono_print_code): Export this.
15749
15750         * tramp-x86.c (x86_magic_trampoline): Tell valgrind to recompile the
15751         patched code.
15752
15753 2003-09-05  Zoltan Varga  <vargaz@freemail.hu>
15754
15755         * mini.h (MonoCompile): Added 'jit_info' field.
15756
15757         * mini.c (mini_method_compile): Save the generated MonoJitInfo into
15758         the cfg structure, since it is needed by the AOT compiler.
15759
15760         * mini.h (MONO_AOT_FILE_VERSION): Bump version number.
15761
15762         * aot.c: A major rewrite. Changes include:
15763         - save exception tables for methods which have them.
15764         - cache failed lookups in aot_get_method () to avoid the (slow) calls 
15765         to g_module_symbol.
15766         - reworked the file format so it is now much smaller and needs
15767         fewer relocation entries.
15768         
15769 2003-09-04  Zoltan Varga  <vargaz@freemail.hu>
15770
15771         * aot.c (load_aot_module): Fix build bustage on platforms without
15772         Boehm GC.
15773
15774 2003-09-04  Martin Baulig  <martin@ximian.com>
15775
15776         * Makefile.am (INCLUDES): Added $(LIBGC_CFLAGS).
15777
15778 2003-09-04  Zoltan Varga  <vargaz@freemail.hu>
15779
15780         * TODO: Some new optimization ideas.
15781
15782         * aot.c: Move AOT module loading logic here from mono_assembly_open.
15783
15784         * aot.c: Save the optimization flags used to compile the code into
15785         the AOT module.
15786
15787         * mini.h mini-x86.c mini.c aot.c: Added new types of relocations to
15788         support emitting domain specific code.
15789         
15790         * mini.h mini.c aot.c: Modified the JIT so the generated AOT code is 
15791         no longer domain neutral. It can be made domain neutral by compiling 
15792         with --optimize=shared.
15793
15794         * aot.c (mono_aot_get_method_inner): Allow sharing of AOT methods
15795         between appdomains.
15796
15797         * driver.c mini.h mini.c: New --no-aot debugging option which disables
15798         loading of AOT code.
15799
15800         * inssel-x86.brg: Added missing AOTCONST -> OUTARG_VT rule.
15801         
15802         * tramp-x86.c (x86_magic_trampoline): Avoid patching the calling method
15803         if there is no domain neutrality information.
15804
15805 2003-09-01  Zoltan Varga  <vargaz@freemail.hu>
15806
15807         * aot.c (mono_compile_assembly): Emit a symbol containing the file 
15808         format version into the generated library.
15809
15810         * mini-x86.c (mono_arch_patch_code): Do not emit the address of the
15811         callee method into the caller since one of them could be shared.
15812
15813         * mini.h mini-x86.c aot.c: Added two new relocations so throwing
15814         system exceptions from AOT code now works.
15815
15816         * tramp-x86.c (x86_magic_trampoline): Avoid patching the calling 
15817         method if it is domain neutral and the callee is not.
15818
15819         * graph.c (cfg_emit_one_loop_level): Fix warning.
15820
15821 2003-08-30  Zoltan Varga  <vargaz@freemail.hu>
15822
15823         * aot.c (mono_compile_assembly): Oops. Remove debugging cruft from
15824         last checkin.
15825
15826 2003-08-29  Zoltan Varga  <vargaz@freemail.hu>
15827
15828         * mini.c (mini_init): Call mono_marshal_init () explicitly since it
15829         is needed  by code which is executed before mono_runtime_init ().
15830         Thanks to Bernie Solomon (bernard@ugsolutions.com) for noticing this.
15831         
15832         * mini.c (mono_thread_abort): Fix warning.
15833         (mono_jit_compile_method): Call static constructor in the AOT case too.
15834
15835         * aot.c (mono_compile_assembly): Fix warning.
15836
15837 2003-08-28  Gonzalo Paniagua Javier <gonzalo@ximian.com>
15838
15839         * mini.c: register a SIGINT handler if MONO_DEBUG is defined.
15840
15841 2003-08-28  Zoltan Varga  <vargaz@freemail.hu>
15842
15843         * inssel.brg (OP_UNBOXCAST): Add support for the AOT case.
15844
15845         * cpu-pentium.md: Fix the length of call opcodes so they include the
15846         ESP restoring instruction. Fixes #47968.
15847
15848 2003-08-28  Martin Baulig  <martin@ximian.com>
15849
15850         * mini-x86.c (mono_arch_call_opcode): Added support for
15851         MONO_TYPE_GENERICINST.
15852
15853         * mini.c (check_call_signature): Added support for MONO_TYPE_GENERICINST.       
15854
15855 2003-08-27  Zoltan Varga  <vargaz@freemail.hu>
15856
15857         * Makefile.am (BUILT_SOURCES): Fix compilation on platforms without
15858         a JIT. Patch by Bernie Solomon (bernard@ugsolutions.com).
15859
15860         * mini.c jit-icalls.c tramp-x86.c tramp-ppc.c tramp-sparc.c: Get rid of
15861         metadata_section.
15862
15863 2003-08-26  Martin Baulig  <martin@ximian.com>
15864
15865         * mini.c (get_basic_blocks): Added `unsigned char **pos' argument;
15866         when reporting an error, set this to the actual error location.
15867         (mono_method_to_ir): Report the correct error location if
15868         get_basic_blocks() returned an error.
15869
15870 2003-08-25  Zoltan Varga  <vargaz@freemail.hu>
15871
15872         * mini.c (mono_type_blittable): OBJECT is not blittable.
15873         (mono_method_blittable): Methods which have marshalling descriptors
15874         are not blittable either. Fixes #47842.
15875
15876 2003-08-22  Zoltan Varga  <vargaz@freemail.hu>
15877
15878         * driver.c mini.c: Use an environment variable instead of a global 
15879         variable. Also fix the build.
15880
15881         * mini.c (mini_init): Call g_thread_init () to make glib thread-safe. 
15882         Fixes #47682. Thanks to Laurent Morichetti (l_m@pacbell.net) for 
15883         reporting this. 
15884
15885         * driver.c mini.c: Added --with-valgrind option to turn off some
15886         code which prevents mono from running under valgrind.
15887
15888         * mini.c (mono_emit_call_args): Fixed warning.
15889
15890         * mini.c (mono_emulate_opcode): Fixed warning.
15891
15892 Thu Aug 21 19:10:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
15893
15894         * inssel.brg: 64bit fixes from Laurent Morichetti <l_m@pacbell.net>.
15895         * linear-scan.c, mini-ppc.h, mini-sparc.h, mini-x86.h, mini.h,
15896         regalloc.c, regalloc.h: specify available registers in arch-specific
15897         code and support floats in the regallocator (patch by Laurent Morichetti 
15898         <l_m@pacbell.net>)
15899
15900 Wed Aug 20 19:02:22 CEST 2003 Paolo Molaro <lupus@ximian.com>
15901
15902         * mini.c: mono_thread_current() can be called only after
15903         mono_runtime_init(): rearrange code to not call it early on.
15904
15905 Wed Aug 20 13:14:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
15906
15907         * mini.c: allocate jump tables in the code mempools.
15908
15909 Wed Aug 20 13:04:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
15910
15911         * mini.c, mini.h: make sure per-thread data allocated by the jit is
15912         freed.
15913
15914 2003-08-10  Miguel de Icaza  <miguel@ximian.com>
15915
15916         * cpu-pentium.md (ldtoken): Change the length for mul.ovf.un from
15917         12 to 16.  This fixes bug #47453.
15918
15919
15920 Thu Aug 7 15:59:35 CEST 2003 Paolo Molaro <lupus@ximian.com>
15921
15922         * mini-ppc.c: fixed indexed load and unsigned compares.
15923
15924 2003-08-06  Lluis Sanchez Gual  <lluis@ximian.com>
15925
15926         * mini.c: reenabled installation of handler for
15927           thread abort signal.
15928
15929 Tue Aug 5 12:21:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
15930
15931         * cprop.c, mini-x86.c, cpu-pentium.md: fix buglets spotted
15932         by Laurent Morichetti <l_m@pacbell.net>. Disabled local cprop
15933         until it's fixed and actually useful.
15934
15935 Mon Aug 4 12:12:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
15936
15937         * inssel-long32.brg: couple more opcodes implemented.
15938
15939 Thu Jul 31 22:43:02 EDT 2003 Mark Crichton <crichton@gimp.org>
15940         
15941         * mini-sparc.c: Even more opcodes implemeted.
15942
15943 Thu Jul 31 19:36:03 EDT 2003 Mark Crichton <crichton@gimp.org>
15944
15945         * mini-sparc.c: More opcodes implemented.
15946
15947 Thu Jul 31 15:16:26 EDT 2003 Mark Crichton <crichton@gimp.org>
15948
15949         * mini-sparc.c: More opcodes implemented.
15950
15951 Wed Jul 30 22:31:02 EDT 2003 Mark Crichton <crichton@gimp.org>
15952
15953         * inssel-sparc.brg: Add some needed rules.  Direct
15954         copy from PPC.
15955         * Makefile.am: Use inssel-sparc.brg
15956         * exceptions-sparc.c: 0xdeadbeef/0xdecafbad to keep
15957         an assert happy for now.
15958
15959 Wed Jul 30 20:44:07 EDT 2003 Mark Crichton <crichton@gimp.org>
15960
15961         * mini-sparc.c: Fixed compile errors.
15962         * exceptions-sparc.c: Same.  We now produce a mono binary 
15963         on sparc-linux.  Yea.
15964
15965 Wed Jul 30 14:10:12 EDT 2003 Mark Crichton <crichton@gimp.org>
15966
15967         * mini-sparc.c: Renamed registers.  Also some macro cleanups.
15968         * exceptions-sparc.c, tramp-sparc.c: Various compile fixes.
15969         They compile, but do not work.
15970
15971 Wed Jul 30 17:52:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
15972
15973         * Makefile.am, cpu-sparc.md, exceptions-sparc.c, mini-sparc.c,
15974         mini-sparc.h, tramp-sparc.c: Beginning of sparc support
15975         from Mark Crichton <crichton@gimp.org> and Christopher Taylor
15976         (ct@gentoo.org).
15977
15978 Tue Jul 29 12:43:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
15979
15980         * mini.c: more opcodes implemented and better support for generics.
15981
15982 Fri Jul 25 18:51:45 CEST 2003 Paolo Molaro <lupus@ximian.com>
15983
15984         * cpu-g4.md, cpu-pentium.md: updates for new instructions.
15985         * mini.c, mini.h: first cut at generics support: some new instructions 
15986         added and changed the behaviour of some of the existing ones.
15987
15988 2003-07-21  Miguel de Icaza  <miguel@ximian.com>
15989
15990         * mini.c: Removed definition of metadata_shared mutex here.
15991
15992 Tue Jul 22 15:21:24 CEST 2003 Paolo Molaro <lupus@ximian.com>
15993
15994         * mini-x86.c: make vararg calls work for instance methods.
15995
15996 Fri Jul 18 19:26:20 CEST 2003 Paolo Molaro <lupus@ximian.com>
15997
15998         * mini.c, mini.h, mini-x86.c, mini-ppc.c: mono_arch_call_opcode()
15999         returns the arguments in a separte list, now.
16000
16001 Fri Jul 18 13:16:18 CEST 2003 Paolo Molaro <lupus@ximian.com>
16002
16003         * aot.c, mini.c: updates for array type representation changes.
16004
16005 Fri Jul 18 11:28:28 CEST 2003 Paolo Molaro <lupus@ximian.com>
16006
16007         * mini.c: register function to perform jit shutdown.
16008
16009 Thu Jul 17 16:02:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
16010
16011         * mini.c: use a faster allocator if possible.
16012
16013 Thu Jul 17 16:00:39 CEST 2003 Paolo Molaro <lupus@ximian.com>
16014
16015         * aot.c: some cleanups and portability changes.
16016
16017 Wed Jul 2 11:08:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
16018
16019         * mini.c: use faster allocation for CEE_BOX if possible.
16020
16021 Mon Jun 30 19:16:33 CEST 2003 Paolo Molaro <lupus@ximian.com>
16022
16023         * mini.c, mini-ops.h, inssel.brg, mini-x86.c: optimized access to fields.
16024         Moved inlined mempcy code to its own function so that is can be
16025         reused. Added an inline memset function as well (optimized initobj).
16026         * cpu-pentium.md, inssel-x86.brg: add and use lea_membase.
16027
16028 Fri Jun 27 11:19:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
16029
16030         * mini.c, mini-ops.h, inssel.brg: optimized a couple of Array methods.
16031
16032 Wed Jun 25 13:19:25 CEST 2003 Paolo Molaro <lupus@ximian.com>
16033
16034         * mini.c, mini.h, mini.x86.c, mini-ppc.c: added facility so that
16035         arch code can setup the cpu for CLR execution, if needed.
16036         We use it on x86 to set the precision of FP operations.
16037
16038 Tue Jun 17 19:02:55 CEST 2003 Paolo Molaro <lupus@ximian.com>
16039
16040         * mini.c: disable some optimizations if we can guess they'll cost too
16041         much for a given method.
16042
16043 2003-06-17  Zoltan Varga  <vargaz@freemail.hu>
16044
16045         * mini.h mini.c: Rework last patch based on suggestions by Paolo.
16046         
16047 2003-06-17  Zoltan Varga  <vargaz@freemail.hu>
16048         * mini.h mini.c mini-x86.c: Added instruction level coverage 
16049         info collection support.
16050
16051 Mon Jun 16 18:13:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
16052
16053         * driver.c, mini-ppc.c, mini-x86.c, mini.c, mini.h: the coverage stuff
16054         is now implemented in the profiling API. Get rid of a couple of
16055         unnecessary global variables.
16056
16057 2003-06-15  Nick Drochak <ndrochak@gol.com>
16058
16059         * basic-long.cs: tests for negative values for bigmul, and unsigned.
16060         * cpu-g4.md: add op_bigmul and op_bigmul_un
16061         * cpu_pentium.md: add op_bigmul_un
16062         * inssel-long32.brg: add rule for unsigned bigmul
16063         * mini-ops.h: define OP_BIGMUL_UN
16064         * mini-x86.c: THE BUG: handle (un)signed properly
16065         * mini.c: choose unsigned opcode if needed.
16066         This set of patches fixes bug #44291
16067
16068 2003-06-13  Dietmar Maurer  <dietmar@ximian.com>
16069
16070         * mini.c (optimize_branches): improved to handle all kinds of
16071         conditional branches.
16072
16073 Wed Jun 11 18:01:06 CEST 2003 Paolo Molaro <lupus@ximian.com>
16074
16075         * mini.c, mini.h, jit-icalls.c: speedup emulation of opcodes that
16076         don't raise exceptions.
16077
16078 Tue Jun 10 19:00:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
16079
16080         * tramp-x86.c, tramp-ppc.c, debug-mini.c: move arch-specific code
16081         to arch-specific files.
16082
16083 2003-06-09  Martin Baulig  <martin@ximian.com>
16084
16085         * Makefile.am (libs): Added $(LIBGC_LIBS).
16086
16087 Mon Jun 9 20:21:47 CEST 2003 Paolo Molaro <lupus@ximian.com>
16088
16089         * cpu-pentium.md, mini-x86.c: fix (well, actually implement) OP_TAN
16090         and OP_ATAN (fixes bug#44293).
16091
16092 Mon Jun 9 19:00:56 CEST 2003 Paolo Molaro <lupus@ximian.com>
16093
16094         * Makefile.am, mini-x86.c: rename cpu description array to
16095         pentium_desc, since some compilers define the 'pentium' preprocessor
16096         symbol.
16097
16098 2003-05-28  Dietmar Maurer  <dietmar@ximian.com>
16099
16100         * mini.c (mini_select_instructions): add explicit branch if the
16101         following block is not the false target of a conditional branch -
16102         we need this with any optimization that reorder or remove bblocks
16103
16104         * mini.c (optimize_branches): bug fixes
16105
16106 2003-06-06  Dietmar Maurer  <dietmar@ximian.com>
16107
16108         * mini.c (mono_method_to_ir): inline static readonly fields
16109
16110         * ssa.c (fold_tree): start cfold support for long (very simple
16111         cases only)
16112
16113         * cfold.c (mono_constant_fold_inst): opt. CEE_CONV_I8 (OP_ICONST)
16114
16115 Fri Jun 6 11:41:18 CEST 2003 Paolo Molaro <lupus@ximian.com>
16116
16117         * inssel.brg: fixed memcpy (bug #44219).
16118
16119 2003-06-05  Dick Porter  <dick@ximian.com>
16120
16121         * driver.c: Set the glib log levels to not abort if g_message
16122         recurses.
16123
16124         g_set_prgname() has to happen before mini_init() so that the
16125         process handle gets the info.
16126         
16127 Thu Jun 5 20:11:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
16128
16129         * driver.c: add intrins to the default optimizations to get wider
16130         exposure.
16131
16132 Wed Jun 4 19:47:57 CEST 2003 Paolo Molaro <lupus@ximian.com>
16133
16134         * mini.h: some large basic blocks will overflow a 16-bit
16135         integers for symbolic registers.
16136
16137 2003-06-04  Dietmar Maurer  <dietmar@ximian.com>
16138
16139         * mini-x86.c (mono_arch_output_basic_block): revert previous fprem changes.
16140         (mono_arch_output_basic_block): fix bug 43499 
16141
16142 Wed Jun 4 13:13:52 CEST 2003 Paolo Molaro <lupus@ximian.com>
16143
16144         * mini.c: kill duplicated definition of mono_debug_format.
16145
16146 Wed Jun 4 13:09:51 CEST 2003 Paolo Molaro <lupus@ximian.com>
16147
16148         * mini-x86.c, arrays.cs: fixed register allocation bug.
16149
16150 2003-06-04  Dietmar Maurer  <dietmar@ximian.com>
16151
16152         * mini-x86.c (mono_arch_output_basic_block): use IEEE compatible fprem1
16153
16154         * mini.c (mini_get_opcode_for_method): inline IEEERemainder
16155
16156 2003-06-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
16157
16158         * mini.c:
16159         (print_method_from_ip): also print source location information if
16160         available.
16161
16162 2003-06-02  Dietmar Maurer  <dietmar@ximian.com>
16163
16164         * mini.c (mono_find_block_region): bug fix in region code
16165         (mini_method_compile): enable removing unreachable code again, but
16166         only in methods without exception clauses.
16167
16168 Fri May 30 18:40:24 CEST 2003 Paolo Molaro <lupus@ximian.com>
16169
16170         * mini.c, mini-ops.h, cpu-pentium.md, inssel.brg, mini-x86.c, mini.h:
16171         Implemented arglist opcode and handling of TypedReference type.
16172         Fixed x86 call convention when a structure is returned.
16173         Minimal support for calling static vararg methods.
16174
16175 2003-05-30  Dietmar Maurer  <dietmar@ximian.com>
16176
16177         * mini.c (mini_method_compile):  always remove unreachable code,
16178         because the code in them may be inconsistent  (access to dead
16179         variables for example).
16180
16181 Thu May 29 11:44:49 CEST 2003 Paolo Molaro <lupus@ximian.com>
16182
16183         * driver.c, debug-mini.c: warning fixes.
16184
16185 Wed May 28 11:19:15 CEST 2003 Paolo Molaro <lupus@ximian.com>
16186
16187         * Makefile.am, jit.h, mini.h: install header for embedding mono.
16188
16189 Tue May 27 17:56:12 CEST 2003 Paolo Molaro <lupus@ximian.com>
16190
16191         * mini.c: thread-static fields are registered in mono_class_vtable(),
16192         so ensure the function is called before checking for them.
16193
16194 2003-05-27  Dietmar Maurer  <dietmar@ximian.com>
16195
16196         * mini.c (optimize_branches): fix for bug 43586
16197
16198         * jit-icalls.c (mono_llmult_ovf): added an additional check for
16199         overflow (fixes Bug #43639)
16200
16201 Tue May 27 11:33:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
16202
16203         * mini.c, objects.cs: allow the use of stobj for primitive types.
16204
16205 Tue May 27 10:33:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
16206
16207         * mini.c: be less strict about argument checking until we support
16208         running the verifier.
16209
16210 2003-05-27  Nick Drochak <ndrochak@gol.com>
16211
16212         * basic-long.cs: tests for (ulong)int * (ulong)int also
16213         * mini.c: use the same trick for (ulong)int * (ulong)int
16214
16215 2003-05-27  Nick Drochak <ndrochak@gol.com>
16216
16217         * basic-long.cs: add regression test for (long)int * (long)int
16218         * cpu-pentium.md: add op_bigmul specification
16219         * inssel-long32.brg: add OP_BIGMUL rule
16220         * mini-ops.h: add OP_BIGMUL
16221         * mini-x86.c: register allocator: handle case where src1 needs to be
16222         in EAX.
16223         * mini.c: substitute special BIGMUL opcode in the tree for 
16224         (long)int * (long)int
16225
16226 Mon May 26 20:20:13 CEST 2003 Paolo Molaro <lupus@ximian.com>
16227
16228         * jit-icalls.c: call the type ctor on field access if needed.
16229
16230 Mon May 26 15:21:21 CEST 2003 Paolo Molaro <lupus@ximian.com>
16231
16232         * mini-ops.h, mini.c, inssel.brg, exceptions.cs: validate arguments passed
16233         to a method (including results of ldelema, bug#43207).
16234
16235 2003-05-26  Dietmar Maurer  <dietmar@ximian.com>
16236
16237         * graph.c (cfg_emit_one_loop_level): loop over all blocks. use
16238         colors to show exception handler blocks.
16239
16240         * inssel-x86.brg (OP_OUTARG_VT): dont push zero sized structures
16241         (fix for pinvoke7.cs).
16242
16243 Mon May 26 12:11:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
16244
16245         * mini.h, mini.c: ensure correct initialization order for types that
16246         require it. Prepare for lazy compilation of jit icall wrappers.
16247         Provide a name for opcode emulation to reduce unneeded mallocing.
16248
16249 Fri May 23 16:08:54 CEST 2003 Paolo Molaro <lupus@ximian.com>
16250
16251         * mini-x86.c: better register restoring code and profiling
16252         support for tail calls.
16253
16254 Fri May 23 15:30:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
16255
16256         * mini.h, driver.c: prepare for leaf methods optimization.
16257
16258 Fri May 23 15:28:32 CEST 2003 Paolo Molaro <lupus@ximian.com>
16259
16260         * mini.c: get targets of branches before converting a method.
16261
16262 2003-05-23  Dietmar Maurer  <dietmar@ximian.com>
16263
16264         * mini.c (optimize_branches): added some experimental code (disbaled) 
16265
16266 2003-05-22  Dietmar Maurer  <dietmar@ximian.com>
16267
16268         * mini.c (optimize_branches): fix branch to branch optimization 
16269
16270         * exceptions-x86.c (mono_arch_handle_exception): bug fix.
16271
16272         * mini-x86.c (mono_arch_output_basic_block): cleanup up exception code
16273
16274         * inssel-x86.brg: added OP_START_HANDLER, CEE_ENDFINALLY, OP_ENDFILTER
16275
16276         * mini-x86.c (mono_arch_allocate_vars): only reserve space for lmf
16277         if needed.
16278
16279 2003-05-21  Dietmar Maurer  <dietmar@ximian.com>
16280
16281         * mini.c (mono_method_to_ir): call handle_loaded_temps before inlining.
16282         enable use of interface variables again.
16283
16284         * mini-x86.c (mono_arch_get_allocatable_int_vars): dont allocate
16285         I1 to registers because there is no simply way to sign extend 8bit
16286         quantities in caller saved registers on x86.
16287
16288         * inssel-float.brg: set costs of some rules to 2 so
16289         that monobure always select the arch. specific ones if supplied,
16290         regardless of the order we pass the files to monoburg.
16291
16292 Tue May 20 17:19:14 CEST 2003 Paolo Molaro <lupus@ximian.com>
16293
16294         * mini.c, mini-x86.c: since the magic trampoline for jumps
16295         can't patch the code directly, we do it as soon as the
16296         method gets compiled.
16297
16298 Tue May 20 16:02:52 CEST 2003 Paolo Molaro <lupus@ximian.com>
16299
16300         * mini-x86.c, mini.h: introduce a new patching method
16301         to support CEE_JMP and tail calls.
16302         * mini.c: obey tail.call. Don't precompile methods target
16303         of CEE_JMP.
16304         * tramp-x86.c: new trampoline code to handle methods
16305         reached through a jump.
16306
16307 2003-05-20  Dietmar Maurer  <dietmar@ximian.com>
16308
16309         * mini-x86.c (mono_arch_get_allocatable_int_vars): allocate 8/16
16310         bit values to registers
16311
16312 2003-05-19  Dietmar Maurer  <dietmar@ximian.com>
16313
16314         * mini.c (mono_compile_get_interface_var): share interface
16315         variables if possible.
16316
16317 2003-05-16  Martin Baulig  <martin@ximian.com>
16318
16319         * debug-mini.c (mono_init_debugger): New function to initialize
16320         the debugger.  This is not in the debugger since it needs to
16321         access some of mini's internals.
16322
16323 2003-05-16  Dietmar Maurer  <dietmar@ximian.com>
16324
16325         * mini.c (mono_method_to_ir): inlining fixes/cleanups
16326
16327 Fri May 16 13:27:23 CEST 2003 Paolo Molaro <lupus@ximian.com>
16328
16329         * mini.c, mini-opts.h, inssel.brg: inline small memcpy
16330         for value type handling.
16331
16332 2003-05-16  Dietmar Maurer  <dietmar@ximian.com>
16333
16334         * mini.c (mono_method_to_ir): inline LDFLD/STFLD wrappers
16335         (mono_method_check_inlining): enable inlining of all kinds of wrappers
16336
16337 2003-05-15  Lluis Sanchez Gual  <lluis@ideary.com>
16338
16339         * mini.c: fixed little bug in CEE_NEWOBJ case when calling
16340           the constructor through a proxy.
16341
16342 Thu May 15 17:17:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
16343
16344         * jit-icalls.c, inssel.brg: fixes to array element address
16345         calculations.
16346
16347 2003-05-15  Dietmar Maurer  <dietmar@ximian.com>
16348
16349         * mini-x86.c (is_regsize_var): allocate pointer to registers
16350
16351 Thu May 15 13:04:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
16352
16353         * driver.c: fixed typo, added intrins to the set of optimizations
16354         tested with regressions.
16355
16356 Thu May 15 11:57:42 CEST 2003 Paolo Molaro <lupus@ximian.com>
16357
16358         * mini-ops.h, mini.c, inssel.brg: optimize access to 2D arrays.
16359         * jit-icalls.c, exceptions.cs: fixed index out of range checks, added
16360         test case.
16361
16362 2003-05-14  Dietmar Maurer  <dietmar@ximian.com>
16363
16364         * inssel.brg: remove some common pop instructions without side effects
16365
16366 Wed May 14 12:40:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
16367
16368         * inssel-x86.brg: fixed thinko in int to double conversions.
16369
16370 Wed May 14 12:01:58 CEST 2003 Paolo Molaro <lupus@ximian.com>
16371
16372         * mini.c, jit-icalls.c: added runtime thread-static variable support.
16373
16374 Tue May 13 22:02:06 CEST 2003 Paolo Molaro <lupus@ximian.com>
16375
16376         * inssel-long32.brg: two more missing instructions.
16377
16378 2003-05-13  Dietmar Maurer  <dietmar@ximian.com>
16379
16380         * mini.c (mono_emit_call_args): set the cil_code for all arguments
16381         if not already set.
16382
16383 2003-05-12  Zoltan Varga  <vargaz@freemail.hu>
16384
16385         * mini-x86.c (mono_arch_output_basic_block): Handle negative zero
16386         correctly.
16387
16388         * basic-float.cs: Added tests for negative zero.
16389
16390 Sun May 11 14:56:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
16391
16392         * inssel-long32.brg, basic-long.cs, exceptions.cs: handle
16393         a couple of missing operations for long casts, with test cases.
16394
16395 2003-05-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
16396
16397         * exceptions-x86.c: fixed small leaks in mono_arch_handle_exception.
16398
16399 2003-05-09  Dietmar Maurer  <dietmar@ximian.com>
16400
16401         * mini-x86.c (mono_arch_emit_prolog): avoid reallocs with better
16402         code size estimation.
16403
16404 2003-05-08  Dietmar Maurer  <dietmar@ximian.com>
16405
16406         * mini.c (mono_jit_create_remoting_trampoline): make it work with
16407         abstract methods (fix bug 42542)
16408
16409         * aot.c: add ability to handle array types
16410         
16411 2003-05-08  Zoltan Varga  <vargaz@freemail.hu>
16412
16413         * mini.c: Call the _specific versions of the object allocation
16414         functions if possible.
16415
16416 Tue May 6 17:18:33 CEST 2003 Paolo Molaro <lupus@ximian.com>
16417
16418         * driver.c: call setlocale ().
16419
16420 Tue May 6 14:38:22 CEST 2003 Paolo Molaro <lupus@ximian.com>
16421
16422         * mini.h, mini.c, aot.c, debug-mini.c, exceptions.c: build fixes for
16423         windows build.
16424
16425 2003-05-05  Dietmar Maurer  <dietmar@ximian.com>
16426
16427         * mini.c (optimize_branches): dont touch code inside exception clauses (fix bug 38136)
16428
16429         * exceptions-x86.c (ves_icall_get_frame_info): also skip remoting
16430         wrappers (fix bug 42122)
16431
16432 2003-05-04  Martin Baulig  <martin@ximian.com>
16433
16434         * mini.h (mono_jit_init, mono_jit_cleanup): Added prototypes.
16435
16436         * driver.c: s/MONO_OPT_SAHRED/MONO_OPT_SHARED/g.
16437         s/mini_set_defaults/mono_set_defaults/g.
16438
16439 2003-05-04  Martin Baulig  <martin@ximian.com>
16440
16441         * driver.c: s/mini_parse_default_optimizations/mono_parse_default_optimizations/g.
16442
16443 Sun May 4 11:48:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
16444
16445         * inssel-long32.brg: add missing lreg: OP_LCONV_TO_U8 (lreg) rule
16446         (reported by Don Roberts).
16447
16448 Fri May 2 18:36:45 CEST 2003 Paolo Molaro <lupus@ximian.com>
16449
16450         * mini.c: temporarily work around two bugs for this release.
16451
16452 Fri May 2 17:37:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
16453
16454         * Makefile.am: avoid linking libmono with GMODULE_LIBS, because
16455         that contains -export-dynamic and it makes using the ld script
16456         useless.
16457         * mini.h, main.c, driver.c: s/mini_main/mono_main/g.
16458
16459 Fri May 2 12:52:32 CEST 2003 Paolo Molaro <lupus@ximian.com>
16460
16461         * mini.h, mini-x86.c, driver.c: disable optimizations not available on a
16462         specific cpu.
16463
16464 Thu May 1 15:28:21 CEST 2003 Paolo Molaro <lupus@ximian.com>
16465
16466         * mini.c: make sure leave calls all the needed finally blocks,
16467         even when the target jumps out of multiple exception clauses.
16468
16469 Thu May 1 15:18:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
16470
16471         * ldscript, Makefile.am: add linker script to reduce the number of
16472         exported symbols (should also fix the issues with libwine defining
16473         some of the same symbols in io-layer).
16474
16475 2003-05-01  Zoltan Varga  <vargaz@freemail.hu>
16476
16477         * driver.c (mini_main): Avoid assertion when no file name is given on 
16478         the command line.
16479
16480 Wed Apr 30 15:33:11 CEST 2003 Paolo Molaro <lupus@ximian.com>
16481
16482         * driver.c: added --version/-V command line option.
16483         Added the inline optimization in the regression tests.
16484
16485 Wed Apr 30 15:16:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
16486
16487         * mini.c, basic-calls.cs: when inlining, save arguments to locals according 
16488         to the type in the method signature (fixes bug#42134).
16489
16490 Wed Apr 30 12:38:44 CEST 2003 Paolo Molaro <lupus@ximian.com>
16491
16492         * mini.c: when inlining, check this is not null only when needed (bug #42135).
16493
16494 Wed Apr 30 11:44:36 CEST 2003 Paolo Molaro <lupus@ximian.com>
16495
16496         * mini-ppc.h, tramp-pcc.c: type fixes from Max Horn <max@quendi.de>.
16497
16498 2003-04-30  Gonzalo Paniagua Javier <gonzalo@ximian.com>
16499
16500         * driver.c: fixed bug #42100.
16501
16502 2003-04-29  Dietmar Maurer  <dietmar@ximian.com>
16503
16504         * mini.c (mono_method_to_ir): UNBOX need to CAST objects first
16505
16506 Mon Apr 28 17:03:14 CEST 2003 Paolo Molaro <lupus@ximian.com>
16507
16508         * mini.c: moved most of the code required to do inlining to its own
16509         function so it can be reused. Inline also ctors if appropriate.
16510
16511 2003-04-28  Zoltan Varga  <vargaz@freemail.hu>
16512
16513         * Makefile.am: Link with -export-dynamic so shared libs loaded by
16514         the runtime can call mono API functions.
16515
16516 2003-04-27  Martin Baulig  <martin@ximian.com>
16517
16518         * debug-mini.c (mono_debug_init_method): Added
16519         `guint32 breakpoint_id' argument; if the method has a breakpoint,
16520         send a notification to the debugger.
16521
16522         * mini.c (mono_method_to_ir): Don't insert a breakpoint if we're
16523         running in the Mono Debugger, just pass the breakpoint number to
16524         mono_debug_init_method().
16525
16526         * tramp-x86.c, tramp-ppc.c: Removed the breakpoint trampolines.
16527
16528 Sun Apr 27 13:18:04 CEST 2003 Paolo Molaro <lupus@ximian.com>
16529
16530         * mini.c: allow some more unsafe compares.
16531
16532 Sat Apr 26 11:55:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
16533
16534         * mini-x86.c, Makefile.am: make distcheck works (partially from
16535         a patch by Richard Lee <r.h.lee@attbi.com>).
16536         * regset.c, regset.h: removed, they are unused.
16537
16538 2003-04-25  Dick Porter  <dick@ximian.com>
16539
16540         * driver.c: Usage reports the name as 'mono' not 'mini'
16541         * exceptions-x86.c: Build and run on freebsd
16542
16543 Thu Apr 24 17:09:03 CEST 2003 Paolo Molaro <lupus@ximian.com>
16544
16545         * Makefile.am: install the program with the 'mono' name and
16546         the library as libmono instead of mini and libmini.
16547
16548 Thu Apr 24 17:08:07 CEST 2003 Paolo Molaro <lupus@ximian.com>
16549
16550         * driver.c: provide the APIs for the embedding interface of the old jit.
16551
16552 2003-04-23  Dietmar Maurer  <dietmar@ximian.com>
16553
16554         * jit-icalls.c (helper_stelem_ref): impl. (fix bug 41775)
16555
16556 2003-04-23  Martin Baulig  <martin@ximian.com>
16557
16558         * tramp-x86.c, tramp-ppc.c: Reenable the debugger breakpoint interface.
16559
16560         * driver.c: Added `--debug' command line argument to enable
16561         debugging support.
16562
16563 2003-04-23  Martin Baulig  <martin@ximian.com>
16564
16565         * debug.[ch]: Removed.  The code is now in
16566         ../metadata/mono-debug.[ch] and mono-debug-debugger.[ch].
16567
16568         * debug-stabs.c, debug-dwarf2.c: Removed; nobody used this for the
16569         last six months.
16570
16571 2003-04-22  Dietmar Maurer  <dietmar@ximian.com>
16572
16573         * mini.c (mono_method_to_ir): set the cil_code address (fix bug 41525)
16574
16575 2003-04-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
16576
16577         * mini.c:
16578         (mini_cleanup): moved mono_runtime_cleanup call after the call to
16579         mono_domain_finalize.
16580         (mini_method_compile): use mono_method_profile* if the the option is
16581         enabled.
16582
16583 2003-04-17  Zoltan Varga  <vargaz@freemail.hu>
16584
16585         * tramp-x86.c (mono_arch_create_jit_trampoline): Subsitute synchronized
16586         methods with their wrapper.
16587
16588         * tramp-ppc.c (mono_arch_create_jit_trampoline): Subsitute synchronized
16589         methods with their wrapper.
16590
16591         * jit-icalls.c (mono_ldvirtfn): Subsitute synchronized methods with
16592         their wrapper.
16593
16594         * mini.c (mono_method_to_ir): Subsitute synchronized methods with their
16595         wrapper.
16596
16597         * mini.c (mono_method_check_inlining): Avoid inlining synchronized
16598         methods.
16599
16600 2003-04-17  Dietmar Maurer  <dietmar@ximian.com>
16601
16602         * exceptions-x86.c (mono_arch_handle_exception): fix for bug 36252
16603
16604 2003-04-16  Dietmar Maurer  <dietmar@ximian.com>
16605
16606         * mini.c (mono_compile_create_var): use g_malloc/g_realloc instead
16607         of the mempool. This is slightly faster and uses less memory
16608
16609 Wed Apr 16 12:53:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
16610
16611         * mini.c: avoid O(n) allocation for variables.
16612
16613 Tue Apr 15 19:13:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
16614
16615         * mini.c: handle items on the stack after inlining methods.
16616
16617 Tue Apr 15 14:17:57 CEST 2003 Paolo Molaro <lupus@ximian.com>
16618
16619         * mini.c: make the method->opcode optimization dependent
16620         on MONO_OPT_INSTRINS and do it lazily.
16621
16622 Tue Apr 15 14:15:39 CEST 2003 Paolo Molaro <lupus@ximian.com>
16623
16624         * driver.c: print overall results at the end of regression run.
16625
16626 Tue Apr 15 11:18:46 CEST 2003 Paolo Molaro <lupus@ximian.com>
16627
16628         * inssel.brg: don't overwrite symbolic registers.
16629
16630 Mon Apr 14 17:41:34 CEST 2003 Paolo Molaro <lupus@ximian.com>
16631
16632         * inssel-x86.brg: fix conversion from long to float.
16633
16634 2003-04-11  Dietmar Maurer  <dietmar@ximian.com>
16635
16636         * mini.c (mini_init): use an opcode for get_Chars (OP_GETCHR)
16637
16638 2003-04-10  Zoltan Varga  <vargaz@freemail.hu>
16639
16640         * mini.c (mono_type_blittable): MONO_TYPE_OBJECT is blittable.
16641
16642         * driver.c: Added --print-vtable option as in the old JIT.
16643
16644 Thu Apr 10 17:43:49 CEST 2003 Paolo Molaro <lupus@ximian.com>
16645
16646         * inssel-long32.brg, exceptions.cs: fix conversions from long, too.
16647
16648 Thu Apr 10 16:27:43 CEST 2003 Paolo Molaro <lupus@ximian.com>
16649
16650         * inssel.brg, basic.cs: fixed checked conversions to byte and short.
16651
16652 2003-04-09  Zoltan Varga  <vargaz@freemail.hu>
16653
16654         * mini.c regalloc.c regalloc.h: Fix memory leak.
16655
16656 2003-04-09  Dietmar Maurer  <dietmar@ximian.com>
16657
16658         * aot.c (mono_aot_get_method): register all used strings
16659
16660 Wed Apr 9 15:22:18 CEST 2003 Paolo Molaro <lupus@ximian.com>
16661
16662         * mini.c: always intern strings references with ldstr at compile time.
16663
16664 Tue Apr 8 11:41:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
16665
16666         * Makefile.am: add BUILT_SOURCES.
16667
16668 Mon Apr 7 16:31:34 CEST 2003 Paolo Molaro <lupus@ximian.com>
16669
16670         * driver.c: give a better error message when the assembly to execute
16671         doesn't have an entry point.
16672
16673 2003-04-07  Dietmar Maurer  <dietmar@ximian.com>
16674
16675         * Makefile.am: added hack for automake
16676
16677         * mono/mini/mini.c (mono_save_args): always copy arguments to keep
16678         correct sematics.
16679
16680         * mono/mini/ssa.c (mono_ssa_avoid_copies): don't optimize calls
16681
16682 22003-04-07  Martin Baulig  <martin@ximian.com>
16683
16684         * Makefile.am: Added Makefile.am.
16685
16686         * debugger-main.c: Removed, this is now in the debugger where it
16687         belongs.
16688
16689         * mini.pc.in: Call this package `mini' for the moment.
16690
16691
16692
16693
16694
16695
16696
16697
16698
16699
16700
16701
16702
16703