1 2008-12-29 Zoltan Varga <vargaz@gmail.com>
5 * mini-exceptions.c: Check jit_tls->class_cast_from instead of class_cast_to
6 since only the former is nulled out after a successful cast. This prevents
7 crashes with rethrown exceptions when using --debug=casts.
9 2008-12-24 Mark Probst <mark.probst@gmail.com>
13 * mini.h: New macro for checking whether a method is final,
14 i.e. whether the method or its class is marked final.
16 * method-to-ir.c: Use the new macro for all final-checks
17 consistently. Fixes the crash in the System.ServiceModel tests.
19 2008-12-24 Mark Probst <mark.probst@gmail.com>
21 * mini-ppc.c (mono_arch_build_imt_thunk): Fix the build.
23 2008-12-23 Mark Probst <mark.probst@gmail.com>
27 * mini-ppc.c (mono_arch_build_imt_thunk): Save and restore r11.
28 Clobbering it is not allowed because the caller might use it as
29 the vtable register in the interface call.
31 2008-12-23 Mark Probst <mark.probst@gmail.com>
33 * mini-exceptions.c (get_exception_catch_class): Removed another
34 overly strict assertion. Fixes #461198.
36 2008-12-19 Mark Probst <mark.probst@gmail.com>
38 * mini-exceptions.c (get_exception_catch_class): Removed overly
41 2008-12-19 Mark Probst <mark.probst@gmail.com>
45 * method-to-ir.c: Removed an unnecessary assertion.
47 2008-12-16 Martin Baulig <martin@ximian.com>
51 * method-to-ir.c (mono_method_to_ir): Disable debugging
52 information for the init locals block to make the debugger stop
53 after all locals have been initalized.
55 2008-12-16 Martin Baulig <martin@ximian.com>
59 * mini.c (mini_method_compile): Disable MONO_OPT_DEADCE when
60 running inside the debugger.
62 2008-12-16 Martin Baulig <martin@ximian.com>
64 Backport of r120407 from Zoltan Varga.
66 * mini.c (mini_method_compile): Only run local deadce if MONO_OPT_DEADCE
69 * method-to-ir.c (mono_method_to_ir): Fix invalid code generated by the
70 alu->alu imm optimization which only shows if deadce is disabled.
72 2008-12-16 Martin Baulig <martin@ximian.com>
76 * mini-exceptions.c (mono_handle_native_sigsegv): Check
77 mono_debug_using_mono_debugger() in addition to the
78 `no_gdb_backtrace' flag in the `MonoDebugOptions'.
80 2008-12-14 Zoltan Varga <vargaz@gmail.com>
84 * method-to-ir.c (mono_method_to_ir): Set the type of the value pushed on
85 the stack in CEE_LDFLDA. Fixes #450542.
87 * generics.cs: Add a new test.
89 2008-12-14 Zoltan Varga <vargaz@gmail.com>
93 * liveness.c (mono_analyze_liveness): Avoid eliminating the 'this' var in
94 gshared code. Fixes #458947.
96 * generics.cs: Add a test.
98 2008-12-12 Zoltan Varga <vargaz@gmail.com>
102 * mini-arm.c tramp-arm.c: Fix calls to mono_arch_flush_icache.
104 2008-12-10 Rodrigo Kumpera <rkumpera@novell.com>
106 * ssa.c (fold_ins): branch opt can kill dummy switch ops so we can't
107 expect that an OP_BR_REG will be there.
109 * branch-opts.c (remove_block_if_useless): Use MONO_IS_BRANCH_OP instead of checking
110 for the many branch ops. The original check miss OP_BR_REG.
114 Backported from trunk r121173 and r121175
116 2008-12-09 Zoltan Varga <vargaz@gmail.com>
120 * aot-runtime.c (load_method): Avoid calling decode_exception_debug_info
121 while holding the aot lock.
123 2008-12-09 Zoltan Varga <vargaz@gmail.com>
127 * aot-runtime.c (decode_exception_debug_info): Acquire the domain
128 lock when calling mono_domain_alloc (). Hopefully fixes #415608.
130 2008-12-08 Zoltan Varga <vargaz@gmail.com>
134 * mini-exceptions.c (mono_print_thread_dump): Mark threadpool threads
135 as such. Fixes #456669.
137 2008-12-04 Zoltan Varga <vargaz@gmail.com>
141 * aot-compiler.c (add_wrappers): Add pinvoke wrappers.
143 * mini.c (mono_resolve_patch_target): Allow pinvoke methods in
144 MONO_PATCH_INFO_ICALL_ADDR.
146 2008-12-03 Mark Probst <mark.probst@gmail.com>
150 * method-to-ir.c (mono_method_to_ir): Handle ldtoken of an open
151 generic type (via a typedef or typeref) correctly.
153 2008-12-03 Zoltan Varga <vargaz@gmail.com>
157 * mini-trampolines.c (mono_magic_trampoline): Add some debugging code to help
158 diagnose an assertion failure.
160 2008-11-29 Zoltan Varga <vargaz@gmail.com>
164 * mini.h aot-runtime.c: Fix building with DISABLE_AOT.
166 2008-11-17 Rodrigo Kumpera <rkumpera@novell.com>
168 * simd-intrinsics.c (vector2l_intrinsics): CompareGreaterThan requires sse 4.2
171 Backported from trunk.
173 2008-11-17 Zoltan Varga <vargaz@gmail.com>
175 * mini-amd64.h: Change the monitor fastpath defines to check for
176 !PLATFORM_WIN32 so they work on *bsd too.
178 2008-11-11 Zoltan Varga <vargaz@gmail.com>
180 * regalloc2.c (assign_spill_slots): Set cfg->rgctx_var.
182 2008-11-10 Mark Probst <mark.probst@gmail.com>
184 * mini-x86.c (mono_arch_get_argument_info): Don't align argument
185 space for stdcall. Fixes regressions on Win32.
187 2008-11-10 Zoltan Varga <vargaz@gmail.com>
189 * regalloc2.c (handle_reg_constraints): Avoid adding code to unreachable
191 (linear_scan): Remove an assert which doesn't seem to be needed.
193 * local-propagation.c (mono_local_deadce): Avoid a call to
194 MONO_DELETE_INS which would screw up the instruction linking.
196 * mini.c (mono_decompose_op_imm): Make this work with globalra.
198 * regalloc2.c: Upgrade to work the current JIT code.
200 2008-11-09 Zoltan Varga <vargaz@gmail.com>
202 * method-to-ir.c (inline_method): Merge more basic blocks to help the AOT
205 * aot-runtime.c: Remove some dead code.
207 * tramp-arm.c: Use 'code' as the runnning pointer in code generation for
209 (mono_arch_create_rgctx_lazy_fetch_trampoline_full): Implement aot support.
211 * aot-runtime.c (load_named_code): Decode the offset of lazy fetch
212 trampolines using sscanf since atoi doesn't work on large unsigned values.
214 * tramp-amd64.c (mono_arch_create_rgctx_lazy_fetch_trampoline_full):
215 Initialize code_size.
217 2008-11-08 Mark Probst <mark.probst@gmail.com>
219 * method-to-ir.c (mini_emit_inst_for_method): Make
220 Interlocked.CompareExchange work for Int arguments on 32 bit
223 2008-11-07 Mark Probst <mark.probst@gmail.com>
225 * method-to-ir.c (mono_method_to_ir2): Fixed a funny commit error.
227 2008-11-06 Bill Holmes <billholmes54@gmail.com>
229 * main.c Fix MSVC build.
231 Contributed under MIT/X11 license.
233 2008-11-06 Mark Probst <mark.probst@gmail.com>
235 * mini-x86.c (mono_arch_allocate_vars): Make sure locals that need
236 alignment larger than 8 bytes are aligned correctly, too.
238 * mini.c: Honor the min_align field of MonoClass when laying out
241 2008-11-06 Zoltan Varga <vargaz@gmail.com>
243 * method-to-ir.c (mono_method_to_ir2): Fix AOT support for CEE_SWITCH on arm.
245 * aot-compiler.c (emit_plt): Fix a warning.
247 * aot-compiler.c: Implement ARM support in the binary writer.
249 2008-11-05 Rodrigo Kumpera <rkumpera@novell.com>
251 * basic-simd.cs: Add test for getter with byref arg.
252 Fix the naming of a few tests.
253 Add missing checks to a test.
255 2008-11-05 Zoltan Varga <vargaz@gmail.com>
257 * aot-compiler.c (emit_plt): Make the arm code work with the binary writer.
259 * aot-compiler.c aot-runtime.c mini-trampolines.c tramp-amd64.c: Implement
260 most of the full-aot support for monitor enter/exit trampolines.
262 * tramp-x86.c tramp_amd64.c: Add AOT compatible variants of the monitor
263 enter/exit trampoline creation functions.
265 * Makefile.am: Fix the generation of buildver.h so it is not invoked during
268 Wed Nov 5 16:28:53 CET 2008 Paolo Molaro <lupus@ximian.com>
270 * mini.h, aot-compiler.c, method-to-ir.c, aot-runtime.c: remove the
271 incorrectly added MONO_WRAPPER_MONITOR_* (in r117651-r117652) and
272 implement the needed functionality without adding crap to the runtime.
274 2008-11-05 Zoltan Varga <vargaz@gmail.com>
276 * mini-trampolines.c (mono_create_monitor_enter_trampoline): Fix the
279 * mini.c (mono_build_date): New global version holding the build date in
282 * Makefile.am (buildver.c): Generate a file containing the build date.
284 * main.c: Set the build date from the generated file.
286 * mini.c (mono_get_runtime_build_info): New helper function returning build
287 information in a string format.
289 * driver.c (mono_main): Print the build date in --version.
291 * aot-compiler.c aot-runtime.c: Embed the build information into the AOT
292 file when the bind-to-runtime-version option is used.
294 2008-11-05 Rodrigo Kumpera <rkumpera@novell.com>
296 * simd-intrinsics.c: Fix bug when using getters and byref args.
298 2008-11-05 Rodrigo Kumpera <rkumpera@novell.com>
300 * simd-methods.h: Rename prefetch methods.
302 * simd-intrinsics.c: Same.
304 2008-11-05 Mark Probst <mark.probst@gmail.com>
306 * tramp-amd64.c: Enlarge the Monitor.Enter/Exit trampoline code
309 2008-11-04 Zoltan Varga <vargaz@gmail.com>
311 * aot-compiler.c: Use the bundled elf header files instead of depending on
314 * aot-compiler.c (emit_symbol_diff): Allocate memory from the acfg
317 * method-to-ir.c (mono_method_check_inlining): Avoid a getenv () call
320 2008-11-04 Rodrigo Kumpera <rkumpera@novell.com>
322 * cpu-x86.md: Add store nta ops.
328 * mini.h: Add an enum for simd prefetch modes.
330 * simd-methods.h: Refactor the store_aligned code to handle multiple kinds
331 of store. Use the changed code to support store nta.
333 * simd-intrinsics.c: Add prefetch ops for all vector types.
335 2008-11-04 Zoltan Varga <vargaz@gmail.com>
337 * aot-compiler.c: Add an option for JIT compiling the methods by multiple
340 * aot-compiler.c: Use statically allocated buffers for constructing symbol
343 * aot-runtime.c aot-compiler.c: Add support for the MONITOR_ENTER/EXIT
346 2008-11-04 Mark Probst <mark.probst@gmail.com>
348 * mini-x86.c: Fixed commit.
350 2008-11-04 Zoltan Varga <vargaz@gmail.com>
352 * aot-compiler.c (emit_plt): Align the plt section only on x86.
354 2008-11-04 Mark Probst <mark.probst@gmail.com>
356 * mini-trampolines.c, mini.h: Two new trampolines: MONITOR_ENTER
357 and MONITOR_EXIT, for the ASM fastpaths.
359 * method-to-ir.c: Use the ASM fastpath for Monitor.Enter/Exit if
362 * mini.c, patch-info.h: Signature and patch infos for
363 Monitor.Enter/Exit trampolines.
365 * mini-amd64.c, mini-x86.c: Make emit_tls_get() non-static.
367 * tramp-amd64.c, tramp-x86.c, mini-amd64.h, mini-amd64.h:
368 Monitor.Enter/Exit ASM fastpath for Linux.
370 2008-11-04 Zoltan Varga <vargaz@gmail.com>
372 * mini.c (mono_method_to_ir): Fix soft-float support in Array.Get/Set.
374 * objects.cs: Add a new test.
376 * aot-compiler.c: Use mono_100ns_ticks () for computing the profiling info.
378 * aot-runtime.c (load_method): Run class initialization in the PLT case even
379 if MONO_LOG_LEVEL is set.
381 * debug-mini.c (serialize_variable): Fix the encoding of dead variables.
383 * aot-runtime.c (mono_aot_get_method): Skip out-of-date AOT modules.
385 * aot-compiler.c (emit_and_reloc_code): Speed this up a little.
387 * aot-compiler.c: Change the relocation code to use virtual addresses instead
388 of file offsets. Align the sections belonging to the data segment to
391 2008-11-03 Zoltan Varga <vargaz@gmail.com>
393 * aot-compiler.c: Simplify the elf writer by depending on the definitions in
394 elf.h. Port it to amd64.
396 2008-11-03 Rodrigo Kumpera <rkumpera@novell.com>
398 * driver.c: Enable SIMD by default.
400 2008-11-03 Rodrigo Kumpera <rkumpera@novell.com>
402 * cpu-x86.md: Add prefetch op.
408 * mini.h: Add an enum for simd prefetch modes.
410 * simd-methods.h: Add prefetch function names.
412 * simd-intrinsics.c: Add prefetch ops for all vector types.
414 2008-11-03 Zoltan Varga <vargaz@gmail.com>
416 * aot-compiler.c (emit_bytes): Speed this up a little.
418 2008-11-02 Zoltan Varga <vargaz@gmail.com>
420 * aot-compiler.c: Add JIT time etc. statistics.
422 * aot-compiler.c (compile_method): Fix the copying of the cfgs array.
424 * mini.h (MonoCompile): Add 'got_offset' field.
426 * aot-compiler.c: Store the got offset in MonoCompile, get rid of the
427 method_got_offsets array.
429 * aot-compiler.c aot-runtime.c: Add support for the monitor enter/exit
432 * aot-compiler.c (compile_method): Add generic method instances referenced
433 by the method to the list of methods to be compiled, this is required so if
434 A<T> references B<T>, and another assembly references A<int>, then it will
435 also get a copy of B<int>.
437 * method-to-ir.c (mini_emit_inst_for_method): Use the proper wrapper type
438 when checking for monitor enter/exit.
440 2008-10-30 Mark Probst <mark.probst@gmail.com>
442 * method-to-ir.c (mini_emit_inst_for_method): Use the IL fastpaths
443 for Monitor.Enter and Monitor.Exit if enabled.
445 * mini-x86.h, mini-amd64.h: Enable the IL fastpaths for Linux and
448 2008-10-30 Zoltan Varga <vargaz@gmail.com>
450 * method-to-ir.c (type_from_op): Convert CEE_CONV_U on OP_ICONV_TO_U instead
451 of an OP_MOVE. Fixes #440046.
453 * basic-long.cs: Add a new test.
455 2008-10-29 Rodrigo Kumpera <rkumpera@novell.com>
457 * mini.h: Add synchronization note for the managed counter-part.
459 * simd-intrinsics.c: Add SimdRuntime.get_AccelMode intrinsic that
460 returns the simd caps of the current cpu.
462 2008-10-29 Rodrigo Kumpera <rkumpera@novell.com>
464 * basic-simd.cs: Remove Console.WriteLine.
466 2008-10-28 Rodrigo Kumpera <rkumpera@novell.com>
468 * basic-simd.cs: New tests for Vector2ul.
470 2008-10-28 Rodrigo Kumpera <rkumpera@novell.com>
472 * simd-intrinsics.c: Add new vector type Vector2ul.
474 2008-10-28 Rodrigo Kumpera <rkumpera@novell.com>
476 * basic-simd.cs: New tests for Vector2l.
478 2008-10-28 Rodrigo Kumpera <rkumpera@novell.com>
480 * cpu-x86.md: Add long version of most packed int ops.
486 * simd-intrinsics.c: Add new vector type Vector2l.
488 2008-10-28 Rodrigo Kumpera <rkumpera@novell.com>
490 * simd-intrinsics.c: Replace SN_op_BitwiseXor with SN_op_ExclusiveOr.
492 * simd-methods.h: Remove SN_op_BitwiseXor.
494 2008-10-28 Zoltan Varga <vargaz@gmail.com>
496 * mini.c (mono_allocate_stack_slots_full): Align the size of vtypes to their
499 2008-10-27 Rodrigo Kumpera <rkumpera@novell.com>
501 * basic-simd.cs: Test for Vector2d.
503 * basic-simd.cs (test_vector8s_pack_signed_sat): Fixed broken
506 2008-10-27 Rodrigo Kumpera <rkumpera@novell.com>
508 * cpu-x86.md: Add double version of all packed float ops.
514 * simd-intrinsics.c: Add new vector type Vector2d.
516 * simd-intrinsics.c (vector4f_intrinsics): Fix ordering.
518 * simd-methods.h: Add Duplicate.
520 2008-10-27 Rodrigo Kumpera <rkumpera@novell.com>
522 * basic-simd.cs: Test for packing with signed saturation.
524 2008-10-28 Zoltan Varga <vargaz@gmail.com>
526 * aot-compiler.c (add_generic_instances): Add all methods of generic instances
527 found in the TYPESPEC table.
529 2008-10-26 Zoltan Varga <vargaz@gmail.com>
531 * aot-runtime.c (mono_aot_get_method): Log not found methods for extra methods
534 * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file format version.
536 * mini.c (mono_method_to_ir): For MONO_PATCH_INFO_RVA, save field the token
537 instead of the RVA, since the RVA can be changed by tools like the cil
540 * method-to-ir.c (mono_method_to_ir2): Ditto.
542 * debug-mini.c (serialize_variable): Handle ADDRESS_MODE_DEAD.
543 (deserialize_variable): Ditto.
545 2008-10-25 Martin Baulig <martin@ximian.com>
547 * debug-mini.c (write_variable): Use
548 `MONO_DEBUG_VAR_ADDRESS_MODE_DEAD' for dead variables.
550 2008-10-24 Rodrigo Kumpera <rkumpera@novell.com>
552 * cpu-x86.md: Add unsigned variants of packd and packw.
556 * mini-x86.h: Emit the right instruction for packd and packw.
557 Add unsigned variants of packd and packw.
559 * simd-intrinsics.c: Packd and packw were used in place of their
560 unsigned variants. Change that.
561 Add intrinsics for (Signed)PackWithSignedSaturation.
563 * simd-methods.h: Add (Signed)PackWithSignedSaturation.
565 2008-10-24 Rodrigo Kumpera <rkumpera@novell.com>
567 * simd-intrinsics.c (vector4i_intrinsics): New table of intrinsic type.
569 2008-10-24 Rodrigo Kumpera <rkumpera@novell.com>
571 * mini-ops.h: Remove dword packed add/sub with saturation ops.
573 * cpu-x86.md: Remove dword packed add/sub with saturation ops.
575 * simd-intrinsics.c (vector4ui_intrinsics): Remove methods without
578 * simd-intrinsics.c (vector8s_intrinsics): Fix ordering.
580 2008-10-24 Mark Probst <mark.probst@gmail.com>
582 * method-to-ir.c, mini.c: Special casing for the synchronized
583 wrapper for the ldtoken+GetTypeFromHandle case.
585 2008-10-24 Zoltan Varga <vargaz@gmail.com>
587 * mini.c (mono_replace_ins): Move this to branch-opts.c.
589 * mini.c (mono_replace_ins): Propagate has_array_access flag to the newly
590 created/split bblocks.
592 2008-10-24 Rodrigo Kumpera <rkumpera@novell.com>
594 * mini-ops.h: Add packed signed mul high.
598 * mini-x86.c (mono_arch_output_basic_block): Same.
600 * simd-methods.h: Add PackWithUnsignedSaturation and ShiftRightLogic.
602 * simd-intrinsics.c (vector8s_intrinsics): New table of intrinsic type.
604 2008-10-24 Rodrigo Kumpera <rkumpera@novell.com>
606 * basic-simd.cs: Tests for Vector16sb.
608 2008-10-24 Zoltan Varga <vargaz@gmail.com>
610 * inssel.brg (stmt): Fix OP_HARD_NOP rule.
612 2008-10-23 Rodrigo Kumpera <rkumpera@novell.com>
614 * mini-ops.h: Add packed signed min, max and compare greater.
618 * mini-x86.c (mono_arch_output_basic_block): Same. Add packed add/sub with
621 * simd-methods.h: Add CompareGreaterThan.
623 * simd-methods.h: Remove CompareEquals.
625 * simd-intrinsics.c: Add new TODO entry and some cosmetic changes.
627 * simd-intrinsics.c (vector16sb_intrinsics): New table of intrinsic type.
629 * simd-intrinsics.c (vector4f_intrinsics): Rename CompareEquals to
632 2008-10-23 Rodrigo Kumpera <rkumpera@novell.com>
634 * basic-simd.cs: Fix tests due to change in the API.
636 2008-10-21 Zoltan Varga <vargaz@gmail.com>
638 * mini.c method-to-ir.c: Use mono_field_get_name () for accessing field->name.
640 2008-10-21 Rodrigo Kumpera <rkumpera@novell.com>
642 * basic-simd.cs: Fix name change in Vector4f::CompareEqual.
644 * simd-intrinsics.c (simd_intrinsic_emit_store_aligned): Don't use
645 inst_offset as this has invalid values for LDADDR.
647 2008-10-21 Rodrigo Kumpera <rkumpera@novell.com>
649 * basic-simd.cs: Test for SignedPackWithUnsignedSaturation.
651 * simd-intrinsics.c (vector4ui_intrinsics): Add SignedPackWithUnsignedSaturation.
653 2008-10-21 Zoltan Varga <vargaz@gmail.com>
655 * method-to-ir.c (initialize_array_data): Use mono_field_get_data ()
656 for accessing field->data.
658 2008-10-21 Rodrigo Kumpera <rkumpera@novell.com>
660 * basic-simd.cs: Test for SignedPackWithUnsignedSaturation.
662 2008-10-21 Rodrigo Kumpera <rkumpera@novell.com>
664 * simd-methods.h: Add SignedPackWithUnsignedSaturation.
666 * simd-intrinsics.c (vector8us_intrinsics): Add SignedPackWithUnsignedSaturation.
668 2008-10-21 Zoltan Varga <vargaz@gmail.com>
670 * dominators.c (mono_compute_natural_loops): Allocate GList enties
671 from the cfg mempool.
673 2008-10-20 Rodrigo Kumpera <rkumpera@novell.com>
675 * basic-simd.cs: Tests for new methods in Vector8us.
677 2008-10-20 Rodrigo Kumpera <rkumpera@novell.com>
679 * mini-ops.h: Add multiply and store high.
683 * mini-x86.c (mono_arch_output_basic_block): Same.
685 * simd-methods.h: Same.
687 * simd-intrinsics.c (vector8us_intrinsics): Add MultiplyStoreHigh
690 2008-10-19 Zoltan Varga <vargaz@gmail.com>
692 * method-to-ir.c (mono_emit_method_call_full): Remove a needless call to
693 mono_class_setup_vtable ().
695 * mini-trampolines.c (mono_convert_imt_slot_to_vtable_slot): Use
696 mono_class_get_vtable_entry () for accessing klass->vtable.
698 * aot-runtime.c (load_method): Avoid a crash when using MONO_LOG_LEVEL.
700 * aot-compiler.c (add_generic_instances): Avoid a crash if a class is not
703 * method-to-ir.c (mono_save_token_info): Don't save references made from
706 * aot-compiler.c (add_generic_instances): Add static rgctx wrappers for cctors
707 of generic instances.
709 * aot-runtime.c (find_extra_method): Search in all loaded AOT images.
711 2008-10-19 Mark Probst <mark.probst@gmail.com>
713 * cpu-ppc.md, mini-ppc.c: The length of the code generated for
714 OP_JMP depends on the method signature. Calculate it properly.
716 2008-10-19 Zoltan Varga <vargaz@gmail.com>
718 * aot-runtime.c (mono_aot_find_jit_info): Handle extra methods which are
721 * aot-compiler.c (emit_and_reloc_code): Allow direct calling of generic
723 (emit_extra_methods): Add another table mapping method indexes to
724 offsets in the extra_method_info table.
726 * mini.h: Bump AOT file format version.
728 * aot-runtime.c: Merge most of the code from mono_aot_get_method
729 and mono_aot_get_method_from_token () into one function.
731 2008-10-19 Mark Probst <mark.probst@gmail.com>
733 * mini-ppc.c (emit_load_volatile_arguments): Inner loop needs a
736 2008-10-18 Zoltan Varga <vargaz@gmail.com>
738 * aot-compiler.c aot-runtime.c: Fix the hash function used for the extra
741 * method-to-ir.c (mono_method_to_ir2): Change a !compile_aot assert to
744 * mini.c (mono_patch_info_equal): Compare the generic context as well.
746 * mini.h: Bump aot file format version.
748 * aot-compiler.c aot-runtime.c: Generalize the wrapper handling code so the
749 AOT file can contain native code for methods which are not in the METHOD
750 table. Generate code for non-sharable generic instances of generic methods
751 found in the METHODSPEC table.
753 * method-to-ir.c (mono_method_to_ir2): Remove the aot restriction when
754 encoding generic type handles.
756 * ir-emit.h (NEW_AOTCONST_TOKEN): Add a generic_context argument.
757 (NEW_TYPE_FROM_HANDLE_CONST): Add a generic_context argument.
759 * ir-emit.h: Rewrite the EMIT_NEW_XXXCONST macros to use the NEW_XXXCONST
760 macros + MONO_ADD_INS.
762 * mini.c (mono_jump_info_token_new2): New function which takes a generic
765 * mini.h (MonoJumpInfoToken): Include fields for a generic context.
767 * mini.h: Bump aot file format version.
769 * aot-compiler.c aot-runtime.c: Update after changes to MonoJumpInfoToken.
771 2008-10-17 Mark Probst <mark.probst@gmail.com>
773 * mini-x86.h, mini-x86.c, exceptions-x86.c: Align stack on all
774 platforms, with definable stack alignment value. Set to 16 now
777 * mini.c, mini.h, driver.c: Command line option for disabling
780 2008-10-17 Rodrigo Kumpera <rkumpera@novell.com>
782 * basic-simd.cs: Tests for new methods in Vector4ui.
784 2008-10-17 Rodrigo Kumpera <rkumpera@novell.com>
786 * mini-ops.h: Add packed int shuffle.
790 * mini-x86.c (mono_arch_output_basic_block): Same.
792 * simd-intrinsics.c (vector4ui_intrinsics): Add compare equal,
793 extract mask, max, min, shuffle.
795 * simd-intrinsics.c (vector8us_intrinsics): Add max and min.
797 2008-10-17 Rodrigo Kumpera <rkumpera@novell.com>
799 * basic-simd.cs: Tests for new methods in Vector8us.
801 2008-10-17 Mark Probst <mark.probst@gmail.com>
803 * method-to-ir.c (mono_method_to_ir2): "refanytype" produces a
804 RuntimeTypeHandle, not a TypedReference.
806 Fri Oct 17 14:40:50 CEST 2008 Paolo Molaro <lupus@ximian.com>
808 * simd-intrinsics.c: remove relocations.
810 2008-10-17 Zoltan Varga <vargaz@gmail.com>
812 * mini-amd64.c (mono_arch_output_basic_block): Port the IREM_IMM
813 optimizations from the x86 backend.
815 Fri Oct 17 12:00:51 CEST 2008 Paolo Molaro <lupus@ximian.com>
817 * simd-methods.h, simd-intrinsics.c: debloat method names and
818 prepare for no relocations.
820 2008-10-16 Rodrigo Kumpera <rkumpera@novell.com>
822 * mini-ops.h: Add packed min/equal and sum of absolute differences.
826 * mini-x86.c (mono_arch_output_basic_block): Same.
828 * simd-intrinsics.c (vector16b_intrinsics): Add average, compare equal,
829 extract mask, max, min and sum of absolute differences.
831 * simd-intrinsics.c: Increase SIMD_INTRINSIC_NAME_MAX due to new huge
834 2008-10-16 Rodrigo Kumpera <rkumpera@novell.com>
836 * basic-simd.cs: Test for the other mono_simd_simplify_indirection bug.
837 Renamed one test for consistency.
839 2008-10-16 Rodrigo Kumpera <rkumpera@novell.com>
841 * simd-intrinsics.c (mono_simd_simplify_indirection): Apply the previous
842 fix to the code that deal with other blocks.
844 2008-10-16 Rodrigo Kumpera <rkumpera@novell.com>
846 * basic-simd.cs: Test for the mono_simd_simplify_indirection bug.
848 2008-10-16 Rodrigo Kumpera <rkumpera@novell.com>
850 * simd-intrinsics.c (mono_simd_simplify_indirection): Simplify the code
851 that deals with vreg interference. Explicitly check for OP_LDADDR to be
852 able to process the source reg.
854 2008-10-16 Martin Baulig <martin@ximian.com>
856 * mini-ops.h, cpu-amd64.md, cpu-x86.md: Added new `hard_nop' opcode.
858 * inssel.brg: Add `OP_HARD_NOP'.
860 * mini.h (MonoCompile): Added `keep_cil_nops' flag.
862 * mini.c (mono_method_to_ir): In `CEE_NOP': generate a
863 `OP_HARD_NOP' instruction when running inside the debugger.
865 * method-to-ir.c (mono_method_to_ir2): In `CEE_NOP': generate a
866 `OP_HARD_NOP' instruction when running inside the debugger.
868 2008-10-15 Rodrigo Kumpera <rkumpera@novell.com>
870 * simd-intrinsics.c (get_simd_vreg): Using sreg1 of OP_XMOVE
871 now works. The issue with the regalloc tripping up no longer
874 * simd-intrinsics.c (load_simd_vreg): Same.
876 2008-10-15 Rodrigo Kumpera <rkumpera@novell.com>
878 * basic-simd.cs: Tests for new Vector8ui methods.
880 2008-10-15 Rodrigo Kumpera <rkumpera@novell.com>
882 * simd-intrinsics.c (get_simd_vreg): Simplify code and test
883 only for type. This fixes crashes where MonoInst::klass is checked
884 for ops of type != VTYPE or OBJ.
886 * simd-intrinsics.c (load_simd_vreg): Same.
888 2008-10-15 Rodrigo Kumpera <rkumpera@novell.com>
890 * mini-ops.h: Add ops for packed shuffle/max/avg and
895 * mini-x86.c (mono_arch_output_basic_block): Same.
897 * simd-intrinsics.c (vector8us_intrinsics): Add avg, shuffle and
900 * simd-intrinsics.c (simd_intrinsic_emit_extract_mask): New function
901 to emit extract mask op.
903 * simd-intrinsics.c (simd_intrinsic_emit_shuffle): Retrofic this function
904 to emit word shuffles.
906 2008-10-15 Mark Probst <mark.probst@gmail.com>
908 * mini.c (mono_allocate_stack_slots_full): Align stack frame to
909 the largest alignment needed by a variable, but at least
912 2008-10-14 Rodrigo Kumpera <rkumpera@novell.com>
914 * basic-simd.cs: Tests for the fixes in the last commit.
916 2008-10-14 Rodrigo Kumpera <rkumpera@novell.com>
918 * simd-intrinsics.c (get_simd_vreg): Drop the is_this_ptr, this function
919 no longer handles STACK_PTR input.
921 * simd-intrinsics.c (get_simd_vreg): Don't crash when MonoInst::klass == -1.
923 * simd-intrinsics.c (load_simd_vreg): New function that works like
924 get_simd_vreg but handles STACK_PTR input.
926 * simd-intrinsics.c (simd_intrinsic_emit_getter): Use load_simd_vreg
927 as the input can be an arbitrary pointer.
929 * simd-intrinsics.c (simd_intrinsic_emit_ctor): Try the
930 LDADDR local optimization directly otherwise use a store op.
932 2008-10-14 Rodrigo Kumpera <rkumpera@novell.com>
934 * basic-simd.cs: Tests for dup low and dup high.
936 2008-10-14 Rodrigo Kumpera <rkumpera@novell.com>
938 * mini-ops.h: Add dup low and dup high ops.
942 * mini-x86.c (mono_arch_output_basic_block): Same.
944 * simd-intrinsics.c (vector4f_intrinsics): Same.
946 2008-10-13 Rodrigo Kumpera <rkumpera@novell.com>
948 * basic-simd.cs: Tests for recently added functionality.
950 2008-10-13 Rodrigo Kumpera <rkumpera@novell.com>
952 * mini-ops.h: Add remaining sse1 fp ops.
954 * cpu-x86.md: Add remaining sse1 fp ops.
956 * mini-x86.c (mono_arch_output_basic_block): Same.
958 * mini.h: Add enum for simd FP compare conditions.
960 * simd-intrinsics.c (vector4f_intrinsics): Add all new ops.
962 * simd-intrinsics.c (simd_intrinsic_emit_binary): Set inst_c0 to flags
963 so the backed can generate the appropriate op.
965 2008-10-13 Rodrigo Kumpera <rkumpera@novell.com>
966 This patch squeese one more byte from the SimdIntrinsc struct.
968 * mini-x86.c (mono_arch_cpu_enumerate_simd_versions: Use the version number
969 a a shift amount intead of simply or'ing it.
971 * mini.h: Change SIMD_VERSION_* values to be sequential intead of masks.
973 * simd-intrinsics.c (struct SimdIntrinsc): Squeese simd_version and simd_emit_mode into a single
974 byte so we can have an aditional flags field without increasing struct size.
976 * simd-intrinsics.c (emit_intrinsics): Use the value of simd_version as a shift amount before checking
977 against the simd_supported_versions bitmask.
979 * simd-intrinsics.c: Set SIMD_INTRINSIC_NAME_MAX to an appropriate value.
981 Mon Oct 13 10:58:10 CEST 2008 Paolo Molaro <lupus@ximian.com>
983 * mini.c: remove rawbuffer code (the only use here is unsafe because
984 it takes locks during signal handling and the kernel now provides much
985 better info in proc/pid/smaps these days).
987 2008-10-13 Zoltan Varga <vargaz@gmail.com>
989 * mini-amd64.c (mono_arch_output_basic_block): Fix the changes to
990 OP_X86_PUSH_OBJ. Fixes #434620.
992 * objects.cs: Add a test.
994 2008-10-12 Rodrigo Kumpera <rkumpera@novell.com>
996 * basic-simd.cs: Remove PackWithUnsignedSaturation tests as it turns out
997 that the packuswb/packusdw don't work with unsigned numbers for what
998 would be negative numbers in signed format.
1000 * cpu-x86.md: Add doubleword forms of many ops and packing ones.
1001 Fix the len of fconv_to_r8_x and xconv_r8_to_i4.
1003 * mini-ops.h: Add doubleword forms of many ops and packing ones.
1005 * mini-x86.c: Emit doubleword forms of many ops and packing ones.
1007 * simd-intrinsics.c (SimdIntrinsc): Rename the flags field to simd_version.
1009 * simd-intrinsics.c (vector4f_intrinsics): Use simd_version field for sse3 ops.
1011 * simd-intrinsics.c (vector4u_intrinsics): Rename to vector4ui_intrinsics and
1014 * simd-intrinsics.c (simd_version_name): New function, returns the name of the
1015 version as the enum in mini.h.
1017 * simd-intrinsics.c (emit_intrinsics): Instead of having a special emit mode
1018 for sse3 ops, check the simd_version field if present. This way the code
1019 works with all versions of sse.
1021 2008-10-10 Rodrigo Kumpera <rkumpera@novell.com>
1023 * simd-intrinsics.c: Fixed intrinsic name typo.
1025 * mini.h: Added missing simd exported function.
1027 * basic-simd.cs: Added tests for Vector4ui.
1028 Fixed broken test for Vector16b.
1030 2008-10-10 Zoltan Varga <vargaz@gmail.com>
1032 * tramp-amd64.c (mono_arch_create_rgctx_lazy_fetch_trampoline_full): Increase
1033 the max length to 64.
1035 2008-10-10 Mark Probst <mark.probst@gmail.com>
1037 * method-to-ir.c: Only do the fast virtual generic method call for
1038 non-wrapper methods.
1040 * mini.h, mini-trampolines.c: The new generic virtual remoting
1041 trampoline handles virtual method calls via the vtable (as done by
1042 the fast virtual generic method calls) to remoting proxies.
1044 * mini.c (mono_jit_create_remoting_trampoline): For generic
1045 methods reate a generic virtual remoting trampoline.
1047 * mini-amd64.h: Enable fast virtual generic method calls again.
1049 2008-10-10 Mark Probst <mark.probst@gmail.com>
1051 * mini-ppc.c: Use SP (r1), not frame_reg (which might be r31) to
1052 restore registers when doing tail calls.
1054 2008-10-10 Rodrigo Kumpera <rkumpera@novell.com>
1056 * simd-intrinsics.c (emit_intrinsics): Vector4u was renamed to
1059 2008-10-10 Rodrigo Kumpera <rkumpera@novell.com>
1061 * basic-simd.cs: Add test for Vecto16b.PackWithUnsignedSaturation.
1063 2008-10-10 Rodrigo Kumpera <rkumpera@novell.com>
1065 * simd-intrinsics.c (emit_intrinsics): Retrofit to new type names.
1067 2008-10-10 Rodrigo Kumpera <rkumpera@novell.com>
1069 * basic-simd.cs: Retrofit for API changes.
1071 2008-10-10 Mark Probst <mark.probst@gmail.com>
1073 * mini-ppc.c: Handle integer stack arguments for tail calls.
1075 2008-10-10 Rodrigo Kumpera <rkumpera@novell.com>
1077 * optflags-def.h: Removed sse3 optimization.
1081 * mini-x86.c (mono_arch_cpu_optimizazions): Remove detection of
1084 * mini-x86.c: Added mono_arch_cpu_enumerate_simd_versions.
1086 * mini.h: Added enumeration with simd versions.
1088 * simd-intrinsics.c (emit_intrinsics): Use the new static var
1091 * simd-intrinsics.c: Added mono_simd_intrinsics_init.
1093 * mini.c (mini_init): Call mono_simd_intrinsics_init.
1095 2008-10-09 Rodrigo Kumpera <rkumpera@novell.com>
1097 * basic-simd.cs: Added tests for Vector8u and Vector16u.
1099 * basic-simd.cs: Fixed test naming.
1101 2008-10-09 Rodrigo Kumpera <rkumpera@novell.com>
1103 * mini-ops.h: Added ops for packed and saturated math, shifts
1104 and packing/unpacking.
1106 * cpu-x86.md: Added descriptors for the above ops.
1108 * mini-x86.c: Added code to emmit the above ops.
1110 * simd-intrinsics.c: Added support for Vector16u and Vector8u.
1112 2008-10-08 Zoltan Varga <vargaz@gmail.com>
1114 * aot-compiler.c (compile_method): Enable AOT for generic code.
1116 * ir-emit.h (NEW_DOMAINCONST): Use domainvars in AOT code as well.
1118 Wed Oct 8 16:35:43 CEST 2008 Paolo Molaro <lupus@ximian.com>
1120 * mini.c: add a workaround for a common screwup that ends up blamed
1121 to mono (other processes blocking signal delivery).
1123 2008-10-07 Zoltan Varga <vargaz@gmail.com>
1125 * method-to-ir.c (mono_method_to_ir2): Clear ins_flag on all code paths
1126 in the LDFLD/STFLD opcodes. Fixes #432673.
1128 * iltests.il.in: Add a new test.
1130 Tue Oct 7 19:59:07 CEST 2008 Paolo Molaro <lupus@ximian.com>
1132 * mini-arm.c: attach the thread in unmanaged->managed transitions
1133 using delegates (bug #433148).
1135 2008-10-07 Rodrigo Kumpera <rkumpera@novell.com>
1137 * basic-simd.cs: Use new ShuffleSel constants.
1139 2008-10-07 Rodrigo Kumpera <rkumpera@novell.com>
1141 * driver.c (opt_sets): Added combinations of simd, sse2 and sse3.
1143 * mini-x86.c (mono_arch_cpu_optimizazions): Detect sse3 and now
1144 only disable simd intrinsics if no sse2 is detected.
1146 * optflags-def.h: Added sse3.
1148 * simd-intrinsics.c: Avoid generated sse3 intrinsics if the optimization
1151 2008-10-07 Zoltan Varga <vargaz@gmail.com>
1153 * aot-compiler.c (add_wrappers): Fix Delegate/MulticastDelegate classes
1154 when adding delegate-invoke wrappers.
1156 2008-10-07 Zoltan Varga <vargaz@gmail.com>
1158 * Makefile.am: Reenable the simd tests.
1160 2008-10-07 Bill Holmes <billholmes54@gmail.com>
1162 * mini-amd64.c (mono_arch_emit_outarg_vt) : In the ArgValuetypeAddrInIReg case,
1163 add a call to mono_call_inst_add_outarg_reg for the arg->dreg to make sure that no
1164 other vreg is allocated to that hreg.
1166 Contributed under MIT/X11 license.
1168 2008-10-07 Zoltan Varga <vargaz@gmail.com>
1170 * Makefile.am: Disable the simd tests for now as Mono.Simd is not
1173 2008-10-06 Rodrigo Kumpera <rkumpera@novell.com>
1175 * basic-simd.cs: New test suite for SIMD intrinsics.
1177 * Makefile.am: Added new tests.
1179 2008-10-06 Rodrigo Kumpera <rkumpera@novell.com>
1181 * cpu-x86.md: Added new instructions to handle float to int using SSE regs.
1185 * mini-x86.h: Enable mono_arch_decompose_opts if simd intrinsics are enabled.
1187 * mini-x86.c (mono_arch_decompose_opts): Decompose float to int conversion
1188 using SSE2 aware opcodes.
1190 * mini-x86.c (emit_float_to_int): Disable the SSE2 optimization if OPT_SIMD
1191 is enabled, this code path is only reachable if conversion ops are emmited after
1194 * mini.h: Added MonoCompile::fconv_to_r8_x_var to hold the float to int var.
1196 This optimization saves 6 bytes per conversion against the old version.
1198 2008-10-06 Zoltan Varga <vargaz@gmail.com>
1200 * aot-compiler.c (compile_method): Don't skip methods referencing
1201 generic methods without a corresponding entry in token_info_hash, since
1202 encode_method_ref () can handle all generic methods now.
1204 * method-to-ir.c (mono_save_token_info): Don't save the token info if a
1205 generic context is set.
1207 * method-to-ir.c (mono_method_to_ir2): Put back a disable_aot for
1208 generic sharing of LDTOKEN.
1210 2008-10-06 Mark Probst <mark.probst@gmail.com>
1212 * mini-amd64.h: Temporarily disabled fast virtual generic method
1213 calls because it breaks the System.Runtime.Remoting tests.
1215 2008-10-06 Zoltan Varga <vargaz@gmail.com>
1217 * aot-compiler.c (add_wrappers): Add delegate-invoke wrappers.
1219 * method-to-ir.c (check_inline_called_method_name_limit): Return TRUE
1220 so inlining actually works.
1221 (check_inline_caller_method_name_limit): Ditto.
1223 Mon Oct 6 11:04:38 CEST 2008 Paolo Molaro <lupus@ximian.com>
1225 * mini-ppc.c: mono_arch_flush_icache () cast pointer using gsize for
1226 64 bit safety (from Olaf Hering and Andreas Färber).
1228 2008-10-06 Zoltan Varga <vargaz@gmail.com>
1230 * mini-trampolines.c (mono_aot_trampoline): Delegate processing to
1231 mono_magic_trampoline () if aot_get_method_from_token () fails. Remove
1232 unused virtual call support code.
1234 * aot-runtime.c (decode_method_ref): Add a 'no_aot_trampoline' out argument.
1236 * aot-runtime.c (mono_aot_get_method_from_vt_slot): Return NULL for methods
1237 which can't use aot trampolines.
1238 (decode_patch): Don't create aot trampolines for methods which can't use
1241 * aot-compiler.c (encode_method_ref): Add a marker for methods which can't
1242 use aot trampolines.
1244 * mini.h: Bump AOT image format version.
1246 2008-10-05 Zoltan Varga <vargaz@gmail.com>
1248 * method-to-ir.c (mono_method_to_ir2): Pass cil_method instead of cmethod
1249 to save_token_info () since cmethod is inflated for constrained calls.
1251 * mini-<ARCH>.h mini-x86.c: Remove some unused defines.
1253 2008-10-04 Andreas Färber <andreas.faerber@web.de>
1255 * Makefile.am: Add build rules for ppc64.
1256 This avoids the build failing at pedump with unresolved symbols
1257 due to lack of arch_sources. Instead it will now fail earlier
1258 due to lack of cpu-ppc64.md.
1260 Contributed under MIT/X11 license.
1262 2008-10-04 Mark Probst <mark.probst@gmail.com>
1264 * mini-amd64.c (mono_arch_emit_call): Support stack arguments for
1267 * iltests.il.in: Add test case for tail call with many arguments.
1269 2008-10-03 Zoltan Varga <vargaz@gmail.com>
1271 * method-to-ir.c (mono_method_to_ir2): Add an !cfg->compile_aot assert
1272 to the fast virtual generic method code until the aot case is fixed.
1274 2008-10-03 Mark Probst <mark.probst@gmail.com>
1276 * mini-ppc.c, mini-ppc.h: Implement generic virtual method thunks.
1278 2008-10-03 Mark Probst <mark.probst@gmail.com>
1280 * mini-amd64.c, mini-amd64.h: Implement generic virtual method
1283 2008-10-03 Rodrigo Kumpera <rkumpera@novell.com>
1285 * simd-intrinsics.c: Forgot to add this one.
1287 * mini-codegen.c: Fix macro in case SIMD is not supported.
1289 2008-10-03 Rodrigo Kumpera <rkumpera@novell.com>
1291 This patch land initial JIT support for simd intrinsics.
1293 * mini-x86.h: Added new define to make --enable_minimal work on x86.
1295 * Makefile.am: Added simd-intrinsics.c
1297 * simd-intrinsics.c: New file with simd instrinsic related
1300 * cfold.c (mono_constant_fold_ins2): Fold XZERO.
1302 * cpu-x86.md: Add simd related instructions.
1304 * driver.c: Added MONO_OPT_SIMD to the default set of optimizations.
1306 * driver.c: Added two new --regression variants.
1308 * ir-emit.h (MONO_EMIT_NEW_VZERO): Emit XZERO if the type is a simd intrinsic.
1310 * local-propagation.c (mono_local_cprop2): Eliminate useless XMOVE.
1312 * local-propagation.c (mono_local_deadce): Use new macro MONO_IS_NON_FP_MOVE and
1313 extract some complicated logic to helper functions.
1315 * method-to-ir.c (mono_type_to_regmove): Handle simd intrinsics.
1317 * method-to-ir.c (mini_emit_inst_for_method): Emit simd intrinsics.
1319 * method-to-ir.c (mono_handle_global_vregs): If a simd intrinsic was found, apply
1320 the specialized simplification pass.
1322 * method-to-ir.c (mono_spill_global_vars): Use new macro.
1324 * mini-codegen.c: Added SIMD constants to all regbanks arrays.
1326 * mini-codegen.c: Added reg_bank_table_init to initialize the reg desc -> bank
1329 * mini-codegen.c: Define a version of the reg_bank macro that uses desc_to_reg_type
1330 if MONO_ARCH_NEED_SIMD_BANK is defined.
1332 * mini-ops.h: Added the new simd ops.
1334 * mini-x86.c: Added mono_arch_xregname.
1336 * mini-x86.c (mono_arch_cpu_optimizazions): Disable MONO_OPT_SIMD if SSE3 is not detected.
1338 * mini-x86.c (mono_arch_output_basic_block): Add simd related opcodes.
1340 * mini-x86.h: Define simd related MONO_ARCH macros.
1342 * mini.c (mono_type_to_load_membase): Handle simd intrinsics.
1344 * mini.c (mono_type_to_store_membase): Handle simd intrinsics.
1346 * mini.h: Added new macros MONO_IS_NON_FP_MOVE, MONO_IS_REAL_MOVE, MONO_IS_ZERO and
1347 MONO_CLASS_IS_SIMD to deal with simd related IR.
1349 * mini.h (MonoInst): Added spill_var to the backend union.
1351 * mini.h (MonoCompile): Added uses_simd_intrinsics and iconv_raw_var.
1353 * mini.h: Added forward declarations of the new simd fuctions.
1355 * optflags-def.h: Added new optimization names SIMD.
1357 * regalloc.c (mono_regstate_reset): Set next vreg to be the max value of the 3 reg banks.
1359 * regalloc.h: Added support for working with 3 register banks.
1361 * regalloc.h (MonoRegState): Added xsymbolic field if a third regbank is required.
1363 * ssa2.c (mono_ssa_deadce2): Use new MONO_IS_ZERO macro.
1365 Fri Oct 3 16:03:22 CEST 2008 Paolo Molaro <lupus@ximian.com>
1367 * mini-exceptions.c: remove 64 bit related ifdef clutter.
1369 2008-10-03 Zoltan Varga <vargaz@gmail.com>
1371 * mini-exceptions.c (mono_handle_soft_stack_ovf): Unprotect two pages
1372 instead of one on 64 bit systems.
1374 * method-to-ir.c: Remove unused includes.
1376 2008-10-02 Zoltan Varga <vargaz@gmail.com>
1378 * aot-compiler.c (emit_exception_debug_info): Use jinfo->used_regs instead of
1379 cfg->used_int_regs, since the two are different on arm.
1381 2008-10-02 Mark Probst <mark.probst@gmail.com>
1383 * method-to-ir.c, inssel.brg, mini-trampolines.c: Use
1384 mono_method_get_vtable_index() to get the vtable index.
1386 2008-10-02 Mark Probst <mark.probst@gmail.com>
1388 * method-to-ir.c (mono_method_to_ir2): Don't create native
1389 wrappers for array methods, because they're never called (and if
1390 they were called they wouldn't work).
1392 2008-10-02 Mark Probst <mark.probst@gmail.com>
1394 * method-to-ir.c (mono_method_to_ir2): Array methods are
1395 special-cased and must not be invoked indirectly via the (M)RGCTX
1396 when generic sharing is turned on. Fixes #431413.
1398 2008-10-01 Mark Probst <mark.probst@gmail.com>
1400 * method-to-ir.c: When generic sharing is active, call
1401 non-interface virtual generic methods via the standard trampoline.
1403 * mini-trampolines.c: Handle virtual generic shared methods.
1405 * mini.h, mini-x86.c, mini-x86.h: New argument for
1406 mono_arch_build_imt_thunk() which is non-NULL for virtual generic
1407 method thunks and which is the trampoline to call if the lookup
1408 fails. Enable the virtual generic method thunk for x86.
1410 * mini-amd64.c, mini-arm.c, mini-ia64.c, mini-sparc.c,
1411 mini-ppc.c (mono_arch_build_imt_thunk): Add the additional
1412 argument but assert that it's NULL, because these archs don't yet
1413 implement the virtual generic method thunk. Changes in the IMT
1414 thunk data structures.
1416 2008-10-01 Zoltan Varga <vargaz@gmail.com>
1418 * aot-compiler.c (emit_globals): Avoid invalid characters in
1419 the static linking symbol.
1421 * objects.cs: Add a test for the range check optimization. Fix warnings.
1423 * branch-opts.c (mono_if_conversion): Add back the 'optimize range checks'
1424 optimization from the current JIT.
1426 * method-to-ir.c (mini_emit_inst_for_method): Decompose String.Length
1427 later in decompose_array_access_opts () to allow more optimizations.
1429 * method-to-ir.c (mono_handle_soft_float): Rename this to
1430 mono_decompose_soft_float () for consistency.
1432 * mini-ops.h: Fix arguments of OP_STRLEN.
1434 * method-to-ir.c (save_cast_details): Extract the cast details saving code
1435 into a separate function.
1436 (reset_cast_details): Ditto.
1437 (handle_unbox): Save cast details. Fixes #431254.
1439 * method-to-ir.c: Remove some obsolete FIXMEs.
1441 2008-09-30 Rodrigo Kumpera <rkumpera@novell.com>
1443 * ir-emit.h (alloc_dreg): Write a warning before crashing.
1445 2008-09-30 Rodrigo Kumpera <rkumpera@novell.com>
1447 * mini-codegen.c: More work on macros to make them
1448 ready for multiple regbanks.
1450 2008-09-30 Rodrigo Kumpera <rkumpera@novell.com>
1452 * method-to.ir.c (mono_type_to_regmove): Remove static modifier.
1454 * mini.h: Export mono_type_to_regmove. Fix signature of mono_regname_full.
1456 2008-09-30 Rodrigo Kumpera <rkumpera@novell.com>
1458 * mini-codegen.c (mono_spillvar_offset): Proper support for
1461 2008-09-30 Zoltan Varga <vargaz@gmail.com>
1463 * mini-amd64.c (mono_arch_emit_epilog): Remove some duplicated code from
1464 the stack overflow changes.
1466 2008-09-30 Rodrigo Kumpera <rkumpera@novell.com>
1468 * mini-codegen.c: Make all bank macros depend on reg_bank.
1470 * mini-codegen.c (mono_local_regalloc): Make free mask
1471 initialization regbank aware.
1473 2008-09-30 Rodrigo Kumpera <rkumpera@novell.com>
1475 * mini-codegen.c (mono_local_regalloc): Extract callee
1476 mask selection to a function and make it regbank aware.
1478 2008-09-30 Rodrigo Kumpera <rkumpera@novell.com>
1480 * mini-codegen.c (mono_local_regalloc): Changed the cloberring
1481 code to deal with many regbanks.
1483 2008-09-30 Zoltan Varga <vargaz@gmail.com>
1485 * mini-codegen.c: More fp->regbank changes.
1487 2008-09-29 Rodrigo Kumpera <rkumpera@novell.com>
1489 * mini-codegen.c: Change asserts to use MONO_NUM_REGBANKS instead
1490 of a hardcoded constant.
1492 2008-09-29 Rodrigo Kumpera <rkumpera@novell.com>
1494 * method-to-ir.c (type_from_stack_type): Fix typo.
1496 2008-09-29 Zoltan Varga <vargaz@gmail.com>
1498 * mini-ia64.c (emit_move_return_value): Convert float return values to
1501 * objects.cs: Add a new test.
1503 * mini-ia64.c (mono_arch_allocate_vars): Disable fp elimination for
1504 VARARG methods to fix an assert later.
1506 * mini-mips.h mini-mips.c mini-ops.h cpu-mips.md: Update the mips back
1507 end so it at least compiles.
1509 2008-09-28 Zoltan Varga <vargaz@gmail.com>
1511 * method-to-ir.c (emit_optimized_ldloca_ir): Fix this.
1513 2008-09-28 Rodrigo Kumpera <rkumpera@novell.com>
1515 * method-to-ir.c (mono_method_to_ir2): Extract the ldloca + initobj
1516 optimization to a new function (emit_optimized_ldloca_ir) and enable
1517 it for both ldloca and ldloca_s.
1519 2008-09-28 Zoltan Varga <vargaz@gmail.com>
1521 * method-to-ir.c (mono_method_to_ir2): Remove an unnecessary assert in the
1522 gshared CASTCLASS code.
1524 * driver.c (mono_main): Add a workaround for shutdown crashes seen on
1525 amd64, where the libc stack unwinder encounters stack frames referring to
1526 native code in unmapped memory.
1528 * method-to-ir.c (mini_emit_check_array_type): Add support for generic
1531 * generics.cs: Add new test.
1533 2008-09-27 Zoltan Varga <vargaz@gmail.com>
1535 * mini-arm.h driver.c: Print the fp model when using --version on arm. Also,
1536 add a check that one of the ARM_FPU_ constants is defined.
1538 * mini-exceptions.c (mono_handle_soft_stack_ovf): Really fix the build.
1540 * mini-exceptions.c: Fix build on non-altstack platforms.
1542 * method-to-ir.c (mono_method_to_ir2): Fix aot support for the
1545 * ir-emit.h: Add a comment to NEW_PCONST.
1547 * mini-exceptions.c (mono_altstack_restore_prot): Fix a warning.
1549 * mini.h (MonoJitDomainInfo): Move some fields here from MonoDomain.
1551 * mini.c aot-runtime.c method-to-ir.c driver.c mini-trampolines.c: Update
1552 after the changes to MonoJitDomainInfo.
1554 2008-09-27 Mark Probst <mark.probst@gmail.com>
1556 * mini-ppc.c, tramp-ppc.c, mini-ppc.h: Implement generic code sharing.
1558 2008-09-27 Mark Probst <mark.probst@gmail.com>
1560 * mini-ppc.c: Compiler warning fixes.
1562 2008-09-27 Mark Probst <mark.probst@gmail.com>
1564 * mini-ppc.c: Special handling for 1/2 byte structs on Darwin only
1567 2008-09-27 Mark Probst <mark.probst@gmail.com>
1569 * exceptions-ppc.c, mini-ppc.h: Compile
1570 mono_arch_handle_altstack_exception() on Darwin, too.
1572 2008-09-27 Mark Probst <mark.probst@gmail.com>
1574 * method-to-ir.c (mono_emit_rgctx_method_call_full): Must also
1575 work on archs which don't have generic sharing implemented, only
1576 without the vtable_arg.
1578 2008-09-26 Mark Probst <mark.probst@gmail.com>
1580 * mini.c: Added comment explaining why delegate ctor icall
1581 wrappers are compiled.
1583 2008-09-26 Mark Probst <mark.probst@gmail.com>
1585 * mini.c: Don't produce trampolines to delegate ctor icall
1586 wrappers but compile them upfront.
1588 Fri Sep 26 17:00:46 CEST 2008 Paolo Molaro <lupus@ximian.com>
1590 * mini-amd64.c, mini-amd64.h, tramp-amd64.c: amd64 support code for calling a
1591 runtime-set function when going back to managed code. Currently this
1592 is used to set back the protection on the soft ovf pages and/or to
1593 throw the stack overflow exception that happened in unmanaged code.
1595 Fri Sep 26 16:46:23 CEST 2008 Paolo Molaro <lupus@ximian.com>
1597 * tramp-x86.c, mini-x86.h, mini-x86.c: x86 support code for calling a
1598 runtime-set function when going back to managed code. Currently this
1599 is used to set back the protection on the soft ovf pages and/or to
1600 throw the stack overflow exception that happened in unmanaged code.
1602 Fri Sep 26 16:34:37 CEST 2008 Paolo Molaro <lupus@ximian.com>
1604 * mini.h, mini.c, mini-trampolines.c, mini-exceptions.c: added
1605 the support code for restoring stack protection after stack overflows
1606 that happen in unmanaged code. Don't set the exec permission on the
1609 2008-09-26 Zoltan Varga <vargaz@gmail.com>
1611 * mini-trampolines.c (mono_delegate_trampoline): Add wrappers even if
1612 delegate->method_ptr is set. Fixes #428054.
1614 2008-09-25 Zoltan Varga <vargaz@gmail.com>
1616 * tests.cs: Rename to ratests.cs.
1618 * method-to-ir.c: Merge the emit_get_rgctx () calls into the
1619 emit_get_rgctx_... functions.
1621 2008-09-25 Mark Probst <mark.probst@gmail.com>
1623 * method-to-ir.c: Eliminated macro EMIT_GET_RGCTX.
1625 2008-09-25 Mark Probst <mark.probst@gmail.com>
1627 * mini-trampolines.c (mono_magic_trampoline): Unwrap wrappers
1628 before asserting that method is sharable.
1630 2008-09-25 Mark Probst <mark.probst@gmail.com>
1632 * method-to-ir.c, mini.c, jit-icalls.c: New function for checking
1633 whether method needs a static RGCTX wrapper used instead of
1636 * generic-sharing.c, mini.h: A few functions moved to
1637 metadata/generic-sharing.c.
1639 2008-09-25 Mark Probst <mark.probst@gmail.com>
1641 * method-to-ir.c, mini.c, mini-exceptions.c, mini-trampolines.c:
1642 Generic code sharing for value types, which essentially means
1643 treating value type methods like static methods. The RGCTX is
1644 passed in the same way.
1646 2008-09-25 Zoltan Varga <vargaz@gmail.com>
1648 * method-to-ir.c (mono_method_to_ir2): Avoid an assert in the NEWOBJ
1649 opcode when creating multi-dimensional arrays of open types.
1651 * generic-sharing.c (mono_method_check_context_used): Handle arrays of
1654 * generics.cs: Add a test.
1656 * mini-codegen.c: Use macros everywhere for checking floats instead of == 'f'.
1658 2008-09-24 Zoltan Varga <vargaz@gmail.com>
1660 * mini.h (MonoCompile): Add 'disable_vreg_to_lvreg' flag.
1662 * mini.c (mini_method_compile): Set it when running under the debugger.
1664 * method-to-ir.c (mono_handle_global_vregs): Disable global->local
1665 vreg optimization if the flag is set.
1667 * driver.c (mono_main): Add --attach= option to pass options to
1670 * mini.c (sigquit_signal_handler): Start the attach agent.
1672 * ssapre.c: Disable this to save space since it is not yet ported to
1675 * regalloc2.c: Disable this to save space.
1677 * mini.h (MonoJitStats): Remove unused analyze_stack_repeat.
1679 Wed Sep 24 16:01:49 CEST 2008 Paolo Molaro <lupus@ximian.com>
1681 * decompose.c, method-to-ir.c, mini-codegen.c, regalloc2.c: make
1682 the -v option useful again.
1684 2008-09-24 Zoltan Varga <vargaz@gmail.com>
1686 * mini-amd64.c (mono_arch_output_basic_block): Add support for
1689 * inssel.brg (mini_emit_castclass): Avoid the szarray!=array checks for
1690 arrays of arrays. Fixes #428406.
1692 * method-to-ir.c (mini_emit_castclass): Ditto.
1694 * objects.cs: Add new test.
1696 2008-09-23 Rodrigo Kumpera <rkumpera@novell.com>
1698 * method-to-ir.c (type_to_eval_stack_type): The code path for the new JIT
1699 was wrong at it choked against target_type_is_incompatible for byref types.
1701 2008-09-23 Zoltan Varga <vargaz@gmail.com>
1703 * mini-codegen.c: Use 'bank' macros instead of 'is_fp' macros in most
1706 Tue Sep 23 15:31:45 CEST 2008 Paolo Molaro <lupus@ximian.com>
1708 * mini-exceptions.c: update a few more exceptions-related counters.
1710 Tue Sep 23 15:28:29 CEST 2008 Paolo Molaro <lupus@ximian.com>
1712 * aot-runtime.c, method-to-ir.c, mini.c, mini-trampolines.c: use the
1713 new functions to allocate from persistent mempools.
1715 2008-09-23 Zoltan Varga <vargaz@gmail.com>
1717 * mini.h regalloc.h mini-codegen.c: Generalize the regalloc code to allow
1718 multiple register banks in the future.
1720 * mini-codegen.c (mono_local_regalloc): Fix a warning.
1722 2008-09-22 Rodrigo Kumpera <rkumpera@novell.com>
1724 * mini.c (type_to_eval_stack_type): Remove duplicated function.
1726 * method-to-ir.c (type_to_eval_stack_type): Make this version compatible with both JIT.
1728 * mini.h: Export type_to_eval_stack_type.
1730 This function was nearly duplicated in method-to-ir.c and mini.c. The difference
1731 is only ins->klass of byref types.
1733 2008-09-22 Zoltan Varga <vargaz@gmail.com>
1735 * method-to-ir.c (mini_emit_memset): Use a default alignment of 4.
1736 (mini_emit_memcpy2): Ditto.
1738 * mini-amd64.c: Fix a warning.
1740 2008-09-21 Mark Probst <mark.probst@gmail.com>
1742 * exceptions-ppc.c (mono_arch_get_call_filter): Fixed stack frame
1745 2008-09-19 Rodrigo Kumpera <rkumpera@novell.com>
1747 * method-to-ir.c: Extract stloc micro-optimization to a
1748 function and apply it to all cases.
1750 2008-09-19 Mark Probst <mark.probst@gmail.com>
1752 * method-to-ir.c: Don't fail generic code sharing in cases we
1755 2008-09-18 Mark Probst <mark.probst@gmail.com>
1757 * mini-ppc.c: Handle structs in tailcalls on Darwin.
1759 Tue Sep 16 21:07:11 CEST 2008 Paolo Molaro <lupus@ximian.com>
1761 * *.c, *.md, mini-ops.h: introduced relaxed_nop opcode for spin wait
1764 Tue Sep 16 16:39:16 CEST 2008 Paolo Molaro <lupus@ximian.com>
1766 * trace.c: make tracing more useful and correct, with per-thread
1769 2008-09-15 Mark Probst <mark.probst@gmail.com>
1771 * mini-ppc.c (mono_arch_emit_call): Convert floats to R4 when
1772 doing a method call and the argument is an R4.
1774 2008-09-14 Zoltan Varga <vargaz@gmail.com>
1776 * aot-compiler.c (add_wrappers): Do not generate runtime invoke wrappers for
1779 2008-09-13 Mark Probst <mark.probst@gmail.com>
1781 * mini-ppc.c: Convert result to single for OP_ICONV_TO_R4.
1783 2008-09-12 Zoltan Varga <vargaz@gmail.com>
1785 * mini.h (MONO_IS_JUMP_TABLE): Handle GOT_ENTRY.
1786 (MONO_JUMP_TABLE_FROM_INS): Ditto.
1788 2008-09-11 Zoltan Varga <vargaz@gmail.com>
1790 * driver.c: Add a --agent argument (not supported yet) to load managed
1791 agent assemblies before loading the main assembly, similarly to how the
1792 Java VM handles agents.
1794 2008-09-11 Mark Probst <mark.probst@gmail.com>
1796 * mini-ppc.c (mono_arch_allocate_vars): Use arch-independent
1797 function to do stack layout of local variables.
1799 2008-09-11 Mark Probst <mark.probst@gmail.com>
1801 * mini-ppc.c (calculate_sizes): Bugfix in sigcookie position
1804 2008-09-11 Zoltan Varga <vargaz@gmail.com>
1806 * method-to-ir.c ssa2.c mini.c mini-amd64.c decompose.c ssa.c abcremoval.c
1807 abcremoval2.c branch-opts.c driver.c dominators.c: Disable parts of the
1808 JIT if DISABLE_JIT is defined.
1810 * Makefile.am: Avoid compiling/linking in inssel.c if DISABLE_JIT is
1813 2008-09-10 Mark Probst <mark.probst@gmail.com>
1815 * iltests.il.in: Disable the fconv test on PPC (the result is
1816 undefined according to ECMA).
1818 2008-09-10 Mark Probst <mark.probst@gmail.com>
1820 * iltests.il.in: Enable tail call tests for PPC.
1822 * mini.h: Add variable for storing incoming valuetype argument
1823 addresses for tail calls.
1825 * mini-ppc.c: Implement valuetype arguments and return values for
1828 2008-09-09 Mark Probst <mark.probst@gmail.com>
1830 * mini-ppc.c: Partially implement tail calls (struct arguments and
1831 return values not supported).
1833 * method-to-ir.c: Enable tail calls on PPC.
1835 2008-09-08 Zoltan Varga <vargaz@gmail.com>
1837 * aot-compiler.c (emit_wrapper_info): Omit the klass name from
1838 runtime-invoke wrappers to work around the problem of them getting
1839 assigned to a random class.
1841 * aot-runtime.c (mono_aot_get_method): Ditto.
1843 2008-09-07 Zoltan Varga <vargaz@gmail.com>
1845 * mini-exceptions.c mini-mips.h mini-s390.h exceptions-mips.c: Kill
1846 the CUSTOM_EXCEPTION_HANDLING and CUSTOM_STACK_WALK defines.
1848 2008-09-07 Mark Probst <mark.probst@gmail.com>
1850 * method-to-ir.c (mono_method_to_ir2): Disable tail calls for PPC
1851 until they're implemented properly.
1853 * exceptions-ppc.c: Use arch-independent exception-handling code
1854 instead of custom one.
1856 * exceptions-ppc.c, mini-ppc.c, mini-ppc.h: Bug fixes and changes
1859 * tramp-ppc.c, mini-ppc.c: Fixed warnings.
1861 * decompose.c, aot-runtime.c, aot-compiler.c: PPC code also
1862 applies when __powerpc__ is defined.
1864 2008-09-06 Zoltan Varga <vargaz@gmail.com>
1866 * aot-runtime.c (mono_aot_get_method): Add another cache mapping wrapper
1867 methods to their code to avoid computing the full name of wrappers and
1868 doing a lookup in a string hash table.
1870 2008-09-05 Zoltan Varga <vargaz@gmail.com>
1872 * method-to-ir.c: Remove the CHECK_BBLOCK () stuff it is not needed since
1873 we identify bblocks before method_to_ir () is ran.
1875 * branch-opts.c (mono_optimize_branches): Avoid nullifying the exit bblock.
1876 Also avoid optimizing branches pointing to themselves.
1878 * mini.c (mini_method_compile): Ditto. Fixes #422947.
1880 2008-09-05 Rodrigo Kumpera <rkumpera@novell.com>
1882 * driver.c (mono_main): Enable the new verifier under core-clr and cas.
1884 2008-09-05 Zoltan Varga <vargaz@gmail.com>
1886 * tramp-arm.c (mono_arch_nullify_class_init_trampoline): Implement this.
1887 (mono_arch_patch_plt_entry): Fix the calculation of the jump_entry.
1888 (mono_arch_get_nullified_class_init_trampoline): Return 'code' instead of
1891 * aot-compiler.c (emit_plt): Fix the arm plt entries, previously they all
1892 jumped to the same entry in plt_jump_table.
1894 2008-09-02 Rodrigo Kumpera <rkumpera@novell.com>
1896 * method-to-ir.c (initialize_array_data): Handle field with RVA from
1899 2008-08-31 Zoltan Varga <vargaz@gmail.com>
1901 * method-to-ir.c (handle_isinst): Do the assignment at the beginning, so the
1902 other assignment can be if converted. Saves 1.5% on corlib size and fixes
1905 2008-08-29 Geoff Norton <gnorton@novell.com>
1907 * aot-compiler.c: The Mach/ARM compiler doesn't understand the bss
1908 segment, and doesn't properly handle .space as .text. Fixes
1911 2008-08-29 Geoff Norton <gnorton@novell.com>
1913 * mini.c: Disable the mach exception handler when running on
1916 2008-08-29 Geoff Norton <gnorton@novell.com>
1918 * aot-compiler.c: Patch from Renaldas Zioma to properly register
1919 globals on Darwin/ARM
1921 2008-08-28 Zoltan Varga <vargaz@gmail.com>
1923 * mini.c: Avoid not initializing the runtime when doing AOT compilation,
1924 since too many things depend on it. Instead, call
1925 mono_runtime_set_no_exec ().
1927 * mini.c (mono_create_tls_get): Call mono_alloc_preg (cfg) when running with
1930 * aot-compiler.c: Add an 'asm-only' AOT option.
1932 * mini.c: Avoid initializing the runtime when doing AOT compilation.
1934 * aot-compiler.c (compile_method): Disable gshared support for now as it
1937 2008-08-27 Bill Holmes <billholmes54@gmail.com>
1939 * mini-amd64.h : Fix a compiler warning.
1941 * exceptions-amd64.c (mono_arch_unwindinfo_install_unwind_info) :
1942 Changed to use a callback function to retrieve the unwind info.
1943 This avoids problems observed when code blocks were removed by
1944 unloading an app domain.
1946 * mini-amd64.c (mono_arch_cpu_optimizazions) : Removing the peephole
1947 and branch excludes for Winx64. The fix in exceptions-amd64.c allows them
1950 Contributed under MIT/X11 license.
1952 2008-08-27 Bill Holmes <billholmes54@gmail.com>
1954 * mini-amd64.c (mono_arch_output_basic_block) : Fix the OP_X86_PUSH_OBJ
1955 case to keep the stack aligned to 8.
1957 Contributed under MIT/X11 license.
1959 2008-08-26 Zoltan Varga <vargaz@gmail.com>
1961 * aot-runtime.c (mono_aot_get_method): Add a cache for wrapper names to
1962 avoid repeated linear searches.
1964 2008-08-25 Zoltan Varga <vargaz@gmail.com>
1966 * aot-compiler.c (add_wrappers): Avoid calling get_runtime_invoke with
1967 methods it can't handle.
1969 * aot-compiler.c (add_method): Avoid adding a method twice.
1970 (add_wrappers): Add runtime invoke wrappers for all methods.
1972 * tramp-amd64.c (mono_arch_create_rgctx_lazy_fetch_trampoline_full): New
1973 function to create an aot-compatible version of this trampoline.
1975 * aot-compiler.c aot-runtime.c: Add support for AOT rgctx fetch trampolines.
1977 2008-08-24 Zoltan Varga <vargaz@gmail.com>
1979 * aot-compiler.c (compile_method): Skip wrappers of generic icalls.
1981 * method-to-ir.c (mono_method_to_ir2): Replace an assert in UNBOX_ANY
1982 with a generic sharing failure.
1984 * aot-compiler.c (emit_klass_info): Call mono_class_get_nested_types ().
1986 * method-to-ir.c (mono_method_to_ir2): Rethrow the correct exception in
1987 CEE_RETHROW. Fixes #419634.
1989 * mini.c (mono_method_to_ir): Ditto.
1991 * exceptions.cs: Add a new test.
1993 * generic-sharing.c (mini_type_stack_size): Always pass TRUE as allow_open
1994 to mono_type_stack_size_internal () since some callers might not pass in
1997 * mini-x86.c (mono_arch_emit_prolog): Store the rgctx before calling
1998 instrument_prolog. Fixes #419878.
2000 * mini.c (mono_compile_create_var_for_vreg): Make the lvars representing
2001 doubles in soft float mode volatile.
2003 2008-08-23 Zoltan Varga <vargaz@gmail.com>
2005 * ir-emit.h (NEW_ARGSTORE): Use cfg->args and cfg->arg_types to fix the build.
2007 * method-to-ir.c (mono_save_args): Use ARGSTORE instead of TEMPSTORE
2008 to handle soft float correctly.
2010 * tramp-arm.c (mono_arch_create_rgctx_lazy_fetch_trampoline): Implement
2013 * mini.h (struct MonoCallInst): Add dynamic_imt_arg boolean field.
2015 * exceptions-arm.c (mono_arch_find_jit_info): Set ctx->regs [ARMREG_R11]
2016 to sp, since the generics catch code requires it.
2018 * mini-arm.h (MONO_ARCH_VTABLE_REG): Use R0 for this to avoid needless
2021 * method-to-ir.c (emit_imt_argument): Pass imt_arg to
2022 mono_arch_emit_imt_argument ().
2024 * mini-<ARCH>.c (mono_arch_emit_imt_argument): Add an 'imt_arg' argument.
2026 * mini-arm.c tramp-arm.c: Generic sharing updates.
2028 2008-08-22 Zoltan Varga <vargaz@gmail.com>
2030 * mini-arm.c: Fix the arm build.
2032 * generic-sharing.c (mini_type_get_underlying_type): New helper function
2033 handling enums, generic instances and generic sharing.
2034 (mini_type_stack_size_full): Ditto.
2036 * mini-amd64.c mini-x86.c mini-arm.c: Use the new functions.
2038 * mini.h (struct): Add 'uses_rgctx_reg' and 'uses_vtable_reg' fields.
2040 * method-to-ir.c: Set the new fields when using RGCTX_REG/VTABLE_REG.
2042 * tramp-arm.c: Implement the rgctx fetch and the generic class init
2045 * mini-arm.c: Various small generic sharing changes.
2047 * tramp-x86.c (mono_arch_create_generic_class_init_trampoline): Implement
2049 (mono_arch_create_trampoline_code): Remove most of the GENERIC_CLASS_INIT
2052 * mini-trampolines.c (mono_create_generic_class_init_trampoline): New
2053 helper function to return a generic class init trampoline.
2055 * method-to-ir.c mini.c: Use it.
2057 * tramp-amd64.c (mono_arch_create_generic_class_init_trampoline): New
2058 arch-specfic function to return a generic class init trampoline.
2060 * tramp-amd64.c (mono_arch_create_trampoline_code_full): Remove most of
2061 the GENERIC_CLASS_INIT custom code.
2063 * method-to-ir.c (mono_method_to_ir2): If RGCTX_REG is not defined, that is
2064 a fatal error, not a sharing failure.
2066 * tramp-<ARCH>.c (mono_arch_get_rgctx_lazy_fetch_offset): Removed, no longer
2069 * mini-trampolines.c (mono_rgctx_lazy_fetch_trampoline): Get the additional
2070 trampoline argument from MONO_ARCH_VTABLE_REG.
2072 * tramp-x86.c (mono_arch_create_rgctx_lazy_fetch_trampoline): Change the
2073 order of the arguments to the C trampoline: pass 'slot' as the trampoline
2074 argument, and pass the vtable in VTABLE_REG.
2076 * tramp-amd64.c (mono_arch_create_rgctx_lazy_fetch_trampoline): Change the
2077 order of the arguments to the C trampoline: pass 'slot' as the trampoline
2078 argument, and pass the vtable in VTABLE_REG.
2079 (mono_arch_create_trampoline_code_full): Remove some special casing for
2080 the rgctx fetch trampoline.
2082 * mini.c (mono_method_to_ir): Fix the STELEM_ANY+null value optimization.
2085 * iltests.il: Add a test for it.
2087 2008-08-21 Zoltan Varga <vargaz@gmail.com>
2089 * aot-compiler.c (compile_method): Enable AOT support for generics sharing.
2091 * method-to-ir.c (mono_method_to_ir2): Remove an aot restriction which is
2094 * mini-trampolines.c (mono_magic_trampoline): Add a sync wrapper here,
2095 use mono_jit_info_table_find () to avoid recursion.
2096 (mono_delegate_trampoline): Add a sync wrapper here.
2098 * method-to-ir.c (mono_method_to_ir2): Don't call mono_ldftn_nosyc
2101 * mini.c (mono_method_to_ir): Ditto.
2103 * mini-trampolines.c (mono_create_jit_trampoline_in_domain): Remove
2104 add_sync_wrapper argument. Don't add a sync wrapper here.
2105 (mono_create_jump_trampoline): Don't add a sync wrapper here.
2107 * jit-icalls.c (mono_ldftn_nosync): Removed, no longer needed.
2109 2008-08-20 Bill Holmes <billholmes54@gmail.com>
2111 * exceptions-amd64.c (seh_handler): For Winx64 adding missing copy
2112 of nonvolatile registers back from MonoContext to CONTEXT.
2114 Contributed under MIT/X11 license.
2116 2008-08-20 Bill Holmes <billholmes54@gmail.com>
2118 * mini-amd64.c (mono_arch_get_delegate_invoke_impl): When shifting the
2119 arguments on Winx64 there are only 4 argument registers. For this
2120 logic to work the last argument must be pulled from the stack.
2122 Contributed under MIT/X11 license.
2124 2008-08-20 Zoltan Varga <vargaz@gmail.com>
2126 * mini.h (MONO_AOT_FILE_VERSION): Bump aot file format version.
2128 * aot-runtime.c aot-compiler.c patch-info.h mini.c: Get rid of
2129 MONO_PATCH_INFO_WRAPPER, encode/decode wrapper methods like the others in
2130 encode/decode_method_ref ().
2132 * aot-compiler.c (encode_patch): Handle STATIC_RGCTX_INVOKE wrappers.
2134 * aot-runtime.c (decode_patch): Ditto.
2136 * mini.c (mono_resolve_patch_target): Handle RGCTX_FETCH sub-patches of type
2137 MONO_PATCH_INFO_METHOD.
2139 * aot-runtime.c (decode_exception_debug_info): Decode the contents of
2142 * aot-compiler.c (emit_exception_debug_info): Emit the contents of
2145 * method-to-ir.c (emit_imt_argument): Fix AOT+gshared support.
2147 * mini-amd64.c (add_valuetype): Use a dummy gsctx if we didn't receive
2148 one from the caller.
2150 * aot-runtime.c (decode_generic_inst): New function to decode and
2151 return a interned generic inst.
2152 (decode_klass_ref): Use it.
2153 (decode_method_ref): Ditto.
2155 * aot-compiler.c (emit_exception_debug_info): Save
2156 jinfo->has_generic_jit_info too.
2158 2008-08-19 Zoltan Varga <vargaz@gmail.com>
2160 * mini-ia64.c (mono_arch_output_basic_block): Add OP_FCONV_TO_I.
2162 * iltests.il.in: Add a test for fconv_to_i.
2164 * liveness.c: Disable the liveness2 pass for now to save space.
2166 * regalloc2.c: Include mempool-internals.h to fix warnings.
2168 * aot-compiler.c (encode_method_ref): Encode the context of generic
2171 * aot-runtime.c (decode_method_ref): Inflate generic methods using
2172 the context saved in the aot file.
2174 * mini.h (MONO_AOT_FILE_VERSION): Bump aot file format version.
2176 * mini-x86.c (mono_arch_output_basic_block): Disable AOT for OP_JMP.
2178 * method-to-ir.c (mono_method_to_ir2): When using CEE_JMP, make arguments
2179 volatile so they won't be optimized away.
2181 2008-08-19 Rodrigo Kumpera <rkumpera@novell.com>
2187 * dominators.c: Remove duplicated functions that now are in
2188 mempool-internals.h.
2190 2008-08-19 Zoltan Varga <vargaz@gmail.com>
2192 * aot-compiler.c: Fix warnings.
2194 * aot-runtime.c (decode_klass_ref): Add support for VARs/MVARs.
2196 * aot-compiler.c (encode_klass_ref): Encode is_method too for VARs/MVARs.
2198 * method-to-ir.c (emit_get_rgctx_method): Use MONO_PATCH_INFO_METHODCONST
2201 * mini.c (mono_resolve_patch_target): Ditto.
2203 * aot-compiler.c (encode_patch): Add support for RGCTX_FETCH.
2204 (encode_klass_ref): Add support for encoding VARs/MVARs.
2206 * mini.c (mono_patch_info_dup_mp): Handle RGCTX_FETCH.
2208 * aot-runtime.c (decode_patch_info): Rename to 'decode_patch'. Split out
2209 the handling of the got entries into a separate 'decode_got_entry' function.
2210 Add support for RGCTX_FETCH.
2212 * tramp-amd64.c mini-amd64.h: Change the VTABLE_REG to RDI since RAX is
2213 clobbered by the trampoline code.
2215 * tramp-amd64.c mini-amd64.h: Change the VTABLE_REG to RAX since that is
2216 not clobbered by the indirect calling code.
2218 2008-08-18 Zoltan Varga <vargaz@gmail.com>
2220 * mini-x86.c (mono_arch_patch_code): Handle RGCTX_FETCH/GENERIC_CLASS_INIT
2223 2008-08-18 Rodrigo Kumpera <rkumpera@novell.com>
2225 * method-to-ir.c (mono_emit_method_call_full): Alloc the constructor
2226 signature using the compilation mempool otherwise we would leak it.
2228 2008-08-18 Zoltan Varga <vargaz@gmail.com>
2230 * method-to-ir.c (mono_method_to_ir2): Emit the generic class inits using
2231 mono_emit_abs_call ().
2233 * patch-info.h: Add GENERIC_CLASS_INIT.
2235 * mini.c (mono_resolve_patch_target): Handle GENERIC_CLASS_INIT.
2237 * mini-amd64.c (emit_call_body): Treat abs calls which have a patch info
2238 as their target as a near call.
2240 * mini.c (mono_codegen): Handle patches stored in cfg->abs_patches in the
2242 (mono_resolve_patch_target): Add support for MONO_PATCH_INFO_RGCTX_FETCH.
2244 * method-to-ir.c (mono_emit_abs_call): New helper function which emits a
2245 call to a runtime function described by a patch.
2247 * method-to-ir.c: Emit rgctx entry fetches and class init trampolines using
2248 mono_emit_abs_call, this has the advantage that the ABS handling code in
2249 mono_codegen () can handle them both, and can handle other stuff in the
2250 future without additional code.
2252 * mini.h (struct MonoJumpInfoRgctxEntry): New structure describing an rgctx
2254 (MonoCompile): Add 'abs_patches' hashtable, which contains patches describing
2257 * mini.h: Add missing bblock related prototypes.
2259 * mini.h (MonoCompile): Remove unused reverse_inst_list and
2260 reverse_inst_list_len fields.
2262 * mini.c: Refactor this file a bit by moving branch optimizations to
2265 * method-to-ir.c: Merge generic sharing changes missed earlier.
2267 * aot-compiler.c (is_shared_got_patch): Add MONO_PATCH_INFO_METHODCONST.
2269 * aot-runtime.c (decode_patch_info): Refactor the code dealing with the
2270 shared patches. Process METHODCONST as a shared patch.
2272 * liveness.c (mono_analyze_liveness): Disable the liveness2 code for now
2273 as it crashes on the 2.0 mscorlib.
2275 * aot-compiler.c (is_shared_got_patch): Revert the last change as it seems
2278 * aot-compiler.c: Use is_plt_patch () in a few additional places.
2279 (is_shared_got_patch): Add MONO_PATCH_INFO_METHODCONST, which is generated
2282 * aot-compiler.c: Reorganize the got handling code to be a bit more
2285 2008-08-17 Zoltan Varga <vargaz@gmail.com>
2287 * aot-compiler.c: Make the patch_to_plt_offset hash table use
2288 mono_patch_info_equals/hash, and use it to massively simplify
2291 * mini.c (mono_patch_info_hash): Simplify this and add support for
2294 * patch-info.h: Rename RGCTX_LAZY_FETCH_TRAMPOLINE to just RGCTX_FETCH.
2296 * mini.c aot-compiler.c aot-runtime.c: Revert the LAZY_FETCH_TRAMPOLINE
2297 handling code, since an offset is not enough to identify a trampoline.
2299 * method-to-ir.c: Remove some g_assert (!cfg->compile_aot) lines.
2301 2008-08-17 Mark Probst <mark.probst@gmail.com>
2303 * mini.c (mono_op_imm_to_op): Add case for OP_IMUL_IMM.
2305 * method-to-ir.c (mono_method_to_ir2): Decompose OP_CKFINITE.
2307 * mini-ops.h: Argument and result types for OVF_CARRY ops.
2309 * decompose.c: PPC decompositions for various ops.
2311 * cpu-ppc.md, inssel-ppc.brg, mini-ppc.c: PPC changes for Linear IL.
2313 2008-08-17 Zoltan Varga <vargaz@gmail.com>
2315 * tramp-amd64.c (mono_arch_create_rgctx_lazy_fetch_trampoline): Make this
2316 call the generic trampoline code using a call, instead of a jump, to
2317 remove some special casing from the generic trampoline code.
2319 * mini.c (mono_resolve_patch_target): Handle LAZY_FETCH_TRAMPOLINE.
2320 (mono_codegen): Ditto.
2322 * aot-compiler.c aot-runtime.c: Ditto.
2324 * patch-info.h: Add MONO_PATCH_INFO_RGCTX_LAZY_FETCH_TRAMPOLINE.
2326 * mini-trampolines.c (mono_find_rgctx_lazy_fetch_trampoline_by_addr): New
2327 helper function to find the offset corresponding to a lazy fetch trampoline.
2329 * mini.h (MonoCompile): Add 'orig_method' field to hold the original method
2330 when doing generic sharing.
2332 * aot-compiler.c: Use cfg->orig_method instead of cfg->method in a lot of
2335 * mini.c (mono_create_rgctx_lazy_fetch_trampoline): Move this to
2336 mini-trampolines.c to be with the other trampoline creation functions.
2338 * method-to-ir.c (mono_emit_method_call): Remove the 'signature' argument
2339 as it is equal to method->signature in most cases, add a
2340 mono_emit_method_call_full variant which takes a signature and an imt
2343 2008-08-16 Zoltan Varga <vargaz@gmail.com>
2345 * jit-icalls.c (mono_helper_compile_generic_method): Don't pass the context
2346 to this function, since it could be computed easily from the method
2348 (mono_helper_compile_generic_method_wo_context): Removed, not needed any
2351 * method-to-ir.c mini.c: Remove references to
2352 compile_generic_method_wo_context.
2354 * method-to-ir.c (mono_method_to_ir2): Enable AOT for virtual
2355 generic method calls.
2357 * method-to-ir.c (mono_method_to_ir2): Use mono_array_new_1 for 1
2358 dimensional non-szarrays.
2360 * mini.c (mini_init): Register mono_array_new_1.
2362 * jit-icalls.c (mono_array_new_1): New jit icall.
2364 * mini-trampolines.c (mono_magic_trampoline): For jumps, patch the GOT entries
2365 pointing to the method.
2367 * aot-runtime.c (mono_aot_get_method_from_token): Register GOT slots holding
2368 method addresses belonging to METHOD_JUMP patches in the
2369 jump_target_got_slot_hash.
2370 (mono_aot_load_method): Ditto.
2372 * aot-compiler.c (compile_method): Allow AOT compilation of methods with
2373 METHOD_JUMP patches.
2375 * mini.c (mini_create_jit_domain_info): New helper function which
2376 initializes/frees domain->runtime_info.
2377 (mini_free_jit_domain_info): Ditto.
2378 (mini_init): Install the domain hook functions with the runtime.
2380 * mini.h (MonoJitDomainInfo): New structure which stores the domain specific
2381 information maintained by the JIT.
2383 * mini.c (mono_resolve_patch_target): For PATCH_INFO_METHOD_JUMP, move the
2384 insertion into jump_table_hash into mono_codegen (), also implement proper
2387 * method-to-ir.c (mono_method_to_ir2): Don't disable AOT for CEE_JMP and
2388 tail calls, it is already done by the aot code.
2390 * method-to-ir.c (mono_method_to_ir2): Handle CEE_JMP using the tail call
2393 * iltests.il.in: Make the jmp test a bit more complex.
2395 * aot-compiler.c (encode_method_ref): Handle references to normal methods of
2396 generic instances which doesn't have a token.
2398 * aot-runtime.c (decode_method_ref): Ditto.
2400 * method-to-ir.c (handle_unbox_nullable): Don't disable AOT, the aot code
2401 can handle this case now.
2402 (handle_box): Ditto.
2404 2008-08-15 Geoff Norton <gnorton@novell.com>
2406 * mini-x86.c: Fix alignment on Apple x86, and re-disable the alignment
2409 2008-08-15 Zoltan Varga <vargaz@gmail.com>
2411 * method-to-ir.c (mono_method_to_ir2): Allow AOT compilation of methods
2412 calling generic methods.
2414 * aot-compiler.c (encode_patch): Handle MONO_PATCH_INFO_METHOD_RGCTX.
2416 * aot-runtime.c (decode_patch_info): Ditto.
2418 * mini.c (mono_resolve_patch_target): Ditto.
2420 * patch-info.h: Add METHOD_RGCTX.
2422 * mini-amd64.c (mono_arch_output_basic_block): Optimize LOCALLOC_IMM.
2424 2008-08-14 Zoltan Varga <vargaz@gmail.com>
2426 * mini-amd64.c (mono_arch_emit_call): Nullify call->vret_var if returning
2427 arguments in registers.
2429 * decompose.c (mono_decompose_vtype_opts): Create a var for the vreg in
2430 OP_VCALL too, don't depend on OP_OUTARG_VTRETADDR doing it.
2432 * mini.c (mini_method_compile): Abort aot compilation for generic
2433 methods if generic sharing is disabled.
2435 * mini.c (mono_method_to_ir): Disable AOT for virtual calls requiring
2438 * method-to-ir.c (mono_method_to_ir2): Disable AOT for virtual calls
2439 requiring an mrgctx.
2441 * decompose.c (mono_decompose_vtype_opts): Emit the correct sized
2442 store instructions when converting a vcall to a normal call.
2444 * mini.c (sigprof_signal_handler): Call mono_find_jit_info instead of
2445 mono_arch_find_jit_info.
2447 2008-08-13 Zoltan Varga <vargaz@gmail.com>
2449 * method-to-ir.c (check_inline_called_method_name_limit): Optimize this to
2450 avoid calling mono_method_full_name () for every method even if the
2452 (check_inline_caller_method_name_limit): Ditto.
2454 2008-08-12 Zoltan Varga <vargaz@gmail.com>
2456 * driver.c (main_thread_handler): Allow AOT compilation of multiple
2457 assemblies in one run.
2459 * aot-compiler.c (mono_compile_assembly): Only print out a count of
2460 skipped methods if it is not 0.
2462 * Makefile.am (aotcheck): AOT compile all test assemblies in one run.
2464 2008-08-12 Bill Holmes <billholmes54@gmail.com>
2466 * mini.c (mono_codegen): Changing a preprocessor check from WIN64 to
2467 MONO_ARCH_HAVE_UNWIND_TABLE.
2469 Contributed under MIT/X11 license.
2471 2008-08-12 Bill Holmes <billholmes54@gmail.com>
2473 * mini-amd64.c (mono_arch_cpu_optimizazions): Remove peephole and branch
2474 from default optimizaton list on Winx64.
2476 * mini-amd64.c (emit_tls_get): Added Winx64 specific implementation for GetTLS.
2478 * mini-amd64.c (mono_arch_emit_prolog): Adding an offset on Winx64 to get
2479 the LMF from the MonoJitTlsData structure.
2481 * mini-amd64.c (mono_arch_setup_jit_tls_data): Added Winx64 implementation.
2483 Contributed under MIT/X11 license.
2485 2008-08-12 Zoltan Varga <vargaz@gmail.com>
2487 * mini.c (sigsegv_signal_handler): Fix the build.
2489 * mini-amd64.c (emit_call_body): Use image->aot_module instead of
2490 assembly->aot_module.
2492 * aot-runtime.c: Use image->aot_module instead of searching in the aot_modules
2493 hash table. This simplifies and speeds up a lot of code, and fixes support
2496 * mini.c (SIG_HANDLER_SIGNATURE): Avoid crashes if the thread is not registered
2499 * mini-exceptions.c: Ditto.
2501 * exceptions-*c.c (mono_arch_find_jit_info): Remove unused 'trace' and
2502 'native_offset' argument, since these are computed in the
2503 mono_find_jit_info () function.
2505 * mini-exceptions.c (mono_find_jit_info): Make this non-static, as it
2506 is used by exceptions-ppc.c.
2508 * exceptions-ppc.c: Call mono_find_jit_info () instead of
2509 mono_arch_find_jit_info ().
2511 * mini-ppc.h exceptions-ppc.c mini-mips.h mini-mips.c exceptions-mips.c
2512 mini-exceptions.c: Get rid of the CUSTOM_STACK_WALK stuff, use the
2513 generic code in mini-exceptions.c.
2515 2008-08-11 Zoltan Varga <vargaz@gmail.com>
2517 * mini-ppc.c (mono_arch_flush_register_windows): Add this for ppc.
2519 * aot-runtime.c (mono_aot_get_plt_info_offset): Fix a warning.
2521 * aot-runtime.c (mono_aot_get_method): Avoid doing all the loading inside
2522 the aot lock, to avoid deadlocks when mono_aot_get_class_from_name () is
2523 called while holding the loader lock. Fixes #415608.
2524 (mono_aot_get_method_from_token_inner): Ditto.
2526 2008-08-09 Zoltan Varga <vargaz@gmail.com>
2528 * exceptions-ppc.c (mono_jit_walk_stack): Use MONO_INIT_CONTEXT_FROM_CURRENT
2529 to reduce differences between this and the generic implementation in
2531 (ves_icall_get_frame_info): Ditto.
2533 * mini-ppc.h (MONO_INIT_CONTEXT_FROM_CURRENT): Define this for ppc too.
2535 * mini-exceptions.c (mono_exceptions_init): Remove an #ifdef which is no
2538 * exceptions-ppc.c (arch_get_call_filter): Rename this to
2539 mono_arch_get_call_filter () and make it non-static, for consistency with the
2540 other architectures.
2542 2008-08-09 Rodrigo Kumpera <rkumpera@novell.com>
2545 * local-propagation.c:
2546 * mini-x86.c: Correct the name of arch defines.
2548 2008-08-09 Zoltan Varga <vargaz@gmail.com>
2550 * method-to-ir.c (mono_op_to_op_imm_noemul): Correct name of
2551 NO_EMULATE_LONG_SHIFT_OPS define.
2553 2008-08-08 Zoltan Varga <vargaz@gmail.com>
2555 * method-to-ir.c (mono_method_to_ir2): Remove some code from CEE_MONO_LDPTR
2556 now that aot-ed icall wrappers use CEE_MONO_ICALL_ADDR.
2558 * aot-compiler.c aot-runtime.c: Add support for static aot compilation.
2559 MACH fixes. Merged from the 2.0 branch.
2561 * method-to-ir.c (mono_method_to_ir2): Handle CEE_MONO_ICALL_ADDR.
2563 * mini.c (mono_resolve_patch_target): Error out if an icall is not found.
2564 (mono_method_to_ir): Handle CEE_MONO_ICALL_ADDR.
2566 * exceptions-arm.c (mono_arch_get_throw_exception_generic): Add AOT support.
2568 * method-to-ir.c mini.c driver.c aot-compiler.c: Update after
2569 mono_marshal_get_native_wrapper () signature changes.
2571 2008-08-07 Rodrigo Kumpera <rkumpera@novell.com>
2573 * jit-icalls.c (mono_fconv_ovf_u8): Work around soft-float double to long
2574 conversion bug under arm.
2576 2008-08-06 Rodrigo Kumpera <rkumpera@novell.com>
2578 * cpu-arm.md: Increase long_conv_to_ovf_i4_2 max length to 36.
2580 * mini-arm.c (mono_arch_output_basic_block): Implement long to int conversion
2581 with overflow checking.
2583 2008-08-05 Marek Habersack <mhabersack@novell.com>
2585 * Makefile.am (GENMDESC_PRG): when cross-compiling use full path
2586 to the genmdesc.pl file
2588 2008-08-05 Zoltan Varga <vargaz@gmail.com>
2590 * ir-emit.h (EMIT_NEW_ARGSTORE): Fix the usage of param_types and
2591 arg_array in the soft-float versions of the LOAD/STORE macros.
2593 * method-to-ir.c (mono_method_to_ir2): Fix a warning in the arm switch
2596 * ir-emit.h (NEW_VARLOADA): Handle SOFT_FLOAT correctly.
2598 2008-08-02 Zoltan Varga <vargaz@gmail.com>
2600 * mini-ia64.c (add_valuetype): Only reserve half parameter slot for each member of
2601 a float HFA. Fixes #413621.
2603 2008-08-02 Gert Driesen <drieseng@users.sourceforge.net>
2605 * mini-x86.c (mono_arg_get_argument_info): Rename last occurrence of
2606 frame_size to args_size. Fixes build.
2608 2008-08-02 Zoltan Varga <vargaz@gmail.com>
2610 * mini-x86.c (mono_arch_get_argument_info): Rename frame_size to args_size,
2611 and don't align it to MONO_ARCH_FRAME_ALIGNMENT.
2613 * mini-x86.h: Change MONO_ARCH_FRAME_ALIGNMENT to 8 so doubles stored on
2614 the stack are not unaligned. Fixes #413247.
2616 Fri Aug 1 18:46:42 CEST 2008 Paolo Molaro <lupus@ximian.com>
2618 * mini.c: update jitted methods performance counters.
2620 Fri Aug 1 16:30:37 CEST 2008 Paolo Molaro <lupus@ximian.com>
2622 * mini-exceptions.c: increase the exceptions thrown performance
2623 counter in mono_handle_exception ().
2625 2008-07-29 Zoltan Varga <vargaz@gmail.com>
2627 * aot-runtime.c: Use MonoImage's as keys in the aot_modules hash so the aot
2628 can work with netmodules.
2630 2008-07-28 Geoff Norton <gnorton@novell.com>
2632 * mini-x86.h: Correct the frame alignment on OSX. Fixes the jit
2635 2008-07-28 Zoltan Varga <vargaz@gmail.com>
2637 * mini-x86.c (mono_arch_emit_call): Emi the osx stack alignment at the
2640 2008-07-28 Bill Holmes <billholmes54@gmail.com>
2642 * mini-amd64.c (get_call_info): Winx64 fix for passing floats.
2643 The float param registers and other param registers must be the
2644 same index on Windows x64.
2646 * mini-amd64.c (mono_arch_allocate_vars) : Implementing the
2647 ArgValuetypeAddrInIReg argument case. Setting the argument
2648 op to OP_VTARG_ADDR (OP_REGOFFSET)).
2650 * mini-amd64.c (mono_arch_call_opcode) : Winx64 fix. Use the size
2651 variable computed above as the copy length for arguments of storage
2652 type ArgValuetypeAddrInIReg.
2654 * mini-amd64.c (mono_arch_emit_call) : Implementing the
2655 ArgValuetypeAddrInIReg argument case. This case will rely on
2656 mono_arch_emit_outarg_vt to emit the correct code later in the process.
2658 * mini-amd64.c (mono_arch_emit_call) : On Winx64 there always needs to be
2659 a 32 byte stack allocation for all calls. We will omit the adjustment for
2660 jump and tail call instructoins as they do not follow the typical call behavior.
2662 * mini-amd64.c (mono_arch_emit_outarg_vt) : Implementing the case for
2663 ArgValuetypeAddrInIReg. The code emitted will copy the argument to a
2664 local variable and pass the local variable by reference to the called method.
2666 * mini-amd64.c (mono_arch_emit_prolog, emit_load_volatile_arguments) :
2667 Implementing the ArgValuetypeAddrInIReg argument case. When the address
2668 of a struct is passed in a register it must be saved with the other
2669 volatile argument on the stack.
2671 * mini-amd64.c (mono_arch_emit_prolog) : Winx64 fix. When omitting the
2672 frame pointer the stack adjustment value must be saved to the unwind
2675 Contributed under MIT/X11 license.
2677 2008-07-28 Zoltan Varga <vargaz@gmail.com>
2679 * inssel-x86.brg (stmt): Add missing OP_X86_OUTARG_ALIGN_STACK rule
2680 which got lost in the merge.
2682 2008-07-27 Zoltan Varga <vargaz@gmail.com>
2684 * method-to-ir.c: Make the helper_sig variables extern to fix the ppc
2687 * mini-amd64.c (emit_call_body): Add a no_patch case missed earlier.
2689 * mini-amd64.c (emit_call_body): Avoid aligning the call instruction on
2690 icalls, since they won't be patched.
2692 * exceptions-amd64.c (mono_arch_get_restore_context_full): Use a slightly
2693 different code sequence when running under valgrind to prevent some valgrind
2696 * iltests.il.in: Add new regression test.
2698 * method-to-ir.c (mono_method_to_ir2): Fix handling of inlined methods which
2701 * method-to-ir.c (mono_method_to_ir2): Use get_vreg_to_inst () instead of
2702 accessing cfg->vreg_to_inst directly to prevent a crash in LDFLD.
2704 * iltests.il.in: Add new test.
2706 * aot-compiler.c: Fix some warnings.
2708 * decompose.c (mono_decompose_long_opts): Implement OP_ICONV_TO_OVF_I8_UN.
2711 2008-07-27 Zoltan Varga <vargaz@gmail.com>
2713 * driver.c (mono_main): Fix the --gc=none build. Fixes #412482.
2714 (mini_usage_jitdeveloper): Add a missing --wapi option.
2716 2008-07-25 Zoltan Varga <vargaz@gmail.com>
2718 * mini-codegen.c: Simplify the is_fp macros.
2719 (free_up_ireg): Remove, use free_up_reg instead.
2720 (free_up_reg): Fix the fp case.
2722 2008-07-26 Zoltan Varga <vargaz@gmail.com>
2724 * cpu-arm.md (loadr8_membase): Increase the length of this as this is not
2727 * exceptions-x86.c: Merge some changes which seemed to have got lost
2728 in the linear-ir merge.
2730 * liveness.c: Disable the liveness2 pass on 32 bit platforms.
2732 * method-to-ir.c (mono_handle_global_vregs): Make the component vregs of a
2733 long vreg volatile even if the variable was already created.
2735 * liveness.c (update_liveness2): Avoid eliminating dead definitions of
2738 2008-07-26 Zoltan Varga <vargaz@gmail.com>
2740 * cpu-x86.md (fcall_membase): Increase the size of the fcall opcodes.
2742 * mini.c (mono_jit_compile_method_inner): Add support for
2743 MONO_EXCEPTION_BAD_IMAGE.
2745 * method-to-ir.c (mono_method_to_ir2): Avoid a crash if
2746 mini_method_get_context () returns NULL. Fixes #356531.
2748 * mini.c (mono_method_to_ir): Ditto.
2750 * method-to-ir.c (mono_method_to_ir2): Create a variable if needed when
2751 accessing a field of a valuetype in LDFLD/STFLD. Fixes #412399.
2753 2008-07-25 Zoltan Varga <vargaz@gmail.com>
2755 * method-to-ir.c (mono_method_to_ir2): Initialize an uninitialized variable
2756 in the LDFTN implementation.
2758 2008-07-25 Mark Probst <mark.probst@gmail.com>
2760 * mini-trampolines.c (mono_magic_trampoline): When sharing generic
2761 code, patch calls to icalls, too, even if they're not in the
2762 shared generic code hash. Fixes #411962.
2764 2008-07-25 Zoltan Varga <vargaz@gmail.com>
2766 * cpu-x86.md: Increase the length of the fcall opcodes.
2768 * mini-x86.c (emit_move_return_value): Avoid some precision issues for
2769 calls returning floats.
2771 * method-to-ir.c (mono_method_to_ir2): Remove the generic sharing restrictions
2774 * method-to-ir.c (mono_method_to_ir2): Merge some LDFTN gsharing changes
2777 * method-to-ir.c (handle_delegate_ctor): Avoid putting dynamic methods
2778 into the domain->method_code_hash.
2780 * aot-compiler.c: Fix win32 build.
2782 * method-to-ir.c (EMIT_GET_RGCTX): Call EMIT_NEW_LDARG in emit_get_rgctx ().
2784 * method-to-ir.c (mono_method_to_ir2): Use mono_array_new_specific in the
2785 gshared NEWARR implementation.
2787 * cpu-sparc.md: Remove duplicate localloc_imm opcode.
2789 * ir-emit.h (NEW_ARGLOAD): Use cfg->args and cfg->arg_types so this macro
2790 can be used outside of method_to_ir.
2792 * mini.h (MonoCompile): Add arg_types field.
2794 * method-to-ir.c (inline_method): Save/Restore cfg->args and cfg->arg_types.
2796 * method-to-ir.c (mono_method_to_ir2): Set cfg->args and cfg->arg_types to
2797 the values of the local arg_array and param_types array.
2799 2008-07-24 Zoltan Varga <vargaz@gmail.com>
2801 * method-to-ir.c (mono_method_to_ir2): Allocate a GOT var for NEWOBJ, since
2802 got accesses might only get generated later when NEWOBJ is decomposed.
2804 * method-to-ir.c (handle_delegate_ctor): Add an optimization to avoid
2805 looking up the native code of the target method when a delegate is called
2808 * mini-trampolines.c (mono_delegate_trampoline): Add the other half of the
2811 * debug-debugger.c (MONO_DEBUGGER__debugger_info): Fix a warning.
2813 * aot-runtime.c aot-compiler.c: Add a new option 'no-dlsym' which makes
2814 AOT work on platforms without a working dlsym implementation.
2816 * mini.h: Bump AOT image format version.
2818 2008-07-24 Mark Probst <mark.probst@gmail.com>
2820 * mini-exceptions.c: Free a MonoType with
2821 mono_metadata_free_type() instead of g_free().
2823 * aot-runtime.c: Free a MonoType.
2825 2008-07-24 Zoltan Varga <vargaz@gmail.com>
2827 * method-to-ir.c (mono_method_to_ir2): Add a comment for the box+brtrue
2830 * mini-codegen.c (mono_local_regalloc): Remove the remaining items from the
2833 2008-07-23 Massimiliano Mantione <massi@ximian.com>
2834 * mini.c (sigprof_signal_handler): call the new "runtime initialized"
2837 2008-07-23 Zoltan Varga <vargaz@gmail.com>
2839 * method-to-ir.c (mono_method_to_ir2): Set the stack type properly for
2840 NEWOBJ calls on valuetypes.
2842 * iltests.il.in: Add new test.
2844 * mini-x86.c (mono_arch_emit_call): Use mini_type_stack_size ().
2846 2008-07-22 Zoltan Varga <vargaz@gmail.com>
2848 * mini-exceptions.c: Fix some warnings. Remove one ia64 special case as it
2849 is no longer needed.
2851 * mini-ia64.c (mono_arch_emit_prolog): In native-to-managed wrappers, widen
2852 non register sized integer arguments.
2853 (mono_arch_call_opcode): Add support for ArgInFloatRegR4.
2854 (mono_arch_emit_outarg_vt): Pass a more reasonable alignment to
2857 * method-to-ir.c (mono_method_to_ir2): Handle the ret_var_is_local case in
2860 * method-to-ir.c (ADD_WIDEN_OP): New macro to insert a widening op when
2861 two a binop with different sized arguments is emitted.
2863 * mini.c (mono_bblock_insert_after_ins): Properly link up with the next
2864 instruction in the ins==NULL case.
2866 2008-07-23 Zoltan Varga <vargaz@gmail.com>
2868 * mini-ops.h: Add OP_X86_OUTARG_ALIGN_STACK.
2870 * mini-x86.c: Fix osx build.
2872 * mini-amd64.c (mono_arch_output_basic_block): Handle varargs in the CALL_REG
2875 * method-to-ir.c (mono_spill_global_vars): Avoid fusing a load+store into the
2876 instruction for non int sized variables.
2878 * method-to-ir.c (mono_method_to_ir2): Fix an assert in the LDFLD
2881 2008-07-23 Robert Jordan <robertj@gmx.net>
2883 * method-to-ir.c: Fix MSVC build.
2885 2008-07-22 Zoltan Varga <vargaz@gmail.com>
2887 * method-to-ir.c (mono_method_to_ir2): When calling native code which returns
2888 a non int sized type, widen it to an int since newer versions of gcc seem to
2889 generate code which needs this.
2891 * ssa2.c abcremoval2.c: Fix warnings.
2893 * *: Merge the Linear IR branch.
2895 The original branch is at trunk/branches/vargaz/mini-linear-il, and
2896 the ChangeLog file there describes all the changes done over the years.
2897 Further documentation can be found at www.mono-project.com/Linear_IL.
2899 2008-07-21 Bill Holmes <billholmes54@gmail.com>
2901 * mini-amd64.c (get_call_info): Winx64 fix for passing floats.
2902 The float param registers and other param registers must be the
2903 same index on Windows x64.
2905 Contributed under MIT/X11 license.
2907 2008-07-21 Rodrigo Kumpera <rkumpera@novell.com>
2909 * mini.c: Make the previous fix GC safe.
2911 2008-07-21 Raja R Harinath <harinath@hurrynot.org>
2913 * Makefile.am (version.h): Allow a trailing '/' in the repository URL.
2915 2008-07-21 Bill Holmes <billholmes54@gmail.com>
2917 * mini-amd64.c (get_call_info): Correcting the case for MONO_TYPE_TYPEDBYREF
2918 on Winx64. This type will not be passed on the stack (ArgOnStack), but
2919 ArgValuetypeAddrInIReg instead.
2921 Contributed under MIT/X11 license.
2923 2008-07-21 Zoltan Varga <vargaz@gmail.com>
2925 * mini-codegen.c (get_register_spilling): Fix a warning.
2927 2008-07-17 Rodrigo Kumpera <rkumpera@novell.com>
2929 * mini.c: Use mono_runtime_class_init_full to avoid leaking memory
2930 for types which the initialization fails. Raises the provided exception
2931 at the right stop after cleanup.
2933 2008-07-16 Zoltan Varga <vargaz@gmail.com>
2935 * aot-compiler.c: Free most of the memory allocated during compilation.
2937 * mini.c (mini_parse_debug_options): Fix a leak.
2939 * mini.c (mini_method_compile): Don't add the method to the jit info tables
2940 during aot compilation.
2942 2008-07-14 Zoltan Varga <vargaz@gmail.com>
2944 * mini.c (mono_method_to_ir): Disable aot for code using CCASTCLASS on x86 as
2945 it has too much register pressure.
2947 2008-07-13 Zoltan Varga <vargaz@gmail.com>
2949 * inssel.brg (CEE_CASTCLASS): Remove some dead code.
2951 2008-07-12 Zoltan Varga <vargaz@gmail.com>
2953 * mini-x86.h aot-compiler.c aot-runtime.c: Store the plt info offset inline
2956 * mini-amd64.h aot-compiler.c aot-runtime.c: Store the plt info offset inline
2957 on amd64 similar to the way it is done on arm.
2959 * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file format version.
2961 * aot-runtime.c (load_aot_module): Rename 'info' to 'amodule' for
2962 consistency, normalize error messages, avoid loading aot-only modules in
2965 * driver.c (mono_main): Rename --aot-only command line option to --full-aot
2968 * aot-compiler.c aot-runtime.c tramp-arm.c: Implement aot-only support.
2970 2008-07-11 Martin Baulig <martin@ximian.com>
2973 (MonoDebuggerInfo): Add `interruption_request'.
2975 2008-07-12 Zoltan Varga <vargaz@gmail.com>
2977 * aot-compiler.c (emit_plt): Remove some dead code.
2979 * exceptions-arm.c (mono_arch_get_call_filter_full): Initialize ji.
2981 * aot-runtime.c (mono_aot_get_plt_info_offset): New helper function to
2982 return the plt info offset belonging to a given plt entry.
2984 * mini-trampolines.c (mono_aot_plt_trampoline): Use
2985 mono_aot_get_plt_info_offset.
2987 * aot-runtime.c aot-compiler.c tramp-arm.c: Change the arm plt code to be
2988 similar to the amd64 code by makeing jumps through a separate jump table
2989 instead of embedding the jump addresses into the code.
2991 2008-07-11 Zoltan Varga <vargaz@gmail.com>
2993 * mini.c (mono_method_to_ir): Disable aot for calling ldtoken in a generic
2996 2008-07-10 Martin Baulig <martin@ximian.com>
2998 * mini.c (mini_method_compile): Disable generics sharing when
2999 running in the debugger.
3001 2008-07-10 Zoltan Varga <vargaz@gmail.com>
3003 * mini.c (mono_method_to_ir): Create the got var in CEE_REFANYVAL.
3005 * inssel.brg (CEE_CASTCLASS): Avoid reusing temporary registers to prevent
3006 the local register allocator from running out of registers on x86 when
3009 2008-07-10 Bill Holmes <billholmes54@gmail.com>
3011 * inssel-long.brg For OP_LCONV_TO_OVF_I4 an int cast is needed when
3012 expressing IntMin for the VS Compiler. See Compiler Warning (level 2)
3015 Contributed under MIT/X11 license.
3017 2008-07-10 Zoltan Varga <vargaz@gmail.com>
3019 * aot-compiler.c: Get rid of whitespace in the generated assembly file to
3020 speed up the assembler.
3022 2008-07-09 Zoltan Varga <vargaz@gmail.com>
3024 * mini-arm.h tramp-arm.c exceptions-arm.c aot-compiler.c: Beginnings of aot-only
3027 * mini.c: Move the soft float handling macros a bit earlier, add
3028 NEW_TEMPSTORE_SOFT_FLOAT macro, fix warnings, add soft-float support in one
3031 * mini.h: Add prototype for mono_arch_fixup_jinfo.
3033 * mini.c (mini_init): In aot-only mode, set the root domain code manager to
3034 read-only to help catch code allocation requests.
3036 * mini.c inssel.brg aot-compiler.c: Make the use of IMT runtime configurable,
3037 and turn it off when using --aot-only or when compiling with --aot=full.
3039 * mini.c (mono_resolve_patch_target): In aot-only mode, allocate the
3040 jump table for switches from the normal domain mempool, not the code
3043 * mini-trampolines.c (get_unbox_trampoline): New function to return an
3044 unbox trampoline which handles aot-only mode too.
3046 * aot-runtime.c (mono_aot_get_unbox_trampoline): New function to lookup
3047 an AOTed unbox trampoline.
3049 * aot-compiler.c (emit_trampolines): Emit unbox trampolines.
3051 2008-07-09 Bill Holmes <billholmes54@gmail.com>
3053 * wapihandles.c: Fixing MSVC builds. Include statement changed from <> to
3056 Contributed under MIT/X11 license.
3058 2008-07-09 Bill Holmes <billholmes54@gmail.com>
3060 * mini.c (mono_codegen): Allocate space at the end of the code block and store
3061 the unwind information for the method at the end of the allocated block.
3063 * mini-amd64.h: Added declarations for the unwind routines and adding field to
3064 MonoCompileArch to hold the unwind info for SEH on Winx64
3066 * mini-amd64.c (mono_arch_emit_prolog): Calls to the unwind routines added to store
3067 frame pointer info for the method being compiled.
3069 * exceptions-amd64.c (mono_arch_get_throw_corlib_exception): Added a stack adjustment before
3070 the call to mono_exception_from_token.
3072 * exceptions-amd64.c: Added mono_arch_unwindinfo* implementations. This code is responsible
3073 storing the method prolog information in a format that the Winx64 SEH can understand. This
3074 information is stored a the end of the method block because it is all 32-bit offset based.
3076 Contributed under MIT/X11 license.
3078 2008-07-09 Zoltan Varga <vargaz@gmail.com>
3080 * mini.h: Remove duplicate definitions of the mini_wapi_ functions.
3082 * wapihandles.c: Fix warnings.
3084 * aot-runtime.c (load_aot_module): Add a missing error message in aot-only
3087 * mini-trampolines.c (mono_create_jit_trampoline_in_domain): Avoid calling
3088 mono_jit_compile_method in aot-only mode since that calls the type
3091 * mini-trampolines.c (mono_create_delegate_trampoline): Avoid calling
3092 get_delegate_invoke_impl in aot-only mode.
3094 * mini.c (mono_global_codeman_reserve): Reenable the aot-only check.
3096 2008-07-08 Zoltan Varga <vargaz@gmail.com>
3098 * trace.c (mono_trace_enter_method): Fix printing of Type instances.
3100 * aot-compiler.c (compile_method): Disable the check for GSHARED since it
3103 * inssel-long.brg (reg): Add a rule for LCALL_REG (OP_I8CONST).
3105 * tramp-amd64.c (mono_arch_nullify_plt_entry): Read the nullified class
3106 init trampoline from the AOT file as well.
3108 * mini-amd64.c (mono_arch_register_lowlevel_calls): Register
3109 mono_amd64_throw_exception as a jit icall since it is needed by the aot-only
3112 * mini.c (mini_init): Move the call to mono_exceptions_init () after
3115 * exceptions-amd64.c: Add _full variants for the remaining exception code
3116 creation functions as well, allow emission of relocatable code, remove
3117 caching since that is now done by the caller.
3119 * mini-exceptions.c: Add _full variants for the remaining exception code
3120 creation functions as well, add aot-only support.
3122 * aot-compiler.c (compile_method): Allow calls to methods of constructed types
3123 if we can determine a proper token for them.
3124 (add_wrappers): Add a few more wrappers.
3125 (emit_method_code): Remove some dead code.
3126 (emit_trampolines): Emit exception code too.
3128 * mini.c (mono_method_to_ir): Call mono_array_new_2 if possible.
3130 * jit-icalls.c (mono_array_new_2): New jit icall, specialized version of
3131 mono_array_new_va which avoids varargs.
3133 * mini-exceptions.c (mono_exceptions_init): Fix the ppc build.
3135 * mini-trampolines.c: Call mono_create_specific_trampoline () instead of
3136 mono_arch_create_specific_trampoline () in all places.
3138 * aot-compiler.c aot-runtime.c: Refactor the trampoline emitting/loading code
3139 a bit so it can be used for other things as well.
3141 * mini-exceptions.c (mono_exceptions_init): Initialize throw_exception_by_name
3144 * exceptions-amd64.c: Rename the caching from the exception code creation
3145 functions, it is done by the caller instead.
3147 * exceptions-amd64.c: Change the signature of the exception code creation
3148 functions to allow the creation of relocatable code later.
3150 * mini-exceptions.c: Add a set of functions to query the various
3151 runtime-generated exception functions.
3153 * mini.c mini-exceptions.c: Use the newly added functions instead of the
3154 mono_arch_.. () functions.
3156 2008-07-07 Zoltan Varga <vargaz@gmail.com>
3158 * mini-trampolines.c (mono_aot_get_trampoline_code): Removed, no longer used.
3160 * aot-runtime.c aot-compiler.c: AOT the generic trampolines in aot-only mode.
3162 * mini.c (mini_get_imt_trampoline): Call mono_create_specific_trampoline ().
3163 (mini_get_vtable_trampoline): Ditto.
3165 * tramp-amd64.c (mono_arch_create_trampoline_code_full): Create relocatable
3166 code in the AOT case by returning the code size and a list of relocations to
3169 * mini-trampolines.c (mono_create_specific_trampoline): New helper function.
3171 2008-07-07 Bill Holmes <billholmes54@gmail.com>
3173 * mini-amd64.c: On Winx64 the calling convention always requires the caller to
3176 Contributed under MIT/X11 license.
3178 2008-07-07 Zoltan Varga <vargaz@gmail.com>
3180 * aot-compiler.c (emit_exception_debug_info): Serialize the debug info first
3181 so the buffer size can be computed correctly. Fixes #404735.
3183 * debug-mini.c (mono_debug_serialize_debug_info): Lookup the debug info
3184 normally as cfg->debug_info is already freed.
3186 2008-07-06 Zoltan Varga <vargaz@gmail.com>
3188 * mini-amd64.c: For calls returning vtypes in registers, don't store
3189 the return address on the stack, instead allocate a separate local for
3192 2008-07-05 Mark Probst <mark.probst@gmail.com>
3194 * mini-trampolines.c, mini.h: Add an argument to
3195 mono_create_jit_trampoline_in_domain() for turning off the adding
3196 of the sync wrapper.
3198 * mini.c: Use the JIT trampoline without sync instead of
3199 ldftn_nosync in static RGCTX invoke wrappers so that the call can
3202 2008-07-04 Mark Probst <mark.probst@gmail.com>
3204 * driver.c: Turn on GSHARED optimization by default.
3206 2008-07-04 Zoltan Varga <vargaz@gmail.com>
3208 * mini-trampolines.c mini.c mini.h tramp-<ARCH>.c: Rename MONO_TRAMPOLINE_GENERIC
3209 to MONO_TRAMPOLINE_JIT since it better reflects what it does.
3211 * mini-trampolines.c (mono_get_aot_trampoline_code): New internal function to
3212 create a variant of the generic trampoline code callable from AOTed trampolines.
3214 * tramp-amd64.c (mono_arch_create_trampoline_code_full): Add support for generic
3215 trampoline code callable from AOTed trampolines.
3217 * aot-compiler.c aot-runtime.c: Add support for AOTing trampolines.
3219 2008-07-04 Mark Probst <mark.probst@gmail.com>
3221 * inssel.brg, mini-ops.h: New opcode for doing CHECK_THIS in a
3222 pass-through manner.
3224 * mini.c: Generic method sharing. Pass MRGCTX to generic methods
3225 and don't fail sharing for them anymore.
3227 * mini-exceptions.c: Handle exceptions in shared generic methods.
3229 * generic-sharing.c: When checking the context of a generic
3230 method, also check its class's context. Don't treat wrappers as
3233 * mini-trampolines.c: Some code factored out to
3234 metadata/generic-sharing.c. Handle the MRGCTX case.
3236 * jit-icalls.c, jit-icalls.h: ldvirtfn icall for generic sharing -
3237 we must deal with the method being of another instantiation of the
3238 class. Add static rgctx invoke wrappers to generic methods.
3240 2008-07-04 Mark Probst <mark.probst@gmail.com>
3242 * mini.c: Provide all jit infos of generic shared methods with a
3245 * mini-exceptions.c: Handle the new situation that a generic info
3246 might be available, but not info about the this/vtable/mrgctx
3249 2008-07-03 Mark Probst <mark.probst@gmail.com>
3251 * mini.c: Don't accept ldftn and ldvirtftn with uninstantiated
3254 2008-07-03 Zoltan Varga <vargaz@gmail.com>
3256 * dominators.c (check_dominance_frontier): Fix a warning.
3258 * mini.h: Add some missing prototypes.
3260 * ssa.c local-propagation.c debug-debuger.c: Fix warnings.
3262 * driver.c (mono_jit_init_version): Correct the comments since the first
3263 argument should be the name of the root domain, not a filename.
3265 * aot-runtime.c (make_writable): Error out if this is called while running
3267 (load_aot_module): Ditto.
3269 * aot-compiler.c: Really fix the computation of method indexes.
3271 * mini-amd64.c (mono_arch_get_delegate_invoke_impl): Remove the previous
3272 optimizations as this is no longer called frequently.
3274 * mini-trampolines.c (mono_create_delegate_trampoline): Precompute the invoke
3275 method and the invoke impl code and pass it to the delegate trampoline instead of
3276 just the delegate class.
3278 2008-07-02 Zoltan Varga <vargaz@gmail.com>
3280 * aot-compiler.c: Fixup the computation of method indexes.
3281 (add_wrappers): Create the base methods of the runtime invoke wrappers using
3282 the method builder infrastructure.
3284 * aot-runtime.c (decode_exception_debug_info): Don't crash if the method
3287 * mini-trampolines.c (mono_create_jit_trampoline_in_domain): In aot-only
3288 mode, load the method right away instead of creating a trampoline.
3290 * mini-x86.c (mono_arch_get_delegate_invoke_impl): Eliminate locking.
3292 * mini-amd64.c (mono_arch_get_delegate_invoke_impl): Eliminate locking, speed up
3295 2008-07-01 Zoltan Varga <vargaz@gmail.com>
3297 * aot-runtime.c (decode_patch_info): Don't create trampolines in aot_only mode.
3298 (mono_aot_load_method): Use method_index instead of method->token.
3300 * mini.c (mono_jit_compile_method_inner): Move the aot_only check down, so it
3301 can handle icalls etc. properly.
3303 * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file format version.
3305 * aot-compiler.c aot-runtime.c: Allow AOTing many wrapper types.
3307 * mini.c (mono_resolve_patch_target): Handle JIT_ICALL_ADDR.
3308 (mono_codegen): Convert calls made by JIT icall wrappers to the icalls into
3309 JIT_ICALL_ADDR patch type.
3311 * patch-info.h: Add JIT_ICALL_ADDR patch type.
3313 * mini.c (mono_method_to_ir): Allow AOTing methods which access the interruption
3315 (mono_resolve_patch_target): Handle INTERRUPTION_REQUEST_FLAG.
3317 * patch-info.h: Add INTERRUPTION_REQUEST_FLAG.
3319 2008-06-30 Zoltan Varga <vargaz@gmail.com>
3321 * mini.c: Use domain->jit_code_hash_lock for controlling access to
3322 domain->jit_code_hash.
3324 2008-06-29 Zoltan Varga <vargaz@gmail.com>
3326 * mini.c (mini_parse_debug_options): Add 'dont-free-domains' option.
3328 2008-06-27 Zoltan Varga <vargaz@gmail.com>
3330 * mini-trampolines.c (mono_delegate_trampoline): Don't pass a gsctx to
3331 get_this_arg_from_call, let it compute it when needed.
3333 * mini-amd64.c (mono_arch_get_this_arg_reg): Add a 'code' argument, compute
3334 gsctx from code only when needed.
3336 * mini-trampolines.c (get_generic_context): Rename this to
3337 mono_get_generic_context_from_code (), and move it to generic-sharing.c, where
3338 it can be called by the arch backends.
3340 * mini-exceptions.c (mono_print_thread_dump): Allow the argument to be NULL.
3342 2008-06-26 Zoltan Varga <vargaz@gmail.com>
3344 * driver.c (mono_main): Add experimental --aot-only command line option.
3346 * mini.c: Error out when creating trampolines or JIT compiling if --aot-only is
3349 2008-06-26 Kornél Pál <kornelpal@gmail.com>
3351 * driver.c (DllMain): Remove mono_module_handle.
3353 Contributed under MIT/X11 license.
3355 2008-06-25 Zoltan Varga <vargaz@gmail.com>
3357 * aot-compiler.c: Add not-yet-usable 'full' option. Add some infrastructure code
3358 for emitting methods which are not in the source assembly. Detect and report
3359 failure of assembling+linking.
3361 * aot-compiler.c (emit_klass_info): Call mono_class_setup_vtable ().
3363 * aot-compiler.c: Move the contents of the has_glot_slots array to MonoCompile.
3365 2008-06-24 Rodrigo Kumpera <rkumpera@novell.com>
3367 * mini.c: Check if stats is enabled so we don't allocate memory when not needed.
3369 2008-06-24 Zoltan Varga <vargaz@gmail.com>
3371 * mini.h: Remove some obsolete prototypes.
3373 * mini.c: Avoid storing MonoMethod pointers in the JIT stats, store their string format instead.
3375 2008-06-24 Mark Probst <mark.probst@gmail.com>
3377 * mini.c (get_object_generic_inst): Variable-sized arrays are not
3378 supported by Visual Studio, so use alloca().
3380 2008-06-23 Zoltan Varga <vargaz@gmail.com>
3382 * mini-ia64.c (add_valuetype): Increase *gr too when passing a HFA to be in sync with the ABi.
3385 2008-06-23 Mark Probst <mark.probst@gmail.com>
3387 * mini.c: Fail sharing of a generic method if it contains an open
3388 catch clause (because we don't pass MRGCTXs yet).
3390 2008-06-23 Mark Probst <mark.probst@gmail.com>
3392 * mini.c: When compiling a method with generic sharing, insert the
3393 method instantiated with an all-Object generic context into the
3394 jit info table, instead of the context of the first instantiation
3395 of the method we happen to compile.
3397 2008-06-18 Martin Baulig <martin@ximian.com>
3399 * debug-debugger.h (MonoDebuggerInfo): Replaced `version' with
3400 `major_version' and `minor_version'.
3402 2008-06-17 Mark Probst <mark.probst@gmail.com>
3404 * generic-sharing.c, mini.c, mini.h, aot-runtime.c:
3405 mono_method_is_generic_sharable_impl() takes an additional
3406 argument specifying whether to treat type variables as reference
3409 2008-06-17 Mark Probst <mark.probst@gmail.com>
3411 * mini.h: Removed obsolete prototypes.
3413 2008-06-17 Mark Probst <mark.probst@gmail.com>
3415 * mini.c: Don't fail generic sharing for initobj and sizeof - we
3416 already handle them.
3418 2008-06-17 Mark Probst <mark.probst@gmail.com>
3420 * mini.h, mini-trampolines.c, tramp-alpha.c, tramp-amd64.c,
3421 tramp-arm.c, tramp-hppa.c, tramp-ia64.c, tramp-mips.c,
3422 tramp-ppc.c, tramp-s390.c, tramp-s390x.c, tramp-sparc.c,
3423 tramp-x86.c: Added a MonoGenericContext* argument to
3424 mono_arch_get_unbox_trampoline() so that it can call other
3425 functions which require it.
3427 2008-06-17 Mark Probst <mark.probst@gmail.com>
3429 * mini.h, mini-trampolines.c, mini-amd64.c, mini-x86.c,
3430 mini-alpha.c, mini-arm.c, mini-ia64.c, mini-ppc.c:
3431 mono_arch_get_this_arg_from_call() takes a
3432 MonoGenericSharingContext* as well.
3434 2008-06-17 Mark Probst <mark.probst@gmail.com>
3436 * mini.c: Factor out code for emitting unbox into emit_unbox() and
3437 implement generic sharing of unbox.
3439 2008-06-17 Mark Probst <mark.probst@gmail.com>
3441 * mini.c: Don't compute the vtable to determine whether a field is
3442 special static, because it might not work for open types.
3444 2008-06-17 Mark Probst <mark.probst@gmail.com>
3446 * mini.c: Removed the unused token_type and token_source arguments
3447 from get_runtime_generic_context_ptr().
3449 2008-06-17 Marek Habersack <mhabersack@novell.com>
3451 * mini.c (ADD_BINOP): fix the build
3453 2008-06-16 Zoltan Varga <vargaz@gmail.com>
3455 * mini.c (ADD_BINOP): When operating on a native int and an int32, insert
3458 2008-06-16 Mark Probst <mark.probst@gmail.com>
3460 * mini.h: Removed class relations enum that's not used anymore.
3462 2008-06-16 Mark Probst <mark.probst@gmail.com>
3464 * tramp-x86.c, tramp-amd64.c: Slot access code for MRGCTXs.
3466 * mini-trampolines.c: Distinguish between RGCTXs and MRGCTXs in
3467 the lazy fetch trampoline access code.
3469 2008-06-15 Zoltan Varga <vargaz@gmail.com>
3471 * mini-codegen.c (mono_local_regalloc): Add some micro optimizations.
3473 2008-06-14 Zoltan Varga <vargaz@gmail.com>
3475 * mini.c: Fix some soft-float bugs. Fixes #378735 and #398348.
3477 * mini.h (MONO_INST_LIST_ENTRY): Fix warnings on arm.
3479 * mini.c (mono_method_to_ir): Check call signature for NEWOBJ as well.
3481 2008-06-13 Zoltan Varga <vargaz@gmail.com>
3483 * mini-x86.c inssel-x86.brg cpu-x86.md: Implement unsigned min/max
3486 * mini-ops.h: Add MIN/MAX_UN opcodes.
3488 * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Implement unsigned min/max
3491 * basic-math.cs: Add more min/max tests.
3493 * inssel.brg: Remove the OP_MIN/OP_MAX rules. Fix a warning.
3495 2008-06-13 Mark Probst <mark.probst@gmail.com>
3497 * mini.c: Small fix in the prologue of emit_castclass.
3499 2008-06-13 Zoltan Varga <vargaz@gmail.com>
3501 * inssel.brg: Remove the OP_MIN/OP_MAX rules. Fix a warning.
3503 * mini.c (mini_get_inst_for_method): Remove the Min/Max intrinsics, they
3504 do not work even for unsigned types. Fixes #400014.
3506 * basic-math.cs: Add regression tests for unsigned Min/Max.
3508 2008-06-13 Mark Probst <mark.probst@gmail.com>
3510 * mini.c: Added additional context_used argument to several
3511 functions, which will be needed for sharing generic methods. Use
3512 GET_RGCTX macro wherever appropriate. Declare only one
3513 context_used in mono_method_to_ir().
3515 2008-06-13 Mark Probst <mark.probst@gmail.com>
3517 * mini.c, generic-sharing.c: Removed generic class relations.
3519 * mini.c, tramp-amd64.c, tramp-x86.c: Additional arguments to
3520 functions due to MRGCTX changes.
3522 2008-06-13 Mark Probst <mark.probst@gmail.com>
3524 * inssel.brg, inssel-long.brg, inssel-long32.brg, mini-ops.h,
3525 graph.c, local-propagation.c, aliasing.c: New opcodes for calls
3526 with calculated IMT.
3528 * mini.c: Generic sharing of calls via generic interfaces.
3530 * jit-icalls.c, jit-icalls.h: Helper function for compiling a
3531 generic method with non-constant MonoGenericContext*. Instead,
3532 the context is taken out of the method itself.
3534 2008-06-13 Mark Probst <mark.probst@gmail.com>
3536 * mini.c: Generic sharing of ldvirtftn.
3538 2008-06-13 Mark Probst <mark.probst@gmail.com>
3540 * mini.c: Generic sharing of ldftn.
3542 2008-06-13 Mark Probst <mark.probst@gmail.com>
3544 * mini.c: Do pass VTable/RGCTX argument to static generic methods.
3546 2008-06-13 Mark Probst <mark.probst@gmail.com>
3548 * mini.c: Generic sharing of the special case of ldtoken followed
3549 by a call to GetTypeFromHandle.
3551 2008-06-13 Mark Probst <mark.probst@gmail.com>
3553 * mini.c: Generic sharing of box for nullable types.
3555 2008-06-13 Zoltan Varga <vargaz@gmail.com>
3557 * mini-s390x.c (add_stackParm): Fix computation of offsets when arguments
3558 are passed on the stack. Fixes #324807.
3560 2008-06-12 Bill Holmes <billholmes54@gmail.com>
3562 * mini-amd64.c:add_valuetype: Adding Winx64 code to fill the ArgInfo
3563 for the ArgValuetypeAddrInIReg case.
3565 * mini-amd64.c:mono_arch_allocate_vars: Adding a case for
3566 ArgValuetypeAddrInIReg to avoid asserts. Code needs to be added here.
3568 * mini-amd64.c: mono_arch_call_opcode: Adding Winx64 code for an ArgInfo of
3569 type ArgValuetypeAddrInIReg. The code emitted will copy the argument to a
3570 local variable and pass the local variable by reference to the called method.
3572 * mini-amd64.c: mono_arch_emit_prolog: Adjust the stack for calls to
3573 mono_jit_thread_attach and mono_get_lmf_addr for Winx64.
3575 Contributed under MIT/X11 license.
3577 2008-06-10 Rodrigo Kumpera <rkumpera@novell.com>
3579 * debug-mini.c (mono_debug_free_method_jit_info): Moved to metadata/mono-debug.c.
3581 * debug-mini.c (mono_debug_print_vars): Release memory after printing
3584 2008-06-10 Martin Baulig <martin@ximian.com>
3587 (mono_debug_close_method): Check whether `cfg->epilogue_begin != NULL'.
3589 2008-06-09 Kornél Pál <kornelpal@gmail.com>
3591 * main.c: Add and set argv [argc] to NULL to match C specification that fixes
3592 possible error when no arguments are passed.
3594 Contributed under MIT/X11 license.
3596 2008-06-09 Rodrigo Kumpera <rkumpera@novell.com>
3598 * mini-exceptions.c (ves_icall_get_trace): Skip source locations
3599 where the file name is NULL.
3601 2008-06-09 Zoltan Varga <vargaz@gmail.com>
3603 * mini.c: Fix s390 build.
3605 2008-06-08 Zoltan Varga <vargaz@gmail.com>
3607 * trace.c (mono_trace_parse_options): Fix warnings.
3609 * mini-amd64.c: Revert most of the last patch for now as it breaks the build.
3611 2008-06-07 Zoltan Varga <vargaz@gmail.com>
3613 * mini.c (remove_block_if_useless): Avoid printing the method name.
3615 * mini.c: Remove needless setting of ins->cil_code which is now done by
3618 * mini-amd64.c: Add some code to avoid saving callee saved registers in the
3621 * tramp-amd64.c (mono_arch_patch_callsite): Tell valgrind to discard the
3622 translated code after it has been patched.
3624 2008-06-06 Zoltan Varga <vargaz@gmail.com>
3626 * mini-amd64.c (emit_call_body): Align the call displacement to 4 bytes to
3627 avoid problems during code patching on SMP systems.
3628 (emit_call): Avoid adding a patch info which is already added by
3630 (mono_arch_emit_exceptions): Ditto.
3632 2008-06-05 Zoltan Varga <vargaz@gmail.com>
3634 * tramp-*.c (mono_arch_get_unbox_trampoline): No need to check for ret->byref,
3635 MONO_TYPE_ISSTRUCT already checks for it.
3637 2008-06-05 Bill Holmes <billholmes54@gmail.com>
3639 * mini-amd64.c:merge_argument_class_from_type: When marshaling
3640 structs with floats on Winx64 the float registers are not used.
3641 The integer registers are always used..
3642 * mini-amd64.c:add_valuetype: When marshaling structs on Winx64
3643 only one register will be used and only if the size of the struct
3644 is 1,2,4, or 8 bytes.
3646 * tramp-amd64.c : Adjusting size used for mono_global_codeman_reserve
3649 Contributed under MIT/X11 license.
3651 2008-06-05 Martin Baulig <martin@ximian.com>
3653 * debug-debugger.c (debugger_lookup_class): Also call
3654 mono_class_setup_methods() here; we're only called from RTI.
3656 2008-06-05 Andreas Färber <andreas.faerber@web.de>
3658 * mini.c (mini_init): Add DTrace probes ves-init-{begin,end}.
3659 (mini_method_compile) Add DTrace probes method-compile-{begin,end}.
3660 * Makefile.am (libmono_la_LIBADD,libmono_static_la_LIBADD,mono_LDADD):
3661 Post-process object files and add dtrace-generated object, if necessary.
3663 Contributed under MIT/X11 license.
3665 2008-06-04 Mark Probst <mark.probst@gmail.com>
3667 * inssel.brg, mini-ops.h: Added opcode for unboxcast with computed
3670 * mini.c: Generic sharing for unbox.any and castclass.
3672 2008-06-04 Mark Probst <mark.probst@gmail.com>
3674 * mini.c: Ignore tailcall prefix in shared generic code and when
3675 doing calls which require a vtable/rgctx argument.
3677 2008-06-04 Mark Probst <mark.probst@gmail.com>
3679 * mini.c: Don't free the JIT info.
3681 * driver.c: Changes in the JIT info table testing code.
3683 2008-06-03 Zoltan Varga <vargaz@gmail.com>
3685 * tramp-arm.c (mono_arch_create_trampoline_code): Check for thread
3686 interruption. Fix some warnings.
3688 * tramp-*.c (mono_arch_create_trampoline_code): Call the _force_ variant of
3689 interruption_checkpoint.
3691 Tue Jun 3 13:07:03 CEST 2008 Paolo Molaro <lupus@ximian.com>
3693 * jit.h, mini.h, trace.c, driver.c: introduce an API to enable tracing
3694 from embedding applications.
3696 2008-06-02 William Holmes <billholmes54@gmail.com>
3698 * mini-amd64.c : Correcting some of the issues for Winx64 dealing with
3699 reserving 32 bytes on the stack when making calls.
3701 Contributed under MIT/X11 license.
3703 2008-06-01 Zoltan Varga <vargaz@gmail.com>
3705 * mini-arm.c (mono_arch_output_basic_block): Merge some small fixes from
3706 the linear IL branch.
3708 * driver.c: Print out more information for --version on arm.
3710 2008-05-30 Zoltan Varga <vargaz@gmail.com>
3712 * mini-amd64.c (mono_arch_emit_prolog): Increase max_offset when processing
3713 bb_exit instead, since out of line bblocks might not actually be emitted
3716 * mini-amd64.c (mono_arch_emit_prolog): Increase bb->max_offset by the
3717 maximum epilog size for out of line bblocks if tracing is enabled.
3719 * iltests.il.in: Merge tests/long-shift.regalloc.il into this file.
3721 2008-05-28 Rodrigo Kumpera <rkumpera@novell.com>
3723 * arrays.cs: Regression tests for allocating arrays with negative sizes.
3725 2008-05-28 Zoltan Varga <vargaz@gmail.com>
3727 * mini-x86.h mini-x86.c inssel-x86.brg cpu-x86.md: Add support for
3728 CAS instrinsics. Optimize the implementation of the ATOMIC_EXCHANGE
3731 2008-05-27 Zoltan Varga <vargaz@gmail.com>
3733 * mini.c (mini_get_inst_for_method): Add support for CAS instrinsics when
3734 the 'value' to store is a constant.
3736 * mini-ops.h: Add OP_ATOMIC_CAS_IMM opcodes.
3738 * mini-amd64.c (mono_arch_output_basic_block): Optimize the the implementation
3739 of ATOMIC_EXCHANGE opcodes, add support for the CAS opcodes.
3741 2008-05-26 Zoltan Varga <vargaz@gmail.com>
3743 * mini.c generic-sharing.c jit-icalls.c aot-compiler.c: Use accessor functions
3744 for accessing method->generic_container.
3746 2008-05-24 Zoltan Varga <vargaz@gmail.com>
3748 * mini.c (mono_method_check_inlining): Avoid creating vtables if possible.
3750 * mini.c (SIG_HANDLER_SIGNATURE): Fix sparc build too.
3752 * mini.c (SIG_HANDLER_SIGNATURE): Fix IA64 build.
3754 * mini.c (mono_jit_compile_method_inner): Avoid a crash if mono_class_vtable ()
3757 2008-05-23 Zoltan Varga <vargaz@gmail.com>
3759 * driver.c (mono_main): Set mono_setup_vtable_in_class_init to FALSE.
3761 * mini.c: Handle the case when mono_class_vtable () fails.
3763 2008-05-23 Massimiliano Mantione <massi@ximian.com>
3764 * mini.c (sigprof_signal_handler): Support call chains (backtrace) in
3767 2008-05-22 Mark Probst <mark.probst@gmail.com>
3769 * mini.c, jit-icalls.c, jit-icalls.h: Make generic sharing work
3770 together with domain sharing.
3772 2008-05-22 Mark Probst <mark.probst@gmail.com>
3774 * mini.c: Treat callvirts to final methods like non-virtual calls
3775 when doing generic sharing, i.e. look them up in the runtime
3778 2008-05-22 Mark Probst <mark.probst@gmail.com>
3780 * inssel.brg, mini-ops.h: Added opcodes for mkrefany and refanyval
3781 with computed types (for generic sharing).
3783 * mini.c: Generic sharing for mkrefany and refanyval.
3785 2008-05-22 Zoltan Varga <vargaz@gmail.com>
3787 * inssel.brg (mini_emit_virtual_call): Avoid constructing a generic vtable if
3790 * mini-trampolines.c (mono_magic_trampoline): Avoid calling setup_methods () in
3791 the generic sharing code.
3793 * mini-trampolines.c (mono_magic_trampoline): Call mono_class_setup_methods ()
3796 2008-05-21 Zoltan Varga <vargaz@gmail.com>
3798 * mini.h: Remove the declaration of mono_aot_init_vtable ().
3800 2008-05-21 C.J. Adams-collier <cjac@colliertech.org>
3802 * driver.c: updated copyright date
3804 2008-05-21 Zoltan Varga <vargaz@gmail.com>
3806 * aot-runtime.c mini.c: Remove the AOT init_vtable stuff as it is no longer
3809 2008-05-19 Martin Baulig <martin@ximian.com>
3811 * debug-debugger.h (MonoDebuggerInfo): Add `using_mono_debugger'
3812 pointing to the new `_mono_debug_using_mono_debugger' variable.
3815 (mono_main): Check mono_debug_using_mono_debugger() rather than
3816 the `MONO_INSIDE_MDB' environment variable to check whether we're
3817 inside the debugger.
3819 2008-05-19 Zoltan Varga <vargaz@gmail.com>
3821 * mini.c (mini_method_compile): Use cfg->args [0] for accessing the this
3824 2008-05-08 Rodrigo Kumpera <rkumpera@novell.com>
3826 * declsec.h: Move MONO_SECMAN_FLAG to metadata/metadata-internals.h.
3828 * mini.c: Added mini_assembly_can_skip_verification. This
3829 function checks if the assembly requested to skip verification.
3830 Fixes part of #387274.
3832 2008-05-07 Zoltan Varga <vargaz@gmail.com>
3834 * mini.c (mini_get_method): Disable the check for open generic classes when
3835 using generic sharing.
3837 * generics.cs: Add a test for #387034.
3839 * mini.c (mini_get_method): Check whenever the method class is an open generic
3840 type, and return NULL in that case, causing a verification error. Fixes
3843 2008-05-06 Rodrigo Kumpera <rkumpera@novell.com>
3845 * driver.c (mono_main): Revert r102623. The right
3846 thing to do is to enable the verifier under verifiable
3847 unless a --security flag was passed.
3849 We need this non-trivial behavior for --verify-all otherwise
3850 mcs-compileall won't be able to use it. As it needs everything to
3851 be verified under validil.
3853 2008-05-06 Martin Baulig <martin@ximian.com>
3857 * debug-mini.c (mono_debugger_thread_created): Add proper locking.
3858 (mono_debugger_thread_cleanup): Likewise.
3859 (mono_debugger_extended_notification): Likewise.
3861 2008-05-06 Rodrigo Kumpera <rkumpera@novell.com>
3863 * mini.c (mono_method_to_ir): Verify visibility of call related opcodes
3864 against both inflated and non-inflated methods. We need to check against the
3865 generic definition for cases where the instantiated method is not visible.
3866 We need to check against the inflated types for cases where the instantiation
3867 changes any super type. This fixes #382986.
3869 Note that this doesn't need to be applied to other parts of mono_method_to_ir
3870 that check for visibiliy as generic params only appears as the type subject
3871 of tokens on call opcodes. Field manipulation and ldftn must always
3872 target an exact type.
3874 2008-05-06 Rodrigo Kumpera <rkumpera@novell.com>
3876 * driver.c (mono_main): Using --verify-all enables the verifier under validil mode
3877 if no related --security flag is passed.
3879 2008-05-05 Andreas Färber <andreas.faerber@web.de>
3881 * mini-arch.h: Prepare support for ppc64.
3883 Contributed under MIT/X11 license.
3885 2008-05-05 Andreas Färber <andreas.faerber@web.de>
3887 * aot-runtime.c: Prepare support for ppc64.
3889 Contributed under MIT/X11 license.
3891 2008-05-05 Andreas Färber <andreas.faerber@web.de>
3893 * mini-ops.h: Prepare support for ppc64.
3895 Contributed under MIT/X11 license.
3897 2008-05-04 Andreas Färber <andreas.faerber@web.de>
3899 * helpers.c: Add support for OSX/ppc64 and Linux/ppc64 (dis)assemblers.
3901 Contributed under MIT/X11 license.
3903 2008-05-03 Zoltan Varga <vargaz@gmail.com>
3905 * aot-runtime.c (load_aot_module): Avoid trying to load aot code for dynamic
3906 assemblies, since aot_name is not a full path, causing us to load MS.NET
3907 assemblies on windows.
3909 2008-04-28 Kornél Pál <kornelpal@gmail.com>
3911 * mini.c (mono_jit_compile_method_inner): Use g_warning instead of g_error
3912 for unsupported METHOD_IMPL_ATTRIBUTE_NATIVE.
3913 * main.c: Use UTF-8 encoded command line instead of Windows default code
3914 page on Windows to support Unicode.
3915 * driver.c (DllMain): New function for mixed-mode assembly support.
3916 * Makefile.am: Add -Wl,--kill-at to libmono_la_LDFLAGS on Windows to
3917 export __stdcall functions without decoration.
3919 Contributed under MIT/X11 license.
3921 2008-04-28 Mark Probst <mark.probst@gmail.com>
3923 * tramp-amd64.c, mini-amd64.c: Preserve R11 in the trampoline by
3924 saving it very early.
3926 2008-04-28 Mark Probst <mark.probst@gmail.com>
3928 * mini.h, mini.c: Lots of code for accessing the old RGCTX
3929 deleted. The only way to access the new RGCTX is via the
3932 * mini.c, mini-amd64, mini-x86.c, mini-exceptions.c: Pass the
3933 vtable instead of the RGCTX to static methods.
3935 * mini-tramplines.c, tramp-amd64.c, tramp-x86.c: Trampoline for
3936 accessing the new RGCTX.
3938 * generic-sharing.c: There is no separation between self, type
3939 arguments and other types in the RGCTX anymore.
3941 2008-04-25 Jonathan Chambers <joncham@gmail.com>
3943 * mini-amd64.c (add_general): Remove previous stack adjustment.
3944 (mono_arch_call_opcode): Remove OP_OUTARG_MEMBASE and instead simply
3945 adjust stack pointer after pushing args. Adjust ARGS_OFFSET to account
3946 for 32 bytes of stack space reserved for all calls.
3948 * inssel-amd64.brg (OP_OUTARG_MEMBASE): Remove.
3949 (OP_AMD64_OUTARG_ALIGN_STACK): Take argument to specify size of stack
3952 Code contributed under MIT/X11 license.
3954 2008-04-23 Rodrigo Kumpera <rkumpera@novell.com>
3956 * mini.c (mini_method_verify): Only verify non-inflated methods, check
3957 against the root definition, peeling out method and type instantiations.
3958 Cache verify success results, code that fails verification is still
3959 checked multiple times.
3961 2008-04-23 Zoltan Varga <vargaz@gmail.com>
3963 * mini.c (mono_method_to_ir): Avoid inserting write barriers for stores of null.
3965 2008-04-23 Jonathan Chambers <joncham@gmail.com>
3967 * mini-amd64.c (add_general): Always increment stack on Win64.
3968 (mono_arch_call_opcode): Use OP_OUTARG_MEMBASE instead of OP_OUTARG
3971 * inssel-amd64.brg (OP_OUTARG_MEMBASE): Add OP_OUTARG_MEMBASE for
3972 stack based argument handling on Win64.
3974 Code contributed under MIT/X11 license.
3976 2008-04-23 Raja R Harinath <harinath@hurrynot.org>
3978 * Makefile.am (version.h): Add support for git-svn.
3980 2008-04-22 Zoltan Varga <vargaz@gmail.com>
3982 * mini-exceptions.c (mono_handle_native_sigsegv): Rework the gdb calling code
3983 so instead of calling g_spawn_command_line_sync, we do everything by hand,
3984 avoiding allocations and libc functions which might deadlock.
3986 * mini-exceptions.c (mono_handle_native_sigsegv): Avoid calling gdb if the
3987 'no-gdb-backtrace' option is set.
3989 * mini.c (mini_parse_debug_options): Parse 'no-gdb-backtrace' option.
3991 * mini.h (MonoDebugOptions): Add 'no_gdb_backtrace' option.
3993 2008-04-21 Martin Baulig <martin@ximian.com>
3995 * debug-debugger.h (MonoDebuggerInfo): Removed `attach', `detach'
3996 and `get_lmf_addr'; `notification_address' is no longer a pointer.
3998 2008-04-21 Martin Baulig <martin@ximian.com>
4000 * debug-debugger.h (MonoDebuggerInfo): Added `thread_vtable_ptr',
4001 `thread_vtable', `event_handler_ptr' and `event_handler'.
4003 2008-04-21 Martin Baulig <martin@ximian.com>
4005 * debug-debugger.h (MonoDebuggerInfo): Added `init_code_buffer';
4006 allows delayed initialization of the `executable_code_buffer' when
4009 2008-04-21 Martin Baulig <martin@ximian.com>
4011 * mini.h (mono_debugger_create_notification_function): Removed.
4012 * tramp-*.c (mono_debugger_create_notification_function): Removed.
4014 * mdb-debug-info64.s
4015 (MONO_DEBUGGER__notification_function): Added this in the .text section.
4017 * mdb-debug-info32.s
4018 (MONO_DEBUGGER__notification_function): Added this in the .text section.
4020 * Makefile.am: Fix the mdb-debug-info*.s logic; the debugger
4021 currently only works on x86 and x86_64, so don't create it on ppc.
4023 2008-04-21 Martin Baulig <martin@ximian.com>
4025 * mini.h (MonoDebugOptions): Added `mdb_optimizations'.
4028 (mini_method_compile): In the fp elimination check, check
4029 `debug_options.mdb_optimizations' in addition to
4030 mono_debug_using_mono_debugger().
4032 * driver.c (mono_main): Added `--debug=mdb-optimizations' option to
4033 disable some JIT optimizations which are only disabled when
4034 running inside the debugger.
4035 Added `--help-debug' option to describe the debugging options.
4036 (parse_debug_options): New static function to parse the `--debug'
4037 options, so we can easily add more stuff in future.
4039 2008-04-20 Zoltan Varga <vargaz@gmail.com>
4041 * mini.c (set_exception_type_from_invalid_il): Avoid reading invalid memory when
4042 the method has no body.
4044 2008-04-19 Jonathan Chambers <joncham@gmail.com>
4046 * mini-amd64.c (cpuid): Implement with MSVC intrinsic as inline
4047 assembly is not allowed in MSVC 64-bit compiler.
4048 (mono_arch_cpu_init): Don't set floating point precision on MSVC build
4049 as we get floating point exceptions everywhere.
4051 * exceptions-amd64.c (get_throw_trampoline): Push empty args on stack to
4052 correctly align arguments for call to throw_exception.
4053 (prepare_for_guard_pages): Cast to guint64 instead of unsigned long.
4055 Code contributed under MIT/X11 license.
4057 2008-04-19 Zoltan Varga <vargaz@gmail.com>
4059 * mini-amd64.c (amd64_patch): Make the check for (%rip) addressing more strict.
4061 2008-04-17 Zoltan Varga <vargaz@gmail.com>
4063 * inssel.brg (OP_SWITCH): Use (gint64) instead of (long) to cast a large constant.
4065 * mini-amd64.c (NEW_INS): Set cil_code.
4067 * mini.c (mini_method_compile): Move the disabling of fp elimination to here
4068 from mini-amd64.c so all debugger related logic is in one place.
4070 * mini.c: Set cfg->ip to NULL after passes which set it so instructions created
4071 later won't have a random ip assigned to them.
4073 2008-04-16 Zoltan Varga <vargaz@gmail.com>
4075 * mini-trampolines.c (mono_create_jump_trampoline): Add an assert to check that
4076 the arch specific function initializes code_size.
4077 (mono_create_delegate_trampoline): Ditto.
4079 * mini-mips.h mini-mips.c inssel-mips.brg inssel-long32-mips.brg cpu-mips.md
4080 tramp-mips.c: Resurrect MIPS port and also fix the issues on little-endian
4083 * liveness.c (mono_analyze_liveness): Disable the initlocals optimization if
4084 running under the debugger.
4086 * linear-scan.c (mono_linear_scan): Avoid sharing registers if running under the
4089 * mini.c (mini_method_compile): Set a few flags in cfg if running under the
4090 debugger. Also move the disabling of optimizations here from driver.c.
4091 (mono_allocate_stack_slots_full): Avoid sharing stack slots if running under the
4094 * mini.h (MonoCompile): Add a few new flags.
4096 2008-04-15 Zoltan Varga <vargaz@gmail.com>
4098 * mini.c (mono_method_to_ir): Set cfg->ip before processing an IL instruction
4099 so the cil_code field of created MonoInst's is properly set.
4100 (mini_select_instructions): Ditto.
4102 * mini.h (MONO_INST_NEW): Initialize the cil_code field using cfg->ip.
4103 (MONO_INST_NEW_CALL): Ditto.
4105 * mini.c inssel.brg inssel-x86.brg inssel-amd64.brg: Use MONO_INST_NEW ()
4106 in many places so the ins->cil_code field is properly initialized.
4108 * mini.c (mono_bblock_add_inst): Call MONO_ADD_INS () so the logic is in one
4111 2008-04-14 Zoltan Varga <vargaz@gmail.com>
4113 * mini.c (mini_method_compile): Print a different message when compiling a
4116 * mini.c (GENERIC_SHARING_FAILURE): Print a failure message when verbose_level
4119 2008-04-11 Zoltan Varga <vargaz@gmail.com>
4121 * mini-amd64.c (mono_arch_output_basic_block): Implement OP_ABS directly using
4124 * basic-math.cs: Fix warnings. Add a test for Math.Abs ().
4126 2008-04-11 Zoltan Varga <vargaz@gmail.com>
4128 * mini.c (handle_stack_args): Make this return void since its return value was
4129 never used. Also set cfg->unverifiable for invalid IL instead of calling
4132 2008-04-10 Mark Probst <mark.probst@gmail.com>
4134 * mini.c: Make sure "this" is live in catch clauses with type
4135 variables in shared generic code.
4137 2008-04-08 Mark Probst <mark.probst@gmail.com>
4139 * mini.c: Replaced uses of MONO_TYPE_IS_REFERENCE with calls to
4140 generic_class_is_reference_type() to ensure the proper behaviour
4141 when sharing generic code and the type in question is a type
4144 2008-04-08 Zoltan Varga <vargaz@gmail.com>
4146 * mini-exceptions.c: Applied patch from Mark Spruiell (mes@zeroc.com). Fix
4147 race conditions when printing thread dumps. Fixes #377738.
4149 2008-04-08 Massimiliano Mantione <massi@ximian.com>
4151 aliasing.c (update_aliasing_information_on_inst): Fixed a bug which
4152 shows up when both MonoInst arguments can cause aliasig.
4153 There is likely no way in the current JIT to trigger this problem, but
4154 it showed up in the development of generics sharing, when in a new
4155 opcode both args of an OP_GROUP can be aliases (addresses of a local).
4156 When the generics sharing code will be committed, its tests will be
4157 valid also for this bug.
4159 2008-04-08 Zoltan Varga <vargaz@gmail.com>
4161 * aot-runtime.c (decode_patch_info): Always transform PATCH_INFO_WRAPPER to
4164 * mini.c (mono_resolve_patch_target): Fix a crash in the AOT case if method is
4167 2008-04-07 Zoltan Varga <vargaz@gmail.com>
4169 * mini-exceptions.c (mono_handle_exception_internal): When --debug=casts is used,
4170 use a more detailed exception message for InvalidCastException.
4172 * mini.h (MonoJitTlsData): Add 'class_cast_from' and 'class_cast_to' fields.
4174 * driver.c (mono_main): Add --debug=casts option to turn on better
4175 InvalidCastException message details.
4177 * mini.c (mini_get_debug_options): New helper function to return the address of
4178 the debug_options variable.
4180 * mini.c (mono_get_jit_tls_intrinsic): New helper function to create a load of
4181 the jit_tls TLS variable.
4183 * mini.c (mono_jit_tls): New TLS variable.
4185 * inssel.brg: Save the details of a cast to a TLS variable when the --debug=casts
4188 2008-04-07 Rodrigo Kumpera <rkumpera@novell.com>
4190 * mini.h: Removed verifer related stuff. This code was moved to verify.c
4192 * mini.c: Removed verifer related stuff, code moved to verify.c.
4194 * driver.c: Using code from verify.c instead of mini.c.
4196 2008-04-05 Zoltan Varga <vargaz@gmail.com>
4198 * mini.c (check_for_method_verify): Remove the mscorlib comment since it is no
4201 2008-04-04 Rodrigo Kumpera <rkumpera@novell.com>
4203 * mini.c (check_for_method_verify): Enabling verification of
4204 corlib if mono_verify_all is set. Bugs in the verifier preventing that
4207 2008-04-04 Zoltan Varga <vargaz@gmail.com>
4209 * exceptions-amd64.c (throw_exception): Unify the win32/non-win32 cases, save
4210 caller saved registers as well.
4212 * exceptions-amd64.c (mono_arch_get_restore_context): Restore most caller
4213 saved registers as well.
4215 2008-03-30 Zoltan Varga <vargaz@gmail.com>
4217 * mini-x86.c cpu-x86.md inssel-x86.brg: Add min/max intrinsics.
4219 * mini-amd64.c mini-amd64.h cpu-amd64.md: Get rid of the non-SSE2 floating point
4222 2008-03-27 Zoltan Varga <vargaz@gmail.com>
4224 * mini-amd64.c (mono_arch_get_this_arg_reg): Add a 'gsctx' argument and pass it
4226 (get_call_info): Take a gsctx argument instead of 'cfg'.
4228 2008-03-26 Zoltan Varga <vargaz@gmail.com>
4230 * mini.c (check_for_method_verify): Avoid verifying mscorlib methods even if
4231 mono_verify_all is set.
4233 * driver.c (compile_all_methods_thread_main): Don't exit at the first error.
4235 * mini.c mini.h: Remove the unused and incomplete stack merge verification code.
4237 2008-03-25 Zoltan Varga <vargaz@gmail.com>
4239 * driver.c (compile_all_methods_thread_main): Error out if compilation fails with
4242 * driver.c mini.c mini.h: Add a --verify-all development option to test the
4243 verifier and the code generated by the compiler.
4245 2008-03-25 Mark Probst <mark.probst@gmail.com>
4247 * mini.c: Generic sharing of the non-nullable case of the box
4250 2008-03-24 Zoltan Varga <vargaz@gmail.com>
4252 * inssel.brg: Fix the build.
4254 * iltests.il.in: Add a test for lconv.ovf.u8.un.
4256 2008-03-24 Rodrigo Kumpera <rkumpera@novell.com>
4258 * mini.c (mono_method_to_ir): Implement readonly for ldelema and
4259 Array:Address. Fixes #372410.
4261 * iltests.il.in: New tests for readonly prefix.
4263 2008-03-23 Zoltan Varga <vargaz@gmail.com>
4265 * mini.h mini.c mini-trampolines.c: Move trampoline related code to
4268 * mini.h mini.c mini-exceptions.c: Move mini_init_exceptions () to
4271 * mini-amd64.c mini-s390.c (mono_arch_lowering_pass): Use mono_decompose_op_imm ().
4273 * mini.c (mono_decompose_op_imm): New helper function.
4275 * mini-s390x.c (calculate_sizes): Rename this to get_call_info for consistency
4276 with the other architectures, add an 'mp' argument, fold 'sz' argument into the
4279 * mini-s390x.c: Handle DIV_IMM/REM_IMM in the lowering pass instead of in
4280 mono_arch_output_basic_block. Fix warnings.
4282 * inssel-s390x.brg: Remove the unneccesary OP_LMUL_IMM rule to fix the s390x build
4285 2008-03-22 Zoltan Varga <vargaz@gmail.com>
4287 * mini-exceptions.c (ves_icall_get_frame_info): Remove the ia64/s390 workarounds
4288 since the extra frame is now detected automatically inside the loop.
4290 * mini-s390.c (mono_arch_peephole_pass_2): Remove the arch independent peephole
4291 opts which are now in mono_peephole_ins ().
4293 * mini-s390.c (mono_arch_output_basic_block): Fix OP_FCALL_MEMBASE.
4295 * mini-exceptions.c (ves_icall_get_frame_info): Skip native-to-managed wrapper
4296 frames and skip duplicate managed-to-native frames. Fixes #367665.
4298 * mini-x86.c (mono_arch_peephole_pass_1): Remove the arch independent peephole
4299 opts which are now in mono_peephole_ins ().
4300 (mono_arch_peephole_pass_2): Ditto.
4302 * mini-codegen.c (mono_peephole_ins): Fix a problem on 32 bit platforms.
4304 * mini-codegen.c (mono_peephole_ins): New helper function containing the
4305 arch independent peephole optimizations.
4307 * mini-amd64.c (mono_arch_peephole_pass_1): Remove the arch independent peephole
4308 opts which are now in mono_peephole_ins ().
4310 * mini-amd64.c (mono_arch_peephole_pass_2): Ditto.
4312 * mini-s390.c (mono_arch_output_basic_block): Fix build.
4314 * tramp-s390.c (mono_arch_get_vcall_slot): Handle an additional instruction
4317 * mini-s390.c (mono_arch_output_basic_block): Handle big offsets in the
4318 CALL_MEMBASE opcodes. Fix setting of the destination in the OP_LCONV_TO_OVF_I
4321 2008-03-21 Zoltan Varga <vargaz@gmail.com>
4323 * mini-s390.c (calculate_sizes): Rename this to get_call_info for consistency
4324 with the other architectures, add an 'mp' argument, fold 'sz' argument into the
4327 * mini-s390.c: Handle DIV_IMM/REM_IMM in the lowering pass instead of in
4328 mono_arch_output_basic_block. Fix warnings.
4330 2008-03-20 Zoltan Varga <vargaz@gmail.com>
4332 * inssel-long32.brg: Add rules for long conv.ovf.i/conv.ovf.u/conv.ovf.i.un/
4335 2008-03-20 Zoltan Varga <vargaz@gmail.com>
4337 * inssel-long.brg: Add rules for long conv.ovf.i/conv.ovf.u/conv.ovf.i.un/
4340 * iltests.il: Add new tests.
4342 2008-03-20 Kornél Pál <kornelpal@gmail.com>
4344 * mini.c: Removed Windows version macros.
4346 2008-03-20 Mark Probst <mark.probst@gmail.com>
4348 * generic-sharing.c: Put reflection types in the extensible part
4349 of the runtime generic context.
4351 * mini.c: Generic sharing of the GetTypeHandle special case of the
4352 ldtoken instruction.
4354 2008-03-20 Zoltan Varga <vargaz@gmail.com>
4356 * mini.h (MONO_BB_FOR_EACH_INS_SAFE): New helper macro.
4358 * mini-<ARCH>.c: Use the new macro instead in the peephole/lowering passes.
4360 * mini.h (MONO_DEL_INS): Rename to MONO_DELETE_INS and Add a 'bb' argument for
4361 consistency with the other version on the linear IR branch.
4363 * mini-<ARCH>.c: Update callers of MONO_DEL_INS.
4365 * inssel-long32.brg inssel-long.brg: Add rules for conv.ovf.i/conv.ovf.u.
4367 * iltests.il.in: Add new tests.
4369 2008-03-19 Zoltan Varga <vargaz@gmail.com>
4371 * inssel-long32.brg inssel-long.brg: Add rules for conv.ovf.i.un/conv.ovf.u.un.
4373 * iltests.il.in: Add new tests.
4375 2008-03-19 Mark Probst <mark.probst@gmail.com>
4377 * mini.c: Two variables with the same name were declared in
4378 nesting contexts and one wasn't initialized. Fixed.
4380 2008-03-19 Mark Probst <mark.probst@gmail.com>
4382 * mini.c: Generic sharing of the initobj instruction.
4384 Tue Mar 18 20:18:02 CET 2008 Paolo Molaro <lupus@ximian.com>
4386 * mini.c: make the test to optimize ldtoken from typeof() more
4389 2008-03-18 Mark Probst <mark.probst@gmail.com>
4391 * mini.c: Generic sharing of the initobj instruction for reference
4394 Tue Mar 18 12:39:27 CET 2008 Paolo Molaro <lupus@ximian.com>
4396 * mini.h, mini-amd64.c, mini-x86.c, tramp-amd64.c, tramp-x86.c: change
4397 the mono_breakpoint_clean_code() code to perform bound checks.
4399 Tue Mar 18 11:50:14 CET 2008 Paolo Molaro <lupus@ximian.com>
4401 * mini.h, mini-trampolines.c, tramp-*.c: change the signature of
4402 mono_arch_patch_callsite() to include the start of the managed method
4403 to be able to perform bound checks.
4405 2008-03-17 Mark Probst <mark.probst@gmail.com>
4407 * mini.c: Generic sharing for the isinst instruction.
4409 2008-03-17 Mark Probst <mark.probst@gmail.com>
4411 * mini-ops.h, inssel.brg, inssel-long.brg, inssel-long32.brg,
4412 inssel-long32-mips.brg: Added opcodes for doing indirect calls
4413 with the runtime generic context argument.
4415 * mini.c: Share calls to several types of unsharable methods by
4416 putting the address of the method code in the runtime generic
4417 context and doing an indirect call.
4419 * graph.c, local-propagation.c, aliasing.c: Added the new opcodes
4422 2008-03-16 Mark Probst <mark.probst@gmail.com>
4424 * generic-sharing.c: Change due to a change in the runtime genric
4427 2008-03-15 Martin Baulig <martin@ximian.com>
4430 (mono_arch_nullify_class_init_trampoline): Add call to
4431 mono_breakpoint_clean_code() to make things work when running
4432 inside the debugger.
4435 (mono_arch_nullify_class_init_trampoline): Add call to
4436 mono_breakpoint_clean_code() to make things work when running
4437 inside the debugger.
4439 2008-03-14 Zoltan Varga <vargaz@gmail.com>
4441 * inssel-long.brg (reg): Fix 64 bit build.
4443 2008-03-14 Mark Probst <mark.probst@gmail.com>
4445 * mini.c, mini.h: Share static generic code by passing it an
4446 implicit argument pointing to the runtime generic context.
4448 * mini-ops.h, inssel.brg, inssel-long.brg, inssel-long32.brg,
4449 inssel-long32-mips.brg: New opcodes for calling shared static,
4450 which need to be passed the runtime generic context.
4452 * mini-amd64.c, mini-x86.c: Save the runtime generic context
4453 argument on the stack in the prologue if needed. New function for
4454 finding the runtime generic context argument from the registers
4455 saved by the trampoline.
4457 * mini-amd64.h, mini-x86.h: Specify which register to use for the
4458 runtime generic context argument.
4460 * tramp-amd64.c: Also restore the register used for the runtime
4461 generic context argument.
4463 * mini-trampoline.c: Resolve shared static calls by consulting the
4464 runtime generic context via the new argument.
4466 * generic-sharing.c: Add an argument to sharability-checking
4467 functions that specifies whether type variables should be treated
4468 as sharable type arguments.
4470 * inssel-x86.brg: Removed a superfluous, buggy rule.
4472 * graph.c, local-propagation.c, aliasing.c: Added the new opcodes
4475 2008-03-14 Martin Baulig <martin@ximian.com>
4477 * debug-debugger.c (main_thread_handler): Call
4478 mono_runtime_run_main() without sending any notifications.
4480 * debug-debugger.h (MonoDebuggerInfo): Added `get_method_signature.
4482 2008-03-14 Zoltan Varga <vargaz@gmail.com>
4484 * mini-trampolines.c (mono_magic_trampoline): Fix build on platforms without IMT.
4486 2008-03-14 Mark Probst <mark.probst@gmail.com>
4488 * tramp-x86.c: Fixed register restore offsets in the trampoline
4489 code for ECX and EDX.
4491 2008-03-12 Geoff Norton <gnorton@novell.com>
4493 * mini-arm.h: Add some #defines for locating sp, pc, r4 with
4494 different ucontext_t implementations.
4495 * exceptions-arm.c: Use the above defines to get exceptions working on
4496 iPhone (based on a patch by Luke Howard lukeh@padl.com)
4497 * mini-arm.c: Implement iPhone icache support (based on a patch by
4498 Luke Howard lukeh@padl.com)
4500 2008-03-12 Mark Probst <mark.probst@gmail.com>
4502 * mini.c: Enable generic sharing of calls to non-static
4503 non-interface non-generic non-value-type methods.
4505 * mini-trampolines.c: Resolve calls from shared generic code.
4507 2008-03-11 Zoltan Varga <vargaz@gmail.com>
4509 * Makefile.am il2tests.il iltests.il.in: Delete il2tests, merge it into iltests.
4511 * tramp-amd64.c (mono_arch_create_trampoline_code): Correctly save RBP as well.
4513 Mon Mar 10 11:59:34 CET 2008 Paolo Molaro <lupus@ximian.com>
4515 * mini.c: some fixes for the AOT compiler.
4517 2008-03-07 Zoltan Varga <vargaz@gmail.com>
4519 * cpu-amd64.md: Add clob:1 to some float opcodes.
4521 2008-03-07 Rodrigo Kumpera <rkumpera@novell.com>
4523 * mini.h: Added MiniVerifierMode enumeration.
4525 * mini.c: Added mini_verifier_set_mode to control
4526 the usage of the new verifier.
4528 * mini.c (mono_method): Integrated the new verifier.
4530 * driver.c: Extended --security option with validil and
4531 verifiable options to activate the new verifier.
4533 2008-03-07 Zoltan Varga <vargaz@gmail.com>
4535 * mini.c jit-icalls.h jit-icalls.c: Generalize the exception creation
4536 optimization to ctors taking 0 or 2 arguments too.
4538 * mini.c (mono_method_to_ir): Optimalize the size of the exception throwing code
4541 * jit-icalls.h (mono_create_corlib_exception): New JIT icall.
4543 * mini-amd64.c (mono_arch_emit_prolog): Improve the first_bb optimization a bit.
4545 2008-03-06 Zoltan Varga <vargaz@gmail.com>
4547 * mini.c (mono_method_to_ir): Apply one of the ldstr optimizations in the
4548 non-aot case as well.
4550 * cpu-amd64.md: Reduce the max size of some frequently used opcodes.
4552 * aot-runtime.c (decode_patch_info): Update this after the ldfld/stfld wrapper
4555 * aot-compiler.c (encode_patch): Ditto.
4557 * mini.h (G_MININT32): Fix the definition of this.
4559 2008-03-05 Zoltan Varga <vargaz@gmail.com>
4561 * mini.h: Define G_MININT32/G_MAXINT32 if using an older glib version.
4563 * cfold.c: Remove definition of G_MININT32 which is now in mini.h.
4565 2008-03-04 Zoltan Varga <vargaz@gmail.com>
4567 * mini-amd64.c (mono_arch_compute_omit_fp): Don't disable fp elimination for
4568 methods returning vtypes in registers.
4569 (mono_arch_allocate_vars): Ditto.
4571 * mini-amd64.c (mono_arch_get_this_arg_reg): New arch specific helper function.
4573 * tramp-amd64.c (mono_arch_get_unbox_trampoline): Use mono_arch_get_this_arg_reg ().
4575 * generics.cs: Add a test from the linear IR branch.
4577 * mini-amd64.c (emit_load_volatile_arguments): Handle vtypes passed in regs too.
4579 * mini.c (inline_method): Cache failed inline attempts.
4581 2008-03-04 Mark Probst <mark.probst@gmail.com>
4583 * mini.c: For shared methods of generic classes put the location
4584 of "this" into the MonoGenericJitInfo.
4586 * mini-x86.c, mini-amd64.c, mini.h: Added function for fetching a
4587 register out of a MonoContext by register number. Add the generic
4588 sharing context as an argument to mono_arch_find_this_argument().
4590 * mini-alpha.c, mini-arm.c, mini-hppa.c, mini-ia64.c, mini-mips.c,
4591 mini-ppc.c, mini-s390.c, mini-s390x.c, mini-sparc.c: Added stub
4592 for new arch function.
4594 * mini-exception.c: Handle open exception clauses in shared
4597 * mini-trampolines.c: Supply additional argument to
4598 mono_arch_find_this_argument().
4600 2008-03-04 Zoltan Varga <vargaz@gmail.com>
4602 * Makefile.am (regtests): Run the bench.exe tests last.
4604 2008-03-03 Zoltan Varga <vargaz@gmail.com>
4606 * mini-amd64.c (mono_arch_emit_prolog): Improve the first bblock optimization
4609 2008-03-02 Zoltan Varga <vargaz@gmail.com>
4611 * mini.c (mono_method_to_ir): Allow callvirt on static methods for compatibility
4614 * mini-amd64.c (mono_arch_emit_prolog): Fix tracing after the last change.
4616 * mini-amd64.c (mono_arch_emit_prolog): Avoid saving dead arguments.
4618 * mini.c (mono_method_check_inlining): Avoid disabling inlining for methods
4619 whose class has no cctor.
4621 * liveness.c (mono_analyze_liveness): Mark dead arguments with MONO_INST_IS_DEAD.
4623 2008-03-01 Zoltan Varga <vargaz@gmail.com>
4625 * mini.c (mono_method_to_ir): Report calling a static method using callvirt as
4628 2008-02-29 Zoltan Varga <vargaz@gmail.com>
4630 * mini-ops.h: Remove OP_SPARC_INARG_VT, add a new OP_VTARG_ADDR opcode instead
4631 to be in sync with the code on the linear IR branch.
4633 * mini-sparc.c inssel-sparc.brg: Use OP_VTARG_ADDR.
4635 * inssel-s390.brg (OP_SETRET (freg)): Set dreg correctly.
4637 2008-02-27 Zoltan Varga <vargaz@gmail.com>
4639 * mini-mips.c: Use cfg->vret_addr instead of cfg->ret.
4641 * mini-s390x.c: Use cfg->vret_addr instead of cfg->ret.
4643 * mini-s390.c: Use cfg->vret_addr instead of cfg->ret.
4645 * mini-<ARCH>.h mini.c: Get rid of the MONO_ARCH_HAVE_CREATE_VARS define.
4647 * mini-<ARCH>.c (mono_arch_create_vars): Define this for all architectures.
4649 * mini.c (mono_method_to_ir): Avoid invalid memory reads for methods without a
4652 2007-11-14 Yoichi NAKAYAMA <nakayama@pixela.co.jp>
4654 * inssel-mips.brg (OP_OUTARG_MEMBASE (CEE_LDIND_R4 (base))): Add missing
4655 OP_LOADR4_MEMBASE emission.
4657 * mini-codegen.c (mono_spillvar_offset_int): Remove assertion.
4658 (mono_spillvar_offset_float): Ditto.
4660 * mini-mips.c (mono_arch_emit_prolog): Ditto.
4662 * inssel-long32-mips.brg: Fix wrong branching, reduce redundant code
4665 * basic-long.cs: Add regression tests for them.
4667 * mini-mips.c (add_float32_arg): Respect o32 calling convention in gr
4669 (mono_arch_allocate_vars): Fix representation of single-precision float
4671 (mono_arch_output_basic_block): Ditto.
4673 * inssel-mips.brg: Ditto, remove duplicate items.
4675 * mini-mips.c (emit_load_volatile_arguments): New function to handle
4676 arguments of tail calls as on other platforms.
4677 (mono_arch_output_basic_block): Handle tail calls.
4679 * inssel-mips.brg (OP_OUTARG_VT (CEE_LDOBJ (base))): Correct destination
4682 * objects.cs (test_5_pass_static_struct): Add test for it.
4684 Contributed under MIT/X11 license.
4686 2008-02-26 Zoltan Varga <vargaz@gmail.com>
4688 * Makefile.am: Use gmcs for compiling the regression tests.
4690 * *.2.cs *.2.il: Rename to *.cs and *.il.
4692 2008-02-24 Zoltan Varga <vargaz@gmail.com>
4694 * regalloc.h: Make the vassign array smaller.
4696 * mini.c (mini_method_compile): Remove an unused field in cfg.
4698 * mini-codegen.c: Add a bunch of micro optimizations.
4700 2008-02-23 Zoltan Varga <vargaz@gmail.com>
4702 * regalloc.h: Remove some unused fields.
4704 2008-02-22 Zoltan Varga <vargaz@gmail.com>
4706 * mini-amd64.c (mono_arch_patch_code): Fix a warning.
4708 * ssa.c (mono_ssa_remove): Avoid declaring volatile variables dead.
4710 2008-02-22 Mark Probst <mark.probst@gmail.com>
4712 * mini.h: New trampoline type (RGCTX_LAZY_FETCH).
4714 * mini-trampolines.c, tramp-amd64.c, tramp-x86.c: RGCTX lazy fetch
4715 trampoline: Fetch an entry from the runtime generic context. If
4716 it's NULL, jump to the actual trampoline to fill the runtime
4717 generic context. Otherwise, return it.
4719 * mini.c: Call the lazy fetch trampoline to get entries out of the
4720 runtime generic context.
4722 * tramp-ia64.c, tramp-arm.c, tramp-alpha.c, tramp-s390.c,
4723 tramp-s390x.c, tramp-ppc.c, tramp-hppa.c, tramp-mips.c,
4724 tramp-sparc.c: Stubs for the lazy fetch trampoline.
4726 2008-02-21 Mark Probst <mark.probst@gmail.com>
4728 * mini.c: Fetch data out of the extensible part of the runtime
4729 generic context instead of calling a helper function.
4731 * generic-sharing.c: Some functions moved into
4732 metadata/generic-sharing.c. Helper function for fetching other
4733 types now checks and asserts against extensible rgctx (just for
4734 debugging purposes - the helper function isn't called anymore
4735 unless for debugging).
4737 2008-02-21 Zoltan Varga <vargaz@gmail.com>
4739 * mini-arm.c (mono_arch_output_basic_block): Implement proper argument passing
4740 for tail calls up to the point that the tests in iltests.exe run. Also add a
4741 dummy CKFINITE implementation.
4742 (mono_arch_emit_prolog): Avoid saving the method in the LMF since it is only
4743 needed for trampoline LMF frames.
4745 * exceptions-arm.c (mono_arch_find_jit_info): Only read lmf->method for
4746 trampoline LMF frames.
4748 2008-02-21 Rodrigo Kumpera <rkumpera@novell.com>
4750 * mini.c (inline_method): clean any pending loader error when inlining fail.
4751 Otherwise loader errors in mono_method_to_ir leaks and cause spurious errors.
4753 2008-02-21 Zoltan Varga <vargaz@gmail.com>
4755 * aot-compiler.c (encode_patch): Handle ICALL_ADDR patch type.
4757 * aot-runtime.c (decode_patch_info): Ditto.
4759 * mini.c (mono_resolve_patch_target): Ditto.
4761 * aot-compiler.c (compile_method): Add some experimental code for AOT compiling
4764 * patch-info.h (PATCH_INFO): Add 'ICALL_ADDR' patch type.
4766 * mini.c (mono_method_to_ir): Convert a CEE_MONO_LDPTR opcode to an AOT constant
4767 if it references an icall address.
4769 2008-02-20 Zoltan Varga <vargaz@gmail.com>
4771 * cpu-s390x.md: Remove some more unused opcodes.
4773 * cpu-s390x.md: Remove some unused opcodes.
4775 * mini-ia64.c (mono_arch_lowering_pass): Add some more opcodes. Use
4776 mono_op_imm_to_op ().
4778 * mini-sparc.c (opcode_to_sparc_cond): Use the mono_opcode_to_cond () functions
4779 instead of a switch statement.
4781 * mini-sparc.c (mono_arch_allocate_vars): Allocate a stack slot for use by
4782 the int<->float conversion opcodes instead of using mono_spillvar_offset_float ().
4784 * mini-codegen.c: Eliminate rassign macro which is no longer needed.
4786 * mini-codegen.c: Remove unused mono_regstate2_... functions.
4788 * mini-codegen.c (mono_print_ins_index): Avoid printing an index when it is
4791 2008-02-19 Zoltan Varga <vargaz@gmail.com>
4793 * driver.c (mono_main): Improve error reporting when an assembly cannot be
4794 opened. Fixes #362607.
4796 * cpu-ia64.md cpu-s390x.md: Remove some unused opcodes.
4798 * iltests.il.in: Add a test for static methods in interfaces.
4800 2008-02-18 Zoltan Varga <vargaz@gmail.com>
4802 * genmdesc.c (build_table): Fix a crash on older glib versions.
4804 * cpu-sparc.md: Remove some unused opcodes.
4806 * genmdesc.c: Error out if the .md contains CEE_ opcodes if
4807 MONO_ARCH_ENABLE_NORMALIZE_OPCODES is defined.
4809 * cpu-amd64.md: Remove some unused opcodes.
4811 * mini.h mini-ops.h mini.c: Define the OP_Ccc opcodes in mini-ops.h normally
4812 like the other opcodes.
4814 2008-02-17 Zoltan Varga <vargaz@gmail.com>
4816 * mini-ia64.c: Use cfg->vret_addr instead of cfg->ret.
4818 * mini-arm.h mini-arm.c: Use cfg->vret_addr instead of cfg->ret.
4820 * mini-sparc.c: Use cfg->vret_addr instead of cfg->ret. Name the MonoCompile
4821 variables 'cfg' instead of 'm' for consistency.
4823 * mini-x86.c: Use cfg->vret_addr instead of cfg->ret.
4825 * mini.h (MonoCompile): Add new 'vret_addr' field which represents the hidden
4826 argument holding the vtype return address, to avoid the ambigious use of
4827 cfg->ret for this purpose.
4829 * mini.c (NEW_RETLOADA): Use vret_addr if set.
4831 * mini-amd64.c: Use cfg->vret_addr instead of cfg->ret.
4833 * mini-codegen.c (mono_print_ins): Rename to mono_print_ins_index (), Add a
4834 new mono_print_ins () function which only takes one argument.
4836 2008-02-15 Zoltan Varga <vargaz@gmail.com>
4838 * mini-s390.h (MONO_OUTPUT_VTR): Use cfg instead of s, avoid assignments to
4841 2008-02-14 Zoltan Varga <vargaz@gmail.com>
4843 * mini-ops.h: Get rid of OP_SPARC_LOCALLOC_IMM.
4845 * mini-sparc.c inssel-sparc.brg: Use OP_LOCALLOC_IMM instead of OP_SPARC_LOCALLOC_IMM.
4847 * mini-x86.c: Sync with the version on the linear IR branch by adding new
4848 opcodes and other small changes.
4850 * mini-ops.h: Add some new opcodes from the linear IR branch.
4852 * mini-ops.h: Get rid of the OP_X86_..._MEMBASE opcodes.
4854 * mini-x86.c inssel-x86.brg cpu-x86.md: Get rid of the confusing _MEMBASE
4855 opcodes, use the REG_MEMBASE opcodes instead.
4857 * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Get rid of the confusing _MEMBASE
4858 opcodes, use the REG_MEMBASE opcodes instead.
4860 * mini-amd64.c (mono_arch_output_basic_block): Sync with the version on the
4863 * mini.c (mono_op_imm_to_op): New helper function.
4865 * mini-ops.h: Add some opcodes from linear IR branch.
4867 2008-02-13 Zoltan Varga <vargaz@gmail.com>
4869 * mini-alpha.h mini-alpha.c tramp-alpha.c: Alpha port updates from Sergey Tikhonov
4872 2008-02-12 Zoltan Varga <vargaz@gmail.com>
4874 * mini.c (mono_normalize_opcodes): Always convert CEE_CONV_R4/R8 to
4877 * mini-ia64.c cpu-ia64.md: Add OP_ICONV_TO_R4/R8.
4879 2008-02-09 Zoltan Varga <vargaz@gmail.com>
4881 * aot-compiler.c (emit_method_code): Add an assert.
4883 * mini-arm.h mini-arm.c exceptions-arm.c: Modify the exception throwing code and
4884 the IMT code so it is AOT friendly. Enable AOT for methods which call interface
4887 2008-02-08 Zoltan Varga <vargaz@gmail.com>
4889 * mini-arm.c (mono_arch_output_basic_block): Fix the ordering of arguments for
4890 some load/store opcodes so they are consistent.
4891 (mono_arch_emit_prolog): Simplify some code.
4893 * aot-runtime.c (mono_aot_get_plt_entry): Fix a warning.
4895 * objects.cs: Add tests for large argument offsets on ARM.
4897 * mini-arm.c (mono_arch_emit_prolog): Fix handling of arguments with large
4898 stack offsets. Fixes #359651.
4900 * mini.c (mono_normalize_opcodes): Remap CEE_CONV_R4/R8 properly.
4902 * cpu-s390x.md: Add OP_LCONV_TO_R4/R8.
4904 * cpu-ia64.md mini-ia64.h mini-ia64.c: Get rid of CEE_ opcodes.
4906 * mini-ops.h: Add OP_ICONV_TO_R_UN opcode.
4908 * mini.c (mono_normalize_opcodes): Remap CEE_CONV_R_UN too.
4910 * cpu-s390x.md cpu-s390.md mini-s390x.c mini-arm.c cpu-arm.md mini-s390.c: Get
4911 rid of CEE_CONV_R_UN.
4913 * mini-s390x.c mini-s390x.h cpu-s390x.md inssel-s390x.brg: Get rid of CEE_ opcodes.
4915 2008-02-07 Zoltan Varga <vargaz@gmail.com>
4917 * mini-s390.c mini-s390.h cpu-s390.md: Get rid of CEE_ opcodes.
4919 * mini.c (mono_normalize_opcodes): Add some more opcodes.
4921 * mini-arm.c mini-arm.h cpu-arm.md: Get rid of CEE_ opcodes.
4923 * cpu-amd64.md: Remove some unused opcodes.
4925 * mini-sparc.c mini-sparc.h cpu-sparc.md: Get rid of CEE_ opcodes.
4927 * mini-x86.c mini-x86.h cpu-x86.md: Get rid of CEE_ opcodes.
4929 * mini.c mini-<ARCH>.c: Remove mono_arch_local_regalloc (), instead make
4930 arch specific functions for its parts. Call the peephole pass after local
4931 regalloc so the prolog can compute a more accurate max_offset.
4933 * mini.c (mono_normalize_opcodes): New mini pass to convert CEE_ opcodes to
4934 the corresponding OP_I/OP_L opcodes.
4936 * mini-amd64.c mini-amd64.h cpu-amd64.md: Get rid of CEE_ opcodes.
4938 * mini-sparc.c (mono_arch_output_basic_block): Fix the sparc build.
4940 2008-02-06 Zoltan Varga <vargaz@gmail.com>
4942 * mini-s390.c (mono_arch_get_inst_for_method): Remove the Interlocked cases
4943 as they are handled in mini.c.
4945 * mini-s390x.c (mono_arch_get_inst_for_method): Ditto.
4947 * mini-<ARCH>.c (mono_arch_get_inst_for_method): Remove the MemoryBarrier
4948 case since it is handled in mini.c.
4950 * cpu-sparc.md (sparc_setfreg_float): Fix the sparc build.
4952 * mini-ops.h: Add new opcodes OP_CALL/OP_CALLVIRT.
4954 * *.c: Use the new opcodes in the IR and back end code.
4956 * mini-ops.h cpu-<ARCH>.md: Correct the name of the bgt_un opcodes.
4958 * mini-amd64.c (emit_call_body): Use a far-call for calling dynamic methods.
4960 2008-02-06 Mark Probst <mark.probst@gmail.com>
4962 * mini-trampolines.c (mono_generic_class_init_trampoline): Removed
4963 an assert because it has a race condition.
4965 2008-02-06 Zoltan Varga <vargaz@gmail.com>
4967 * tramp-amd64.c (mono_arch_patch_callsite): Add more diagnostics.
4969 * inssel.brg mini-<ARCH>.c cpu-<ARCH>.md: Get rid of unused CEE_RET opcode.
4971 * mini-<ARCH>.c cpu-<ARCH>.md: Get rid of unused LDIND/STIND opcodes.
4973 * *.brg mini-<ARCH>.c cpu-<ARCH>.md: Get rid of OP_SETREG/OP_SETFREG/OP_SETREGIMM,
4974 use OP_MOVE/OP_FMOVE/OP_ICONST instead.
4976 2008-02-05 Zoltan Varga <vargaz@gmail.com>
4978 * cpu-amd64.md (move): Correct the maximum size of move.
4980 2008-02-05 Mark Probst <mark.probst@gmail.com>
4982 * tramp-amd64.c, tramp-x86.c, mini-trampolines.c: Added a check in
4983 the generic class init trampoline to return quickly if the class
4986 2008-02-04 Zoltan Varga <vargaz@gmail.com>
4988 * tramp-amd64.c (mono_arch_patch_callsite): Add some diagnostics to help debug
4989 issues where an 32 bit callsite cannot be patched by a 64 bit address.
4991 2008-02-03 Zoltan Varga <vargaz@gmail.com>
4993 * generics.2.cs generics-variant-types.2.il: Merge some tests from the linear IR
4996 2008-01-31 Zoltan Varga <vargaz@gmail.com>
4998 * objects.cs: Add some soft-float tests.
5000 * mini.c: Fix a couple more soft-float issues.
5002 * helpers.c (mono_disassemble_code): Fix disassembly on ARM.
5004 * mini-amd64.c (peephole_pass): Use IXOR instead of LXOR for zeroing a register to
5007 2008-01-30 Zoltan Varga <vargaz@gmail.com>
5009 * exceptions-x86.c (mono_arch_find_jit_info): Fix stack unwinding when an
5010 exception happens while compiling a virtual method.
5012 2008-01-29 Zoltan Varga <vargaz@gmail.com>
5014 * mini-sparc.c (mono_arch_emit_epilog): Fix folding of negative return values.
5016 * mini-sparc.c: Fix build.
5018 * mini-sparc.c (get_call_info): Add support for generic sharing.
5020 * mini-exceptions.c: Add a FIXME.
5022 2008-01-27 Zoltan Varga <vargaz@gmail.com>
5024 * mini-exceptions.c (mono_handle_exception_internal): Remove the old style
5025 altstack handling code.
5027 * mini-s390.c (mono_arch_emit_exceptions): Really fix a warning.
5029 * mini-s390.c (mono_arch_emit_exceptions): Fix a warning.
5031 * mini-s390.c: Add support for generic sharing.
5033 * mini-exceptions.c (ves_icall_System_Security_SecurityFrame_GetSecurityFrame):
5035 (ves_icall_System_Security_SecurityFrame_GetSecurityStack): Ditto.
5037 * mini-s390x.c (mono_arch_emit_exceptions): Fix a warning.
5039 * mini-s390x.c: Add support for generic sharing.
5041 * mini-exceptions.c (ves_icall_System_Security_SecurityFrame_GetSecurityFrame):
5043 (ves_icall_System_Security_SecurityFrame_GetSecurityStack): Ditto.
5045 * mini-s390x.c: Use is_imm16 instead of is_uimm16 when checking whenever s390_aghi
5046 can be used since it takes a 16 bit signed immediate.
5048 * inssel-s390x.brg: Fix OP_SETRET.
5050 * mini-s390x.c (mono_arch_output_basic_block): Fix OP_BREAK.
5052 * mini-codegen.c (mono_opcode_to_cond): Fix a warning.
5054 * mini-s390x.c cpu-s390x.md: Implement sext.i4 properly by sign extension.
5056 * mini.c (mono_create_delegate_trampoline): Don't use mono_create_ftpntr here.
5058 * mini-trampolines.c (mono_delegate_trampoline): Use mono_get_addr_from_ftnptr
5061 * mini-ia64.h mini-ia64.c: Add minimal support for the delegate trampoline
5064 * mini.h inssel-x86.brg inssel-amd64.brg tramp-alpha.c tramp-ia64.c: Get rid
5065 of the unused mono_arch_patch_delegate_trampoline stuff.
5067 2008-01-26 Zoltan Varga <vargaz@gmail.com>
5069 * basic-long.cs: Move the fp related tests to basic-float.cs.
5071 * mini-ops.h (OP_OUTARG_FREG_R4): New opcode.
5073 * mini-ia64.c inssel-ia64.brg: Implement proper R4 argument passing.
5075 * basic-calls.cs: Add a test for proper float argument passing.
5077 * mini-ia64.h (mono_ia64_context_get_ip): Do not substract 1 from the ip
5078 if the context corresponds to an exception received through a signal.
5080 * exceptions.cs: Add a test for nullref handling at the start of a try
5083 * mini-ia64.c (mono_arch_call_opcode): Fix ia64 argument passing.
5085 * jit-icalls.c (mono_break): New JIT icall.
5087 * mini-<ARCH>.c: Use mono_break instead of mono_arch_break.
5089 * mini-arm.c (arm_patch): Add support for patching the blx calling sequence.
5091 2008-01-25 Zoltan Varga <vargaz@gmail.com>
5093 * cpu-*.md: Get rid of unused opcodes.
5095 * cpu-g4.md: Rename this to cpu-ppc.md for consistency with other archs.
5097 * Makefile.am: Move mini-trampolines.c to $(common_sources) since it is now used
5100 * mini-<ARCH>.h mini.c: Get rid of the MONO_ARCH_HAVE_CREATE_SPECIFIC_TRAMPOLINE
5103 * mini-s390x.h tramp-s390x.c Makefile.am: Rework the s390x trampoline code to use
5104 the arch independent trampoline code in mini-trampolines.c.
5106 * aot-runtime.c (mono_aot_init_vtable): Fix a warning.
5108 * mini.c (get_runtime_generic_context_ptr): Fix a warning.
5110 * mini-s390.h: Remove an unused define.
5112 * mini-s390.h tramp-s390.c Makefile.am: Rework the s390 trampoline code to use
5113 the arch independent trampoline code in mini-trampolines.c.
5115 * mini-arm.c (mono_arch_emit_prolog): Fix build.
5117 2008-01-24 Zoltan Varga <vargaz@gmail.com>
5119 * mini-sparc.c (mono_arch_output_basic_block): Remove some unecessary code.
5121 * mini-s390.c (mono_arch_emit_prolog): Fix build.
5123 * mini-s390x.c (mono_arch_emit_prolog): Fix build.
5125 * mini-ppc.c (mono_arch_emit_prolog): Fix build.
5127 * cpu-amd64.md: Use smaller sizes for int opcodes.
5129 * *.c: Get rid of the NOT_IMPLEMENTED define which is now in mini.h.
5131 * *.cs: Add some tests from the linear-ir branch. Move structs tests to
5134 * driver.c (mono_main): Add a --break-at-bb command line argument for JIT
5137 * mini.h *.c: Change cfg->vars to contain the MonoMethodVar entries directly
5138 instead of though a pointer to save an indirection when accessing elements of
5141 * mini.h (MONO_IS_COND_BRANCH_OP): Move these macros here from mini.c. Fix
5143 (NOT_IMPLEMENTED): New helper macro.
5144 (MONO_BB_FOR_EACH_INS): New helper macro to iterate through the instructions
5147 * *.c: Use the new helper macro.
5149 2008-01-21 Zoltan Varga <vargaz@gmail.com>
5151 * mini-x86.h (MONO_ARCH_AOT_SUPPORTED): Disable AOT for apple x86.
5153 2008-01-20 Zoltan Varga <vargaz@gmail.com>
5155 * mini-amd64.c (mono_arch_emit_prolog): Optimize the omit fp case to save two
5158 2008-01-18 Zoltan Varga <vargaz@gmail.com>
5160 * mini-amd64.c (mono_arch_emit_prolog): Disable the new optimization if
5161 profiling is enabled.
5163 * mini-amd64.c (mono_arch_call_opcode): Emit the save_sp_to_lmf instruction at
5165 (mono_arch_emit_prolog): Add more first bblock optimizations.
5167 * mini-amd64.c (mono_arch_call_opcode): Keep assignments to the arg registers
5168 in order if possible.
5169 (mono_arch_emit_prolog): Optimize assignments to arg registers in the first
5170 bblock, since the arguments are still in their original registers.
5172 * mini.c (type_from_op): Calling add.ovf on floats is not valid IL code.
5174 2008-01-17 Zoltan Varga <vargaz@gmail.com>
5176 * mini.c (mono_method_to_ir): Use the no-spilling optimization for CEE_CALLI
5179 * mini-amd64.c (mono_arch_emit_prolog): Save an instruction if the LMF is at
5182 * mini-amd64.h (MONO_ARCH_HAVE_NOTIFY_PENDING_EXC): Turn on this for amd64.
5184 * exceptions-amd64.c (mono_arch_notify_pending_exc): New function to
5185 process async exceptions received while in unmanaged code.
5187 * mini.c (mini_init): Install a callback with the runtime which will be called
5188 when a thread receives an async exception while in unmanaged code.
5190 * mini.c driver.c: Update after mono_get_native_wrapper () signature change.
5192 * mini-s390x.c (mono_arch_output_basic_block): Fix s390x build.
5194 2008-01-16 Wade Berrier <wberrier@novell.com>
5201 2008-01-16 Zoltan Varga <vargaz@gmail.com>
5203 * mini-x86.c (mono_arch_output_basic_block): Remove some gccism which prevents
5204 compilation with sun cc.
5206 * cpu-*.md: Fix the build.
5208 * cpu-x86.md: Fix the length of some load membase opcodes. Fixes #354241.
5210 * mini-amd64.h: Add some comments to the MonoLMF structure.
5212 * mini-ops.h cpu-amd64.c: Add a OP_AMD64_SAVE_SP_TO_LMF opcode.
5214 * mini-amd64.c exceptions-amd64.c tramp-amd64.c: Avoid setting the rip field
5215 in the LMF structure if possible. This saves two instructions in the
5216 managed->native wrappers.
5218 * mini-ops.h *.md: Make some opcodes names uniform by removing the op_ prefix.
5220 2008-01-16 Mark Probst <mark.probst@gmail.com>
5222 * generic-sharing.c: New type argument lookup code which uses the
5223 runtime generic context template.
5225 2008-01-15 Zoltan Varga <vargaz@gmail.com>
5227 * mini.c (mono_method_to_ir): Avoid emitting a write barrier when storing NULL.
5229 * mini-arm.c (add_general): Fix arm eabi parameter passing.
5230 (mono_arch_output_basic_block): Fix localloc implementation.
5232 * mini-amd64.c (peephole_pass): Sync store+load optimizations with the x86 version.
5234 * mini-ia64.c (peephole_pass): Fix ia64 build.
5236 * mini-amd64.c (peephole_pass): Fix a warning.
5238 * mini-amd64.c (mono_arch_allocate_vars): Make sure the LMF is always stored
5239 at a constant offset from sp/fp.
5241 * exceptions-amd64.c (mono_arch_find_jit_info): Compute the LMF address from fp/sp
5242 instead of obtaining it from *lmf in the managed method case.
5244 2008-01-14 Zoltan Varga <vargaz@gmail.com>
5246 * exceptions-amd64.c (mono_arch_find_jit_info): Remove some duplicate code.
5248 Mon Jan 14 12:33:06 CET 2008 David S. Miller <davem@davemloft.net>
5250 * mini.h (MonoInstList): New type.
5251 (MONO_INST_LIST_INIT, MONO_INST_LIST_EMPTY,
5252 __MONO_INST_LIST_ADD, MONO_INST_LIST_ADD,
5253 MONO_INST_LIST_ADD_TAIL, __MONO_INST_LIST_DEL,
5254 __MONO_INST_LIST_SPLICE, MONO_INST_LIST_SPLICE,
5255 MONO_INST_LIST_SPLICE_TAIL, MONO_INST_LIST_SPLICE_INIST,
5256 MONO_INST_LIST_SPLICE_TAIL_INIT, mono_container_of,
5257 MONO_INST_LIST_ENTRY, MONO_INST_LIST_FIRST_ENTRY,
5258 MONO_INST_LIST_LAST_ENTRY, MONO_INST_LIST_FOR_EACH,
5259 MONO_INST_LIST_FOR_EACH_PREV, MONO_INST_LIST_FOR_EACH_SAFE,
5260 MONO_INST_LIST_FOR_EACH_PREV_SAFE,
5261 MONO_INST_LIST_FOR_EACH_ENTRY,
5262 MONO_INST_LIST_FOR_EACH_ENTRY_REVERSE,
5263 MONO_INST_LIST_FOR_EACH_ENTRY_SAFE,
5264 mono_inst_list_first, mono_inst_list_last,
5265 mono_inst_list_next, mono_inst_list_prev): New instruction
5266 list handling interfaces.
5267 (MonoBasicBlock): Remove 'last_ins' and 'code', replace with
5268 list head 'ins_list'.
5269 (MonoInst): Replace next pointer with list head 'node'.
5270 (MonoCallInst): Make 'out_args' a MonoInstList.
5271 (MONO_INST_NEW_CALL): Explicitly init ->out_args.
5272 (MonoCompile): Delete reverse_inst_list and
5273 reverse_inst_list_len.
5274 * mini-hppa.c (mono_arch_call_opcode, NEW_INS,
5275 mono_arch_lowering_pass, mono_arch_local_regalloc,
5276 mono_arch_output_basic_block, mono_arch_emit_prolog):
5277 Convert to new instruction lists.
5278 (insert_after_ins): Delete.
5279 * inssel.brg (MONO_EMIT_NEW_BRANCH_BLOCK): Convert to new
5281 * mini-hppa.h (MONO_EMIT_NEW_COMPARE_BRANCH_BLOCK): Likewise.
5282 * mini.c (NEW_BBLOCK, ADD_BBLOCK, CHECK_BBLOCK,
5283 split_bblock, mono_add_ins_to_end, mono_emit_call_args,
5284 mono_emulate_opcode, mono_emit_load_got_addr,
5285 inline_method, mono_method_to_ir, mono_print_bb_code,
5286 print_dfn, decompose_pass, nullify_basic_block,
5287 replace_out_block_in_code, remove_block_if_useless,
5288 merge_basic_blocks, move_basic_block_to_end,
5289 try_unsigned_compare, optimize_branches, mono_print_code,
5290 mini_select_instructions, remove_critical_edges): Likewise.
5291 * mini-amd64.c (emit_sig_cookie, mono_arch_call_opcode,
5292 peephole_pass_1, peephole_pass, mono_arch_lowering_pass,
5293 mono_arch_output_basic_block, mono_arch_emit_prolog):
5295 * mini-mips.c (mono_arch_call_opcode, peephole_pass,
5296 NEW_INS, mono_arch_lowering_pass, mono_arch_local_regalloc,
5297 mono_arch_output_basic_block): Likewise.
5298 (inst_list_prepend, insert_after_ins): Delete.
5299 * mini-mips.h (MONO_EMIT_NEW_BRANCH_NONZERO_LABEL,
5300 MONO_EMIT_NEW_COMPARE_BRANCH_BLOCK): Convert to new
5302 * mini-x86.c (emit_sig_cookie, mono_arch_call_opcode,
5303 peephole_pass_1, peephole_pass, mono_arch_output_basic_block,
5304 mono_arch_emit_prolog): Likewise.
5305 * cfold.c (mono_constant_fold): Likewise.
5306 * liveness.c (visit_bb, mono_analyze_liveness,
5307 optimize_initlocals): Likewise.
5308 * ssapre.c (dump_code, process_bb, code_motion): Likewise.
5309 * graph.c (mono_draw_code_cfg): Likewise.
5310 * ssa.c (mono_ssa_rename_vars, mono_ssa_compute,
5311 mono_ssa_remove, mono_ssa_avoid_copies, mono_ssa_create_def_use,
5312 mono_ssa_cprop): Likewise.
5313 * abcremoval (get_relations_from_previous_bb, process_block):
5315 * local-propagation (mono_cprop_invalidate_values,
5316 mono_local_cprop_bb): Likewise.
5317 * mini-s390x.c (mono_arch_call_opcode, emit_sig_cookie,
5318 peephole_pass, mono_arch_output_basic_block,
5319 mono_arch_emit_prolog): Likewise.
5320 * mini-arm.c (mono_arch_call_opcode, peephole_pass,
5321 NEW_INS, mono_arch_lowering_pass, mono_arch_local_regalloc,
5322 mono_arch_emit_prolog): Likewise.
5323 (insert_after_ins): Delete.
5324 * aliasing.c (print_code_with_aliasing_information,
5325 mono_build_aliasing_information, mono_aliasing_deadce):
5326 Convert to new instruction lists.
5327 * mini-ia64.c (emit_sig_cookie, mono_arch_call_opcode,
5328 peephole_pass, NEW_INS, mono_arch_lowering_pass,
5329 mono_arch_local_regalloc, mono_arch_output_basic_block):
5331 (insert_after_ins): Delete.
5332 * mini-sparc.c (emit_sig_cookie, mono_arch_call_opcode,
5333 peephole_pass, mono_arch_output_basic_block): Convert to
5334 new instruction lists.
5335 * mini-codegen (InstList, inst_list_prepend,
5336 insert_after_ins): Delete.
5337 (insert_before_ins, get_register_force_spilling,
5338 get_register_spilling, free_up_ireg, free_up_reg,
5339 create_copy_ins, create_spilled_store, alloc_int_reg,
5340 alloc_float_reg, alloc_reg, mono_local_regalloc): Convert
5341 to new instruction lists.
5342 * mini-ppc.c (mono_arch_call_opcode, peephole_pass,
5343 NEW_INS, mono_arch_lowering_pass, mono_arch_local_regalloc,
5344 mono_arch_output_basic_block, mono_arch_emit_prolog): Likewise.
5345 (insert_after_ins): Delete.
5346 * mini-alpha.c (NEW_INS, peephole_pass, mono_arch_lowering_pass,
5347 mono_arch_local_regalloc, mono_arch_output_basic_block,
5348 mono_arch_call_opcode): Convert to new instruction lists.
5349 (insert_after_ins): Delete.
5350 * mini-s390.c (mono_arch_call_opcode, emit_sig_cookie,
5351 peephole_pass, mono_arch_output_basic_block,
5352 mono_arch_emit_prolog): Convert to new instruction lists.
5354 2008-01-11 Zoltan Varga <vargaz@gmail.com>
5356 * mini-amd64.c (mono_arch_output_basic_block): Use a 4 byte load in OP_CHECK_THIS.
5358 * mini-sparc.c (mono_arch_output_basic_block): Use a byte load in CHECK_THIS.
5361 * Makefile.am (version.h): Make this work with non-bash shells.
5363 2008-01-10 Zoltan Varga <vargaz@gmail.com>
5365 * mini.c (handle_delegate_ctor): Optimize away setting of NULL target.
5367 2008-01-08 Zoltan Varga <vargaz@gmail.com>
5369 * mini.c (mono_method_to_ir): Fix possible reading of invalid memory in
5370 the InitializeArray optimization.
5372 2008-01-06 Zoltan Varga <vargaz@gmail.com>
5374 * mini.c driver.c: Don't include os/gc_wrapper.h.
5376 2008-01-05 Zoltan Varga <vargaz@gmail.com>
5378 * mini.c (print_jit_stats): Print GC statistics if available.
5380 2008-01-04 Zoltan Varga <vargaz@gmail.com>
5382 * mini-amd64.c (mono_arch_allocate_vars): Align argument storage offsets to 8.
5384 2007-12-29 Zoltan Varga <vargaz@gmail.com>
5386 * mini-ppc.c (mono_arch_get_delegate_invoke_impl): Fix flushing of icache.
5388 2007-12-26 Zoltan Varga <vargaz@gmail.com>
5390 * mini.c (mini_init): Move the setting of GC_stackbottom to mono_gc_base_init ().
5392 * mini.c (mini_init): Call mono_gc_base_init () instead of MONO_GC_PRE_INIT ().
5394 * driver.c (mono_main): Ditto.
5396 2007-12-23 Zoltan Varga <vargaz@gmail.com>
5398 * mini-trampolines.c (mono_delegate_trampoline): Use mono_get_delegate_invoke ().
5400 * aot-compiler.c (emit_klass_info): Avoid emitting info if one of the methods
5401 in the vtable can't be encoded.
5402 (compile_method): Ditto.
5404 2007-12-21 Zoltan Varga <vargaz@gmail.com>
5406 * mini.c (setup_jit_tls_data): Use the MONO_ARCH_INIT_TOP_LMF_ENTRY macro if
5409 * mini-amd64.h mini-amd64.c exceptions-amd64.c tramp-amd64.c: Rename lmf->ebp to
5412 * exceptions-amd64.c (mono_arch_find_jit_info): Fix the detection of whenever
5413 the top LMF entry belongs to the current method.
5415 * mini.c: Update after renaming of mono_thread_get_pending_exception ().
5417 2007-12-20 Zoltan Varga <vargaz@gmail.com>
5419 * tramp-ia64.c (mono_arch_create_trampoline_code): Fix a warning.
5421 * tramp-ia64.c (mono_arch_create_trampoline_code): Ditto.
5423 * tramp-sparc.c (mono_arch_create_trampoline_code): Check for thread interruption.
5425 * tramp-amd64.c (mono_arch_create_trampoline_code): Ditto.
5427 * tramp-x86.c (mono_arch_create_trampoline_code): Check for thread interruption.
5429 * cpu-amd64.md mini-amd64.h mini-amd64.c inssel-amd64.brg: Add ulong->double
5432 * basic-float.cs: Add an ulong->double cast test.
5434 2007-12-15 Zoltan Varga <vargaz@gmail.com>
5436 * mini.c (mono_method_to_ir): Fix a warning.
5438 2007-12-14 Zoltan Varga <vargaz@gmail.com>
5440 * mini-ops.h: Add OP_SWITCH.
5442 * mini.c graph.c ssa.c aliasing.c mini-<ARCH>.c inssel-<ARCH>.brg: Avoid using
5443 CEE_SWITCH in back-end code, use OP_SWITCH instead.
5445 2007-12-11 Geoff Norton <gnorton@novell.com>
5447 * mini-s390x.c: Minor change to the MAX() define to allow
5448 it to compile with other gcc versions.
5450 2007-12-11 Geoff Norton <gnorton@novell.com>
5453 * mini-s390x.c: Implement sext_i4 to fix the build on s390x
5455 2007-12-11 Rodrigo Kumpera <rkumpera@novell.com>
5457 exceptions-arm.c (mono_arch_get_restore_context): Restore
5460 exceptions-arm.c (throw_exception): Save the frame pointer.
5461 This is a partial fix for #323747. Only the client side is
5464 2007-12-11 Rodrigo Kumpera <rkumpera@novell.com>
5466 * mini.c (mono_method_to_ir): Verbose message in CEE_NEWOBJ
5467 was using an unrelated variable to log the class which
5468 needed the cctor to be called. This was crashing on arm.
5470 2007-12-09 Robert Jordan <robertj@gmx.net>
5472 * mini-x86.c (mono_arch_emit_epilog):
5473 Consider all kinds of 64-bit types. Fixes #323114.
5475 2007-12-08 Zoltan Varga <vargaz@gmail.com>
5477 * tramp-amd64.c (mono_arch_create_trampoline_code): Clean up the code a bit.
5479 2007-12-07 Zoltan Varga <vargaz@gmail.com>
5481 * mini-amd64.c (peephole_pass): Add a missing instruction check.
5483 Fri Dec 7 22:08:23 CET 2007 Paolo Molaro <lupus@ximian.com>
5485 * mini.c: run type ctor before allocating an object, not only
5486 when running it's constructor method (fixes at least part of bug #342507).
5488 2007-12-07 Zoltan Varga <vargaz@gmail.com>
5490 * mini-trampolines.c (mono_delegate_trampoline): Fix a warning.
5492 * mini-trampolines.c (mono_generic_class_init_trampoline): Remove a debug printf.
5493 * mini.h mini-amd64.c mini-x86.c: Get rid of the mono_arch_find_vtable ()
5496 * tramp-x86.c tramp-amd64.c mini-trampolines.c: Pass the vtable argument to
5497 mono_generic_class_init_trampoline () the same as it is done with the other
5500 * mini-arm.h mini-arm.c tramp-arm.c inssel-arm.brg cpu-arm.md
5501 aot-runtime.c aot-compiler.c: Implement AOT support.
5503 2007-12-07 Mark Probst <mark.probst@gmail.com>
5505 * mini-trampolines.c (mono_generic_class_init_trampoline): Fixed
5506 build for archs which don't have the vtable trampoline defined
5509 2007-12-07 Zoltan Varga <vargaz@gmail.com>
5511 * tramp-x86.c (mono_arch_create_trampoline_code): Fix the build.
5513 * tramp-ppc.c (mono_arch_create_trampoline_code): Use the new helper function.
5515 * mini-trampolines.c (mono_get_trampoline_func): New helper function.
5517 * tramp-<ARCH>.c: Use the new helper function.
5519 2007-12-07 Mark Probst <mark.probst@gmail.com>
5521 * inssel.brg: Added a pattern for the OP_TRAMPCALL_VTABLE
5522 trampoline call, which takes a vtable argument.
5524 * graph.c, mini-ops.h, local-propagation.c, aliasing.c: Treat
5525 OP_TRAMPCALL_VTABLEs like other calls.
5527 * mini-amd64.c, mini-amd64.h, mini-x86.c, mini-x86.h: Designated a
5528 register to hold the vtable argument to the OP_TRAMPCALL_VTABLE
5529 call. Implemented a support function which fetches the vtable
5530 from a register set.
5532 * mini.c, mini.h, tramp-amd64.c, tramp-x86.c, mini-trampolines.c:
5533 Implemented a generic class init trampoline, using the
5534 OP_TRAMPCALL_VTABLE opcode.
5536 * mini.c: Implemented static field access when sharing generic
5537 code. This implies initing the class using the new
5538 OP_TRAMPCALL_VTABLE call.
5540 2007-12-07 Mark Probst <mark.probst@gmail.com>
5542 * mini.c: Don't compile methods with sharing enabled if their
5543 classes are disabled for sharing.
5545 2007-12-06 Zoltan Varga <vargaz@gmail.com>
5547 * inssel.brg: Add a missing sign extension to the GETCHR and array access
5548 opcodes. Fixes #346563.
5550 * objects.cs: Add a new test.
5552 * aot-compiler.c (emit_method_code): Put back an #ifdef which is needed.
5554 * mini-<ARCH>.h mini.c aot-compiler.c aot-runtime.c: Get rid of the
5555 HAVE_PIC_AOT define and use AOT_SUPPORTED instead.
5557 2007-12-06 Zoltan Varga <vargaz@gmail.com>
5559 * mini-arm.h mini-arm.c: Add support for the common vtable trampoline.
5561 2007-12-03 Zoltan Varga <vargaz@gmail.com>
5563 * mini-arm.c (mono_arch_emit_exceptions): Avoid uninitialized memory in the
5566 2007-12-02 Zoltan Varga <vargaz@gmail.com>
5568 * patch-info.h (PATCH_INFO): Add DELEGATE_TRAMPOLINE.
5570 * mini.c aot-compiler.c aot-runtime.c: Implement the delegate creation
5571 optimization in the AOT case.
5573 2007-11-30 Zoltan Varga <vargaz@gmail.com>
5575 * aot-runtime (mono_aot_get_method_from_vt_slot): Add support for multi-byte method ref encodings.
5577 * aot-runtime.c (decode_klass_ref): Implement decoding of generic instances.
5579 * aot-compiler.c (encode_klass_ref): Implement proper encoding of generic instances.
5581 * mini.c (mono_method_to_ir): Optimize the common ldftn+create delegate combination.
5583 * mini-trampolines.c (mono_delegate_trampoline): Add some code to handle the case when the delegate
5584 is created by the inlined delegate ctor.
5586 * mini-x86.c (mono_arch_output_basic_block): Unify div/rem code and handle the case when sreg2 is EDX.
5588 * mini.c (mono_jit_compile_method_inner): Replace calls to delegate invoke with the trampoline here too.
5590 2007-11-29 Zoltan Varga <vargaz@gmail.com>
5592 * cpu-x86.md: Fix the length of ckfinite.
5594 2007-11-28 Zoltan Varga <vargaz@gmail.com>
5596 * mini-x86.c (mono_arch_output_basic_block): Unify div/rem code and handle the case when sreg2 is EDX.
5598 * mini-x86.c (mono_arch_output_basic_block): Clean up the fp stack properly in CKFINITE.
5599 (mono_arch_output_basic_block): Get rid of unused last_ins and last_offset.
5601 * mini-x86.c (mono_arch_output_basic_block): Add some micro optimizations.
5603 * mini-x86.c inssel-x86.brg cpu-x86.md: Move the implementation of the
5604 OP_START_HANDLER/OP_ENDFINALLY/OP_ENDFILTER opcodes to mini-x86.c.
5606 2007-11-28 Martin Baulig <martin@ximian.com>
5609 (mono_arch_get_delegate_invoke_impl): Call mono_debug_add_delegate_trampoline()
5610 after creating the trampoline.
5612 2007-11-27 Zoltan Varga <vargaz@gmail.com>
5614 * aot-runtime.c (load_aot_module): Check runtime version if needed.
5616 * aot-compiler.c: Add bind-to-runtime-version for producing AOT files which only load into a runtime with
5619 * generic-sharing.c (mono_helper_get_rgctx_other_ptr): Change the signature to take the calling class
5620 instead of the calling method to help AOT.
5622 * mini.c (get_runtime_generic_context_other_ptr): Update after the change.
5624 2007-11-26 Zoltan Varga <vargaz@gmail.com>
5626 * aot-runtime.c (mono_aot_init_vtable): Simplify this if MONO_ARCH_COMMON_VTABLE_TRAMPOLINE
5629 2007-11-23 Zoltan Varga <vargaz@gmail.com>
5631 * aot-compiler.c (emit_class_name_table): Properly encode generic class names.
5633 * aot-compiler.c (compile_method): Correct check for generic method definitions.
5634 (encode_method_ref): No need to handle generic method definitions specially.
5636 * mini.h (MONO_AOT_FILE_VERSION): Bump this.
5638 * aot-runtime.c (decode_klass_ref): Clean this up and rename from
5641 * aot-compiler.c (encode_klass_ref): Clean this up and rename from
5643 (compile_method): Enable generic sharing.
5645 2007-11-22 Zoltan Varga <vargaz@gmail.com>
5647 * mini.c (get_runtime_generic_context_other_ptr): Disable AOT here.
5648 (mini_method_compile): Add preliminary support for AOTing shared generic code.
5650 * aot-compiler.c (compile_method): Add preliminary support for AOTing shared
5653 * mini-trampolines.c: Fix a warning.
5655 * mini.c (get_runtime_generic_context_other_ptr): Use NEW_METHODCONST instead of
5657 (mono_method_to_ir): Use NEW_DOMAINCONST in one place.
5658 (generic_class_is_reference_type): Remove unused function.
5660 * mini-trampolines.c (mono_magic_trampoline): Avoid loading metadata if possible
5661 in the generic vtable trampoline case.
5663 * aot-runtime.c (mono_aot_init_vtable): Use the generic vtable trampoline.
5665 * aot-runtime.c (mono_aot_get_method_from_vt_slot): New helper function to
5666 return an AOT method based on a vtable slot.
5668 * aot-compiler.c (compile_method): Avoid AOTing synchronized methods for now.
5670 * mini.c (mini_get_vtable_trampoline): Export this.
5672 2007-11-22 Martin Baulig <martin@ximian.com>
5675 (MonoDebuggerInfo): Move `debugger_version' up.
5677 2007-11-22 Martin Baulig <martin@ximian.com>
5680 (mono_arch_get_delegate_invoke_impl): Call mono_debug_add_delegate_trampoline().
5682 * mini-trampolines.c
5683 (mono_delegate_trampoline): Call mono_debugger_trampoline_compiled()
5684 after compiling the method.
5686 2007-11-20 Martin Baulig <martin@ximian.com>
5689 (mono_debugger_insert_method_breakpoint): Moved into mono-debug-debugger.c.
5690 (mono_debugger_remove_breakpoint): Likewise.
5691 (mono_debugger_check_breakpoints): Likewise.
5693 * debug-debugger.c: Implement the new breakpoint interface here.
5695 2007-11-18 Zoltan Varga <vargaz@gmail.com>
5697 * mini-amd64.c (mono_arch_output_basic_block): Unify the implementation of
5698 CEE_CONV_I1/SEXT_I1 and I2 since they are the same.
5700 * mini-x86.c (mono_arch_output_basic_block): Ditto.
5702 2007-11-17 Zoltan Varga <vargaz@gmail.com>
5704 * mini-amd64.c (mono_arch_output_basic_block): Fix a typo.
5706 * mini-x86.c (mono_arch_get_inst_for_method): Remove code which is now in
5709 * mini-ia64.c (mono_arch_get_inst_for_method): Remove code which is now in
5712 * mini-amd64.c (mono_arch_compute_omit_fp): Disable fp elimination for methods
5713 returning a vtype in a register.
5715 * mini.c (mini_get_inst_for_method): Move the handling of the atomic operations
5716 here from the arch specific code.
5718 * mini-amd64.c (mono_arch_get_inst_for_method): Remove code which is now in
5721 * mini-amd64.c (mono_arch_output_basic_block): Add some micro optimizations.
5722 (mono_arch_emit_prolog): Increment maximum prolog size.
5724 * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Move the implementation of the
5725 START_HANDLER/ENDFINALLY/ENDFILTER opcodes to mini-amd64.c.
5727 * mini-x86.c (get_call_info): Receive a MonoCompile instead of a
5728 MonoGenericSharingContext.
5730 * mini-ia64.c (get_call_info): Receive a MonoCompile instead of a
5731 MonoGenericSharingContext. Allocate memory from the cfg mempool.
5733 2007-11-15 Mark Probst <mark.probst@gmail.com>
5735 * mini.c, mini.h, generic-sharing.c: Functions for producing code
5736 which extract fields out of the runtime generic context. Full
5737 sharing of the NEWARR opcode.
5739 Thu Nov 15 14:20:21 CET 2007 Paolo Molaro <lupus@ximian.com>
5741 * abcremoval.c, mini.c, ssa.c, ssapre.c: updated to implement
5742 --enable-minimal=ssa.
5744 2007-11-13 Zoltan Varga <vargaz@gmail.com>
5746 * mini-trampolines.c (mono_delegate_trampoline): Update after
5747 mono_marshal_get_delegate_invoke () signature change.
5749 2007-11-13 Mark Probst <mark.probst@gmail.com>
5751 * mini.c: Removed the shared context in favor of the generic
5752 sharing context. Allocate the MonoJitInfo structure with room for
5753 the generic sharing context if it's needed.
5755 * mini.h: Remove MonoGenericSharingContext declaration. It's in
5756 domain-internals.h now.
5758 * mini-x86.c: Pass the generic sharing context to get_call_info ().
5760 * generic-sharing.c: Several changes for working without a shared
5761 context and instead operating on open types instead.
5763 2007-11-12 David S. Miller <davem@davemloft.net>
5765 * inssel-sparc.brg: Fix double instruction emit.
5767 2007-11-12 Zoltan Varga <vargaz@gmail.com>
5769 * mini.c (mono_jit_runtime_invoke): Avoid trying to compile the Array
5770 Get/Set/Address methods.
5772 * mini.c debug-debugger.c mini-trampolines.c: Update after
5773 mono_marshal_get_delegate_invoke signature change.
5775 2007-11-12 Rodrigo Kumpera <rkumpera@novell.com>
5777 * cpu-arm.md: Increase the max size of OP_THROW to 24 bytes.
5778 This can happens with dynamic methods. Fixes the other bug in #322722.
5780 2007-11-12 Rodrigo Kumpera <rkumpera@novell.com>
5782 * tramp-arm.c (mono_arch_patch_callsite): Support patching
5785 * mini-arm.c (arm_patch): Implement patching of BX call
5786 sequence. Fixes one of the bugs in #322722.
5788 2007-11-03 David S. Miller <davem@huronp11.davemloft.net>
5790 * mini-sparc.c (mono_arch_flush_icache): Make more efficient
5791 under Linux. We only need to flush every 32-byte cache line.
5793 2007-11-07 Massimiliano Mantione <massi@ximian.com>
5796 move_basic_block_to_end: Add branches when needed, eventually creating
5798 optimize_branches: added a parameter that tells if it's ok to create
5799 new BBs (doing is "df_visit" has been called is (IMHO) a nightmare),
5800 and avoid calling move_basic_block_to_end when it's not ok.
5803 2007-11-07 Mark Probst <mark.probst@gmail.com>
5805 * mini.c: Abort inlining call to InitializeArray if something
5806 looks wrong. Let the icall handle it, which now has proper safety
5809 2007-11-05 Rodrigo Kumpera <rkumpera@novell.com>
5811 * mini.c (mono_spill_call): add support for soft-float.
5813 * mini.c (mono_method_to_ir): add support for soft-float
5814 to inlined functions that return float.
5816 * mini.c (mono_method_to_ir): add support for soft-float
5817 to cee_stsfld opcode on float fields.
5819 2007-11-05 Geoff Norton <gnorton@novell.com>
5821 * mini-x86.h: Fix the structure access for X86 Leopard.
5824 2007-11-05 Martin Baulig <martin@ximian.com>
5826 * mini-trampolines.c
5827 (mono_magic_trampoline): Call mono_debugger_trampoline_compiled()
5828 after compiling the method to notify the debugger.
5830 2007-11-05 Martin Baulig <martin@ximian.com>
5832 * debug-debugger.h (MonoDebuggerInfo): Use the new breakpoint tables.
5834 2007-11-02 Zoltan Varga <vargaz@gmail.com>
5836 * mini-sparc.c (EMIT_COND_SYSTEM_EXCEPTION_GENERAL): Applied patch from
5837 David Miller <davem@davemloft.net>. Allow larger offsets in branches.
5839 2007-11-01 Zoltan Varga <vargaz@gmail.com>
5841 * mini-amd64.c (mono_arch_emit_prolog): Check the domain as well for
5842 native-to-managed wrappers.
5844 2007-11-01 Geoff Norton <gnorton@novell.com>
5846 * mini-ppc.h, mini-x86.h: Handle Leopards renaming of some structure
5849 Wed Oct 31 20:23:14 CET 2007 Paolo Molaro <lupus@ximian.com>
5851 * mini.c, mini-x86.c: when getting back from unmanaged code
5852 to managed via a marshaled delegate we also need to set the
5855 Wed Oct 31 19:53:33 CET 2007 Paolo Molaro <lupus@ximian.com>
5857 * mini-amd64.c, mini-amd64.h, tramp-amd64.c: breakpoint table support
5860 Wed Oct 31 19:29:30 CET 2007 Paolo Molaro <lupus@ximian.com>
5862 * mini.c, mini.h, mini-x86, tramp-x86.c, mini-x86.h: added API to
5863 let the debugger or other external agents to tell the JIT when
5864 a sw breakpoint has been inserted in the code that the JIT needs
5865 to be able to inspect.
5867 2007-10-31 Martin Baulig <martin@ximian.com>
5870 (MonoDebuggerInfo): Remove `runtime_class_init'.
5872 2007-10-30 Martin Baulig <martin@ximian.com>
5875 (mono_debugger_thread_created): Added `MonoThread *' argument.
5876 (mono_debugger_extended_notification): New public method.
5877 (mono_debugger_trampoline_compiled): New public method.
5880 (MonoDebuggerThreadInfo): Added `thread' and
5881 `extended_notifications' fields.
5884 (debugger_executable_code_buffer): New static variable.
5887 (MonoDebuggerInfo): Added `executable_code_buffer',
5888 `executable_code_buffer_size', `breakpoint_info_area',
5889 `breakpoint_table' and `breakpoint_table_size'.
5891 2007-10-26 Rodrigo Kumpera <rkumpera@novell.com>
5893 * mini-arm.c (mono_arch_build_imt_thunk): Take the advantage
5894 that IP either is an unused value or the vtable pointer. IMT
5895 calls use vtable + offset now. Reduced by almost half the size
5898 2007-10-26 Jonathan Chambers <joncham@gmail.com>
5900 * mini-amd64.c: Begin Win64 port. Use AMD64_ARG_REG#
5901 defines to access param registers. Replace long usage with
5902 gsize as sizeof(long) != sizeof(void*) on Win64.
5904 * mini-amd64.h: Add %rdi and %rsi to MonoLMF structure
5905 on Win64. Fix intrinsic, use _AddressOfReturnAddress
5906 instead of non-existant _GetAddressOfReturnAddress.
5908 * tramp-amd64.c: Use AMD64_ARG_REG# defines to access
5909 param registers. Save/restore %rdi and %rsi in MonoLMF.
5911 * exceptions-amd64.c: Use AMD64_ARG_REG# defines to access
5912 param registers. Modify (throw_exception) signature to take
5913 %rdi and %rsi on Win64.
5915 Code is contributed under MIT/X11 license.
5917 Thu Oct 25 23:06:58 CEST 2007 Paolo Molaro <lupus@ximian.com>
5919 * helpers.c: unlink debugging output files.
5921 2007-10-25 Zoltan Varga <vargaz@gmail.com>
5923 * mini.c: Move mono_create_ftnptr () to object.c.
5925 2007-10-24 Rodrigo Kumpera <rkumpera@novell.com>
5927 * helpers.c (mono_disassemble_code): MonoCompile parameter is now
5928 optional. This function can now be used to disassemble code generated
5929 outside the JIT such as trampolines and IMT thunks.
5931 * mini-arm.h: defined MONO_ARCH_HAVE_IMT.
5933 * mini-arm.c (decode_vcall_slot_from_ldr): added, extract the
5934 vtable pointer from a ldr instruction.
5936 * mini-arm.c (mono_arch_get_vcall_slot_addr): support the
5937 new IMT call sequence.
5939 * mini-arm.c (mono_arch_output_basic_block): emit the IMT
5940 call sequence for interface invocations.
5942 * mini-arm.c (mono_arch_emit_imt_argument): added, required
5943 for imt support. This function is empty since IMT on ARM requires no
5944 special handling on the IR side.
5946 * mini-arm.c (mono_arch_find_imt_method): added, required for
5949 * mini-arm.c (mono_arch_find_this_argument): added, required
5952 * mini-arm.c (arm_emit_value_and_patch_ldr): added, patches
5953 a ldr instruction to load a value stored in the code stream.
5955 * mini-arm.c (mono_arch_build_imt_thunk):added, required
5959 2007-10-23 Zoltan Varga <vargaz@gmail.com>
5961 * mini.c (mini_init): Install the jump trampoline callback.
5963 Tue Oct 23 17:07:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
5965 * mini-trampolines.c: handle synchronized methods with the common
5966 vtable trampoline (bug #335601).
5968 2007-10-17 Zoltan Varga <vargaz@gmail.com>
5970 * mini-ia64.h mini-amd64.c: Add support for the common vtable trampoline.
5972 * inssel.brg (mini_emit_virtual_call): Fix the computation of ins->inst_offset on
5975 * mini-ia64.h mini-ia64.c: Add support for IMT.
5977 * mini-x86.c (mono_arch_emit_prolog): Increase the size allocated for the
5978 prolog. Fixes #331958.
5980 2007-10-15 Zoltan Varga <vargaz@gmail.com>
5982 * mini-sparc.h mini-sparc.c: Add support for the common vtable trampoline.
5984 Mon Oct 15 11:18:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
5986 * mini-ppc.c, mini-ppc.h: ppc support for the common vtable
5989 Mon Oct 15 10:41:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
5991 * mini-amd64.c, mini-amd64.h: amd64 support for the common vtable
5994 Mon Oct 15 10:39:26 CEST 2007 Paolo Molaro <lupus@ximian.com>
5996 * mini-x86.c, mini-x86.h: x86 support for the common vtable
5999 Mon Oct 15 10:37:15 CEST 2007 Paolo Molaro <lupus@ximian.com>
6001 * mini-trampolines.c: changed the magic rampoline to understand
6002 the common vtable trampoline method: the method to invoke is
6003 determined by the vtable displacement of the call.
6005 Mon Oct 15 10:35:12 CEST 2007 Paolo Molaro <lupus@ximian.com>
6007 * mini.c, mini.h: register the common vtable trampoline if the
6008 architecture supports it.
6010 Mon Oct 15 09:50:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
6012 * cpu-amd64.md: use the correct max length for tls_get.
6014 2007-10-14 Zoltan Varga <vargaz@gmail.com>
6016 * mini.c (mono_method_to_ir): Use mini_get_class in CEE_LDELEM_ANY and
6017 CEE_STELEM_ANY. Fixes #333696.
6019 Thu Oct 11 18:04:29 CEST 2007 Paolo Molaro <lupus@ximian.com>
6021 * exceptions-x86.c: provide more graceful handling of the case where
6022 we followed a bogus function pointer from managed code (bug #332866).
6024 2007-10-11 Mark Probst <mark.probst@gmail.com>
6026 * mini.h, mini.c: Introduced the MonoGenericSharingContext, which
6027 replaces the generic_shared flag and will carry more information
6030 * generic-sharing.c: Added mini_type_stack_size() which allows
6031 allows open types if given a generic sharing context.
6032 mini_get_basic_type_from_generic() takes a
6033 MonoGenericSharingContext* instead of a MonoCompile* now.
6035 * mini-alpha.c, mini-amd64.c, mini-arm.c, mini-hppa.c,
6036 mini-ia64.c, mini-mips.c, mini-ppc.c, mini-s390.c, mini-s390x.c,
6037 mini-sparc.c, mini-x86.c: Trivial changes required by the two
6038 changes above. Just passing arguments through to the right
6041 Wed Oct 10 19:44:42 CEST 2007 Paolo Molaro <lupus@ximian.com>
6043 * mini-arm.c: unify the call emission to emit_code_seq().
6045 Wed Oct 10 13:05:46 CEST 2007 Paolo Molaro <lupus@ximian.com>
6047 * tramp-arm.c: reduced the trampoline size.
6049 2007-10-10 Mark Probst <mark.probst@gmail.com>
6051 * generic-sharing.c, mini.h, mini-amd64.c, mini-x86.c: Moved type
6052 variable handling out of arch-specific code.
6054 Wed Oct 10 10:49:28 CEST 2007 Paolo Molaro <lupus@ximian.com>
6056 * mini-arm.c: implemented fast delegate dispatch.
6058 2007-10-09 Zoltan Varga <vargaz@gmail.com>
6060 * mini-amd64.c (mono_arch_compute_omit_fp): Add more checks to ensure
6061 that fp elimination is turned off if the space required by locals is too
6064 Tue Oct 9 21:01:03 CEST 2007 Paolo Molaro <lupus@ximian.com>
6066 * Makefile.am, mini-arm.c, mini-arm.h, tramp-arm.c: ported
6067 ARM to the new style trampoline.
6069 2007-10-09 Zoltan Varga <vargaz@gmail.com>
6071 * tramp-amd64.c: Rework the specific trampoline code to make it smaller.
6073 * mini-amd64.h mini-amd64.c: Export amd64_patch as mono_amd64_patch.
6075 2007-10-09 Martin Baulig <martin@ximian.com>
6078 (MonoDebuggerMetadataInfo): Added `field_info_type_offset' and
6079 `field_info_offset_offset'.
6081 Tue Oct 9 09:47:51 CEST 2007 Paolo Molaro <lupus@ximian.com>
6083 * mini-ppc.c, mini-ppc.h, mini-ops.h, inssel-ppc.brg, cpu-g4.md:
6084 removed more internal usage of the r11 register and made it available
6085 to the register allocator.
6087 2007-10-08 Mark Probst <mark.probst@gmail.com>
6089 * mini.c, mini-amd64.c, mini-x86.c: Allow open generic contexts
6090 when sharing generics and treat type variables as references.
6092 Mon Oct 8 10:55:38 CEST 2007 Paolo Molaro <lupus@ximian.com>
6094 * mini-ppc.c: started removing the internal uses of register r11
6095 to eventually allow the register allocator to manage it as an
6096 additional available register.
6098 Mon Oct 8 14:25:39 CEST 2007 Paolo Molaro <lupus@ximian.com>
6100 * tramp-amd64.c: fixed memory corruption in the trampoline generation.
6102 Mon Oct 8 12:06:33 CEST 2007 Paolo Molaro <lupus@ximian.com>
6104 * tramp-ppc.c, tramp-x86.c: reduce the alignment requirements for
6105 specific trampolines as they are not performance critical as a jump
6106 target (maybe align as before only for AOT code?). This saves about
6107 200 KB of native code on x86 for monodevelop startup.
6109 Mon Oct 8 10:04:40 CEST 2007 Paolo Molaro <lupus@ximian.com>
6111 * tramp-ppc.c: reduce the size of the trampolines, saves 160KB on
6112 monodevelop startup.
6114 2007-10-06 Zoltan Varga <vargaz@gmail.com>
6116 * mini-sparc.c (mono_arch_get_vcall_slot_addr): Allow signed displacements.
6118 * mini-sparc.h mini-sparc.c: Implement IMT support.
6120 * tramp-sparc.c (mono_arch_create_trampoline_code): Rework the trampoline code so
6121 its smaller and doesn't clobber sparc_g1.
6123 * mini-sparc.c (mono_arch_get_vcall_slot_addr): Update after trampoline changes.
6125 Fri Oct 5 18:28:11 CEST 2007 Paolo Molaro <lupus@ximian.com>
6127 * mini-ppc.c: optimized the size of the IMT thunks a bit.
6129 Fri Oct 5 18:08:30 CEST 2007 Paolo Molaro <lupus@ximian.com>
6131 * mini-ppc.c: implemented fast delegate invocation.
6133 Fri Oct 5 00:01:05 CEST 2007 Paolo Molaro <lupus@ximian.com>
6135 * mini-ppc.h, mini-ppc.c: IMT support for the PPC architecture.
6137 Thu Oct 4 22:04:49 CEST 2007 Paolo Molaro <lupus@ximian.com>
6139 * mini-ppc.c, mini-ppc.h, tramp-ppc.c, Makefile.am: port the PPC
6140 code to the new style trampoline in preparation for IMT support.
6142 Thu Oct 4 19:01:59 CEST 2007 Paolo Molaro <lupus@ximian.com>
6144 * mini-ppc.c, tramp-ppc.c: don't use r13 as it's used by the PPC EABI
6145 systems already. This also reduces the specific trampiline sizes and
6146 prepares for the use of r12 as the IMT identifier register.
6148 Thu Oct 4 16:38:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
6150 * mini-mips.h: endianess fix (simplified from a patch by
6151 Thomas Kunze <thommy@tabao.de>, bug #323737).
6153 Thu Oct 4 14:43:49 CEST 2007 Paolo Molaro <lupus@ximian.com>
6155 * exceptions-ppc.c, mini-ppc.h: refactor to use macros
6156 to access ucontext fields and enable netbsd support
6157 (partially from Magnus Henoch <mange@freemail.hu>).
6159 Thu Oct 4 12:35:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
6161 * genmdesc.pl: patch from Henryk Plötz <henryk@openmoko.org> to
6162 use the preprocessor from the CPP env var if it is set.
6164 Wed Oct 3 17:11:38 CEST 2007 Paolo Molaro <lupus@ximian.com>
6166 * mini-trampolines.c: fixed an assertion and moved it earlier in the
6167 code, before interface_offset gets used.
6169 2007-10-02 Zoltan Varga <vargaz@gmail.com>
6171 * mini-trampolines.c (mono_convert_imt_slot_to_vtable_slot): Call
6172 mono_class_setup_vtable () before accessing klass->vtable.
6174 2007-10-01 Zoltan Varga <vargaz@gmail.com>
6176 * aot-compiler.c (get_plt_index): Rework the handling of wrappers to be not so
6179 Mon Oct 1 15:00:27 CEST 2007 Paolo Molaro <lupus@ximian.com>
6181 * mini.c, mini-trampolines.c, mini.h: enable the lazy filling of the
6182 IMT slots (this saves hundreds of KB of memory in programs like
6183 IronPython and Monodevelop).
6185 Mon Oct 1 14:44:19 CEST 2007 Paolo Molaro <lupus@ximian.com>
6187 * mini.c: print the delegate counter.
6189 Mon Oct 1 14:36:50 CEST 2007 Paolo Molaro <lupus@ximian.com>
6191 * mini-x86.c: make it easier to enable the debugging code for IMT
6194 2007-09-28 Martin Baulig <martin@ximian.com>
6197 (MonoDebuggerMetadataInfo): Add `klass_image_offset',
6198 `mono_method_klass_offset' and `mono_method_token_offset'.
6200 2007-09-20 Mark Probst <mark.probst@gmail.com>
6202 * mini.c: First generics sharing implementation. Can only share
6203 in very simple cases. If sharing doesn't work it falls back to
6204 dedicated compilation.
6206 * mini.h: Flag in MonoCompile to specify whether generic
6207 compilation is shared. Flags enum for marking which generic inst
6208 of a context is used. Prototypes for helper functions.
6210 * generic-sharing.c: Helper functions for generic method sharing.
6212 * optflags-def.h: Optimization flag (gshared) for enabling generic
6213 method sharing added.
6215 * Makefile.am: generic-sharing.c added.
6217 2007-09-19 Daniel Nauck <dna@mono-project.de>
6219 * mini.c (mono_thread_abort): fixed typo in r86014. It should be '==' instead of '!='.
6221 2007-09-19 Massimiliano Mantione <massi@ximian.com>
6222 * mini.c (mono_thread_abort): Correctly handle ThreadAbortException,
6225 2007-09-19 Martin Baulig <martin@ximian.com>
6227 * mini.c (mini_cleanup): Only call mono_debugger_cleanup() here;
6228 mono_debug_cleanup() is now part of mono_cleanup().
6230 2007-09-18 Zoltan Varga <vargaz@gmail.com>
6232 * driver.c (mono_main): Fix a warning.
6234 2007-09-17 Zoltan Varga <vargaz@gmail.com>
6236 * aot-compiler.c: Optimize various parts when processing large assemblies.
6239 * mini.c (mono_patch_info_hash): Improve hash function.
6241 2007-09-14 Jonathan Chambers <joncham@gmail.com>
6243 * mini-exceptions.c: Add HAVE_UNISTD_H check around include.
6245 Code is contributed under MIT/X11 license.
6247 2007-09-14 Zoltan Varga <vargaz@gmail.com>
6249 * mini.c (mini_init): Fix a leak.
6251 * debug-mini.c (mono_debug_free_method_jit_info): Fix a leak.
6253 Fri Sep 14 12:53:13 CEST 2007 Paolo Molaro <lupus@ximian.com>
6255 * mini.c: redirect string.InternalAllocStr() to the managed allocator.
6257 2007-09-14 Zoltan Varga <vargaz@gmail.com>
6259 * mini-amd64.c (mono_arch_find_imt_method): Add support for AOT code.
6261 2007-09-13 Zoltan Varga <vargaz@gmail.com>
6263 * Makefile.am generics-variant-types.2.il generics.cs: Add some generics
6266 * inssel.brg: Reorganize the isinst/castclass code to reduce code duplication.
6268 * mini.c (handle_alloc): Enable managed allocators in AOT code.
6270 * aot-compiler.c (encode_patch): Add support for MONO_WRAPPER_ALLOC.
6272 * aot-runtime.c (decode_patch_info): Ditto.
6274 2007-09-12 Jonathan Chambers <joncham@gmail.com>
6276 * mini-x86.c (mono_arch_get_delegate_invoke_impl): Implement
6277 static case. Cache delegates in architecture specific code,
6278 based on number of parameters.
6280 * mini-amd64.c (mono_arch_get_delegate_invoke_impl): Cache delegates
6281 in architecture specific code, based on number of parameters.
6283 * mini-trampolines.c (mono_delegate_trampoline): Architecture specific
6284 caching happen in architecture specific code now.
6286 Code is contributed under MIT/X11 license.
6288 2007-09-12 Jonathan Chambers <joncham@gmail.com>
6290 * mini.h, mini.c, mini-x86.c, mini-amd64.c, mini-hppa.c, mini-mips.c,
6291 mini-s390x.c, mini-arm.c, mini-ia64.c, mini-sparc.c, mini-ppc.c, mini-alpha.c,
6292 mini-s390.c: Add mono_arch_init and mono_arch_cleanup methods.
6294 Code is contributed under MIT/X11 license.
6296 2007-05-15 Massimiliano Mantione <massi@ximian.com>
6297 * mini.c: (mono_thread_abort) Fixed bug #82416.
6299 Tue Sep 11 16:15:53 CEST 2007 Paolo Molaro <lupus@ximian.com>
6301 * mini.: hook the new managed GC allocation feature into the JIT.
6303 Tue Sep 11 16:14:16 CEST 2007 Paolo Molaro <lupus@ximian.com>
6305 * mini.c: implementation for the new runtime tls opcode.
6307 2007-09-11 Martin Baulig <martin@ximian.com>
6310 (MonoDebuggerMetadataInfo): Add `mono_method_flags_offset' and
6311 `mono_method_inflated_offset'.
6313 2007-09-07 Zoltan Varga <vargaz@gmail.com>
6315 * driver.c mini.h mini.c: Add a new devel command line option for injecting
6316 async exceptions into a method.
6318 * mini-amd64.h mini-amd64.c: Implement injecting of async exceptions for the
6319 purpose of testing whenever the unwinder works at every instruction.
6321 Thu Sep 6 12:42:14 CEST 2007 Paolo Molaro <lupus@ximian.com>
6323 * mini.c: check accessibility of method used in ldftn (fixes
6326 2007-09-04 Zoltan Varga <vargaz@gmail.com>
6328 * mini-amd64.c (mono_arch_output_basic_block): Fix a warning.
6330 * inssel.brg: Fix a warning.
6332 2007-09-03 Martin Baulig <martin@ximian.com>
6334 * debug-debugger.c: `MONO_DEBUGGER_EVENT_INITIALIZE_MANAGED_CODE'
6335 now takes the `main_method' as argument.
6337 2007-09-02 Zoltan Varga <vargaz@gmail.com>
6339 * cpu-sparc.md (endfilter): Add missing src1:i argument.
6341 2007-08-30 Jonathan Chambers <joncham@gmail.com>
6343 * driver.c: include the cil-coff.h header on Windows.
6345 Code is contributed under MIT/X11 license.
6347 Thu Aug 30 16:17:23 CEST 2007 Paolo Molaro <lupus@ximian.com>
6349 * mini.c, driver.c: don't include the cil-coff.h header.
6351 Thu Aug 30 14:50:53 CEST 2007 Paolo Molaro <lupus@ximian.com>
6353 * mini.c: flag places that needs fixes fo soft-float support.
6355 Wed Aug 29 18:26:20 CEST 2007 Paolo Molaro <lupus@ximian.com>
6357 * mini.h, inssel-float.brg: fix soft-float constant loads on big
6358 endian systems (partially from Dean Jenkins, bug #81924).
6360 2007-08-28 Mark Probst <mark.probst@gmail.com>
6362 * mini.c (check_linkdemand): Remove embedded reference object in
6363 call to LinkDemandSecurityException.
6364 (mono_jit_compile_method_inner): Call LinkDemandSecurityException
6365 with an IntPtr instead of a reference object.
6367 2007-08-28 Zoltan Varga <vargaz@gmail.com>
6369 * mini.c (handle_initobj): Handle alignment properly.
6371 * inssel.brg (mini_emit_memset): Ditto.
6373 * inssel.brg (mini_emit_memcpy): Ditto.
6375 * inssel-sparc.brg: Ditto.
6377 * mini.h mini.c inssel-*.brg: Pass alignment information to OP_MEMCPY/MEMSET.
6379 2007-08-26 Zoltan Varga <vargaz@gmail.com>
6381 * mini-exceptions.c (mono_handle_exception_internal): Skip the first frame for
6382 exceptions raised in unmanaged code. Fixes part of #82594.
6384 2007-08-24 Mark Probst <mark.probst@gmail.com>
6386 * mini.c (mono_method_to_ir), declsec.c
6387 (mono_declsec_linkdemand_aptc): Fixed custom attr leaks.
6389 2007-08-22 Martin Baulig <martin@ximian.com>
6392 (MonoDebuggerThreadInfo): New typedef.
6393 (mono_debugger_thread_table): New global variable.
6394 (mono_debugger_thread_created): New public function.
6395 (mono_debugger_thread_cleanup): New public function.
6399 - removed `get_current_thread' and `lookup_assembly'.
6400 - removed `data_table'.
6401 - added `thread_table'.
6404 (mono_thread_start_cb): Call mono_debugger_thread_created().
6405 (mono_thread_attach_cb): Likewise.
6406 (mini_thread_cleanup): Call mono_debugger_thread_cleanup().
6407 (mini_cleanup): Move mono_debug_cleanup() down, after free'ing the
6410 * driver.c (mono_main): Move mono_debug_init() up, before calling
6411 mini_init(); mono_debug_init_1() and mono_debug_init_2() are gone.
6413 Tue Aug 21 16:40:04 CEST 2007 Paolo Molaro <lupus@ximian.com>
6415 * mini-x86.c, inssel-x86.brg: group multiple stack adjustments
6416 together when passing several arguments of type double (gives a small
6417 speedup and saves a few bytes of generated code).
6419 2007-08-20 Jb Evain <jbevain@novell.com>
6421 * mini.c (mono_method_to_ir): fix leak on InvalidProgramException.
6423 2007-08-20 Jb Evain <jbevain@novell.com>
6425 * mini.c (mono_method_to_ir): throw MethodAccessException
6426 and FieldAccessException instead of InvalidProgramException.
6428 2007-08-20 Mark Probst <mark.probst@gmail.com>
6430 * mini.c: CoreCLR security checks.
6432 * mini.h: Removed MonoSecurityMode (moved to
6433 metadata/security-manager.h) and mono_security_mode global var
6434 (replaced by set/get functions in security-manager.h).
6436 * driver.c: Added "core-clr-test" security mode for testing. Used
6437 set-function for setting security mode.
6439 2007-08-17 Mark Probst <mark.probst@gmail.com>
6441 * mini.c: MonoJitInfo's are freed hazardously now. Statistics for
6442 the new jit_info_table.
6444 * driver.c: Test code for the new jit_info_table (enabled by the
6445 define MONO_JIT_INFO_TABLE_TEST).
6447 2007-08-14 Zoltan Varga <vargaz@gmail.com>
6449 * tramp-amd64.c (mono_arch_nullify_class_init_trampoline): Fix
6450 detection of call <REG> instruction sequence. Fixes build on freebsd.
6452 2007-08-13 Zoltan Varga <vargaz@gmail.com>
6454 * mini-exceptions.c: Fix a warning.
6456 2007-08-11 Zoltan Varga <vargaz@gmail.com>
6458 * exceptions-amd64.c (mono_arch_handle_altstack_exception): Enable the new
6459 stack overflow handling code on amd64 too.
6461 * mini-exceptions.c (mono_setup_altstack): Make this use
6462 mono_thread_get_stack_bounds ().
6464 * mini-x86.h: Disable sigaltstack on solaris x86.
6466 2007-08-10 Zoltan Varga <vargaz@gmail.com>
6468 * mini-exceptions.c (mono_setup_altstack): Enable this to work on solaris x86.
6470 2007-08-10 Geoff Norton <gnorton@customerdna.com>
6472 * tramp-x86.c: Remove some unneeded alignment changes on Apple. Fixes #82387.
6474 2007-08-08 Zoltan Varga <vargaz@gmail.com>
6476 * mini-exceptions.c (mono_print_thread_dump): Enable this on amd64 too.
6478 * mini-amd64.h (MONO_INIT_CONTEXT_FROM_FUNC): Fix a warning.
6480 2007-08-03 Neale Ferguson <neale@sinenomine.net>
6482 * mini-s390.c (add_general): Adjust offset calculation to take into account of rounding up
6485 Thu Aug 2 17:36:22 CEST 2007 Paolo Molaro <lupus@ximian.com>
6487 * mini-ppc.c: avoid an invalid encoding of unsigned right shift by 0
6488 to be emitted (bug #82281).
6490 2007-08-01 Martin Baulig <martin@ximian.com>
6492 Merged the `debugger-dublin' branch.
6494 * debug-debugger.h (MonoDebuggerInfo):
6495 Removed the `old_*' compatibility entries.
6496 Added `debugger_version' and `data_table'.
6497 Renamed `get_method_addr_or_bpt' -> `insert_breakpoint'.
6498 Renamed `remove_method_breakpoint' -> `remove_breakpoint'.
6501 (MiniDebugMethodBreakpointInfo): Add `address_list'.
6502 (mono_debugger_check_breakpoints): Take a `MonoDebugMethodAddress *'
6503 instead of a `gconstpointer'.
6504 (mono_debugger_insert_method_breakpoint): Return a
6505 `MonoDebugMethodAddressList *'.
6507 2007-06-28 Martin Baulig <martin@ximian.com>
6509 * debug-debugger.h (MonoDebuggerInfo): Added `debugger_version'.
6511 2007-08-01 Zoltan Varga <vargaz@gmail.com>
6513 * mini-amd64.h (MONO_INIT_CONTEXT_FROM_FUNC): Avoid using
6514 __builtin_frame_address () since it is broken on older gcc versions.
6516 Tue Jul 31 17:34:42 CEST 2007 Paolo Molaro <lupus@ximian.com>
6518 * mini.c, mini.h, mini-exceptions.c: added a bit of documentation
6519 on the stack overflow handling and made the managed stack overflows
6520 catchable in most cases using soft guard pages.
6521 * exceptions-x86.c: added code to restore the protection in the soft
6522 guard pages at the end of exception handling.
6524 2007-07-31 Zoltan Varga <vargaz@gmail.com>
6526 * mini.c (SIG_HANDLER_SIGNATURE): Fix a warning.
6528 Mon Jul 30 17:43:13 CEST 2007 Paolo Molaro <lupus@ximian.com>
6530 * exceptions-ppc.c, mini-ppc.h: arch-specific stack overflow
6533 Mon Jul 30 17:38:13 CEST 2007 Paolo Molaro <lupus@ximian.com>
6535 * mini-alpha.h, mini-ia64.h, mini-sparc.h: disable the altstack
6536 signal handling support until it has been ported to the new mechanism.
6537 * mini.c: fixed stack overflow detection and use the new
6538 architecture code to handle signals on the altstack.
6540 Mon Jul 30 17:33:02 CEST 2007 Paolo Molaro <lupus@ximian.com>
6542 * exceptions-amd64.c, mini-amd64.h: amd64 code to handle
6543 stack overflows on the alt stack.
6545 Mon Jul 30 17:29:56 CEST 2007 Paolo Molaro <lupus@ximian.com>
6547 * exceptions-x86.c, mini-x86.h, mini.h: new code to handle
6548 stack overflows on the alt stack.
6550 Mon Jul 30 11:50:06 CEST 2007 Paolo Molaro <lupus@ximian.com>
6552 * exceptions-ppc.c: cleanup preparing for altstack support.
6554 Mon Jul 30 11:31:24 CEST 2007 Paolo Molaro <lupus@ximian.com>
6556 * exceptions-arm.c: cleanup preparing for altstack support.
6558 2007-07-27 Mark Probst <mark.probst@gmail.com>
6560 * mini.c (print_jit_stats): Output hazard pointer stats.
6562 2007-07-26 Mark Probst <mark.probst@gmail.com>
6564 * driver.c, mini.c: Replaced security mode flags with a single
6567 Thu Jul 26 20:12:12 CEST 2007 Paolo Molaro <lupus@ximian.com>
6569 * mini.c, mini-exceptions.c: cleanup the sigaltstack code.
6571 2007-07-25 Mark Probst <mark.probst@gmail.com>
6573 * mini.c, mini.h, driver.c (mono_main): Added command-line flag
6574 (which doesn't do anything yet) for activating Core CLR
6575 (Silverlight) security.
6577 Tue Jul 24 21:16:17 CEST 2007 Paolo Molaro <lupus@ximian.com>
6579 * mini-codegen.c: work around a possible gcc bug on arm.
6581 Tue Jul 24 17:20:19 CEST 2007 Paolo Molaro <lupus@ximian.com>
6583 * driver.c, mini-x86.h, mini-amd64.h: print a nice error
6584 message for platforms that don't support AOT compilation.
6586 Mon Jul 23 10:29:29 CEST 2007 Paolo Molaro <lupus@ximian.com>
6588 * mini.h, mini.c, driver.c: temporary smcs hack.
6590 Mon Jul 23 09:29:34 CEST 2007 Paolo Molaro <lupus@ximian.com>
6592 * mini-arm.h, mini-arm.c: arm EABI fixes.
6594 2007-07-22 Zoltan Varga <vargaz@gmail.com>
6596 * exceptions-x86.c (mono_arch_find_jit_info): Handle the lmf->method == NULL
6599 * tramp-x86.c (mono_arch_create_trampoline_code): Only set lmf->method for
6600 trampolines taking a method argument.
6602 * mini-x86.h (MonoLMF): Add an 'esp' field plus comments.
6604 * mini-x86.c (mono_arch_emit_prolog): Update after changes to the LMF structure.
6605 * tramp-x86.c (mono_arch_create_trampoline_code): Ditto.
6607 * exceptions-x86.c (mono_arch_get_jit_info): Properly clean up the stack after
6608 JIT compilation throws an exception. Fixes #82050.
6610 2007-07-19 Mark Probst <mark.probst@gmail.com>
6612 * mini.c: Removed the MonoLoaderErrorKind enum and replaced it
6613 with the MONO_EXCEPTION_ defines.
6615 2007-07-17 Zoltan Varga <vargaz@gmail.com>
6617 * mini-amd64.c (mono_arch_find_imt_method): Handle mov reg,IMM64 case. Fixes
6620 * mini-amd64.c (mono_arch_find_imt_method): Add some debug code to help find out
6621 the cause of an assertion.
6623 Mon Jul 16 19:31:21 CEST 2007 Paolo Molaro <lupus@ximian.com>
6625 * mini.c, jit-icalls.c: mono_get_inflated_method() is obsolete,
6628 2007-07-15 Zoltan Varga <vargaz@gmail.com>
6630 * mini-amd64.c (mono_arch_build_imt_thunk): Remove the non-32bit MonoMethod
6631 assert. Should fix #82103.
6633 2007-07-14 Zoltan Varga <vargaz@gmail.com>
6635 * mini-exceptions.c (mono_jit_walk_stack_from_ctx): Use MONO_CONTEXT_GET_SP ()
6636 here too. Fixes #82095.
6638 * mini-amd64.c (mono_arch_build_imt_thunk): Add support for non-32bit MonoMethod
6641 * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add a couple asserts.
6643 * mini-amd64.h: Enable IMT for amd64.
6645 * mini-amd64.c (mono_arch_build_imt_thunk): Optimize IMT thunk size.
6647 2007-07-12 Zoltan Varga <vargaz@gmail.com>
6649 * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add support for IMT call sequences.
6651 2007-07-12 Mark Probst <mark.probst@gmail.com>
6653 * mini.c (check_linkdemand, mono_method_to_ir): Abort compilation
6654 as soon as check_linkdemand sets an exception_type.
6656 Thu Jul 12 12:18:22 CEST 2007 Paolo Molaro <lupus@ximian.com>
6658 * mini-x86.c: fixed offsets for IMT call sequence.
6659 * mini-x86.h: enable IMT again.
6661 2007-07-11 Zoltan Varga <vargaz@gmail.com>
6663 * trace.c (mono_trace_enter_method): Decode MonoType too.
6665 * mini-amd64.c (mono_arch_get_vcall_slot_addr): Handle signed displacements too.
6667 * mini.h mini-x86.h mini-trampolines.c: Change the signature of mono_arch_find_imt_method () to pass the calling code address too.
6669 * mini-amd64.c: Add preliminary IMT implementation.
6671 Wed Jul 11 18:21:30 CEST 2007 Paolo Molaro <lupus@ximian.com>
6673 * mini-x86.c: adjusted mono_arch_get_vcall_slot_addr () to
6674 understand the new IMT-base interface invocation (thanks to
6675 Daniel Nauck for the report and the remote debugging session).
6677 Wed Jul 11 14:54:39 CEST 2007 Paolo Molaro <lupus@ximian.com>
6679 * mini-x86.c: size and speed optimizations for the IMT bsearch.
6681 2007-07-11 Zoltan Varga <vargaz@gmail.com>
6683 * Makefile.am (aotcheck): Make this actually use the AOTed code.
6685 Wed Jul 11 12:41:32 CEST 2007 Paolo Molaro <lupus@ximian.com>
6687 * mini-trampolines.c: implement AOT IMT support.
6688 * mini-x86.h: enable IMT support for wider testing.
6690 2007-07-10 Zoltan Varga <vargaz@gmail.com>
6692 * inssel.brg (emit_imt_argument): Add aot support here.
6694 * aot-runtime.c (decode_patch_info): Fix reading of MONO_PATCH_INFO_METHOD.
6696 Tue Jul 10 17:50:58 CEST 2007 Paolo Molaro <lupus@ximian.com>
6698 * mini-x86.c, mini-x86.h, tramp-x86.c: x86 arch-specific changes
6699 of the IMT implementation, partially from massi, with my
6700 implementation of the bsearch sequence. Disabled by default until
6701 the AOT code is implemented.
6703 2007-07-10 Zoltan Varga <vargaz@gmail.com>
6705 * cpu-x86.md: The source argument of sext_i1/i2 must by a byte reg.
6707 * inssel-x86.brg: Add reg:ldind.i1(regvar) rules. Fixes #82056.
6709 Tue Jul 10 17:33:12 CEST 2007 Paolo Molaro <lupus@ximian.com>
6711 * inssel.brg, mini.c, mini.h, mini-trampolines.c:
6712 arch-independent IMT JIT code from Massimiliano
6713 Mantione (massi@ximian.com) with small cleanups from me.
6715 Tue Jul 10 13:07:24 CEST 2007 Paolo Molaro <lupus@ximian.com>
6717 * Makefile.am: fix svn invocation to get the svn revision to be
6718 independent of the local language (build fix).
6720 2007-07-09 Mark Probst <mark.probst@gmail.com>
6722 * mini.c (inline_method): Reset cfg->exception_type if the
6723 inlining is aborted. Fixes: 82049.
6725 Mon Jul 9 17:26:47 CEST 2007 Paolo Molaro <lupus@ximian.com>
6727 * mini.c: remove assert from exception handling code when exception_ptr
6730 2007-07-05 Zoltan Varga <vargaz@gmail.com>
6732 * mini.c (mono_codegen): Add an assert.
6734 * mini-x86.c (mono_arch_emit_prolog): Allocate space for the profiler method
6735 enter and leave code.
6736 * mini-amd64.c (mono_arch_emit_prolog): Likewise.
6738 Thu Jul 5 20:12:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
6740 * mini-ppc.c: fixed memory corruption for localloc(0)
6743 2007-07-05 Zoltan Varga <vargaz@gmail.com>
6745 * mini.c: Fix warnings.
6747 Wed Jul 4 15:30:36 CEST 2007 Paolo Molaro <lupus@ximian.com>
6749 * optflags-def.h, mini-x86.c: added sse2 optimization flag and use it
6750 to emit better double->int conversions.
6752 Tue Jul 3 19:42:16 CEST 2007 Paolo Molaro <lupus@ximian.com>
6754 * mini.c: the provided Min/Max optimizations are valid for unisgned
6757 2007-07-03 Rodrigo Kumpera <rkumpera@novell.com>
6759 * 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
6761 2007-06-28 Miguel de Icaza <miguel@novell.com>
6763 * mini.c (mono_running_on_valgrind): Add support for reporting the
6764 method and its boundaries to valgrind.
6766 2007-06-28 Martin Baulig <martin@ximian.com>
6768 * debug-debugger.h (MonoDebuggerInfo): Added `debugger_version'.
6770 2007-06-25 Zoltan Varga <vargaz@gmail.com>
6772 * ssa.c (visit_inst): Add support for OP_BR. Fixes #81946.
6774 * generic.2.cs: Add new test case.
6776 2007-06-25 Martin Baulig <martin@ximian.com>
6778 Merged the `debugger-dublin' branch.
6781 (mono_debugger_insert_method_breakpoint): New public method.
6782 (mono_debugger_remove_method_breakpoint): Likewise.
6783 (mono_debugger_check_breakpoints): New static method.
6784 (mono_debug_close_method): Call mono_debugger_check_breakpoints().
6786 * debug-debugger.h (MonoDebuggerInfo):
6787 Renamed (to keep backward compatibility in the vtable):
6788 `insert_breakpoint' -> `old_insert_breakpoint'.
6789 `remove_breakpoint' -> `old_remove_breakpoint'.
6790 `create_string' -> `old_create_string'.
6791 `lookup_class' -> `old_lookup_class'.
6792 `lookup_type' -> removed; changed into a dummy field.
6793 `lookup_assembly' -> `old_lookup_assembly'.
6794 Added (same functionality, but different signature):
6795 `create_string', `lookup_class', `lookup_assembly'
6797 `get_method_addr_or_bpt', `remove_method_breakpoint',
6798 `runtime_class_init'.
6800 * debug-debugger.c: Merged the `debugger-dublin' branch.
6802 2007-06-23 Zoltan Varga <vargaz@gmail.com>
6804 * mini-amd64.c (peephole_pass_1): Optimize away moves at the beginning of the bb as
6806 (peephole_pass): Likewise.
6808 Fri Jun 22 09:17:08 CEST 2007 Paolo Molaro <lupus@ximian.com>
6810 * driver.c: hopefully make setaffinity work also for ancient
6813 2007-06-22 Atsushi Enomoto <atsushi@ximian.com>
6815 * driver.c : win32 build fix.
6817 Thu Jun 21 19:24:03 CEST 2007 Paolo Molaro <lupus@ximian.com>
6819 * driver.c: check for the MONO_NO_SMP env var and bind to a single
6820 processor if it is set.
6822 2007-06-21 Martin Baulig <martin@ximian.com>
6824 * debug-mini.h: New file.
6827 (mono_debugger_insert_breakpoint_full): Moved here from
6828 ../metadata/mono-debug-debugger.c.
6829 (mono_debugger_remove_breakpoint): Likewise.
6830 (mono_debugger_breakpoint_callback): Likewise.
6832 2007-06-15 Raja R Harinath <rharinath@novell.com>
6834 * jit-icalls.c (mono_helper_compile_generic_method): Update to
6835 changes in MonoGenericClass.
6837 2007-06-14 Zoltan Varga <vargaz@gmail.com>
6839 * mini-codegen.c (mono_opcode_to_type): Fix ia64 build.
6841 2007-06-14 Raja R Harinath <rharinath@novell.com>
6843 * jit-icalls.c (mono_helper_compile_generic_method): Update to
6844 removal of MonoGenericMethod.
6846 Thu Jun 14 12:42:04 CEST 2007 Paolo Molaro <lupus@ximian.com>
6848 * mini-exceptions.c: hooks for the exception events profiling API.
6850 2007-06-14 Randolph Chung <tausq@debian.org>
6852 * Makefile.ma: Add hppa target.
6853 * mini-arch.h: Include mini-hppa.h
6854 * cpu-hppa.md, exceptions-hppa.c, inssel-hppa.brg, mini-hppa.c,
6855 mini-hppa.h, tramp-hppa.c: New files for 32-bit HPPA port.
6856 Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
6858 2007-06-14 Randolph Chung <tausq@debian.org>
6860 * inssel.brg: Add rules for "chained" compare-branch operations so that
6861 a single compare op can affect multiple branches. Adjust cost for
6862 OP_CEQ/OP_CGT/OP_CGT_UN/OP_CLT/OP_CLT_UN.
6863 * inssel-long32.brg: Update rules to use compare-branch macros. Adjust
6864 cost for some rules so that they can more easily be overridden by
6865 per-arch rules (with fixes from lupus).
6866 Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
6868 2007-06-13 Randolph Chung <tausq@debian.org>
6870 * mini-ops.h: Reorder branch ops so that they match the order of the
6871 corresponding CEE_* ops. The code expects them this way.
6872 Add new ops for HPPA target.
6873 Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
6875 2007-06-13 Randolph Chung <tausq@debian.org>
6877 * mini-exceptions.c: Handle cases where the stack grows towards
6879 Contributed under the X11 license (http://bugzilla.ximian.com/show_bug.cgi?id=81866).
6881 Wed Jun 13 19:13:23 CEST 2007 Paolo Molaro <lupus@ximian.com>
6883 * jit-icalls.c, mini.h, mini.c: added virtual generic invoke
6885 * driver.c: explain where a non-matching corlib is found.
6887 2007-06-13 Mark Probst <mark.probst@gmail.com>
6889 * mini.c (print_jit_stats): Output dynamic code allocation stats.
6891 2007-06-10 Sanghyeon Seo <sanxiyn@gmail.com>
6893 * mini-exceptions.c: Generate a method profile leave event during
6894 an exception to ensure that the profiler gets notified.
6896 2007-06-07 Zoltan Varga <vargaz@gmail.com>
6898 * mini-amd64.c (peephole_pass): Merge some small changes from the linear-ir
6901 * cpu-amd64.md: Add long_and/or/xor opcodes.
6903 2007-06-06 Wade Berrier <wberrier@novell.com>
6905 * cpu-s390x.md (shr_imm): Correct the length of shr_imm instruction.
6906 (./class/lib/monolite/mcs.exe:25498): WARNING **: wrong maximal instruction
6907 length of instruction shr_imm (expected 8, got 10)
6909 2007-06-06 Zoltan Varga <vargaz@gmail.com>
6911 * mini-ia64.c (mono_arch_output_basic_block): Really fix the build.
6913 2007-06-06 Mark Probst <mark.probst@gmail.com>
6915 * mini.c, driver.c: Changed MonoDomain.jit_code_hash to a
6916 MonoInternalHashTable again (fixed bug in the internal hash table
6919 2007-06-06 Mark Probst <mark.probst@gmail.com>
6921 * mini.c, driver.c: Reverted the MonoInternalHashTable changes.
6922 Have to figure out what makes it crash the SWF regression.
6924 2007-06-05 Zoltan Varga <vargaz@gmail.com>
6926 * mini-ia64.c (mono_arch_lowering_pass): Fix ia64 build.
6928 Tue Jun 5 17:40:04 CEST 2007 Paolo Molaro <lupus@ximian.com>
6930 * mini.c: optimize out the type check when storing null in a
6933 2007-06-04 Mark Probst <mark.probst@gmail.com>
6935 * mini.c, driver.c: Changed MonoDomain.jit_code_hash to a
6936 MonoInternalHashTable.
6938 Mon Jun 4 11:29:43 CEST 2007 Paolo Molaro <lupus@ximian.com>
6940 * inssel.brg, mini.c, mini-ops.h: optimized Math.Mini/Max
6941 signed integer methods.
6943 2007-06-02 Zoltan Varga <vargaz@gmail.com>
6945 * mini-x86.c (mono_arch_get_delegate_invoke_impl): Disable the static case
6946 permanently since the current approach doesn't work.
6948 2007-06-02 Zoltan Varga <vargaz@gmail.com>
6950 * inssel.brg (stmt): Only call delegate->invoke_impl if
6951 MONO_ARCH_HAVE_CREATE_DELEGATE_TRAMPOLINE is defined.
6953 2007-06-01 Zoltan Varga <vargaz@gmail.com>
6955 * mini-amd64.c (mono_arch_output_basic_block): Unify div/rem opcodes and handle
6956 the sreg2==rdx case.
6958 * mini-amd64.c cpu-amd64.md: Correct length of r4const instruction and take into
6959 account if it contains a rex prefix.
6960 (peephole_pass): Handle OP_FMOVE as well.
6962 2007-06-01 Zoltan Varga <vargaz@gmail.com>
6964 * mini-x86.c (mono_arch_get_delegate_invoke_impl): Disable the static case for now
6965 as it causes regressions.
6967 2007-05-31 Zoltan Varga <vargaz@gmail.com>
6969 * mini-x86.c (mono_arch_get_delegate_invoke_impl): Implement support for the
6970 static case as well.
6972 * tramp-ia64.c (mono_arch_create_trampoline_code): Fix ia64 build.
6974 * mini-x86.c (mono_arch_get_delegate_invoke_impl): New arch dependent function.
6975 (mono_arch_get_this_arg_from_call): Ditto.
6977 * tramp-x86.c (mono_arch_patch_delegate_trampoline): Removed.
6979 * inssel.brg (mini_emit_virtual_call): Call delegate->Invoke through the delegate's
6982 * mini-amd64.c (mono_arch_get_delegate_invoke_impl): New arch dependent function.
6983 (mono_arch_get_this_arg_from_call): Ditto.
6985 * tramp-amd64.c (mono_arch_patch_delegate_trampoline): Removed.
6987 * mini-trampolines.c (mono_delegate_trampoline): Complete rewrite. On first call,
6988 try to create optimized invoke code and use that for further invocations.
6989 Otherwise, use the original mono_marshal_get_delegate_invoke () implementation.
6991 * mini-x86.h mini-ia64.h: Remove MONO_ARCH_HAS_CREATE_DELEGATE_TRAMPOLINE for now.
6993 2007-05-29 Rodrigo Kumpera <kumpera@gmail.com>
6995 * inssel.brg (mini_emit_virtual_call): Statically dispatch virtual calls to
6996 sealed classes or methods.
6997 *devirtualization.cs: tests for the new optimization
6999 2007-05-29 Zoltan Varga <vargaz@gmail.com>
7001 * liveness.c (update_gen_kill_set): No need to set VOLATILE flags here, it is done
7002 by the update_volatile () function.
7004 2007-05-27 Zoltan Varga <vargaz@gmail.com>
7006 * driver.c (mono_main): Call g_thread_init () early since newer glib versions
7009 * abcremoval.c (mono_perform_abc_removal): Avoid using alloca.
7011 2007-05-24 Jonathan Chambers <joncham@gmail.com>
7013 * mini.c: Add configure checks for header files.
7014 * mini-x86.c: Add configure checks for header files.
7015 * trace.c: Add configure checks for header files.
7016 * aot-runtime.c: Add configure checks for header files.
7017 * aot-compiler.c: Add configure checks for header files.
7018 * driver.c: Add configure checks for header files.
7019 * mini-codegen.c: Add configure checks for header files.
7021 Code is contributed under MIT/X11 license.
7023 2007-05-22 Zoltan Varga <vargaz@gmail.com>
7025 * mini-ia64.c (mono_arch_lowering_pass): Fix the handling of
7026 icompare_imm -128 + op_iclt. Fixes #81703.
7028 2007-05-19 Zoltan Varga <vargaz@gmail.com>
7030 * mini-codegen.c (mono_local_regalloc): Fix long-shift-regalloc on amd64.
7032 2007-05-15 Massimiliano Mantione <massi@ximian.com>
7034 * inssel.brg: added "mini_emit_load_intf_bit_reg_vtable", and used it
7035 inside "mini_emit_isninst_iface_cast" and "mini_emit_castclass_iface"
7036 so that all isinst checks now use "interface_bitmap".
7038 2007-05-15 Zoltan Varga <vargaz@gmail.com>
7040 * cpu-amd64.md (jmp): Fix a warning.
7042 * inssel.brg (CEE_SWITCH): Hopefully fix #80738.
7044 * basic.cs: Add new regression test.
7046 * basic.cs: Remove test which is now in basic-long.cs.
7048 * mini-ia64.c (mono_arch_output_basic_block): Sign extend in CEE_CONV_I8/CEE_CONV_I.
7050 * basic-long.cs: Add new test.
7052 2007-05-13 Zoltan Varga <vargaz@gmail.com>
7054 * mini-sparc.c (mono_spillvar_offset_float): Fix sparc build.
7056 2007-05-12 Zoltan Varga <vargaz@gmail.com>
7058 * cpu-x86.md minix-86.c: Add a peephole_pass_1 () as on amd64.
7060 * mini-x86.c (mono_arch_output_basic_block): Use mono_opcode_to_cond () in a few
7063 * mini-x86.c (mono_arch_emit_exceptions): Decrease the size of the exception
7064 throwing code a bit.
7066 * exceptions-x86.c (mono_arch_get_throw_corlib_exception): Decrease the size of
7067 the exception throwing code a bit.
7069 * mini-x86.c (get_call_info): Allocate result from a mempool.
7071 2007-05-11 Zoltan Varga <vargaz@gmail.com>
7073 * aot-compiler.c (find_typespec_for_class): Fix the assert.
7075 * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file version.
7077 * mini.h (MonoCompile): Add 'token_info_hash' field.
7079 * mini.c: Save token->method associations during compilation so the AOT
7080 compiler can use it.
7082 * aot-compiler.c aot-runtime.c: Add support for compiling non-generic methods
7083 which reference generic classes and methods.
7085 2007-05-10 Zoltan Varga <vargaz@gmail.com>
7087 * mini.h mini-<ARCH>.h: Get rid of MONO_ARCH_HAS_XP_LOCAL_REGALLOC.
7089 * aot-compiler.c (compile_method): Fix a typo in a comment.
7091 * aot-runtime.c (decode_cached_class_info): Skip generic types.
7093 * aot-compiler.c: Add minimal support for AOTing generic code by skipping
7096 * mini.c (mono_method_to_ir): Disable AOT when calling helper_compile_generic_method.
7098 2007-05-09 Zoltan Varga <vargaz@gmail.com>
7100 * mini.h (MonoCompile): Add 'args' field.
7102 * mini.c (mono_compile_create_vars): Store variables representing the arguments
7105 * mini-<ARCH>.c: Use cfg->args for accessing the method arguments.
7107 2007-05-08 Zoltan Varga <vargaz@gmail.com>
7109 * mini.c (mono_compile_get_interface_var): Remove this unused function.
7111 * mini-ops.h inssel.brg mini-<ARCH>.c: Add a new opcode for ckfinite as well.
7113 * mini-ops.h: Introduce new opcodes used in the IR instead of the original CEE_
7114 opcodes for some opcodes.
7116 * mini.h *.brg *.c: Use the new opcodes.
7118 2007-05-08 Massimiliano Mantione <massi@ximian.com>
7120 * mini.h: Bumped aot revision.
7122 * inssel.brg: modified code generation of type checks for interfaces
7123 to use the new "MonoClass.interface_bitmap" instead of the old
7124 "MonoClass.interface_offsets".
7126 2007-04-30 Zoltan Varga <vargaz@gmail.com>
7128 * cpu-amd64.md (jmp): Increase the maximum size of the jmp opcode to 128.
7130 2007-04-29 Zoltan Varga <vargaz@gmail.com>
7132 * abcremoval.c (summarize_integer_value): Handle OP_LCONV_TO_I4 to fix abcrem on
7135 2007-04-27 Neale Ferguson <neale@sinenomine.net>
7137 * mini-s390x.c: Fix MONO_TYPE_VALUETYPE processing.
7139 2007-04-27 Wade Berrier <wberrier@novell.com>
7141 * mini-s390x.c: Remove redeclaration of CompRelation and CompType (defined in
7142 mini.h) to fix build.
7144 2007-04-26 Zoltan Varga <vargaz@gmail.com>
7146 * mini-amd64.c (peephole_pass_1): Fix and reenable this pass.
7148 * mini-amd64.c (mono_arch_local_regalloc): Disable the new peephole_pass_1 as it
7149 causes the corlib unit tests to fail.
7151 2007-04-25 Zoltan Varga <vargaz@gmail.com>
7153 * mini-codegen.c (mono_opcode_to_type): Fix a bug in the previous patch.
7155 * mini-amd64.c (peephole_pass_1): New pass to perform before local regalloc.
7157 * mini-codegen.c (mono_opcode_to_cond): New helper function to convert conditional
7158 opcodes to the comparison relations.
7160 * mini-codegen.c (mono_opcode_to_type): New helper function to convert conditional
7161 opcodes to their types.
7163 * mini-ia64.c mini-amd64.c: Use mono_opcode_to_cond and mono_opcode_to_type.
7165 * mini-amd64.c (get_call_info): Allocate the result from the cfg mempool and cache
7166 it in cfg->arch.cinfo.
7168 * local-propagation.c (mono_local_cprop_bb): Fix a warning.
7170 * mini.h mini.c branch-opts.c: Change bbhash to be an array and store it in
7171 cfg->cil_offset_to_bb.
7173 2007-04-24 Zoltan Varga <vargaz@gmail.com>
7175 * liveness.c (optimize_initlocals): New mini-pass to optimize away dead assignments
7176 created becase of initlocals.
7178 2007-04-23 Zoltan Varga <vargaz@gmail.com>
7180 * mini-alpha.c cpu-alpha.md: More alpha port work from
7181 Sergey Tikhonov <tsv@solvo.ru>.
7183 2007-04-21 Andreas Faerber <andreas.faerber@web.de>
7185 * Makefile.am (BUILT_SOURCES): Fix for automake 1.6.x. Fixes #81417.
7187 2007-04-19 Zoltan Varga <vargaz@gmail.com>
7189 * cpu-s390.md (break): Correct the length of break instruction.
7191 Thu Apr 19 16:28:52 CEST 2007 Paolo Molaro <lupus@ximian.com>
7193 * mini.c: fix a couple of soft-float issues and comments.
7195 2007-04-15 Miguel de Icaza <miguel@novell.com>
7197 * trace.c (is_filenamechar): - is also a filename char.
7199 2007-04-15 Neale Ferguson <neale@sinenomine.net>
7201 * mini-s390.c: Correct checking for enum type in return value processing.
7203 2007-04-14 Raja R Harinath <rharinath@novell.com>
7205 * Makefile.am (BUILT_SOURCES): Add 'version.h'.
7206 (version.h): Makefile is in the build directory.
7208 2007-04-06 Andreas Faerber <andreas.faerber@web.de>
7210 * mini-amd64.h: fix for assertion failure on Solaris/amd64
7212 2007-04-11 Martin Baulig <martin@ximian.com>
7214 * mini.c (can_access_member): Fix handling of generic classes;
7217 2007-04-10 Zoltan Varga <vargaz@gmail.com>
7219 * aot-runtime.c (mono_aot_plt_resolve): Fix disabling of AOT. Fixes #81316.
7221 2007-04-05 Zoltan Varga <vargaz@gmail.com>
7223 * aot-runtime.c: Fix disabling of AOT. Fixes #81316.
7225 Fri Mar 23 20:25:31 CET 2007 Paolo Molaro <lupus@ximian.com>
7227 * mini-codegen.c: make sure the right spill amount is
7228 used for fp or integer registers (fixes the float_sub_spill() on ppc).
7230 Fri Mar 23 19:43:35 CET 2007 Paolo Molaro <lupus@ximian.com>
7232 * mini-ppc.c: fixes for the fp_branch_nan test.
7234 2007-03-23 Zoltan Varga <vargaz@gmail.com>
7236 * basic.cs: Comment out new test which still fails on ia64.
7238 Fri Mar 23 15:54:23 CET 2007 Paolo Molaro <lupus@ximian.com>
7240 * mini.c: immediate shifted or fix (mono_metadata_user_string assert).
7242 Fri Mar 23 12:53:28 CET 2007 Paolo Molaro <lupus@ximian.com>
7244 * mini-ppc.c, mini-ppc.h: struct passing ABI fix (bug #77968).
7246 2007-03-22 Zoltan Varga <vargaz@gmail.com>
7248 * cfold.c (FOLD_BINOP): Cast the result to gint32 to prevent overflow problems
7249 on 64 bit machines. Fixes part of #80738.
7251 * basic.cs: Add regression test.
7253 2007-03-17 Zoltan Varga <vargaz@gmail.com>
7255 * inssel.brg basic.cs: Revert previous change to fix build.
7257 * inssel.brg (SWITCH): Clean out the upper word of the switch value on 64 bit
7260 * inssel.brg (SWITCH): Use an integer comparison. Fixes #80738.
7262 * basic.cs: Add new regression test.
7264 2007-03-17 Zoltan Varga <vargaz@gmail.com>
7266 * mini-ia64.c (mono_arch_emit_prolog): Fix an assert when a function has too
7269 2007-03-16 Neale Ferguson <neale@sinenomine.net>
7271 * cpu-s390x.md: Correct length of break instruction.
7273 2007-03-16 Neale Ferguson <neale@sinenomine.net>
7275 * mini-s390x.c, cpu-s390x.md: Fix #80507 for s390x.
7276 * mini-s390.c, cpu-s390.md: Fix #80507 for s390.
7278 2007-03-15 Jonathan Chambers <joncham@gmail.com>
7280 * *.c: Begin WIN64 port.
7281 * mini.c: Use correct register in profiler.
7282 * mini-amd64.c: No inline assembly on Win64.
7283 * mini-amd64.h: Implement MONO_INIT_CONTEXT_FROM_FUNC for Win64.
7284 Only define MONO_ARCH_USE_SIGACTION on non-windows platforms.
7285 * exceptions-amd64.c: Only need gregs_from_ucontext if MONO_ARCH_USE_SIGACTION
7286 is defined. Implement mono_arch_sigctx_to_monoctx, mono_arch_monoctx_to_sigctx, and
7287 mono_arch_ip_from_context for Win64.
7289 Contributed under MIT/X11 license.
7291 2007-03-15 Zoltan Varga <vargaz@gmail.com>
7293 * exceptions-amd64.c (seh_handler): Ditto.
7295 * exceptions-x86.c (seh_handler): Fix a memory leak.
7297 Thu Mar 15 13:47:59 CET 2007 Paolo Molaro <lupus@ximian.com>
7299 * mini-arm.c, mini-mips.c, mini-ppc.c, mini-s390.c,
7300 mini-s390x.c: fixed peephole optimizations to deal
7301 correctly with 1 and 2 byte reload avoidance.
7303 Thu Mar 15 10:17:54 CET 2007 Paolo Molaro <lupus@ximian.com>
7305 * cpu-s390.md, cpu-s390x.md: update localloc length.
7307 Wed Mar 14 21:00:19 CET 2007 Paolo Molaro <lupus@ximian.com>
7309 * cpu-g4.md: added missing descriptions.
7311 2007-03-14 Miguel de Icaza <miguel@novell.com>
7313 * Makefile.am: Add support so the tail tests are not executed on
7314 PowerPC as that is a known limitation of the PowerPC port.
7316 2007-03-13 Jonathan Chambers <joncham@gmail.com>
7318 * runmdesc.bat: Move to msvc directory.
7320 2007-03-13 Jonathan Chambers <joncham@gmail.com>
7322 * runmdesc.bat: Run executable that was produced by the current
7323 target and sent via an argument.
7325 2007-03-11 Zoltan Varga <vargaz@gmail.com>
7327 * mini.c (mono_method_to_ir): Fix box+brtrue optimization. Fixes
7330 * generics.2.cs: Add regression test.
7332 2007-03-09 Wade berrier <wberrier@novell.com>
7334 * mini-ppc.h: Undo typo of MONO_CONTEXT_SET_SP (ppc doesn't define this symbol)
7336 2007-03-09 Zoltan Varga <vargaz@gmail.com>
7338 * aot-runtime.c (load_aot_module): Load all dependent assemblies eagerly since all
7339 AOT code depends on this.
7341 Thu Mar 8 19:36:13 CET 2007 Paolo Molaro <lupus@ximian.com>
7343 * mini.c: more precise tracking of types in the eval stack
7344 (part of fix for bug #81044).
7346 2007-03-07 Zoltan Varga <vargaz@gmail.com>
7348 * aot-runtime.c (mono_aot_get_class_from_name): Add a cache.
7350 * aot-compiler.c (encode_patch): Remove an obsolete comment.
7352 2007-03-06 Zoltan Varga <vargaz@gmail.com>
7354 * mini-exceptions.c (mono_handle_native_sigsegv): Fix a warning.
7356 * mini.c (mono_method_to_ir): Add a workaround for bug #80733.
7358 2007-02-22 Zoltan Varga <vargaz@gmail.com>
7360 * mini.c (type_from_op): Convert CEE_CONV_U to OP_LCONV_TO_U when the argument is
7361 a pointer on 64 bit systems. Fixes #80190.
7363 * iltests.il: Add new regression test.
7365 Tue Feb 20 11:33:28 CET 2007 Paolo Molaro <lupus@ximian.com>
7367 * mini.c: inline a constant for Environment.IsRunningOnWindows.
7369 2007-02-19 Geoff Norton <gnorton@customerdna.com>
7371 * trace.c: Remove an erroneous alignemnt check when tracing.
7372 Fixes --trace on OSX86.
7374 Wed Feb 14 19:45:56 CET 2007 Paolo Molaro <lupus@ximian.com>
7376 * mini-$(arch).h: initialize SP in context for all the archs.
7378 2007-02-14 Sebastien Pouliot <sebastien@ximian.com>
7380 * mini-x86.h: Initialize SP in MONO_INIT_CONTEXT_FROM_FUNC. Fix CAS
7381 regressions in the thread tests.
7383 2007-02-14 Zoltan Varga <vargaz@gmail.com>
7385 * *-alpha.*: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>:
7386 - fixed implementation of LOCALLOC opcode
7387 - implemented non-un compare for floats
7389 - implementation of FDIV and CKFINITE opcodes
7390 - fixes for latest mono updates
7391 - additional arch opcodes
7393 Mon Feb 12 11:54:16 CET 2007 Paolo Molaro <lupus@ximian.com>
7395 * Makefile.am: simplify and merge rules for cross-compilation.
7397 2007-02-07 Massimiliano Mantione <massi@ximian.com>
7399 * local-propagation.c: Actually *apply* the fix for bug 80591...
7401 Tue Feb 6 19:03:19 CET 2007 Paolo Molaro <lupus@ximian.com>
7403 * mini-exceptions.c: backuot part of the last change
7404 (fixes cas tests on amd64 related to GetExecutingAssembly ()).
7406 2007-02-06 Massimiliano Mantione <massi@ximian.com>
7407 * inssel.brg: Fix bug 59286.
7410 Tue Feb 6 12:23:50 CET 2007 Paolo Molaro <lupus@ximian.com>
7412 * mini-exceptions.c: patch from Zoltan to correctly check for
7413 stack boundaries (using the stack register, not the frame register),
7414 fixes bugs #80724, #79717.
7416 2007-02-03 Zoltan Varga <vargaz@gmail.com>
7418 * mini-ia64.c inssel-sparc.brg mini-sparc.c cpu-sparc.md: Get rid of OP_SETREG/
7419 OP_SETREGIMM, use OP_MOVE/OP_ICONST instead.
7421 * mini-amd64.c (mono_arch_output_basic_block): Fix ATOMIC_EXCHANGE in the
7422 presence of frame pointer elimination.
7424 2007-02-01 Geoff Norton <gnorton@customerdna.com>
7426 * mini-x86.h: NetBSD UCONTEX_REG defines.
7428 2007-02-01 Zoltan Varga <vargaz@gmail.com>
7430 * inssel-amd64.brg: Fix amd64 build.
7432 Thu Feb 1 14:02:09 CET 2007 Paolo Molaro <lupus@ximian.com>
7434 * mini.h: remove extern to workaround what looks likes gcc bug 26905
7437 2007-01-31 Zoltan Varga <vargaz@gmail.com>
7439 * mini-codegen.c (mono_is_regsize_var): New helper function usable by the back
7442 * mini-<ARCH>.c: Use mono_is_regsize_var ().
7444 2007-01-30 Mark Mason <mason@broadcom.com>
7446 * exceptions-mips.c: Lots of exception handling fixes, LMFs now work, some cleanups.
7447 * mini-mips.h: Add LMF magic numbers, and fix context set/get macros.
7448 * mini-mips.c: Cleanups, LMF handling now works, optimize store of zero, implement localloc
7449 beginning support for CEE_JMP [not quite working yet]
7450 * tramp-mips.c: LMF handling now works
7452 2007-01-30 Zoltan Varga <vargaz@gmail.com>
7454 * mini-amd64.c (peephole_pass): Optimize code common in initlocals blocks.
7456 * mini.h (NULLIFY_INS): New macro.
7458 Tue Jan 30 16:33:33 CET 2007 Paolo Molaro <lupus@ximian.com>
7460 * mini.c: statistical profiler fix for windows, patch
7461 from Tor Lillqvist (tml@novell.com).
7463 2007-01-30 Massimiliano Mantione <massi@ximian.com>
7464 * local-propagation.c: Fix bug 80591.
7466 Mon Jan 29 12:14:34 CET 2007 Paolo Molaro <lupus@ximian.com>
7468 * Makefile.am: put back the --export-dynamic option as with
7469 the previous gmodule flags (thanks to Robert Jordan).
7471 2007-01-28 Zoltan Varga <vargaz@gmail.com>
7473 * mini-sparc.c (peephole_pass): Fix #80622 for sparc as well.
7475 mini.h *.c: Allocate fp vregs from the same pool as the int vregs. Use this to
7476 simplify and speed up the local register allocator. Also rename some fields
7477 like iassign->vassign.
7479 * regalloc.c: Remove some functions which are no longer used since their
7480 inlined version is in mini-codegen.c.
7482 * mini-codegen.c: Rename mono_regstate2_ functions to mono_regstate_.
7484 * basic.cs objects.cs iltests.il: Merge tests from the linear IL branch.
7486 2007-01-27 Zoltan Varga <vargaz@gmail.com>
7488 * mini-amd64.c (peephole_pass): Remove optimizations which omit a
7489 narrowing. Fixes #80622.
7491 * iltests.il: Add new regresssion test.
7493 Fri Jan 26 18:31:45 CET 2007 Paolo Molaro <lupus@ximian.com>
7495 * mini.h, mini-trampolines.c, aliasing.c, mini-codegen.c,
7496 debug-debugger.c, debug-debugger.h: warning fixes.
7497 * driver.c: updated copyright year and made it fit in one line.
7499 Fri Jan 26 12:48:39 CET 2007 Paolo Molaro <lupus@ximian.com>
7501 * aot-runtime.c: updated to use mono-dl instead of gmodule.
7503 2007-01-25 Zoltan Varga <vargaz@gmail.com>
7505 * mini-x86.c (mono_arch_output_basic_block): Fix #80507 for x86.
7507 * mini-amd64.c (mono_arch_output_basic_block): Fix #80507 for amd64.
7509 * iltests.il: Add new test for bug #80507.
7511 Wed Jan 24 19:10:28 CET 2007 Paolo Molaro <lupus@ximian.com>
7513 * mini-arm.h: use soft-float also on vfp for now.
7515 Wed Jan 24 14:54:40 CET 2007 Paolo Molaro <lupus@ximian.com>
7517 * mini.c: fix some more soft-float issues.
7519 2007-01-24 Zoltan Varga <vargaz@gmail.com>
7521 * mini-sparc.h (MONO_ARCH_FRAME_ALIGNMENT): Fix sparc build.
7523 2007-01-24 Massimiliano Mantione <massi@ximian.com>
7524 * mini-arch.h, , inssel-amd64.brg, mini-x86.c, inssel-x86.brg,
7525 mini-ia64.c, mini-sparc.c, mini-alpha.c: Introduced
7526 MONO_ARCH_LOCALLOC_ALIGNMEENT to fix bug 80498.
7528 Wed Jan 24 12:04:39 GMT 2007 Paolo Molaro <lupus@ximian.com>
7530 * mini-arm.c: typo fix.
7532 2007-01-23 Neale Ferguson <neale@sinenomine.net>
7534 * mini-s390x.c: Use lgb instructions for I1 type variables instead of lb.
7536 2007-01-21 Zoltan Varga <vargaz@gmail.com>
7538 * mini.c (mono_allocate_stack_slots_full): Allocate memory from the cfg mempool.
7539 Share stack slots for scalar types. Avoid expensive g_list_free () calls.
7541 * mini-x86.c (mono_arch_allocate_vars): Don't free the result of allocate_stack_slots_full.
7543 * mini-amd64.c mini-ia64.c mini-alpha.c: Ditto.
7545 * mini.h (MonoJitStats): Add a new JIT statistics: locals_stack_size.
7547 * inssel.brg: Fix a warning.
7549 * mini.h (MonoBasicBlock): Make bb->dominated a GSList.
7551 * abcremoval.c ssa.c ssapre.c: Update after this change.
7553 * dominators.c (compute_dominators): Allocate bb->dominated from the cfg mempool.
7555 * dominators.c (df_set): Use mono_bitset_union_fast.
7557 Sat Jan 20 16:59:01 CET 2007 Paolo Molaro <lupus@ximian.com>
7559 * mini.h, genmdesc.c, genmdesc.pl, mini-${arch}.c, cprop.c,
7560 mini-codegen.c: reduce relocations and memory usage for the cpu
7563 2007-01-20 Zoltan Varga <vargaz@gmail.com>
7565 * mini-codegen.c (mono_regstate2_alloc_int): Optimize this using bsfq on amd64.
7567 * genmdesc.c genmdesc.pl mini.h: Remove some unused fields from the mdesc tables
7568 to reduce their size.
7570 2007-01-19 Mark Mason <mason@broadcom.com>
7572 * exceptions-mips.c: fix mono_arch_ip_from_context(), increase exception debug support.
7573 * mini-mips.c: more configuration macros, support long conditional branches, additional
7574 asserts, fix epilog instrumentation.
7575 * mini-mips.h: use standard stack walk
7576 * cpu-mips.md: increase size of div, rem and conditional branches
7578 Fri Jan 19 17:23:32 CET 2007 Paolo Molaro <lupus@ximian.com>
7580 * mini.h, mini-codegen.c, mini-$(arch).h: claenup references
7583 2007-01-19 Zoltan Varga <vargaz@gmail.com>
7585 * aot-compiler.c (encode_klass_info): Allow classes of the form <Type>[][].
7586 (compile_method): Ditto.
7588 * aot-runtime.c (decode_klass_info): Ditto.
7590 * mini.c (mono_method_to_ir): Call mono_get_got_var () in a place where it is
7591 needed by the code generated by inssel.brg. Also fix a warning.
7593 Thu Jan 18 17:55:22 CET 2007 Paolo Molaro <lupus@ximian.com>
7595 * mini.c: deal with enums that become genericinsts by
7596 being nested in a generic class (bug #79956).
7598 Thu Jan 18 16:52:56 CET 2007 Paolo Molaro <lupus@ximian.com>
7600 * mini.c: match the generic definition to check for
7601 private access with generic types (bug #78431).
7603 Thu Jan 18 11:50:13 CET 2007 Paolo Molaro <lupus@ximian.com>
7605 * genmdesc.pl, Makefile.am: perl implementation of genmdesc,
7606 to make life easier for people cross-compiling that insist on not
7609 2007-01-17 Mark Mason <mason@broadcom.com>
7611 * inssel-long.brg: patch to deal with mips missing flags
7612 * inssel-long32-mips.brg: implement overflow checks
7613 * insset-mips.brg: implement overflow checks
7614 * mini-mips.h: implement conditional exception handling
7615 * mini-mips.c: add mips_emit_exc_by_name(), implement conditional exception handling.
7616 Remove unused code, minor cleanups.
7617 * exceptions-mips.c: minor cleanups
7618 * mini-ops.h: add mips conditional exception ops
7619 * cpu-mips.md: add mips conditional exception ops
7622 Wed Jan 17 19:22:34 CET 2007 Paolo Molaro <lupus@ximian.com>
7624 * inssel.brg: patch from Mark Mason <mason@broadcom.com>
7625 to deal with mips missing of flags.
7627 Tue Jan 16 20:01:01 CET 2007 Paolo Molaro <lupus@ximian.com>
7629 * exceptions-ppc.c: execute fault handlers.
7631 Tue Jan 16 19:54:44 CET 2007 Paolo Molaro <lupus@ximian.com>
7633 * mini-ppc.c: handle missing call locationss with FORCE_INDIR_CALL.
7635 Tue Jan 16 13:14:31 CET 2007 Paolo Molaro <lupus@ximian.com>
7637 * mini.c: handle also floating point values in initialize_array.
7639 Tue Jan 16 12:42:40 CET 2007 Paolo Molaro <lupus@ximian.com>
7641 * mini.c, aot-runtime.c, aot-compiler.c: enable aot compilation of
7642 array initialization and make it conditional on the intrins option.
7644 Tue Jan 16 11:28:45 CET 2007 Paolo Molaro <lupus@ximian.com>
7646 * mini.h, patch-info.h, Makefile.am, aot-compiler.c: reduce
7647 relocations and put the patch info names close to the enum definition.
7649 2007-01-15 Mark Mason <mason@broadcom.com>
7651 * basic.cs, exceptions.cs: break up large tests to increase debugability.
7653 Mon Jan 15 18:57:14 CET 2007 Paolo Molaro <lupus@ximian.com>
7655 * mini.c: optimized RuntimeHelpers::InitializeArray () calls.
7657 2007-01-12 Raja R Harinath <rharinath@novell.com>
7659 * mini.c (mono_method_to_ir): Use new MonoGenericContext accessor.
7661 Thu Jan 11 11:16:42 CET 2007 Paolo Molaro <lupus@ximian.com>
7663 * Makefile.am: distribute the mips sources.
7665 Wed Jan 10 19:49:33 CET 2007 Paolo Molaro <lupus@ximian.com>
7667 * mini-codegen.h: handle bug #80489 here, by excluding ecx
7670 Wed Jan 10 19:08:05 CET 2007 Paolo Molaro <lupus@ximian.com>
7672 * cpu-x86.md: back out for now as this triggers other regressions.
7674 Wed Jan 10 18:33:16 CET 2007 Paolo Molaro <lupus@ximian.com>
7676 * cpu-x86.md: force src1 and dest regpair for long shift instructions
7677 to eax:edx, so ecx can't get allocated to them (bug #80489).
7679 Tue Jan 9 12:36:11 CET 2007 Paolo Molaro <lupus@ximian.com>
7681 * mini.c, mini-exceptions.c: enabled running fault handlers
7684 2007-01-03 Miguel de Icaza <miguel@novell.com>
7686 * driver.c: If nothing fail, do not use the string "failed",
7687 because it makes it very annoying to view test result logs on the
7690 2006-12-30 Miguel de Icaza <miguel@novell.com>
7692 * debug-debugger.c (mono_debugger_main): Rename "main" to
7693 "main_method" to prevent a warning.
7695 Remove a warning for unused field.
7697 2006-12-28 Martin Baulig <martin@ximian.com>
7700 (MONO_DEBUGGER__debugger_info): Add `get_lmf_addr'.
7702 2006-12-22 Martin Baulig <martin@ximian.com>
7704 * mdb-debug-info32.s, mdb-debug-info64.s: New files.
7705 Put a pointer to the `MONO_DEBUGGER__debugger_info' into a
7706 seperate `.mdb_debug_info' section, so we can access it from the
7707 debugger even if the binary is stripped.
7709 * debug-debug.c: Reference the `MONO_DEBUGGER__debugger_info_ptr'
7710 from the `.mdb_debug_info' here to prevent the linker from
7711 removing that section.
7713 * Makefile.am (mono_debugger_sources): Add mdb-debug-info32.s /
7716 2006-12-19 Robert Jordan <robertj@gmx.net>
7718 * mini-x86: enable the code to return small structures in
7719 registers for FreeBSD as well. Fixes bug #80278.
7720 * aot-runtime.c: Include sys/wait.h for WEXITSTATUS/WIFEXITED.
7722 Mon Dec 18 19:47:17 CET 2006 Paolo Molaro <lupus@ximian.com>
7724 * mini-x86.c: align the stack when calling the profiler
7725 function instrumenting the prolog (on OSX).
7727 Thu Dec 14 15:22:43 CET 2006 Paolo Molaro <lupus@ximian.com>
7729 * mini.c: emit a break opcode where Debugger.Break () is called.
7731 2006-12-13 Miguel de Icaza <miguel@novell.com>
7733 * mini.c (mono_method_to_ir): Provide useful information on this
7734 assert, to prevent others from debugging like I did.
7736 Tue Dec 12 17:01:38 CET 2006 Paolo Molaro <lupus@ximian.com>
7738 * mini.c: enable code which was incorrectly commented
7741 Tue Dec 12 16:28:15 CET 2006 Paolo Molaro <lupus@ximian.com>
7743 * mini-x86.c: enable on OSX, too, the code to return small
7744 structures in registers.
7746 Mon Dec 11 19:22:35 CET 2006 Paolo Molaro <lupus@ximian.com>
7748 * mini-x86.c: remove the use of the dynamic code manager here, too.
7750 Mon Dec 11 19:08:33 CET 2006 Paolo Molaro <lupus@ximian.com>
7752 * mini.h, debug-debugger.c, tramp-*.c: fixed
7753 mono_debugger_create_notification_function() to use
7754 mono_global_codeman_reserve () instead of a dynamic code manager.
7756 Tue Dec 5 17:54:50 CET 2006 Paolo Molaro <lupus@ximian.com>
7758 * mini.c, jit-icalls.h, jit-icalls.c: remove the
7759 ves_array_element_address() jit icall and use a generated
7760 managed method instead (which is about 4 times faster for a rank 3
7763 2006-11-29 Mark Mason <mason@broadcom.com>
7765 * basic-calls.cs: additional tests for passing
7766 structures as function arguments.
7768 2006-11-29 Mark Mason <mason@broadcom.com>
7770 * mini-mips.h: disable custom exception handling
7771 * mini-mips.c: throw/rethrow should use jalr to call
7772 exception stubs. Fixed bug with passing structures
7773 by value. More support for tracing floating point
7776 Wed Nov 29 20:28:17 CET 2006 Paolo Molaro <lupus@ximian.com>
7778 * mini.c: fixed typo in the soft-float ldind.r4 handling
7781 Wed Nov 29 11:33:03 CET 2006 Paolo Molaro <lupus@ximian.com>
7783 * mini.c, mini.h, driver.c: added --runtime command line
7784 option to select a different runtime than the autodetected one.
7785 * jit.h: added API for embedders to initialize with a specific
7788 Tue Nov 28 21:24:55 CET 2006 Paolo Molaro <lupus@ximian.com>
7790 * mini.c: handle also boxing of r4 values (bug #80024).
7792 Tue Nov 28 19:45:44 CET 2006 Paolo Molaro <lupus@ximian.com>
7794 * mini-ppc.c: force indirect calls until we reserve
7795 enough address space for all the generated code.
7797 Tue Nov 28 20:04:34 GMT 2006 Paolo Molaro <lupus@ximian.com>
7799 * exceptions-arm.c: workaround bugs in the libc definition
7802 Mon Nov 27 15:13:41 CET 2006 Paolo Molaro <lupus@ximian.com>
7804 * inssel.brg: fixes from me and Mark Mason.
7806 2006-11-23 Dick Porter <dick@ximian.com>
7808 * wapihandles.c (mini_wapi_seminfo): No need to adjust the counter
7809 semaphore display now we've fixed the initial value
7811 Wed Nov 22 11:04:37 CET 2006 Paolo Molaro <lupus@ximian.com>
7813 * inssel.brg: partially revert the last change to fix the build.
7815 2006-11-21 Mark Mason <mason@broadcom.com>
7817 * inssel.brg: Add and use compare-and-branch macros to support
7818 architectures that do not have condition code registers (ie. MIPS).
7819 * *-mips.{c,brg,md}: Fix copyright statements
7821 2006-11-20 Mark Mason <mason@broadcom.com>
7823 * Makefile.am: remove mini-codegen.c from list of MIPS sources
7824 * mini.c: Allow GET_CONTEXT to be specified by the arch port
7825 * mini.h: Added declaration for mono_print_ins()
7826 * mini-codegen.c: added ins_spec initializer for MIPS
7827 * mini-codegen.c (mono_call_inst_add_outarg_reg): added asserts for
7828 vreg to be virtual and hreg to be non-virtual.
7829 * mini-codegen.c (mono_spillvar_offset): assert if MIPS - spilling
7830 is not yet working/implemented correctly.
7831 * mini-codegen.c (print_ins): rename to mono_print_ins(), make
7832 non-static, fixup calls to print_ins() from other parts in the file.
7834 2006-11-20 Mark Mason <mason@broadcom.com>
7836 * basic-calls.cs: added tests for passing structures as arguments
7839 Mon Nov 20 19:40:11 CET 2006 Paolo Molaro <lupus@ximian.com>
7841 * inssel-long32.brg: optimize signed division by power of two.
7843 Mon Nov 20 17:37:58 CET 2006 Paolo Molaro <lupus@ximian.com>
7845 * mini-arm.c: added support for interworking with thumb code
7846 (mono must be still be built using the ARM instruction encoding).
7848 2006-11-19 Miguel de Icaza <miguel@novell.com>
7850 * mini.c (type_from_op): Separate the conditions for OP_EQ as the
7851 verifier has different rules for it. Fixes a few verifier issues
7854 * mini-exceptions.c (mono_handle_native_sigsegv): Put the message
7855 at the end, so people know what happened.
7857 Thu Nov 16 14:07:18 CET 2006 Paolo Molaro <lupus@ximian.com>
7859 * brach-opts.c: in optimize_exception_target() make sure we
7860 are in a catch clause (fixes bug #79871).
7862 Thu Nov 16 12:42:13 CET 2006 Paolo Molaro <lupus@ximian.com>
7864 * jit-icalls.c, jit-icalls.h, mini-arm.c, mini.c:
7865 more soft-float support fixes.
7867 Wed Nov 15 18:45:47 GMT 2006 Paolo Molaro <lupus@ximian.com>
7869 * mini-arm.c, inssel-arm.brg: ABI fix for longs and doubles
7870 that are passed half on the stack and half in registers.
7872 Wed Nov 15 17:00:27 CET 2006 Paolo Molaro <lupus@ximian.com>
7874 * mini-ops.h, mini-arch.h, helpers.c, Makefile.am:
7875 more mips integration work from Mark E Mason
7876 <mark.e.mason@broadcom.com>.
7878 Wed Nov 15 16:34:03 CET 2006 Paolo Molaro <lupus@ximian.com>
7880 * exceptions-mips.c, inssel-mips.brg, mini-mips.h,
7881 cpu-mips.md, inssel-long32-mips.brg, mini-mips.c,
7882 tramp-mips.c: added sources for the mips port, not
7883 integrated in the build yet. Contributed by
7884 Mark E Mason <mark.e.mason@broadcom.com>.
7886 2006-11-14 Neale Ferguson <neale@sinenomine.net>
7888 * mini-s390[x].c (is_regsize_var): Support PTR/FNPTR too.
7890 Tue Nov 14 16:06:37 CET 2006 Paolo Molaro <lupus@ximian.com>
7892 * Makefile.am, inssel-float.brg, inssel-softfloat.brg:
7893 put the soft-float rules in its own file since it seems to
7894 break s390 compilation.
7896 Mon Nov 13 15:54:38 CET 2006 Paolo Molaro <lupus@ximian.com>
7898 * mini-arm.c: fixed wrnings.
7900 Fri Nov 10 19:18:32 CET 2006 Paolo Molaro <lupus@ximian.com>
7902 * mini-arm.c, mini-arm.h, cpu-arm.md, inssel-float.brg,
7903 inssel-arm.brg: ARM support for soft-float.
7905 Fri Nov 10 18:38:15 CET 2006 Paolo Molaro <lupus@ximian.com>
7907 * mini.c, jit-icalls.c, jit-icalls.h: added first cut at handling
7908 loads and stores of 32 bit fp values.
7910 2006-11-10 Zoltan Varga <vargaz@gmail.com>
7912 * mini-sparc.c (is_regsize_var): Support PTR/FNPTR too.
7914 * tramp-sparc.c (mono_arch_patch_callsite): Fix this function so it actually
7915 works. Fixes #79852 and #79463.
7917 Thu Nov 9 16:56:13 CET 2006 Paolo Molaro <lupus@ximian.com>
7919 * mini.c, mini-codegen.c, jit-icalls.c, jit-icalls.h:
7920 more soft-float support WIP and fixes.
7922 Wed Nov 8 16:40:02 CET 2006 Paolo Molaro <lupus@ximian.com>
7924 * mini-arm.c: some VFP updates.
7926 Tue Nov 7 19:45:51 CET 2006 Paolo Molaro <lupus@ximian.com>
7928 * mini-exceptions.c: 0 is a valid local var offset in some
7929 architectures, don't assert (bug #78508).
7931 Tue Nov 7 18:17:52 GMT 2006 Paolo Molaro <lupus@ximian.com>
7933 * exceptions-arm.c: fixed off by one error in stack walk code.
7935 Tue Nov 7 11:27:26 CET 2006 Paolo Molaro <lupus@ximian.com>
7937 * mini.h, mini.c: more precise tracking of type load exceptions.
7939 2006-11-03 Robert Jordan <robertj@gmx.net>
7941 * Makefile.am: [WIN32] Add monow.exe target.
7942 * driver.c: [WIN32] Don't detach the console when debugging.
7945 2006-10-30 Miguel de Icaza <miguel@novell.com>
7947 * tramp-x86.c (mono_arch_patch_delegate_trampoline): Eliminate warning.
7949 2006-10-23 Zoltan Varga <vargaz@gmail.com>
7951 * aot-compiler.c (emit_method_info): Add a case missed earlier.
7953 * driver.c (mini_regression): Fix --regression with AOT.
7955 * aot-compiler.c (emit_method_info): Fix AOT on amd64.
7957 2006-10-17 Zoltan Varga <vargaz@gmail.com>
7959 * mini.c (GET_CONTEXT): Correct the definition of this for sparc/linux.
7961 * mini-sparc.h: Don't use sigaction on sparc/linux.
7963 * exceptions-sparc.c: Call mono_arch_flush_icache () in a couple of places.
7965 * mini-sparc.c (mono_sparc_flushw): Call mono_arch_flush_icache ().
7967 * mini-exceptions.c: Add proper include files for getpid ().
7969 2006-10-16 Zoltan Varga <vargaz@gmail.com>
7971 * aot-runtime.c (mono_aot_get_method): Change this to return the native code
7972 address instead of a MonoJitInfo* to avoid decoding the exception info for the
7975 * aot-runtime.c aot-compiler.c: Use uint16 instead of uint32 entries in the
7976 name cache to reduce its size.
7978 * mini.h (MONO_AOT_FILE_VERSION): Bump aot file format version.
7980 2006-10-15 Zoltan Varga <vargaz@gmail.com>
7982 * mini-x86.c: Save/restore the current LMF structure more efficiently using
7983 the mono_lmf TLS variable.
7985 * exceptions-x86.c (mono_arch_find_jit_info): Only access lmf->method in
7986 trampoline lmf frames.
7988 * mini-sparc.h (MONO_ARCH_ENABLE_EMIT_STATE_OPT): Define this on sparc as well.
7990 2006-10-14 Zoltan Varga <vargaz@gmail.com>
7992 * mini-amd64.c: Save/restore the current LMF structure more efficiently using
7993 the mono_lmf TLS variable.
7995 * mini-exceptions.c: Access the LMF structure through accessors.
7997 * mini.c: Allow the backends the option for storing the lmf in a dedicated TLS
7998 variable instead of in jit_tls->lmf.
8000 * mini-x86.c mini-amd64.c: Update after lmf->lmf_addr name change.
8002 * exceptions-amd64.c (mono_arch_find_jit_info): Only access lmf->method in
8003 trampoline lmf frames.
8005 * mini-amd64.c (mono_arch_emit_prolog): Do not set lmf->method as it is not needed.
8007 2006-10-12 Zoltan Varga <vargaz@gmail.com>
8009 * mini.c trace.c mini-x86.c: Revert these too.
8011 * mini.c trace.c mini-x86.c: Remove warning workarounds after the mono_type_size ()
8014 Tue Oct 10 11:35:20 CEST 2006 Paolo Molaro <lupus@ximian.com>
8016 * genmdesc.c: removed now dead code.
8018 2006-10-09 Robert Jordan <robertj@gmx.net>
8020 * mini.c: Disable the CrashReporter on MacOS X; Fixes #74869
8022 Mon Oct 9 17:06:41 CEST 2006 Paolo Molaro <lupus@ximian.com>
8024 * mini.h: do not leave gaps in the opcode values.
8026 Mon Oct 9 16:08:51 CEST 2006 Paolo Molaro <lupus@ximian.com>
8028 * jit-icalls.h: flag functions as internal here, too.
8030 Mon Oct 9 15:58:18 CEST 2006 Paolo Molaro <lupus@ximian.com>
8032 * mini.h, aliasing.h, declsec.h, regalloc.h, trace.h: mark internal
8033 functions with the internal attribute.
8035 Mon Oct 9 15:52:45 CEST 2006 Paolo Molaro <lupus@ximian.com>
8037 * aot-compiler.c: fclose the file descriptor in the profile read loop.
8039 Fri Oct 6 16:01:38 CEST 2006 Paolo Molaro <lupus@ximian.com>
8041 * mini.c, jit-icalls.c, inssel-float.brg: beginnings of support
8044 2006-10-05 Zoltan Varga <vargaz@gmail.com>
8046 * mini-x86.c (emit_load_volatile_arguments): New function to handle arguments of
8047 tail calls as on other platforms.
8049 * mini.c (mono_method_to_ir): Fix a few tailcall problems. Fixes #79557.
8051 * iltests.il: Add a few tailcall tests.
8053 Tue Oct 3 16:33:08 CEST 2006 Paolo Molaro <lupus@ximian.com>
8055 * driver.c: fix loop for old compilers (bug #79521).
8057 2006-10-02 Zoltan Varga <vargaz@gmail.com>
8059 * mini-exceptions.c (ves_icall_get_trace): Remove debug printf.
8061 * aot-runtime.c (mono_aot_get_class_from_name): Avoid a memory allocation.
8063 * aot-compiler.c: Add a new option 'metadata-only' to only emit the cached
8064 metadata without any code.
8066 * mini-exceptions.c (mono_handle_native_sigsegv): Add some code to print out
8067 more precise debugging information using gdb.
8069 2006-09-30 Zoltan Varga <vargaz@gmail.com>
8071 * inssel-ia64.brg: Make the helper methods static.
8073 Thu Sep 28 16:40:07 CEST 2006 Paolo Molaro <lupus@ximian.com>
8075 * inssel-x86.brg: make the helper methods static.
8077 Thu Sep 28 16:31:32 CEST 2006 Paolo Molaro <lupus@ximian.com>
8079 * inssel-amd64.brg, mini-amd64.c: small cleanup, use inst_call.
8081 Thu Sep 28 15:36:07 CEST 2006 Paolo Molaro <lupus@ximian.com>
8083 * mini.c: updates for monoburg changes.
8084 * inssel.brg: make a few helper functions static as they should.
8086 2006-09-27 Zoltan Varga <vargaz@gmail.com>
8088 * Makefile.am: Move mini-codegen.c to common_sources.
8090 Wed Sep 27 15:07:08 CEST 2006 Paolo Molaro <lupus@ximian.com>
8092 * mini.h: instroduce inst_call in MonoInst for use in OUTARG
8094 * Makefile.am, cpu-g4.md, inssel-ppc.brg, mini-codegen.c, mini-ppc.c,
8095 mini-ppc.h: port to use the common local register allocator.
8097 2006-09-26 Zoltan Varga <vargaz@gmail.com>
8099 * mini.h: Remove the comment too then.
8101 Tue Sep 26 14:02:58 CEST 2006 Paolo Molaro <lupus@ximian.com>
8103 * mini.h: put back backend.data which is to be used shortly and
8104 doesn't increase the size of MonoInst. If any 64 bit arch aligned
8105 pointers on 4 byte boundaries it'd have much bigger issues running
8106 and you can ifdef it out anyway.
8108 2006-09-26 Zoltan Varga <vargaz@gmail.com>
8110 * mini.h (MonoInst): Remove backend.data field since it is unused and increases
8111 MonoInst size by 4 bytes on 64 bit machines.
8113 Tue Sep 26 11:57:26 CEST 2006 Paolo Molaro <lupus@ximian.com>
8115 * *.{c,h,brg}: long due removal of the unused field in MonoInst and
8116 replacement with more meaningful field names. Arch maintainers, please
8117 check the assigned names are good enough for your arch.
8119 2006-09-26 Zoltan Varga <vargaz@gmail.com>
8121 * cpu-ia64.md mini-ia64.c inssel-ia64.brg mini-ops.h: Get rid of the
8122 OP_IA64_FETCHADD opcodes, use OP_ATOMIC_ADD_IMM_NEW opcodes instead.
8124 Mon Sep 25 11:05:24 CEST 2006 Paolo Molaro <lupus@ximian.com>
8126 * mini.h, driver.c, optflags-def.h, Makefile.am: reduce runtime
8127 relocations and memory requirements, put the optimization flags
8128 definitions in their own file.
8130 2006-09-24 Zoltan Varga <vargaz@gmail.com>
8132 * jit-icalls.c (mono_helper_stelem_ref): Remove this unused helper function.
8134 * mini.c (mini_init): Remove reference to mono_helper_stelem_ref.
8136 2006-09-22 Zoltan Varga <vargaz@gmail.com>
8138 * mini-amd64.c (add_valuetype): Fix an uninitialized memory issue.
8140 Thu Sep 21 19:06:09 CEST 2006 Paolo Molaro <lupus@ximian.com>
8142 * inssel.brg: use the correct function to get the size of an item
8143 in an array, given an element class.
8144 * aot-compiler.c: do not access class->class_size directly.
8146 Thu Sep 21 12:10:56 CEST 2006 Paolo Molaro <lupus@ximian.com>
8148 * mini.h, debug-mini.c: added a debugging function to print
8149 info about local variables and arguments in a jitted method.
8151 2006-09-20 Zoltan Varga <vargaz@gmail.com>
8153 * mini-alpha.c: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>.
8155 * exceptions-ia64.c: Fix some problems reported by Bill Seurer <seurer@us.ibm.com>.
8157 2006-09-19 Zoltan Varga <vargaz@gmail.com>
8159 * mini-ia64.c (mono_arch_call_opcode): Avoid using the same loop index in the
8160 inner and outer loops when passing vtypes.
8162 Tue Sep 19 17:53:40 CEST 2006 Paolo Molaro <lupus@ximian.com>
8164 * mini-ppc.c: take into account the cpu errata for cache flushing
8165 which caused some random errors (bug #79381).
8167 2006-09-19 Zoltan Varga <vargaz@gmail.com>
8169 * mini-amd64.c (mono_arch_emit_exceptions): Emit the call to
8170 mono_arch_throw_corlib_exception using emit_call () too. Fixes #79271.
8172 2006-09-17 Zoltan Varga <vargaz@gmail.com>
8174 * aot-runtime.c (load_aot_module): Return immeditely if the AOT module was already
8177 * exceptions-amd64.c (gregs_from_ucontext): Apply another patch from the
8180 * mini-amd64.c (emit_call): Avoid near calls on freebsd.
8181 (mono_arch_patch_code): Remove the unused handling of MONO_PATCH_INFO_CLASS_INIT.
8183 * tramp-amd64.c (mono_arch_create_specific_trampoline): Fix check for 32 bitness of
8186 2006-09-13 Zoltan Varga <vargaz@gmail.com>
8188 * aot-runtime.c (load_aot_module_from_cache): Fix PPC build.
8190 2006-09-12 Zoltan Varga <vargaz@gmail.com>
8192 * mini.c (UNVERIFIED): Add a 'break-on-unverified' MONO_DEBUG option so this
8193 macro does not have to be changed during debugging.
8195 * 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>.
8197 * cpu-pentium.md: Rename this to cpu-x86.md for consistency with other platforms.
8199 * Makefile.am mini-x86.c mini-codegen.c: Rename pentium_desc to x86_desc.
8201 * mini.c (mini_get_ldelema_ins): Allow ldelema2d optimization if
8202 MONO_ARCH_NO_EMULATE_MUL is defined.
8204 * mini-ia64.h (MONO_ARCH_CALLEE_FREGS): Reserve f33 for use by instructions.
8206 * mini-ia64.h: Define MONO_ARCH_NO_EMULATE_MUL.
8208 * mini-ia64.c: Implement CEE_MUL based on gcc emitted code.
8210 * mini-ia64.c (mono_arch_lowering_pass): Optimize store_membase_imm with offset==0.
8212 2006-09-11 Zoltan Varga <vargaz@gmail.com>
8214 * mini-x86.h mini-amd64.h mini-exceptions.c: Move the bsd specific MAP_ANON
8215 stuff to mini-exceptions.c where it is used.
8217 * mini-sparc.c (mono_arch_setup_jit_tls_data): Remove the duplicate altstack
8218 setup code, the real one is in mini-exceptions.c.
8220 * mini-amd64.h mini-amd64.c exceptions-amd64.c: Move all dependencies on the
8221 layout of ucontext_t to helper functions in exceptions-amd64.c, as on x86. Add
8222 some changes from the freebsd ports tree.
8224 * mini-amd64.h exceptions-amd64.c: Fix the amd64 build. Get rid of the SC_
8227 * mini-amd64.h: Freebsd has MAP_ANON instead of MAP_ANONYMOUS.
8229 Mon Sep 11 13:18:55 CEST 2006 Paolo Molaro <lupus@ximian.com>
8231 * mini.c: on Linux, check for /proc to be mounted
8232 (bug# 79351, novell bug#201204).
8234 Mon Sep 11 13:10:12 CEST 2006 Paolo Molaro <lupus@ximian.com>
8236 * mini.c: handle cases where pthread_attr_getstack() behaves
8237 incorrectly (bug #78096).
8239 Mon Sep 11 11:31:10 BST 2006 Paolo Molaro <lupus@ximian.com>
8241 * mini-arm.c: support larger stack frames (bug #79272).
8243 2006-09-08 Zoltan Varga <vargaz@gmail.com>
8245 * aot-runtime.c (mono_aot_get_class_from_name): Remove a debug printf.
8247 * aot-compiler.c: Add a hash table to the AOT file mapping class names to typedef
8250 * aot-runtime.c (mono_aot_get_class_from_name): New function used by
8251 mono_class_from_name () to find a class from its name.
8253 * mini.c (mini_init): Register mono_aot_get_class_from_name () with the runtime.
8255 2006-09-07 Zoltan Varga <vargaz@gmail.com>
8257 * mini-amd64.c (emit_call): Avoid strstr () call if possible.
8259 2006-09-05 Kornél Pál <kornelpal@gmail.com>
8261 * Makefile.am: Renamed mono-1.dll to mono.dll. (-avoid-version)
8263 2006-09-04 Zoltan Varga <vargaz@gmail.com>
8265 * mini.c (mono_icall_get_wrapper): Fix a race condition on initializing
8266 callinfo->trampoline.
8268 * mini-amd64.c (emit_call): Special case calls to the vararg array icalls. Hopefully
8270 (mono_arch_patch_code): Add some debug code to help track down similar failures in the
8273 2006-09-03 Zoltan Varga <vargaz@gmail.com>
8275 * aot-runtime.c (mono_aot_plt_resolve): Add an assert.
8277 2006-09-02 Zoltan Varga <vargaz@gmail.com>
8279 * tramp-x86.c (mono_arch_create_specific_trampoline): Don't increase
8280 stats.method_trampolines, it is already done by the generic trampoline code.
8282 * tramp-amd64.c (mono_arch_create_specific_trampoline): Ditto.
8284 2006-09-01 Zoltan Varga <vargaz@gmail.com>
8286 * mini.c: Remove some references to mono_compile_aot, and use cfg->compile_aot instead.
8288 * aot-runtime.c: Add some tweaks to the MONO_AOT_CACHE functionality.
8290 * tramp-amd64.c (mono_arch_create_specific_trampoline): Fix a FIXME.
8292 * mini.c (print_jit_stats): Print mscorlib mempool size too.
8294 * mini.c (print_jit_stats): Print new stats.
8296 * *-alpha.c: More alpha port work from Sergey Tikhonov <tsv@solvo.ru>.
8298 2006-08-31 Zoltan Varga <vargaz@gmail.com>
8300 * mini.c (mini_get_ldelema_ins): Fix verifier error when calling
8301 Address on two dimensional arrays. Fixes #78729.
8303 * mini.h (MonoCompile): Add a 'skip_visibility' field.
8305 * mini.c (method_to_ir): Disable visibility checks if skip_visibility is set on
8308 * mini-amd64.c (mono_arch_emit_exceptions): Fix assertion introduced by the last change.
8310 * mini.c (mono_runtime_cleanup_handlers): Clean up signal handlers on unix. Fixes
8313 * mini.c (handle_array_new): Applied patch from "briaeros007". Fix
8315 (mini_get_ldelema_ins): Ditto.
8317 2006-08-30 Zoltan Varga <vargaz@gmail.com>
8319 * mini-amd64.c (mono_arch_emit_exceptions): Align fp constants to 16 bytes.
8320 (mono_arch_output_basic_block): Avoid unaligned accesses in FNEG implementation.
8323 2006-08-29 Neale Ferguson <neale@sinenomine.net>
8325 * mini-s390.c, mini-s390x.c: Fix VARARG case processing with 0 arguments. Add
8326 mono_arch_get_patch_offset as a dummy entry point to allow successful link.
8328 * exceptions-s390x.c: Cosmetic change.
8330 * tramp-s390.c: Fix warning.
8332 * cpu-s390.md: Correct length of mul_imm.
8334 Wed Aug 23 19:24:00 CEST 2006 Paolo Molaro <lupus@ximian.com>
8336 * aot-compiler.c: added binary writer with ELF backend
8337 implementation (only on Linux/x86 for now).
8339 2006-08-18 Zoltan Varga <vargaz@gmail.com>
8341 * Makefile.am: Don't run net 2.0 AOT tests.
8343 * aot-compiler.c (compile_method): Skip methods with tail calls as well.
8344 (mono_compile_assembly): Skip net 2.0 assemblies as well.
8346 * aot-runtime.c (load_patch_info): Fix an uninitialized memory error.
8348 Fri Aug 18 19:38:28 CEST 2006 Paolo Molaro <lupus@ximian.com>
8350 * aot-compiler.c: simplified and refactored the asm-writing code
8351 to allow different backends.
8353 2006-08-18 Zoltan Varga <vargaz@gmail.com>
8355 * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file format version.
8357 * aot-compiler.c aot-runtime.c: Reorg the GOT slot allocation code a
8358 little. Share patches of type TYPE_FROM_HANDLE as well.
8360 * mini.c (mono_patch_info_equal): New helper function.
8361 (mono_patch_info_hash): Ditto.
8363 * aot-compiler.c (emit_method_code): Fix s390 build.
8365 * mini.c (mono_allocate_stack_slots_full): Fix yet another place where byref
8366 is not handled because it is stored as a flag and not as a type ctor. Fixes
8369 2006-08-17 Zoltan Varga <vargaz@gmail.com>
8371 * aot-compiler.c: Fix computation of GOT slot statistics.
8373 * aot-compiler.c aot-runtime.c: Implement sharing of GOT slots for classes/fields.
8374 Also remove support for not PIC AOT.
8376 * mini.h: Bump AOT file format version.
8378 * objects.cs: Add a test for #78990.
8380 * mini-x86.c (mono_arch_output_basic_block): Applied patch from Peter Dettman
8381 (peter.dettman@iinet.net.au). Fixes #79087.
8383 * basic-long.cs: Add a test for the above.
8385 2006-08-16 Zoltan Varga <vargaz@gmail.com>
8387 * aot-compiler.c (get_got_offset): Add a cache for GOT entries, not yet used.
8389 * aot-compiler.c (get_plt_index): Add a cache for wrappers too. Simplify the
8392 2006-08-15 Zoltan Varga <vargaz@gmail.com>
8394 * mini.c (mini_init): Fix registration of idiv/imul opcodes which can throw
8397 2006-08-10 Jonathan Chambers <joncham@gmail.com>
8399 * mini.c: Don't verify COM proxy invoke calls
8402 2006-08-10 Dick Porter <dick@ximian.com>
8404 * wapihandles.c (mini_wapi_seminfo): More info, to help track down
8405 which process is holding semaphores locked.
8407 2006-08-08 Zoltan Varga <vargaz@gmail.com>
8409 * mini-ia64.c mini-amd64.c: Fix #79027.
8411 * mini-sparc.c (mono_arch_call_opcode): Fix the previous patch.
8413 * mini-sparc.c (mono_arch_call_opcode): Fix #79027.
8415 * mini-x86.c (mono_arch_call_opcode): Handle the case where there are no
8416 implicit arguments in a vararg call. Fixes #79027.
8418 2006-08-07 Zoltan Varga <vargaz@freemail.hu>
8420 * mini.c (mono_get_element_address_signature): Use CDECL calling convention on windows. Fixes #78969.
8421 (mono_get_array_new_va_signature): Ditto.
8423 2006-08-05 Zoltan Varga <vargaz@gmail.com>
8425 * aot-runtime.c: Call init_plt lazily.
8427 * inssel-long.brg: Fix unsigned long->int conversion.
8429 * aot-runtime.c (init_plt): Remove a redundant make_writable () call.
8431 * aot-compiler.c aot-runtime.c: Reorganize the file structure in the amd64 case so
8432 that most data is now in the .rss/.data section.
8434 2006-08-04 Zoltan Varga <vargaz@gmail.com>
8436 * aot-compiler.c: Correct the computation of the 'direct-calls' statistic.
8438 * aot-compiler.c: Print the number of methods without GOT slots as a statistics.
8440 * aot-compiler.c aot-runtime.c tramp-amd64.c: Resurrect amd64 AOT support.
8442 * tramp-amd64.c (mono_arch_patch_callsite): Fix a warning.
8444 * jit-icalls.c (mono_helper_compile_generic_method): Unbox vtypes since this is a
8445 virtual call. Fixes #79010.
8447 * mini.c (mono_method_to_ir): Pass an additional out arg to compile_generic_method
8448 and use the result as the this argument in the real call.
8450 * generics.2.cs: Add a new test for #79010.
8452 2006-08-03 Zoltan Varga <vargaz@gmail.com>
8454 * mini-x86.c: Fix a warning.
8456 * aot-compiler.c: Add a bunch of statistics.
8458 * mini.c (inline_method): Disable inlining in out-of-line bblocks.
8460 2006-08-02 Zoltan Varga <vargaz@gmail.com>
8462 * mini-arch.h Makefile.am mini-ops.h mini-codegen.c: More alpha updates.
8464 2006-08-01 Zoltan Varga <vargaz@gmail.com>
8466 * 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>.
8468 2006-07-13 Miguel de Icaza <miguel@novell.com>
8470 * mini.c (mono_method_to_ir): Obtain the original method in the
8471 CIL stream and use this to perform validation.
8475 2006-07-19 Zoltan Varga <vargaz@gmail.com>
8477 * mini-x86.c (mono_arch_get_argument_info): Fix a warning.
8478 (mono_arch_call_opcode): Ditto.
8480 * mini.c (mono_method_to_ir): Clear ins_flag at the end of CEE_CALL. Fixes
8483 * mini.c (mono_patch_info_dup_mp): New helper function.
8485 * aot-compiler.c (compile_method): Fix some of the memory allocated during
8486 compilation. Fixes #78827.
8488 2006-07-18 Kornél Pál <kornelpal@gmail.com>
8490 * declsec.c: Use original security informations for
8491 MONO_WRAPPER_MANAGED_TO_MANAGED.
8493 2006-07-15 Jonathan Chambers <joncham@gmail.com>
8495 * mini.c: Allow Com Interop methods/classes and
8496 don't verify COM wrapper calls
8499 2006-07-13 Zoltan Varga <vargaz@gmail.com>
8501 * inssel-long32.brg: Fix long->i4 checked conversion.
8503 * exceptions.cs: Add a test for the above.
8505 2006-07-08 Zoltan Varga <vargaz@gmail.com>
8507 * mini-exceptions.c (mono_setup_altstack): Fix a memory leak.
8509 * mini.c: Applied patch from Joachim Ante (joe@otee.dk). Fix some shutdown
8512 * helpers.c (mono_disassemble_code): Avoid using fixed temporary files. Fixes
8515 2006-07-03 Zoltan Varga <vargaz@gmail.com>
8517 * mini.c: Fix solaris/x86 exception handling.
8519 * Makefile.am: Get rid of $(ICU_LIBS).
8521 2006-07-02 Zoltan Varga <vargaz@gmail.com>
8523 * mini-exceptions.c: Fix handling of unhandled SIGSEGV exceptions on ia64.
8524 (ves_icall_System_Security_SecurityFrame_GetSecurityStack): Use MONO_INIT_CONTEXT_FROM_CURRENT.
8525 (ves_icall_System_Security_SecurityFrame_GetSecurityFrame): Ditto.
8527 * mini-ia64.h (MONO_CONTEXT_SET_FUNC): New macro.
8529 * mini-exceptions.c (mono_handle_native_sigsegv): Prevent infinite loops if
8530 this function causes a SIGSEGV.
8532 2006-06-22 Zoltan Varga <vargaz@gmail.com>
8534 * mini.c: Remove unused solaris/x86 includes.
8536 2006-06-21 Zoltan Varga <vargaz@gmail.com>
8538 * jit.h: Add G_BEGIN_DECLS/G_END_DECLS.
8540 2006-06-20 Jb Evain <jbevain@gmail.com>
8542 * cpu-g4.md: fix max length of start_handler instruction.
8544 2006-06-20 Massimiliano Mantione <massi@ximian.com>
8545 * simple-cee-ops.h, simple-mini-ops.h: Fixed bug 78656.
8547 2006-06-16 Massimiliano Mantione <massi@ximian.com>
8548 * ssa.c: Fixed bug 78653 for SSA based deadce.
8549 * mini.h: added MONO_INST_DEFINITION_HAS_SIDE_EFFECTS flag go
8550 MonoInst.flags, used in SSA based deadce.
8551 * aliasing.c: Fixed bug 78653 for "fastpath" deadce.
8552 * simple-cee-ops.h, simple-mini-ops.h: Fixed bug 78653.
8554 Thu Jun 15 16:52:46 CEST 2006 Paolo Molaro <lupus@ximian.com>
8556 * tramp-ppc.c: don't use malloc () for trampoline code, sometimes
8557 it can end up using non executable memory on ppc64 systems
8558 running ppc32 userspace (fix from Johannes Berg).
8560 2006-06-14 Dick Porter <dick@ximian.com>
8562 * wapihandles.c: Fix a bunch of signed/unsigned warnings from gcc
8565 2006-06-13 Massimiliano Mantione <massi@ximian.com>
8566 * mini.c: Made so that inline is locally disabled if it would
8567 trigger a .cctor, because too many apps depend on this behavior
8568 (which seems to be also the one of the MS CLR).
8570 2006-06-13 Zoltan Varga <vargaz@gmail.com>
8572 * mini-amd64.c (mono_emit_stack_alloc): Fix initialization of localloc'ed memory.
8573 No idea why this worked before.
8575 * branch-opts.c (mono_branch_optimize_exception_target): Avoid branches
8576 which branch to outer exception clauses since they could skip the
8577 inner finally clauses. Fixes #78633.
8579 * exceptions.cs: Add a test for the above.
8581 * mini.c (merge_basic_blocks): Nullify the branch at the end of the first bb.
8584 * iltests.il: Add a test for the above.
8586 2006-06-12 Zoltan Varga <vargaz@gmail.com>
8588 * mini.c (remove_block_if_useless): Do not remove the bblock immediately
8589 after the end of a try bblock, to prevent asserts in mini_method_compile ().
8591 * iltests.il: Add a test for the above.
8593 2006-06-10 Zoltan Varga <vargaz@gmail.com>
8595 * mini-ia64.c (mono_arch_lowering_pass): Remove some code duplication.
8597 * mini-ia64.c inssel-ia64.brg: Implement the new net 2.0 Interlocked.Add
8598 methods as instrinsics.
8600 2006-06-09 Wade Berrier <wberrier@novell.com>
8602 * Makefile.am: Fix sources list for svn rename so that make dist succeeds
8603 (simple-cee-ops.h ssapre-mini-ops.h)
8605 2006-06-09 Neale Ferguson <neale@sinenomine.net>
8607 * mini-exceptions.c (ves_icall_get_frame_info): Fix this function on s390/s390x.
8608 * mini-s390x.c, mini-s390.c: Correct ATOMIC operations (incorrect register for CS
8610 * mini-s390x.h, mini-s390.h: Simplify MCONTEXT_GET_BP.
8611 * cpu-s390x.md: Fix max. length values for a couple of instructions.
8613 2006-06-09 Jonathan Chambers <jonathan.chambers@ansys.com>
8615 * mini-exceptions.c: Minor fix for building mono in Visual Studio.
8617 2006-06-08 Massimiliano Mantione <massi@ximian.com>
8619 * ssapre-cee-ops.h: Renamed as "simple-cee-ops.h"
8620 * simple-cee-ops.h: Was "ssapre-cee-ops.h" (renamed).
8621 * ssapre-mini-ops.h: Renamed as "simple-mini-ops.h"
8622 * simple-mini-ops.h: Was "ssapre-mini-ops.h" (renamed).
8623 * local-propagation.c: In mono_cprop_invalidate_values use a whitelist
8624 of opcodes, so that bug 78549 should not happen again.
8625 * ssapre.c: Updated to use the renamed files.
8627 2006-06-08 Zoltan Varga <vargaz@gmail.com>
8629 * mini-amd64.c (mono_arch_output_basic_block): Fix a wrong reg-reg move
8630 in OP_ATOMIC_EXCHANGE_I4.
8632 2006-06-07 Wade Berrier <wberrier@novell.com>
8634 * tramp-s390.c: Fix s390 build (add missing pointer declarations
8635 in mono_debugger_create_notification_function)
8637 2006-06-06 Zoltan Varga <vargaz@gmail.com>
8639 * mini.c (NEW_AOTCONST_TOKEN): Fix amd64 build.
8641 * mini.c (type_from_stack_type): Disable some changes which do not
8644 * driver.c: Reenable opts.
8646 * mini.h (MonoStackSlot): New structure to keep track of the verification state
8647 of the evaluation stack.
8649 * mini.h (MonoBasicBlock): Add a 'stack_state' field to keep track of the
8650 evaluation stack trace at entry to the bblock.
8652 * mini.c (merge_stacks): New function to perform verification of stack merges.
8653 Turned off by default.
8655 * mini.c: Fill up ins->klass for instructions whose type is STACK_OBJ or
8658 2006-06-06 Massimiliano Mantione <massi@ximian.com>
8660 * local-propagation.c: Fixed bug 78549.
8662 2006-06-04 Zoltan Varga <vargaz@gmail.com>
8664 * mini-exceptions.c (ves_icall_get_frame_info): Fix this function on ia64.
8666 2006-06-02 Miguel de Icaza <miguel@novell.com>
8668 * tramp-sparc.c, tramp-ppc.c, tramp-s390.c, tramp-s390x.c,
8669 tramp-arm.c, tramp-ia64.c
8670 (mono_debugger_create_notification_function): Update signature to
8671 new signature and use new protocol for creating the notification
8674 Should fix the build.
8676 2006-06-02 Geoff Norton <gnorton@customerdna.com>
8678 * exceptions-ppc.c (mono_jit_walk_stack)
8679 (ves_icall_get_frame_info): Fix the build
8681 2006-06-02 Zoltan Varga <vargaz@gmail.com>
8683 * mini.c (mono_set_defaults): Fix the handling of -O=-all.
8685 2006-05-31 Raja R Harinath <rharinath@novell.com>
8687 * il2tests.2.il: New file for generics CIL tests. Add test for
8689 * Makefile.am: Update.
8692 * mini.c (mono_method_to_ir): Don't apply box+brtrue optimization
8695 2006-05-30 Massimiliano Mantione <massi@ximian.com>
8697 * aliasing.c: Fixed bug 78311.
8699 2006-05-29 Martin Baulig <martin@ximian.com>
8701 * mini-exceptions.c (mono_find_jit_info): When computing the
8702 native offset, check whether we're actually inside the method's
8703 code; call mono_debug_print_stack_frame() to format the frame.
8704 (ves_icall_System_Exception_get_trace): Call
8705 mono_debug_print_stack_frame() to format the stack frame.
8706 (ves_icall_get_trace): Update to the new debugging API.
8707 (mono_jit_walk_stack_from_ctx): Likewise.
8708 (ves_icall_get_frame_info): Likewise.
8710 * mini.c (get_method_from_ip): Use the new debugging API.
8711 (mono_print_method_from_ip): Likewise.
8714 (mono_jit_walk_stack): Use the new debugging API.
8715 (ves_icall_get_frame_info): Likewise.
8717 2006-05-27 Zoltan Varga <vargaz@gmail.com>
8719 * mini-amd64.c (mono_arch_output_basic_block): Fix MONO_PROFILE_COVERAGE.
8721 2006-05-25 Massimiliano Mantione <massi@ximian.com>
8723 * mini.c: Added "limitator" to inline for debugging.
8725 2006-05-24 Martin Baulig <martin@ximian.com>
8727 * debug-debugger.c (mono_debugger_init): Create a private,
8728 malloc()-based code manager for the notification function and
8729 intentionally leak it on exit. This fixes the crash-on-exit race
8733 (mono_debugger_create_notification_function): Added
8734 `MonoCodeManager *' argument.
8737 (mono_debugger_create_notification_function): Added
8738 `MonoCodeManager *' argument.
8740 2006-05-23 Massimiliano Mantione <massi@ximian.com>
8742 * aliasing.c: Fixed 64 bit issue.
8743 * driver.c: Enabled inline,consprop,copyprop,treeprop,deadce by
8744 default since all known bugs are fixed (one more time!).
8746 Tue May 23 13:47:28 CEST 2006 Paolo Molaro <lupus@ximian.com>
8748 * mini.c: write barrier support.
8750 2006-05-23 Martin Baulig <martin@ximian.com>
8752 * debug-debugger.c: Revert Paolo's change. Add comment and #error
8753 check at the top of the file.
8755 Sun May 21 12:22:29 CEST 2006 Paolo Molaro <lupus@ximian.com>
8757 * debug-debugger.c: fix the build. Again. Hopefully Martin will stop
8758 reverting changes without reason and without changelog entries.
8760 2006-05-18 Zoltan Varga <vargaz@gmail.com>
8762 * mini-sparc.c (mono_arch_output_basic_block): Add support for large stack offets
8763 to a few opcodes. Fixes #78439.
8765 * mini-sparc.c: Rename mono_sparch_break () to mono_arch_break () to improve
8766 consistency with other archs.
8768 * mini-ia64.c (mono_arch_emit_prolog): Remove debug stuff left in by mistake.
8770 Wed May 17 18:07:33 CEST 2006 Paolo Molaro <lupus@ximian.com>
8772 * debug-debugger.c: fix the build.
8774 2006-05-17 Martin Baulig <martin@ximian.com>
8777 (debugger_thread_vtable): Moved here from ../metadata/threads.c.
8778 (debugger_init_threads): Formerly known as mono_debugger_init_threads().
8779 (debugger_finalize_threads): Formaly known as mono_debugger_finalize_threads().
8780 (debugger_attach): Call GC_mono_debugger_add_all_threads().
8782 2006-05-11 Zoltan Varga <vargaz@gmail.com>
8784 * mini.c (mini_init): Call pthread_attr_destroy () to fix a small memory leak.
8786 2006-05-10 Zoltan Varga <vargaz@gmail.com>
8788 * mini-x86.c (mono_arch_instrument_epilog): Fix handling of
8789 MONO_TYPE_GENERICINST.
8791 * mini-amd64.c (mono_arch_instrument_epilog): Fix handling of
8792 MONO_TYPE_GENERICINST.
8794 2006-05-09 Zoltan Varga <vargaz@gmail.com>
8796 * mini-x86.c (mono_arch_get_vcall_slot_addr): Add a missing call sequence. Fixes
8799 2006-05-08 Zoltan Varga <vargaz@gmail.com>
8801 * mini.c (mono_create_jump_trampoline): Allocate MonoJitInfo from the domain
8803 (mono_jit_free_method): Remove the method from jump_trampoline_hash as well.
8805 2006-05-06 Zoltan Varga <vargaz@gmail.com>
8807 * mini.c (mini_cleanup): Applied patch from Joachim Ante (joe@otee.dk). Call
8808 mono_trace_cleanup ().
8810 * iltests.il: Fix problem with the newly added test.
8812 * mini-codegen.c (mono_local_regalloc): When changing the dreg of an instruction
8813 due to register constraints, free up the previous hreg. Fixes #78314.
8815 * iltests.il: Add new test for #78314.
8817 * mini-x86.c (mono_arch_get_inst_for_method): Use OP_ATOMIC_ADD_NEW_I4 for
8818 Interlocked.Add. Fixes #78312.
8820 * mini-amd64.c (mono_arch_get_inst_for_method): Ditto.
8822 2006-05-05 Zoltan Varga <vargaz@gmail.com>
8824 * inssel.brg (mini_emit_virtual_call): Fix a warning.
8826 2006-05-05 Martin Baulig <martin@ximian.com>
8828 * debug-mini.c (mono_debug_open_block): New method.
8831 (mono_arch_output_basic_block): Call mono_debug_open_block() at
8832 the beginning of each basic block.
8835 (mono_arch_output_basic_block): Call mono_debug_open_block() at
8836 the beginning of each basic block.
8838 2006-05-04 Massimiliano Mantione <massi@ximian.com>
8840 * driver.c: Disabled inline,consprop,copyprop,treeprop,deadce by
8841 default until I understand why they break the build on amd64.
8843 2006-05-04 Zoltan Varga <vargaz@gmail.com>
8845 * mini.c (mini_cleanup): Call mono_cleanup ().
8847 * mini.c (UNVERIFIED): New macro to make it easier to track down verification
8850 2006-05-04 Massimiliano Mantione <massi@ximian.com>
8852 * aliasing.c: Fixed shameful cut&paste error that caused JIT crashes.
8853 * driver.c: Enabled inline,consprop,copyprop,treeprop,deadce by
8854 default since all known bugs are fixed, and I cannot reproduce bug
8855 77944... I'm asking Matt Hargett to test again after this commit.
8857 2006-04-28 Massimiliano Mantione <massi@ximian.com>
8859 * mini-codegen.c: Fixed typo that thrashed inline.
8861 2006-04-28 Zoltan Varga <vargaz@gmail.com>
8863 * dominators.c (compute_dominators): Avoid using a worklist since
8864 it is not correct in some cases. Instead, iterate over all bblocks as
8865 in the original paper. Fixes --compile-all -O=all System.Xml.dll.
8867 2006-04-28 Miguel de Icaza <miguel@novell.com>
8869 * mini.c (mono_jit_compile_method_inner): Use
8870 mono_prepare_exception_from_error that resets the value
8873 2006-04-27 Miguel de Icaza <miguel@novell.com>
8875 * mini.c: Move the mini_loader_error_to_exception to metadata.
8877 2006-04-27 Massimiliano Mantione <massi@ximian.com>
8879 * aliasing.c: Fixed bug 78210.
8881 2006-04-27 Massimiliano Mantione <massi@ximian.com>
8883 * driver.c: Disabled inline,consprop,copyprop,treeprop,deadce by
8884 default until all their problems (or the ones they trigger) are fixed.
8886 2006-04-26 Zoltan Varga <vargaz@gmail.com>
8888 * aot-runtime.c (mono_aot_get_method_from_token_inner): Fix the previous patch.
8890 * aot-runtime.c (mono_aot_get_method_from_token_inner): Mark the method
8891 as loaded only after resolving patches since that could invoke the same method.
8893 * aot-runtime.c (mono_aot_plt_resolve): Fix ppc etc. builds.
8895 * aot-compiler.c: Refactor mono_aot_compile_aot () into a bunch of smaller
8898 * aot-runtime.c (init_plt): Use a normal trampoline to transfer code to the
8901 * aot-compiler.c (emit_plt): Pass the plt offset in %eax instead of on the
8904 * mini-trampolines.c (mono_aot_plt_trampoline): New trampoline to handle calls
8905 made from AOT code through the PLT table.
8907 * mini-x86.h mini-amd64.h: Define MONO_ARCH_AOT_PLT_OFFSET_REG to the register
8908 holding the plt offset when a call is made to the aot plt trampoline.
8910 2006-04-25 Zoltan Varga <vargaz@gmail.com>
8912 * aot-runtime.c aot-compiler.c cpu-amd64.md mini-amd64.c: Update parts of the
8915 * Makefile.am (common_sources): Fix build breakage.
8917 * aot-runtime.c aot-compiler.c: Reorganize the AOT code yet again: Make all
8918 calls through a jump table similar to the ELF PLT table. Avoid indirect calls for
8919 intra-assembly calls if possible.
8921 * tramp-*.c: Add new functions for patching/nullifying PLT entries.
8923 * mini-trampolines.c: Handle PLT entries.
8925 * mini.c: Avoid creating a GOT var for calls.
8927 * jit-icalls.c (helper_ldstr_mscorlib): New helper function for loading strings
8930 * jit-icalls.c (helper_newobj_mscorlib): New helper function to create objects
8933 * mini.c (mono_method_to_ir): Use the new helper functions in throw bblocks in
8936 * mini.h: Bump AOT file format version.
8938 * mini.c (get_basic_blocks): Fix the calculation of bb->out_of_line so it
8941 2006-04-25 Martin Baulig <martin@ximian.com>
8943 * driver.c: Disable copyprop, consprop and inline when running
8944 inside the debugger.
8946 2006-04-25 Martin Baulig <martin@ximian.com>
8948 * debug-debugger.h (MonoDebuggerInfo): Replaced `get_thread_id'
8949 with `get_current_thread' and added `detach'.
8950 (MonoDebuggerMetadataInfo): Added `thread_size',
8951 `thread_tid_offset', `thread_stack_ptr_offset' and
8952 `thread_end_stack_offset'.
8954 2006-04-25 Zoltan Varga <vargaz@gmail.com>
8956 * aot.c Makefile.am: Split aot.c into two new files aot-compiler.c and
8959 * inssel.brg (mini_emit_load_intf_reg_vtable): Use a new kind of AOT constant
8960 ADJUSTED_IID to avoid the need for adjusting the IID at runtime.
8962 * mini.h (MonoJumpInfoType): Add MONO_PATCH_INFO_ADJUSTED_IID.
8964 * mini.c (mono_resolve_patch_target): Handle ADJUSTED_IID.
8966 * aot.c: Add support for ADJUSTED_IID.
8968 2006-04-24 Zoltan Varga <vargaz@gmail.com>
8970 * aot.c (emit_method_order): Don't align method_order_end.
8972 * inssel.brg (stmt): Fix interface calls in AOT code which got broken by
8973 the interface ID changes.
8975 2006-04-21 Dick Porter <dick@ximian.com>
8977 * mini.c (mini_thread_cleanup): Clear the JIT TLS data when
8978 cleaning up a thread. Fixes the new part of bug 77470.
8980 2006-04-20 Geoff Norton <gnorton@customerdna.com>
8982 * mini-ppc.c: Call mono_jit_thread_attach when transitioning a native
8985 2006-04-19 Zoltan Varga <vargaz@gmail.com>
8987 * mini.h mini.c: Remove mono_type_to_ldind/stind () which are now in marshal.c.
8989 * mini.c (mono_runtime_install_handlers): Handle SIGABRT similarly to
8990 SIGSEGV. Fixes #78072.
8992 * mini-exceptions.c (mono_handle_native_sigsegv): Add a 'signal' argument,
8993 unregister our SIGABRT handler.
8995 2006-04-19 Massimiliano Mantione <massi@ximian.com>
8997 * mini.c: Disabled inline where it can alter the call stack in a
8998 way visible from managed code.
8999 * driver.c: enabled inline,consprop,copyprop,treeprop,deadce by
9002 2006-04-16 Zoltan Varga <vargaz@gmail.com>
9004 * mini-amd64.c (mono_arch_emit_prolog): Attach the thread to the runtime as it is done
9005 on other platforms. Fixes #78089.
9007 2006-04-13 Martin Baulig <martin@ximian.com>
9009 * driver.c: Also check a `MONO_INSIDE_MDB' environment variable to
9010 determine whether we're inside the debugger.
9013 (MonoDebuggerMetadataInfo): Added all offsets from `MonoDefaults'.
9015 2006-04-12 Zoltan Varga <vargaz@gmail.com>
9017 * mini.c (mono_method_to_ir): Handle multiple LEAVE statements inside a single
9018 handler clauses. Fixes #78024.
9020 * mini-sparc.c (mono_arch_output_basic_block): Handle large offsets
9021 in the CALL_MEMBASE opcodes. Fixes #78088.
9022 (mono_arch_get_vcall_slot_addr): Ditto.
9024 2006-04-10 Martin Baulig <martin@ximian.com>
9026 * debug-debugger.c: The thread handling code has now been moved
9027 into ../metadata/threads.c.
9029 2006-04-10 Zoltan Varga <vargaz@gmail.com>
9031 * driver.c (mono_main): Fix --with-gc=none build.
9033 * mini-codegen.c (mono_spillvar_offset): Improve alignment.
9034 (mono_spillvar_offset_float): Ditto.
9035 (mono_local_regalloc): Only do the OP_MOVE optimization if ins->dreg is a local
9036 hreg, not when its !global, since on ia64, there is a third category: stacked
9039 Mon Apr 10 14:39:49 CEST 2006 Paolo Molaro <lupus@ximian.com>
9041 * mini.c: set MonoInst->klass for load field address and a few other
9044 2006-04-10 Zoltan Varga <vargaz@gmail.com>
9046 * helpers.c (mono_disassemble_code): Emit debug info on amd64 as well.
9048 2006-04-07 Zoltan Varga <vargaz@gmail.com>
9050 * dominators.c (compute_dominators): Fix yet another bug which surfaced after
9051 the branch opt changes.
9053 2006-04-06 Dick Porter <dick@ximian.com>
9055 * wapihandles.c (mini_wapi_semdel): Fix parameters in semctl () call.
9057 * wapihandles.c (mini_wapi_seminfo):
9058 * driver.c (mono_main): Add semaphore info option
9060 2006-04-05 Zoltan Varga <vargaz@gmail.com>
9062 * dominators.c (compute_dominators): Fix a bug which surfaced after the recent
9063 branch optimization changes. Fixes #78009.
9065 Wed Apr 5 16:40:33 CEST 2006 Paolo Molaro <lupus@ximian.com>
9067 * mini.c: ignore accessibility of methods in managed->native wrappers.
9069 2006-04-04 Zoltan Varga <vargaz@gmail.com>
9071 * mini.c (mini_cleanup): Call print_jit_stats () earlier since it accesses metadata.
9073 * mini.c (mini_cleanup): Free 'emul_opcode_map' as well.
9075 2006-04-03 Zoltan Varga <vargaz@gmail.com>
9077 * mini.c: Modify the branch optimizations to preserve the invariant that
9078 the entries inside the in_bb and out_bb arrays are unique.
9079 (mono_unlink_bblock): Avoid creation of new arrays.
9081 2006-04-02 Zoltan Varga <vargaz@gmail.com>
9083 * mini.c (mono_unlink_bblock): Fix regression caused by previous
9086 2006-04-01 Zoltan Varga <vargaz@gmail.com>
9088 * mini.c (optimize_branches): Remove the "optimizations" in
9089 the cbranch1/cbranch2 -> branch cases which were causing several
9090 problems in the past. Fixes #77986.
9092 2006-03-31 Chris Toshok <toshok@ximian.com>
9094 * driver.c (DEFAULT_OPTIMIZATIONS): back out the new set of
9095 default optimizations :(
9097 2006-03-31 Zoltan Varga <vargaz@gmail.com>
9099 * inssel-x86.brg mini-codegen.c mini.c: Merge some changes/fixes from linear-il
9102 2006-03-31 Massimiliano Mantione <massi@ximian.com>
9104 * local-propagation.c: Added comments to structs and removed
9105 "Mono" prefixes from local tree mover types.
9107 2006-03-30 Zoltan Varga <vargaz@gmail.com>
9109 * Makefile.am (arch_sources): Define this for each architecture so
9110 libmono_la_SOURCES is defined in one place.
9112 Wed Mar 29 20:51:14 CEST 2006 Paolo Molaro <lupus@ximian.com>
9114 * driver.c, wapihandles.c, Makefile.am: integrate the io-layer utils
9117 Wed Mar 29 17:16:57 CEST 2006 Paolo Molaro <lupus@ximian.com>
9119 * driver.c: print the GC name supplied by configure.
9121 2006-03-29 Massimiliano Mantione <massi@ximian.com>
9123 * local-propagation.c: Added tree mover, and moved here all the
9124 local propagation code from mini.c
9125 * mini.c: Added support for treeprop, and moved all the local
9126 propagation code to local-propagation.c
9127 * mini.h: Added support for treeprop
9128 * driver.c: Added support for treeprop, enabled consprop, copyprop,
9129 treeprop, inline and deadce by default
9130 * Makefile.am: Added local-propagation.c
9132 2006-03-25 Zoltan Varga <vargaz@gmail.com>
9134 * exceptions-sparc.c: Applied patch from David S. Miller <davem@sunset.davemloft.net>: Implement correct support for sparc/linux.
9136 Fri Mar 24 20:07:19 CET 2006 Paolo Molaro <lupus@ximian.com>
9138 * debug-debugger.c: make it compile without the Boehm GC.
9140 Wed Mar 22 18:25:18 CET 2006 Paolo Molaro <lupus@ximian.com>
9142 * mini.c: fixed issue with mismatch when an icall is registered
9143 with multiple names but same address.
9145 Tue Mar 21 15:59:57 CET 2006 Paolo Molaro <lupus@ximian.com>
9147 * declsec.c, mini-exceptions.c: use write barrier to set reference
9148 fields of managed objects.
9150 2006-03-19 Zoltan Varga <vargaz@gmail.com>
9152 * mini.c (mono_print_method_from_ip): Recognize JIT trampolines as well.
9153 (can_access_internals): Fix a warning.
9155 * mini.c (print_method_from_ip): Rename this to
9156 mono_print_method_from_ip so it gets exported.
9158 * trace.c: Deal with strings inside StringBuilder's containing garbage
9159 and fix memory leaks. Fixes #77848.
9161 2006-03-19 Zoltan Varga <vargaz@gmail.com>
9163 * mini.c (mini_init): Disable the setting of GC_stackbottom on ia64. Hopefully
9166 2006-03-16 Neale Ferguson <neale@sinenomine.net>
9168 * mini-s390.c: Remove OP_X86_TEST_NULL.
9170 Thu Mar 16 17:19:04 CET 2006 Paolo Molaro <lupus@ximian.com>
9172 * mini.c: use the correct GetHashCode() for the moving collector.
9174 2006-03-16 Massimiliano Mantione <massi@ximian.com>
9176 * liveness.c: Regalloc spill cost tuning.
9178 2006-03-15 Neale Ferguson <neale@sinenomine.net>
9180 * mini-s390x.h: Correct S390_LONG macro.
9182 * mini-s390x.c: Cleanup unused code.
9184 2006-03-15 Zoltan Varga <vargaz@gmail.com>
9186 * jit-icalls.h: New file.
9188 * Makefile.am mini.c jit-icalls.c: Use a proper include file for the jit
9189 icalls and include that instead of including jit-icalls.c.
9191 * mini-ppc.c (mono_arch_output_basic_block): Remove references to
9194 Tue Mar 14 20:23:53 CET 2006 Paolo Molaro <lupus@ximian.com>
9196 * mini.c: when checking for member accessibility, also check for
9197 friend assemblies and for explicit interface implementations.
9199 2006-03-14 Zoltan Varga <vargaz@gmail.com>
9201 * mini-codegen.c (mono_local_regalloc): Remove incorrect g_free () calls.
9203 * cpu-arm.md cpu-g4.md: Remove x86_ opcodes.
9205 * mini-x86.h (MONO_ARCH_INST_FIXED_REG): Reorganize the comparisons so
9206 common cases are done first.
9208 * mini-ops.h: Only define platform specific opcodes on the given platform.
9210 * mini.h regalloc.h mini-codegen.c: Merge optimizations from the linear-il
9213 2006-03-14 Martin Baulig <martin@ximian.com>
9215 Revert Paolo's change from r57348:
9217 * mini.h: don't use gboolean for bitfields.
9218 * mini.c: verifier changes for fields and methods accessibility.
9220 2006-03-13 Neale Ferguson <neale@sinenomine.net>
9222 * mini-s390.h, mini-s390x.h: Fix calls to mono_call_inst_add_outarg_reg.
9224 * mini-s390x.c: Fix conv_r_un.
9226 * cpu-s390, cpu-s390x.md: Fix lengths.
9228 Sun Mar 12 17:31:22 CET 2006 Paolo Molaro <lupus@ximian.com>
9230 * mini.c: nested types have access to all the nesting
9231 levels, not just the enclosing types.
9233 Sun Mar 12 16:23:11 CET 2006 Paolo Molaro <lupus@ximian.com>
9235 * mini.c: added a few more verification checks.
9237 2006-03-12 Zoltan Varga <vargaz@gmail.com>
9239 * liveness.c: Merge optimizations from the linear-il branch.
9241 2006-03-11 Zoltan Varga <vargaz@gmail.com>
9243 * mini-ia64.c (emit_call): Add a comment.
9245 * tramp-ia64.c (mono_arch_patch_callsite): Handle indirect calls as well.
9247 * tramp-ia64.c: Fix some warnings.
9249 Sat Mar 11 20:15:59 CET 2006 Paolo Molaro <lupus@ximian.com>
9251 * mini.h: don't use gboolean for bitfields.
9252 * mini.c: verifier changes for fields and methods accessibility.
9254 2006-03-11 Zoltan Varga <vargaz@gmail.com>
9256 * mini.c (mono_icall_get_wrapper): Fix an ia64 bug introduced by the
9257 lazy icall wrapper changes.
9259 * dominators.c: Replace all the dominator algorithms with faster
9260 ones from the linear-il branch.
9262 * inssel-*.brg: Allocate call->out_ireg_args and call->out_freg_args from
9265 * mini-amd64.h (MONO_ARCH_INST_FIXED_REG): Reorganize the comparisons so
9266 common cases are done first.
9268 * mini-amd64.c: Fix some warnings.
9270 * mini-codegen.c mini-*.c: Allocate call->out_ireg_args and call->out_freg_args
9273 * mini.c (mono_jit_compile_method_with_opt): Fix a race in the newly
9276 * mini.h: Add a missing prototype.
9278 2006-03-10 Zoltan Varga <vargaz@gmail.com>
9280 * mini.c: Compile icall wrappers lazily.
9282 * mini-codegen.c: Use printf instead of g_print since its much faster.
9284 * mini.h (mono_bitset_foreach_bit): Use the faster mono_bitset_find_start ()
9287 * mini.c (optimize_branches): Cache the negative result from
9288 remove_block_if_useless ().
9290 * mini.c (optimize_branches): Avoid restarting the iteration after each change.
9291 Also fix some bblock linking issues.
9293 * helpers.c (mono_disassemble_code): Reduce the size of the temporary
9296 * mini.h: Define G_LIKELY/G_UNLIKELY macros for older glib versions.
9298 * mini.h (MonoBasicBlock): Reorganize the fields, putting more frequently
9299 accessed fields first, for better cache behavior.
9301 Fri Mar 10 18:21:41 CET 2006 Paolo Molaro <lupus@ximian.com>
9303 * mini.c: speedup IList<T> array accesses.
9305 2006-03-09 Zoltan Varga <vargaz@gmail.com>
9307 * mini.c (mono_method_to_ir): Handle large methods overflowing the
9308 inline_costs counter. Fixes #77190.
9310 2006-03-06 Zoltan Varga <vargaz@gmail.com>
9312 * mini-exceptions.c: Call mono_trace_is_enabled () before printing
9313 trace messages. Fixes #77706.
9315 2006-03-04 Martin Baulig <martin@ximian.com>
9317 * tramp-amd64.c, tramp-x86.c
9318 (mono_debugger_create_notification_function): Use
9319 mono_global_codeman_reserve() to allocate a buffer at runtime and
9322 * debug-debugger.h (MonoDebuggerInfo): Added `initialize'.
9324 * debug-debugger.c (mono_debugger_init): Dynamically allocate the
9325 notification function at runtime and then call `initialize' in the
9326 `MONO_DEBUGGER__debugger_info' vtable.
9328 2006-03-04 Zoltan Varga <vargaz@gmail.com>
9330 * iltests.il: Fix a visibility problem.
9332 Wed Mar 1 15:55:25 CET 2006 Paolo Molaro <lupus@ximian.com>
9334 * driver.c, mini.c: add hooks for the counters API.
9336 Wed Mar 1 12:28:04 CET 2006 Paolo Molaro <lupus@ximian.com>
9338 * driver.c: show disabled options.
9340 Wed Mar 1 12:18:51 CET 2006 Paolo Molaro <lupus@ximian.com>
9342 * linear-scan.c: always use cost-driven selection.
9344 2006-02-28 Raja R Harinath <rharinath@novell.com>
9346 * jit-icalls.c (helper_compile_generic_method): Revert change from
9349 Mon Feb 27 18:58:19 GMT 2006 Paolo Molaro <lupus@ximian.com>
9351 * cpu-arm.md, mini-arm.c: implemented MemoryBarrier.
9353 Sat Feb 25 17:39:21 CET 2006 Paolo Molaro <lupus@ximian.com>
9355 * inssel.brg: style fixes, mostly to force the updated monoburg
9356 to run for people using svn.
9358 Sat Feb 25 17:07:42 CET 2006 Paolo Molaro <lupus@ximian.com>
9360 * mini.c: match monoburg changes.
9362 Sat Feb 25 16:04:33 CET 2006 Paolo Molaro <lupus@ximian.com>
9364 * mini.h, mini.c, abcremoval.c, aliasing.c, liveness.c,
9365 ssapre.c, graph.c, ssa.c: put the mono_burg_arity[]
9366 declaration in the header file.
9368 Sat Feb 25 14:19:31 CET 2006 Paolo Molaro <lupus@ximian.com>
9370 * helpers.c: reduce relocations and mem usage.
9372 Sat Feb 25 11:58:16 CET 2006 Paolo Molaro <lupus@ximian.com>
9374 * mini.h, mini-codegen.c: disable logging features if
9375 requested by configure.
9377 Sat Feb 25 11:54:49 CET 2006 Paolo Molaro <lupus@ximian.com>
9379 * mini.c: tiny verifier changes.
9381 Fri Feb 24 18:17:52 CET 2006 Paolo Molaro <lupus@ximian.com>
9383 * mini-ops.h, inssel-x86.brg, tramp-x86.c, mini-x86.c,
9384 cpu-pentium.md: stack alignment changes for osx/x86,
9385 partially from Geoff Norton <gnorton@customerdna.com>.
9387 2006-02-24 Raja R Harinath <harinath@gmail.com>
9389 * jit-icalls.c (helper_compile_generic_method): Update to changes
9390 in metadata/class.c.
9392 2006-02-24 Zoltan Varga <vargaz@gmail.com>
9394 * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add a missing check.
9396 * mini-amd64.c (mono_arch_get_vcall_slot_addr): Add support for
9397 interface calls with large offsets.
9399 2006-02-23 Raja R Harinath <rharinath@novell.com>
9401 * jit-icalls.c (helper_compile_generic_method): Document the
9402 special-case we depend on so that we can inflate the method twice
9403 with the same context with no bad side-effects.
9405 Thu Feb 23 13:45:46 CET 2006 Paolo Molaro <lupus@ximian.com>
9407 * mini-x86.c, mini-amd64.c: fix for case when xen support
9410 Wed Feb 22 19:38:40 CET 2006 Paolo Molaro <lupus@ximian.com>
9412 * mini-x86.c, mini-amd64.c: generate code to access tls items
9413 in a faster way for Xen systems.
9415 Wed Feb 22 10:31:25 CET 2006 Paolo Molaro <lupus@ximian.com>
9417 * exceptions-x86.c, mini-x86.h, driver.c, mini-codegen.c:
9418 updates and compilation fixes for the OSX/x86 port, mostly from
9419 Geoff Norton <gnorton@customerdna.com>.
9421 Tue Feb 21 19:56:55 CET 2006 Paolo Molaro <lupus@ximian.com>
9423 * inssel.brg: faster interface call implementation
9424 to sync with the interface_offsets MonoVTable changes.
9426 Mon Feb 20 10:37:57 CET 2006 Paolo Molaro <lupus@ximian.com>
9428 * mini.c: more verification checks.
9430 Fri Feb 17 19:47:29 CET 2006 Paolo Molaro <lupus@ximian.com>
9432 * mini.c: added a few more verification checks.
9434 2006-02-17 Neale Ferguson <neale@sinenomine.net>
9436 * mini-s390x.c, mini-s390x.h: Check for presence of long displacement
9437 facility on the processor and use it if available.
9439 Fri Feb 17 16:12:52 CET 2006 Paolo Molaro <lupus@ximian.com>
9441 * driver.c, aot.c, mini.c: throw exception if the IL code is
9442 invalid or unverifiable.
9444 2006-02-17 Raja R Harinath <rharinath@novell.com>
9446 * generics.2.cs (test_0_ldfld_stfld_mro): Use m.struct_field, not
9449 2006-02-16 Zoltan Varga <vargaz@gmail.com>
9451 * generics.2.cs: Add some tests for generics ldfld/stfld wrappers.
9453 Wed Feb 15 16:23:17 CET 2006 Paolo Molaro <lupus@ximian.com>
9455 * mini-s390x.c, mini-s390.c, mini.c, mini-amd64.c, mini-arm.c,
9456 mini-ia64.c, mini-sparc.c, mini-x86.c, mini-ppc.c: fixed
9457 handling of instantiated generic valuetypes.
9459 2006-02-11 Zoltan Varga <vargaz@gmail.com>
9461 * mini-exceptions.c mini-x86.h mini-x86.c: Get rid of
9462 MONO_INIT_CONTEXT_FROM_CALLER, and use MONO_INIT_CONTEXT_FROM_FUNC
9465 * generics.2.cs: Revert the nullable reftypes tests.
9467 2006-02-10 Zoltan Varga <vargaz@gmail.com>
9469 * mini-exceptions.c (MONO_INIT_CONTEXT_FROM_CALLER): Avoid
9470 using __builtin_frame_address (1) as it doesn't work in the presence
9471 of optimizations. Hopefully fixes #77273.
9473 * Makefile.am generics.cs generics.2.cs: Revert the generics.2.cs
9474 -> generics.cs change as it doesn't work with some automake versions.
9476 Thu Feb 9 16:24:44 CET 2006 Paolo Molaro <lupus@ximian.com>
9478 * mini.c: handle systems that sue a different way to
9479 retrieve the stack address of the current thread.
9481 2006-02-09 Zoltan Varga <vargaz@gmail.com>
9483 * Makefile.am generics.2.cs: Rename this to generics.cs and handle
9484 it specially in the makefile.
9486 * generics.2.cs: Add tests for nullable reference types.
9488 Wed Feb 8 19:33:17 CET 2006 Paolo Molaro <lupus@ximian.com>
9490 * mini.c: always handle the case when mono_jit_init()
9491 is called in a thread different from the main thread,
9492 confusing libgc (bug #77309).
9494 Mon Feb 6 09:01:24 EST 2006 Paolo Molaro <lupus@ximian.com>
9496 * mini-ppc.c: fix handling of exceptions in large methods (bug #74932).
9498 Fri Feb 3 18:51:35 CET 2006 Paolo Molaro <lupus@ximian.com>
9500 * mini.c: change optimize_branches () to use a single loop
9501 and introduce a new optimization to simplify some range checks.
9503 2006-02-03 Martin Baulig <martin@ximian.com>
9505 * debug-debugger.c (debugger_thread_manager_thread_created): Removed
9506 and merged with debugger_thread_manager_add_thread().
9507 (mono_debugger_main): Call debugger_thread_manager_add_thread() to
9508 inform the debugger about the main thread.
9510 2006-02-03 Zoltan Varga <vargaz@gmail.com>
9512 * basic.cs: Add test for div.un/rem.un constant folding.
9514 2006-02-03 Neale Ferguson <neale@sinenomine.net>
9516 * cpu-s390x.md: correct int_xor_imm length
9518 2006-02-03 Zoltan Varga <vargaz@gmail.com>
9520 * generics.2.cs: New test for #77442.
9522 * jit-icalls.c (helper_compile_generic_method): Check for null. Fixes
9525 2006-02-02 Martin Baulig <martin@ximian.com>
9527 * tramp-x86.c, tramp-amd64.c: It's now safe to #include
9528 <mono/metadata/mono-debug-debugger.h>
9530 * debug-mini.c: Don't #define _IN_THE_MONO_DEBUGGER.
9532 2006-02-02 Martin Baulig <martin@ximian.com>
9534 * debug-debugger.h: New header file for debug-debugger.c.
9536 * debug-debugger.c: Big API cleanup; don't run the managed Main()
9537 function is a separate thread anymore; add support for attaching.
9539 2006-02-01 Zoltan Varga <vargaz@gmail.com>
9541 * tramp-x86.c: Fix a warning.
9543 2006-01-31 Zoltan Varga <vargaz@gmail.com>
9545 * mini-amd64.c (mono_arch_compute_omit_fp): Avoid hitting an assertion
9546 on very large methods.
9548 * aot.c (load_patch_info): Fix a warning.
9550 Mon Jan 30 12:51:10 CET 2006 Paolo Molaro <lupus@ximian.com>
9552 * cpu-pentium.md, mini-x86.c, inssel.brg, inssel-x86.brg,
9553 mini-ops.h: alu membase optimizations.
9555 Fri Jan 27 21:11:08 CET 2006 Paolo Molaro <lupus@ximian.com>
9557 * mini-ops.h, mini.c, inssel.brg, inssel-x86.brg: opcode
9558 to speedup StringBuilder.
9560 2006-01-27 Zoltan Varga <vargaz@gmail.com>
9562 * dominators.c (mono_compute_natural_loops): Fix detection of
9563 loop body start blocks.
9565 * mini-exceptions.c (mono_print_thread_dump): Fix non x86 builds.
9567 2006-01-26 Zoltan Varga <vargaz@gmail.com>
9569 * mini.h mini.c mini-exceptions.c: Add thread dump support. Fixes
9572 2006-01-25 Massimiliano Mantione <massi@ximian.com>
9574 * aliasing.c: Fixed aliasing issue on 64 bit archs.
9576 2006-01-25 Martin Baulig <martin@ximian.com>
9578 * debug-debugger.c: Moved the `MonoDebuggerManager' and
9579 `MonoDebuggerThread' typedefs here from mono-debug-debugger.h and
9580 started to cleanup this file a little bit.
9582 Tue Jan 24 18:20:48 CET 2006 Paolo Molaro <lupus@ximian.com>
9584 * mini.c: optimize a codepath frequently happening in generics code.
9586 2006-01-23 Martin Baulig <martin@ximian.com>
9588 * Makefile.am: Only compile debug-debugger.c on supported platforms.
9590 * debug-debugger.c: Kill the IO_LAYER() hack and use the io-layer
9593 * driver.c: debug-debugger.c is only available if
9594 `MONO_DEBUGGER_SUPPORTED' is defined.
9596 2006-01-23 Martin Baulig <martin@ximian.com>
9598 * debug-debugger.c: Only enable this on platforms where the Mono
9599 Debugger is working (x86 and x86_64).
9601 2006-01-21 Martin Baulig <martin@ximian.com>
9603 The Mono Debugger is now using the normal `mono' instead of the
9604 `mono-debugger-mini-wrapper' when executing managed code.
9606 * debug-debugger.c: New file; previously known as
9607 debugger/wrapper/wrapper.c.
9609 * debug-mini.c (mono_init_debugger): Removed.
9611 * driver.c (mono_main): Added new `--inside-mdb' command line
9612 argument which is used when running inside the debugger.
9614 2006-01-20 Zoltan Varga <vargaz@gmail.com>
9616 * liveness.c (mono_analyze_liveness): Remove some unused data
9619 2006-01-17 Zoltan Varga <vargaz@gmail.com>
9621 * mini.h: Move mono_bitset_test_fast macro to monobitset.h where it belongs.
9623 2006-01-16 Zoltan Varga <vargaz@gmail.com>
9625 * mini.h (mono_bitset_test_fast): Disable the 'fast' implementation which
9626 depends on implementation details of monobitset.
9628 * mini.c (mini_get_ldelema_ins): Fix handling of 1 dimensional arrays.
9631 2006-01-15 Zoltan Varga <vargaz@gmail.com>
9633 * liveness.c: Update after monobitset changes.
9635 2006-01-14 Zoltan Varga <vargaz@gmail.com>
9637 * mini-amd64.c (mono_arch_compute_omit_fp): Fix a leak.
9639 2006-01-11 Neale Ferguson <neale@sinenomine.net>
9641 * inssel-s390x.brg: Fix reg: OP_LDADDR(OP_S390_LOADARG) register setting.
9643 * mini-s390x.c: Remove warning messages.
9645 2006-01-11 Ben Maurer <bmaurer@andrew.cmu.edu>
9647 * mini.c: pass the jitinfo to mono_profiler_method_end_jit.
9649 2006-01-10 Zoltan Varga <vargaz@gmail.com>
9651 * generics.2.cs: Add ldelem/stelem_any test.
9653 2006-01-10 Neale Ferguson <neale@sinenomine.net>
9655 * mini-s390.c: Fix ATOMIC_ADD_I4 operation.
9657 2006-01-07 Zoltan Varga <vargaz@gmail.com>
9659 * inssel-long.brg: Fix int->long ovf conversion rules. Fixes #77172.
9661 2006-01-06 Zoltan Varga <vargaz@gmail.com>
9663 * generics.2.cs: Reenable vtype tests.
9665 * inssel-x86.brg: Remove an icorrect valuetype rule.
9667 2006-01-06 Neale Ferguson <neale@sinenomine.net>
9669 * mini-s390x.c, inssel-s390x.brg, cpu-s390x.md: Fix ATOMIC_I8 operations. Provide
9670 initial support for OP_ABS.
9672 2006-01-05 Neale Ferguson <neale@sinenomine.net>
9674 * mini-s390x.c (emit_float_to_int): Correct r8 to unsigned int algorithm.
9676 2006-01-05 Neale Ferguson <neale@sinenomine.net>
9678 * mini-s390.c, mini-s390.h, inssel-s390.brg, cpu-s390.md: Fix r8 to unsigned int
9679 conversion and implement LADD/LSUB.
9681 * exceptions-s390.c: Standardize mono_arch_find_jit_info to match other
9684 2006-01-05 Neale Ferguson <neale@sinenomine.net>
9686 * mini-s390x.c, mini-s390x.h: Fix r8 to unsigned int conversion.
9688 * exceptions-s390x.c: Standardize mono_arch_find_jit_info to match other
9691 2006-01-05 Neale Ferguson <neale@sinenomine.net>
9693 * mini-s390x.c, mini-s390x.h, mini-s390.c, mini-s390.h: Fix lmf handling when
9694 localloc is encountered. Fixes crash in test-183.cs when using gmcs
9695 (stack walk problem).
9697 2006-01-04 Zoltan Varga <vargaz@gmail.com>
9699 * aot.c (mono_aot_load_method): Fix a warning.
9701 2006-01-03 Neale Ferguson <neale@sinenomine.net>
9703 * mini-s390x.h, exceptions-s390x.c, inssel-s390x.brg: Fix compiler warnings
9705 2006-01-03 Zoltan Varga <vargaz@gmail.com>
9707 * iltests.il: Add test for #77148.
9709 * mini.c (mini_get_ldelema_ins): Handle arrays with rank 1 too. Fixes
9712 2006-01-03 Neale Ferguson <neale@sinenomine.net>
9714 * mini-s390x.c, inssel-s390x.brg: Remove debug statements
9716 2006-01-03 Neale Ferguson <neale@sinenomine.net>
9718 * mini-s390x.c, mini-s390x.h, exceptions-s390x.c, tramp-s390x.c, inssel-s390x.brg,
9719 cpu-s390x.md, mini-codegen.c, Makefile.am: add 64-bit s390 support to JIT.
9721 * basic-long.cs: Add lconv-to-r4/r8 tests.
9723 2006-01-03 Zoltan Varga <vargaz@gmail.com>
9725 * mini.c (mono_method_to_ir): Fix DynamicMethod support in some opcodes.
9727 * mini-sparc.c (mono_arch_call_opcode): Use mono_class_value_size ()
9728 here as on other archs.
9730 2005-12-29 Neale Ferguson <neale@sinenomine.net>
9732 * mini-s390.c (mono_arch_get_inst_for_method): Add memory_barrier support.
9734 2005-12-29 Neale Ferguson <neale@sinenomine.net>
9736 * inssel-s390.brg: Correct register assignment; Rework L[ADD|SUB]_OVF[_UN] for s390.
9738 * cpu-s390.md: Fix lengths of a couple of long instructions; Add memory_barrier.
9740 * mini-s390.c: Fix long add/sub overflow instructions; Fix displacement handling in
9741 instrument_prolog; Add memory_barrier instruction.
9743 2005-12-26 Zoltan Varga <vargaz@gmail.com>
9745 * exceptions-x86.c mini-x86.h: Fix solaris/x86 exception handling.
9747 2005-12-23 Zoltan Varga <vargaz@gmail.com>
9749 * tramp-ia64.c (mono_arch_get_unbox_trampoline): Flush icache.
9751 * aliasing.c inssel.brg: Fix warnings.
9753 * inssel-ia64.brg (OP_MEMSET): Fix an optimization which previously
9754 could skip initialization of some parts of memory.
9756 * mini.c mini-ia64.c: Fix warnings.
9758 * inssel-sparc.brg: Add an implementation of lneg which actually works.
9760 2005-12-22 Zoltan Varga <vargaz@gmail.com>
9762 * aliasing.c (mono_build_aliasing_information): Add a workaround for
9763 a crash seen on sparc.
9765 * mini-sparc.c: Add implementation of Thread.MemoryBarrier.
9767 * cpu-sparc.md: Add memory_barrier opcode. Remove unused opcodes.
9769 2005-12-21 Neale Ferguson <neale@sinenomine.net>
9771 * mini-ops.h: Add s390_backchain instruction
9773 * inssel-s390.brg: Use backchaining instruction for LOADARG/STKARG operations.
9775 * cpu-s390.md: Add s390_backchain instruction
9777 * mini-s390.c: Significant ABI changes
9779 * mini-s390.h: Cater for zero length structures
9781 2005-12-20 Neale Ferguson <neale@sinenomine.net>
9783 * mini-s390.c: ABI fixes
9785 * inssel-s390.brg: Remove debug statements
9787 * cpu-s390.md: Fix length of ATOMIC_xx operations
9789 2005-12-19 Zoltan Varga <vargaz@gmail.com>
9791 * basic-float.cs: Add float<->long conversion tests.
9793 2005-12-16 Neale Ferguson <neale@sinenomine.net>
9795 * mini-s390.c: Fix LOCALLOC processing.
9797 * tramp-s390.c (s390_magic_trampoline): Fix base calculation.
9799 2005-12-15 Zoltan Varga <vargaz@gmail.com>
9801 * iltests.il: Add tests for some opcodes not covered by the other
9804 2005-12-15 Neale Ferguson <neale@sinenomine.net>
9806 * mini-s390.c: Fix ADDCC/SBB bug revealed by test_0_ulong_regress; Correct
9807 register loading for Tail processing; Correct trace output.
9809 * inssel-s390.brg: Reimplement LSUB_OVF due to s390 implementation of signed math.
9811 * cpu-s390.md: Correct size of jmp instruction.
9813 2005-12-13 Neale Ferguson <neale@sinenomine.net>
9815 * mini-s390.c (mono_arch_emit_prolog): Remove some debugging bits.
9817 2005-12-13 Neale Ferguson <neale@sinenomine.net>
9819 * inssel-s390.brg tramp-s390.c cpu-s390.md mini-s390.c mini-s390.h:
9820 Bring s390 up to current level.
9822 2005-12-12 Zltan Varga <vargaz@gmail.com>
9824 * generics.2.cs: Disable the newly added tests as they do not work yet.
9826 * generics.2.cs: Add valuetype tests.
9828 2005-12-09 Zoltan Varga <vargaz@gmail.com>
9830 * basic-long.cs: Add i4->u8 test.
9832 * objects.cs: Add tests for JIT intrinsic.
9834 * mini.c (mini_get_inst_for_method): Resurrect the array Rank/Length
9835 optimizations lost by a mistake.
9837 2005-12-07 Zoltan Varga <vargaz@gmail.com>
9839 * basic-long.cs: Remove a test moved to objects.cs.
9841 * arrays.cs: Add more array tests.
9843 2005-12-06 Zoltan Varga <vargaz@gmail.com>
9845 * arrays.cs: Add new tests for multi-dimensional arrays.
9847 2005-12-06 Raja R Harinath <rharinath@novell.com>
9849 * Makefile.am (test_sources2): Add generics.2.cs.
9850 (EXTRA_DIST): Add test_sources2.
9852 2005-12-05 Ben Maurer <bmaurer@ximian.com>
9854 Support for boxing and unboxing nullable types as well as the
9855 isinst operation on nullables, per the CLI ammendment.
9857 * inssel.brg (CEE_ISINST): Special case for nullable
9859 * mini.c (handle_unbox_nullable): new method
9860 (handle_box): Special case for nullable types
9861 (mono_method_to_ir): Call handle_unbox_nullable in correct
9864 * generics.2.cs: New test suite
9866 * Makefile.am: Support for regression tests with generics.
9868 2005-12-03 Zoltan Varga <vargaz@gmail.com>
9870 * mini-amd64.c (emit_load_volatile_arguments): Add loading of arguments
9871 allocated to registers. Fixes #76800.
9873 Thu Dec 1 12:59:40 EST 2005 Paolo Molaro <lupus@ximian.com>
9875 * mini-ppc.c, inssel-ppc.brg: fix ABI issue (pinvoke3.cs).
9877 2005-11-30 Zoltan Varga <vargaz@gmail.com>
9879 * exceptions.cs: Disable test_0_long_cast () test, since it fails on a lot
9882 2005-11-29 Zoltan Varga <vargaz@gmail.com>
9884 * objects.cs basic-calls.cs: Move a test depending on valuetypes to
9887 * inssel-long32.brg (CEE_CONV_I8): Remove unused labels.
9889 * inssel-long32.brg (CEE_CONV_I8): Convert this to a branchless version.
9890 Tue Nov 29 05:41:34 EST 2005 Paolo Molaro <lupus@ximian.com>
9892 * mini-ppc.c, cpu-g4.md: ensure a fp register is converted to
9893 single precision before storing to a single precision location.
9895 2005-11-28 Raja R Harinath <rharinath@novell.com>
9897 * Makefile.am (ILASM): Use profile-dependent location of ilasm.
9899 2005-11-27 Zoltan Varga <vargaz@gmail.com>
9901 * basic-long.cs basic-calls.cs objects.cs: Move some tests to the
9904 * basic.cs: Remove test_0_byte_compares test which was moved to
9905 objects.cs a long time ago.
9907 2005-11-22 Massimiliano Mantione <massi@ximian.com>
9909 * aliasing.c: Fixed aliasing issue on 64 bit archs.
9911 2005-11-20 Zoltan Varga <vargaz@gmail.com>
9913 * mini-ia64.c exceptions-ia64.c: Simplify the way filters/finally
9914 handlers are called.
9916 * mini-ia64.c (mono_arch_emit_exceptions): Optimize size of exception
9919 * mini-ia64.c: Add support for the throw->branch exception
9922 * driver.c (DEFAULT_OPTIMIZATIONS): Add MONO_OPT_EXCEPTION.
9924 2005-11-18 Massimiliano Mantione <massi@ximian.com>
9926 * mini.c: Enabled "fastpath" deadce :-)
9928 2005-11-18 Massimiliano Mantione <massi@ximian.com>
9930 * mini.c: Added "fastpath" deadce (deadce without SSA), and a simple
9931 alias analysis pass to support it.
9934 * liveness.c: Likewise (liveness computation can use aliasing
9935 information to be more accurate).
9936 * driver.c: Added an "ssa" option go tell the JIT to use SSA, and
9937 moreover made so that "--compile-all" uses the given optimization
9938 flags and not the default ones.
9939 * aliasing.c: Alias analysis (new file).
9940 * aliasing.h: Likewise.
9941 * Makefile.am: added "aliasing.c" and "aliasing.h".
9943 2005-11-17 Zoltan Varga <vargaz@gmail.com>
9945 * mini-ops.h: Add missing OP_I opcodes so it is in synch with the
9948 2005-11-13 Zoltan Varga <vargaz@gmail.com>
9950 * mini-exceptions.c (mono_handle_exception_internal): Remove the
9951 fp >= end_of_stack exit condition, as it is not needed, and it might
9952 become true for fp eliminated frames.
9954 2005-11-11 Zoltan Varga <vargaz@gmail.com>
9956 * mini-x86.c (mono_arch_emit_epilog): Use G_STRUCT_OFFSET instead of hard
9959 Tue Nov 8 11:28:20 GMT 2005 Paolo Molaro <lupus@ximian.com>
9961 * mini-arm.c: fixed alignment of doubles/longs to match
9962 the C ABI (bug #76635).
9964 Mon Nov 7 16:13:21 CET 2005 Paolo Molaro <lupus@ximian.com>
9966 * aot.c: fix compilation with --enable-minimal=aot.
9968 Fri Nov 4 12:34:15 GMT 2005 Paolo Molaro <lupus@ximian.com>
9970 * mini-arm.c: fixed compatibility with the new
9971 floating point emulator package for compares.
9973 2005-11-03 Atsushi Enomoto <atsushi@ximian.com?
9975 * mini.c : reverted sig->pinvoke changes (r51396-51397).
9977 2005-11-01 Zoltan Varga <vargaz@freemail.hu>
9979 * mini-exceptions.c (print_stack_frame): Output to stderr.
9980 (mono_handle_native_sigsegv): Ditto.
9982 2005-10-30 Zoltan Varga <vargaz@freemail.hu>
9984 * mini-amd64.c (mono_arch_output_basic_block): Remove unused
9985 OP_LCONV_TO_OVF_I implementation.
9987 * mini-amd64.c: Add support for the throw->branch exception
9990 * branch-opts.c (mono_branch_optimize_exception_target): Allow the case
9991 when the catch clause catches a more general exception, i.e. Object.
9993 2005-10-30 Zoltan Varga <vargaz@gmail.com>
9995 * cpu-ia64.md: Remove unused opcodes.
9997 * mini.c (GET_CONTEXT): Simplify this somewhat by removing arch
9998 specific defines for architectures defining USE_SIGACTION.
10000 * mini-ia64.c: Fix some warnings.
10002 * exceptions-ia64.c (mono_arch_ip_from_context): Fix this, the previous
10003 version seemed to skip a frame.
10005 2005-10-30 Zoltan Varga <vargaz@freemail.hu>
10007 * mini.c: Clean up the usage of sig->pinvoke flag. Now
10008 only calls which are made to native code use this flag.
10010 2005-10-29 Zoltan Varga <vargaz@freemail.hu>
10012 * mini-amd64.c (mono_arch_compute_omit_fp): Disable fp elimination for
10013 varargs methods as well.
10015 * mini-amd64.c exceptions-amd64.c: Allow fp elimination in methods
10016 which have save_lmf set. Reorganize methods prologs a bit.
10018 * mini-amd64.c (mono_arch_compute_omit_fp): Move the check for the
10019 debugger to the proper place.
10021 2005-10-29 Martin Baulig <martin@ximian.com>
10023 * mini-amd64.c (debug_omit_fp): Temporarily disable fp elimination
10024 when running inside the debugger until the debugger has support
10027 2005-10-26 Zoltan Varga <vargaz@gmail.com>
10029 * mini.h: Fix a warning.
10031 2005-10-24 Miguel de Icaza <miguel@novell.com>
10033 * mini.c (mono_pmip): Just a wrapper for get_method_from_ip which
10034 we expose publicly, this returns the string.
10036 2005-10-22 Zoltan Varga <vargaz@freemail.hu>
10038 * exceptions-amd64.c (mono_arch_find_jit_info): Fix some corner cases
10039 with fp elimination.
10041 2005-10-21 Zoltan Varga <vargaz@gmail.com>
10043 * mini-exceptions.c (mono_handle_native_sigsegv): Try to print a
10044 native stacktrace using the glibc 'backtrace' function if available.
10046 2005-10-20 Zoltan Varga <vargaz@gmail.com>
10048 * mini.h (MonoDebugOptions): Remove 'abort_on_sigsegv' option.
10050 * mini-exceptions.c (mono_handle_native_sigsegv): New function to
10051 handle SIGSEGVs received while in native code.
10053 * mini.c (sigsegv_signal_handler): If the SIGSEGV happened in native
10054 code, call mono_handle_native_sigsegv which will abort the runtime
10055 after printing some diagnostics, instead of converting it into a
10056 confusing NullReferenceException.
10058 2005-10-18 Zoltan Varga <vargaz@gmail.com>
10060 * cpu-pentium.md: Remove unused opcodes.
10062 2005-10-18 Zoltan Varga <vargaz@freemail.hu>
10064 * mini-amd64.h (MonoLMF): Add rsp field.
10066 * mini-amd64.c exceptions-amd64.c tramp-amd64.c: Save the sp reg into
10069 2005-10-17 Zoltan Varga <vargaz@gmail.com>
10071 * mini-codegen.c (get_register_spilling): Fix some warnings.
10073 2005-10-16 Zoltan Varga <vargaz@freemail.hu>
10075 * mini-amd64.h mini-amd64.c exceptions-amd64.c: Add support for fp
10076 elimination during exception handling. Enable fp elimination by
10079 * mini-amd64.h mini-amd64.c: Add preliminary support for frame pointer
10082 2005-10-16 Martin Baulig <martin@ximian.com>
10084 * mini-exceptions.c
10085 (mono_debugger_run_finally): New public method for the debugger.
10087 2005-10-10 Zoltan Varga <vargaz@gmail.com>
10089 * debug-mini.c (mono_debug_init_method): Fix warning.
10091 * mini.h branch-opts.c (mono_branch_optimize_exception_target): Make
10092 the 'exname' parameter const to fix some warnings.
10094 2005-10-09 Zoltan Varga <vargaz@freemail.hu>
10096 * mini-exceptions.c (mono_handle_exception_internal): Fix another bug
10097 introduced by the previous patch.
10099 2005-10-08 Zoltan Varga <vargaz@gmail.com>
10101 * basic-float.cs: Add test for precision of float arithmetic.
10103 * mini-ia64.c (mono_arch_output_basic_block): Convert to/from doubles
10104 when loading/storing single values from/to memory.
10106 * mini.c (mono_jit_compile_method_with_opt): Create the function
10107 pointers in the correct domain.
10109 2005-10-08 Zoltan Varga <vargaz@freemail.hu>
10111 * mini-exceptions.c (mono_handle_exception_internal): Fix bug
10112 introduced by previous patch.
10114 * mini-exceptions.c (mono_handle_exception_internal): Handle the case
10115 when out_filter_idx is NULL.
10117 * mini-exceptions.c: Don't run filter clauses twice during exception
10118 handling. Fixes #75755.
10120 2005-10-07 Zoltan Varga <vargaz@gmail.com>
10122 * aot.c: Add support for ldflda wrappers.
10124 * mini.c (mono_method_to_ir): Use ldflda wrappers for CEE_LDFLDA. Fixes
10127 Tue Oct 4 20:23:25 CEST 2005 Paolo Molaro <lupus@ximian.com>
10129 * mini.c, mini.h: do not consider exception handlers blocks when
10130 setting up interface variables.
10132 2005-10-04 Zoltan Varga <vargaz@freemail.hu>
10134 * aot.c (emit_section_change): Fix emitting of sections on win32. Fixes #76322.
10136 2005-10-03 Zoltan Varga <vargaz@gmail.com>
10138 * liveness.c (mono_analyze_liveness): Revert parts of r51051 since it
10139 causes a regression.
10141 * mini.c (mini_thread_cleanup): Fix reading of freed memory.
10143 2005-10-02 Zoltan Varga <vargaz@freemail.hu>
10145 * mini.h (OP_PCONST): Move the definition of OP_PCONST into the rest
10146 of the OP_P definitions.
10148 * TODO: Add a proposal for dealing with the CEE/OP mess.
10150 * mini-amd64.c (mono_arch_output_basic_block): Merge mul_imm
10151 optimizations from the x86 port.
10153 * cpu-amd64.md: Ditto.
10155 * basic.cs basic-long.cs: Add tests.
10157 Fri Sep 30 20:07:20 CEST 2005 Paolo Molaro <lupus@ximian.com>
10159 * Makefile.am, driver.c, mini-x86.c, mini.c, mini.h, branch-opts.c:
10160 Patrik Torstensson's implementation of my exception-handling
10161 optimization idea, when the exception object is not used
10164 Fri Sep 30 19:10:29 CEST 2005 Paolo Molaro <lupus@ximian.com>
10166 * mini-x86.c, cpu-pentium.md: Patrik Torstensson's port
10167 of the mul_imm optimizations from the old jit.
10169 Fri Sep 30 11:37:51 EDT 2005 Paolo Molaro <lupus@ximian.com>
10171 * mini.c, liveness.c: patch by Patrik Torstensson and
10172 Zoltan Varga to improve performance in methods with
10175 2005-09-30 Zoltan Varga <vargaz@gmail.com>
10177 * driver.c: Remove 'Globalization' entry from --version.
10179 2005-09-28 Zoltan Varga <vargaz@gmail.com>
10181 * mini.c (mono_jit_compile_method_inner): Do not load AOT code when
10182 there is a profiler interested in JIT events.
10184 * aot.c: Load profile files produced by the AOT profiling module, and
10185 reorder methods based on the profiling info. Add a 'method_order' table
10186 to the AOT file to make mono_aot_find_jit_info work with the reordered
10189 * mini.h: Bump AOT file version info.
10191 Wed Sep 28 17:12:48 CEST 2005 Paolo Molaro <lupus@ximian.com>
10193 * mini-arm.h: work around what looks like a gcc bug when optimizations
10196 2005-09-28 Raja R Harinath <rharinath@novell.com>
10198 * Makefile.am (AM_CFLAGS): Don't use += to append inside
10199 conditionals. Use ...
10200 (PLATFORM_CFLAGS, ARCH_CFLAGS): ... these.
10202 2005-09-27 Zoltan Varga <vargaz@freemail.hu>
10204 * mini-amd64.c (mono_arch_call_opcode): Use mono_class_value_size ()
10205 to determine the amount of memory to copy when passing valuetypes.
10207 * inssel-amd64.brg: Remove PUSH(LDIND4) rules since they convert an
10208 4 byte load into a 8 byte load. Fix aligning of size in OP_OUTARG_VT.
10210 2005-09-27 Zoltan Varga <vargaz@gmail.com>
10212 * mini.h mini.c aot.c: Add infrastructure to collect pagefault
10213 information about aot.
10215 2005-09-27 Ben Maurer <bmaurer@ximian.com>
10217 * *.c: Replace the use of {Enter,Leave}CriticalSection with
10218 macros. This will allow a deadlock debugger to easily be plugged
10221 Tue Sep 27 09:32:11 EDT 2005 Paolo Molaro <lupus@ximian.com>
10223 * mini-ppc.c, cpu-g4.md: added memory barrier instruction.
10225 2005-09-27 Raja R Harinath <rharinath@novell.com>
10227 * Makefile.am (AM_CFLAGS): Rename from INCLUDES.
10228 (AM_CFLAGS) [PLATFORM_WIN32): Append to it, don't set it.
10229 (AM_CFLAGS) [ARM]: Add arch/arm directory from the build tree.
10230 ($(arch_built)) [CROSS_COMPILING]: Error out.
10232 2005-09-26 Zoltan Varga <vargaz@gmail.com>
10234 * aot.c: Add support for the no_special_static flag for classes.
10236 2005-09-24 Zoltan Varga <vargaz@freemail.hu>
10238 * Reapply reverted patches.
10240 * *: Revert r50174 as well.
10242 * mini-amd64.c cpu-amd64.md inssel-amd64.brg: Revert r50170 as well.
10244 2005-09-24 Zoltan Varga <vargaz@freemail.hu>
10246 * mini-amd64.c: Revert r50342 to see if this fixed buildbot.
10248 2005-09-23 Miguel de Icaza <miguel@novell.com>
10250 * mini.c (SIG_HANDLER_SIGNATURE): Only dereference info if it is
10251 part of the SIG_HANDLER_SIGNATURE.
10253 2005-09-23 Zoltan Varga <vargaz@gmail.com>
10255 * mini.h mini.c: Add a new MONO_DEBUG option to collect metadata pagefault
10258 * mini-x86.c (mono_arch_call_opcode): Fix vararg calling convention
10259 introduced by previous patch.
10261 2005-09-21 Zoltan Varga <vargaz@gmail.com>
10263 * tramp-x86.c (mono_arch_create_trampoline_code): Restore caller
10264 saved registers too.
10266 * mini-x86.c (mono_arch_allocate_vars): Rewrite this so it works based
10267 upon the information returned by get_call_info ().
10269 * mini-x86.c (add_float): Fix stack size calculation.
10270 (mono_arch_call_opcode): Rewrite this so it works based up the
10271 information returned by get_call_info ().
10272 (mono_arch_get_this_vret_args): Ditto.
10274 2005-09-21 Zoltan Varga <vargaz@freemail.hu>
10276 * mini-amd64.c (mono_arch_emit_this_vret_args): Use the information
10277 in cinfo to determine the registers which need to be used.
10279 2005-09-20 Miguel de Icaza <miguel@novell.com>
10281 * driver.c (mono_main): Add --server and --desktop flags.
10283 2005-09-16 Zoltan Varga <vargaz@gmail.com>
10285 * mini-ia64.h: Make register masks 64 bit. Don't treat argument
10286 registers as global registers.
10288 * inssel-ia64.brg (stmt): Remove OP_OUTARG_REG () rules which are no
10289 longer needed with the new register allocator.
10291 * mini-ia64.c: Use OP_MOVE instead of OP_SETREG for reg-reg moves.
10293 * cpu-ia64.md: Remove unused opcodes.
10295 * regalloc.c mini-codegen.c: Make register masks 64 bit on ia64.
10297 2005-09-16 Zoltan Varga <vargaz@freemail.hu>
10299 * cpu-amd64.md: Remove unused opcodes.
10301 * inssel-amd64.brg: Remove OP_OUTARG_REG () rules which are no longer
10302 needed with the new register allocator.
10304 * inssel-amd64.brg mini-amd64.c: Use OP_MOVE instead of OP_SETREG for
10307 2005-09-16 Raja R Harinath <rharinath@novell.com>
10309 * Makefile.am (check-local): Don't invoke semdel-wrapper.
10311 2005-09-16 Martin Baulig <martin@ximian.com>
10313 * exceptions-amd64.c
10314 (throw_exception): Don't call mono_debugger_throw_exception() if
10315 we're a rethrow - see the FIXME in the code.
10317 2005-09-15 Geoff Norton <gnorton@customerdna.com>
10319 * mini.c (mono_init_exceptions): This only works on some architectures.
10321 2005-09-15 Zoltan Varga <vargaz@gmail.com>
10323 * mini.c (mono_method_to_ir): Add OP_LMUL imm -> OP_LMUL_IMM conversion
10326 * inssel-long.brg mini-ia64.c: Add OP_LMUL_IMM rules.
10328 * mini-ia64.h mini-ia64.c: Remove the altstack support code which is
10329 now in mini-exceptions.c.
10331 2005-09-15 Zoltan Varga <vargaz@freemail.hu>
10333 * mini-amd64.h mini-am64.c: Remove the altstack support code which is
10334 now in mini-exceptions.c.
10336 2005-09-15 Zoltan Varga <vargaz@gmail.com>
10338 * exceptions-x86.c: Applied patch from Patrik Torstensson
10339 <patrik.torstensson@gmail.com>. Add stack overflow handling support for win32.
10341 * mini-exceptions.c mini-x86.c mini.c: Move the altstack setup/teardown
10342 code into mini-exceptions.c. Add some assertions to it.
10344 2005-09-12 Zoltan Varga <vargaz@gmail.com>
10346 * aot.c (emit_section_change): Applied patch from "The Software Team"
10347 (<software@solmersa.com>). Fix as errors on windows.
10349 2005-09-11 Zoltan Varga <vargaz@freemail.hu>
10351 * tramp-amd64.c (mono_arch_create_trampoline_code): Fix saving of
10352 method info into the LMF.
10354 2005-09-11 Zoltan Varga <vargaz@gmail.com>
10356 * mini-ia64.c: Add proper unwind info for method epilogs.
10358 * exceptions-ia64.c: Add some code to help debugging.
10360 * mini-ia64.c mini-ia64.h: Add sigaltstack support.
10362 * mini-exceptions.c: Fix warning.
10364 2005-09-11 Zoltan Varga <vargaz@freemail.hu>
10366 * mini.c: Really fix build.
10368 * mini-x86.c mini-amd64.c: Fix build.
10370 2005-09-11 Zoltan Varga <vargaz@gmail.com>
10372 * mini-ia64.c inssel-ia64.brg: Add InterlockedExchange instrinsics.
10374 * mini-ops.h cpu-ia64.md inssel-ia64.brg mini-ia64.c: Implement
10375 some Interlocked methods as intrinsics.
10377 * mini.c (mini_get_inst_for_method): Call arch_get_inst_for_method
10378 for Thread methods as well.
10380 * mini-ops.h: Add OP_MEMORY_BARRIER opcode.
10382 * inssel.brg: Add rule for OP_MEMORY_BARRIER.
10384 * mini-ia64.c mini-x86.c mini-amd64.c
10385 cpu-ia64.md cpu-pentium.md cpu-amd64.md: Add implementation of
10388 * mini.c (mono_init_exceptions): Fix build breakage.
10390 2005-09-10 Zoltan Varga <vargaz@gmail.com>
10392 * mini-ia64.c exceptions-ia64.c tramp-ia64.c: Remove 'manual' emitting
10393 of instructions. Use the new ia64_unw_op macros for emitting unwind
10396 * mini.c (mono_init_exceptions): Initialize exception handling
10397 related trampolines at startup.
10399 Fri Sep 9 19:30:37 BST 2005 Paolo Molaro <lupus@ximian.com>
10401 * cpu-arm.md, mini-arm.c: fix for dynamic code (Gtk# apps).
10403 2005-09-09 Zoltan Varga <vargaz@gmail.com>
10405 * mini.c: Handle type loading errors gracefully during compilation and
10406 throw the appropriate exception.
10408 Fri Sep 9 09:49:14 CEST 2005 Paolo Molaro <lupus@ximian.com>
10410 * ldscript.mono, Makefile.am: use anonymous versions in the ldscript
10411 for the mono binary.
10413 2005-09-09 Martin Baulig <martin@ximian.com>
10415 * mini.c (mono_method_to_ir): Comment out the G_BREAKPOINT()'s for
10418 Thu Sep 8 14:53:45 BST 2005 Paolo Molaro <lupus@ximian.com>
10420 * mini-arm.h: use emulation for conv.r.un for the release.
10422 Thu Sep 8 11:28:45 BST 2005 Paolo Molaro <lupus@ximian.com>
10424 * mini-arm.c, objects.cs: more fixes and tests for them.
10426 Wed Sep 7 17:14:26 BST 2005 Paolo Molaro <lupus@ximian.com>
10428 * mini-arm.c: align structures to at least 4 bytes to be able
10429 to keep our current optimized memcpy.
10431 Tue Sep 6 22:51:08 BST 2005 Paolo Molaro <lupus@ximian.com>
10433 * mini-arm.c, cpu-arm.md, inssel-arm.brg: bugfixes.
10435 2005-09-05 Gonzalo Paniagua Javier <gonzalo@ximian.com>
10437 * mini.c: ignore SIGPIPE.
10439 2005-09-04 Zoltan Varga <vargaz@gmail.com>
10441 * mini-ia64.c (mono_arch_lowering_pass): Convert 'and_imm 255' to zext1.
10443 * mini-ia64.h mini-ia64.c: Add some minor optimizations.
10445 2005-09-02 Zoltan Varga <vargaz@gmail.com>
10447 * mini.h: Add prototype for mono_allocate_stack_slots_full.
10449 Thu Sep 1 21:05:26 BST 2005 Paolo Molaro <lupus@ximian.com>
10451 * exceptions-arm.c, mini.c, mini-arm.c, mini-arm.h:
10452 exception handling support.
10453 * mini-arm.c, mini-arm.h: bigendian fixes (partially from a
10454 patch by Brian Koropoff <briank@marakicorp.com>).
10456 Thu Sep 1 10:22:44 EDT 2005 Paolo Molaro <lupus@ximian.com>
10458 * mini.c: revert another 'optimization' which breaks when
10459 items on the eval stack need to be saved at a basic block end
10462 Wed Aug 31 17:29:32 CEST 2005 Paolo Molaro <lupus@ximian.com>
10464 * jit-icalls.c: for arrays, ensure we always provide
10467 2005-08-30 Zoltan Varga <vargaz@gmail.com>
10469 * mini.c (mono_allocate_stack_slots_full): Fix ia64 build.
10471 * mini.c (mini_get_inst_for_method): Special case Object:.ctor as well.
10473 2005-08-29 Zoltan Varga <vargaz@gmail.com>
10475 * mini-ia64.h mini-ia64.c: Implement frame pointer elimination. Keep
10476 arguments in their original register.
10478 2005-08-28 Zoltan Varga <vargaz@gmail.com>
10480 * mini-ops.h cpu-ia64.md inssel-ia64.brg mini-ia64.c: Optimize
10483 * mini.c (mono_method_to_ir): Disable the MUL->MUL_IMM optimization
10484 when ssapre is enabled.
10486 * inssel-long.brg: Fix bug in previous patch.
10488 * mini-ia64.c mini-ia64.h mini.c inssel-long.brg: Optimize
10489 multiplication by a constant.
10491 2005-08-27 Zoltan Varga <vargaz@gmail.com>
10493 * mini-ia64.c (mono_arch_setup_jit_tls_data): Add support for intel
10496 * tramp-ia64.c (mono_arch_create_trampoline_code): Use st8.spill for
10499 Fri Aug 26 11:09:28 BST 2005 Paolo Molaro <lupus@ximian.com>
10501 * inssel-arm.brg: apply changes tested by Brian Koropoff
10502 <briank@marakicorp.com>.
10504 2005-08-25 Zoltan Varga <vargaz@gmail.com>
10506 * mini-x86.c (mono_arch_emit_prolog): Fix calling of mono_jit_thread_attach () under windows.
10508 2005-08-24 Zoltan Varga <vargaz@gmail.com>
10510 * mini-codegen.c (mono_local_regalloc): Avoid allocating dreg and sreg1/2
10511 to the same register if dreg is just a base register.
10512 (print_ins): Improve printing of membase opcodes.
10514 * inssel-x86.brg: Add optimized ldind(reg) rules.
10516 * mini-x86.c cpu-pentium.md: Changes required to support the new rules.
10518 Wed Aug 24 19:39:36 CEST 2005 Paolo Molaro <lupus@ximian.com>
10520 * mini.c: when running under valgrind, set the stack bottom for
10521 the GC at the actual approximate stack for the app (fixes running
10522 mono with valgrind).
10524 Tue Aug 23 21:38:50 CEST 2005 Paolo Molaro <lupus@ximian.com>
10526 * mini.c: do no break at the first valuetype to init found
10527 (fixes bug #75791).
10529 Tue Aug 23 16:53:21 BST 2005 Paolo Molaro <lupus@ximian.com>
10531 * cpu-arm.md, mini-arm.c: more fixes and LMF support.
10533 Tue Aug 23 15:11:44 CEST 2005 Paolo Molaro <lupus@ximian.com>
10535 * cpu-g4.md: fixed instruction length exposed by the nemerle compiler.
10537 2005-08-23 Zoltan Varga <vargaz@freemail.hu>
10539 * inssel-amd64.brg inssel-x86.brg: Fix the fcall rules.
10541 2005-08-22 Zoltan Varga <vargaz@freemail.hu>
10543 * inssel-x86.brg: Fix assert in patch_delegate_trampoline.
10545 * tramp-x86.c (mono_arch_patch_delegate_trampoline): Add some debug
10548 * tramp-amd64.c (mono_arch_patch_delegate_trampoline): Add some debug
10551 * mini.c (optimize_branches): Don't quit after 1000 iterations on large
10554 Mon Aug 22 19:16:29 BST 2005 Paolo Molaro <lupus@ximian.com>
10556 * tramp-arm.c: allocate less memory for the trampoline and fix typo.
10558 2005-08-22 Zoltan Varga <vargaz@freemail.hu>
10560 * mini.c (mono_method_to_ir): Remove instructions inserted after a branch
10561 in the tail recursion optimization.
10563 * mini.h helpers.c (mono_disassemble_code): Emit starts of basic blocks as
10564 debug info into the assembly file.
10566 * iltests.il: Add test for filter regions.
10568 * mini.c (mono_method_to_ir): Fix handling of nested FILTER clauses. Fix
10569 initial stack of filter regions. Fixes #75755.
10571 Mon Aug 22 17:49:16 BST 2005 Paolo Molaro <lupus@ximian.com>
10573 * mini-arm.c, cpu-arm.c: fixes and support for methods with bigger
10574 stack requirements.
10576 2005-08-22 Zoltan Varga <vargaz@freemail.hu>
10578 * mini.c (mono_create_delegate_trampoline): Fix memory leak. Put back
10579 the check for an already compiled method on non-ia64 platforms.
10580 (mono_create_jump_trampoline): Store the MonoJitInfo structure into the
10583 * mini-x86.h tramp-x86.c: Add support for delegate trampolines.
10585 * inssel-x86.brg: Add some optimized call rules.
10587 2005-08-21 Zoltan Varga <vargaz@freemail.hu>
10589 * mini.c (mono_create_delegate_trampoline): Do not return an already compiled
10592 * mini.h mini-trampolines.c: Pass the trampoline argument to
10593 mono_arch_patch_delegate_trampoline.
10595 * mini-ia64.h mini-ia64.c tramp-ia64.c: Add support for delegate trampolines.
10597 * mini-trampolines.c: Fix build.
10599 * mini-amd64.h: Add delegate trampolines.
10601 * mini.h mini.c mini-trampolines.c tramp-amd64.c: Add delegate trampolines.
10603 * inssel-amd64.brg: Add optimized call rules.
10605 * mini-ia64.c tramp-ia64.c: Improve instruction scheduling.
10607 * inssel-ia64.brg: Add optimized ldind(reg) rules.
10609 2005-08-20 Zoltan Varga <vargaz@freemail.hu>
10611 * mini.c (mono_create_class_init_trampoline): Fix bug caused by last
10614 * mini-ia64.c: Remove LMF fixmes.
10616 * mini-ia64.h: Remove most fields from LMF.
10618 * inssel-ia64.brg (stmt): Fix unaligned access errors.
10620 * mini-trampolines.c: Add support for IA64 function descriptors.
10622 * mini.h mini.c jit-icalls.c exceptions-ia64.cdriver.c: Add support
10623 for IA64 function descriptors.
10625 Sat Aug 20 16:51:44 BST 2005 Paolo Molaro <lupus@ximian.com>
10627 * tramp-arm.c: patch the vtable for virtual calls. Added
10628 support code to register/unregister the LMF.
10629 * mini-arm.c, mini-arm.h: warning fixes, fixes, speedups,
10632 2005-08-19 Dick Porter <dick@ximian.com>
10634 * mini.c: Use a gsize to store the thread ID, so it can hold a 64
10635 bit value if needed.
10637 2005-08-19 Zoltan Varga <vargaz@freemail.hu>
10639 * mini.c (mini_get_method): Move handling of wrapper data here.
10641 * mini.c (mono_method_to_ir): Add support for dynamic methods.
10643 * mini.c (mono_method_to_ir): Convert nonvirtual calls to abstract methods into
10646 * mini.c (mono_method_to_ir): Emit IR for CEE_NOP as well, so
10647 bblock->code does not remain empty.
10649 2005-08-17 Zoltan Varga <vargaz@freemail.hu>
10651 * arrays.cs: Add regression test for #75832.
10653 * inssel-amd64.brg cpu-amd64.md mini-amd64.c: Fix LDELEMA optimization
10654 rules. Fixes #75832.
10656 * mini-ia64.c tramp-ia64.c exceptions-ia64.c: Implement improved
10657 instruction scheduling.
10659 2005-08-12 Zoltan Varga <vargaz@freemail.hu>
10661 * mini-exceptions.c (ves_icall_get_frame_info): Fix IA64 build.
10663 2005-08-11 Zoltan Varga <vargaz@freemail.hu>
10665 * mini-exceptions.c mini-x86.h: Move VC stuff into macros in mini-x86.h.
10667 * mini-codegen.c: Fix VC build.
10669 * cpu-pentium.md: Increase length of atomic_exhange_i4.
10671 2005-08-09 Gonzalo Paniagua Javier <gonzalo@ximian.com>
10673 * mini.h: fix signature for mono_register_opcode_emulation.
10675 2005-08-09 Zoltan Varga <vargaz@freemail.hu>
10677 * mini.c: Get rid of most of the helper_sig_... constants using
10678 mono_create_icall_signature ().
10680 2005-08-08 Zoltan Varga <vargaz@freemail.hu>
10682 * jit-icalls.c (helper_ldstr): New helper function.
10684 * mini.c (get_basic_blocks): Set out_of_line for bblocks containing a throw.
10686 * mini.c (mono_method_to_ir): If an LDSTR instruction is in a bblock with a
10687 throw, load the string using a helper call instead of creating a string object.
10689 * aot.c: Update after LDSTR changes.
10691 * mini.h: Bump AOT file version.
10693 * aot.c: Save class size info into the AOT file. Print more statistics during
10696 * mini.h: Bump AOT file version.
10698 * tramp-amd64.c (mono_arch_nullify_class_init_trampoline): Fix
10699 ordering of disasm cases. Fixes #74957.
10701 Thu Aug 4 19:47:24 BST 2005 Paolo Molaro <lupus@ximian.com>
10703 * mini-ops.h, mini-arch.h, inssel.brg, mini.c, mini.h,
10704 jit-icalls.c, mini-codegen.c, Makefile.am: changes in
10705 the generic code needed for the ARM port.
10707 Thu Aug 4 19:42:54 BST 2005 Paolo Molaro <lupus@ximian.com>
10709 * exceptions-arm.c, tramp-arm.c, mini-arm.c, mini-arm.h, cpu-arm.md,
10710 inssel-arm.brg: more ARM features and fixes.
10712 Mon Aug 1 18:37:38 BST 2005 Paolo Molaro <lupus@ximian.com>
10714 * tramp-arm.c, mini-arm.c, cpu-arm.md, inssel-arm.brg: more
10715 ARM port work in progress.
10717 2005-07-30 Zoltan Varga <vargaz@freemail.hu>
10719 * mini-ia64.c (mono_arch_call_opcode): Ongoing IA64 work.
10721 * mini-exceptions.c mini-ia64.h: Ongoing IA64 work.
10723 * mini-ia64.c (ia64_emit_bundle): Ongoing IA64 work.
10725 * inssel.brg (mini_emit_memset): Add support for unaligned access.
10727 * *-ia64.*: Ongoing IA64 work.
10729 * mini-ia64.c exceptions-ia64.c: Ongoing IA64 work.
10731 2005-07-28 Zoltan Varga <vargaz@freemail.hu>
10733 * TODO: Remove out-of-data todo stuff.
10735 * mini.h mini.c (mono_create_jit_trampoline_from_token): Remove some
10738 * aot.c: Save/load MonoCachedClassInfo->has_nested_classes.
10740 * mini.h: Bump corlib version.
10742 2005-07-27 Martin Baulig <martin@ximian.com>
10745 (create_copy_ins): Added `const unsigned char *ip' argument; set
10746 `copy->cil_code' from it.
10748 2005-07-27 Martin Baulig <martin@ximian.com>
10750 * mini-exceptions.c (mono_handle_exception): Don't call
10751 mono_debugger_handle_exception() for filters.
10753 2005-07-27 Zoltan Varga <vargaz@freemail.hu>
10755 * mini-trampolines.c (mono_aot_trampoline): Handle AppDomain:InvokeInDomain
10758 2005-07-26 Martin Baulig <martin@ximian.com>
10760 Committing a patch from Michal Moskal <michal.moskal@gmail.com>.
10762 * mini.c (mono_method_to_ir): In `CEE_CALLI', only use
10763 helper_compile_generic_method() if the method is actually virtual
10766 2005-07-26 Martin Baulig <martin@ximian.com>
10769 (trampoline_code): Renamed to `mono_trampoline_code' and made it
10770 public; this is now accessed directly by the debugger.
10771 (mono_generic_trampoline_code): Removed.
10774 (mono_debug_init_method): Also add interncalls and wrappers.
10776 2005-07-23 Zoltan Varga <vargaz@freemail.hu>
10778 * mini-ia64.c mini-ia64.h: Add support for tracing/profiling.
10780 2005-07-22 Zoltan Varga <vargaz@freemail.hu>
10782 * aot.c (mono_aot_get_method_from_token): Fix a potential crash here.
10784 2005-07-21 Zoltan Varga <vargaz@freemail.hu>
10786 * aot.c (load_patch_info): Fix handling of stfld_remote wrapper.
10788 2005-07-20 Zoltan Varga <vargaz@freemail.hu>
10790 * mini-amd64.c (mono_arch_setup_jit_tls_data): Use the nice way of
10791 getting TLS offsets on AMD64 too.
10793 2005-07-20 Kornél Pál <kornelpal@hotmail.com>
10795 * driver.c: Detach console when executing IMAGE_SUBSYSTEM_WINDOWS_GUI on win32
10797 Wed Jul 20 18:05:19 BST 2005 Paolo Molaro <lupus@ximian.com>
10799 * exceptions-arm.c, mini-arm.c, tramp-arm.c, cpu-arm.md,
10800 inssel-arm.brg, mini-arm.h: ARM port work in progress.
10802 2005-07-20 Zoltan Varga <vargaz@freemail.hu>
10804 * tramp-amd64.c (mono_arch_create_specific_trampoline): Fix build.
10806 * mini.h mini.c mini-*.h tramp-*.c: Move more cross platform trampoline code
10809 * mini-sparc.c (mono_arch_get_vcall_slot_addr): Call
10810 mono_sparc_is_virtual_call ().
10812 * mini-sparc.c (mono_arch_get_vcall_slot_addr): Fix warning.
10814 * tramp-sparc.c (mono_arch_create_trampoline_code): Fix order of
10815 trampoline parameters.
10817 * mini-sparc.c (mono_arch_get_vcall_slot_addr): Fix signature.
10819 * mini-sparc.c (mono_arch_get_vcall_slot_addr): Rename this
10820 to mono_arch_get_vcall_slot_addr.
10822 * Makefile.am tramp-sparc.c: Update the sparc port to use the generic
10825 * *-sparc.*: Merge the mini-xp-regalloc branch for sparc.
10827 2005-07-19 Zoltan Varga <vargaz@freemail.hu>
10829 * mini-ia64.h mini-ia64.c: Finish pinvoke support.
10831 2005-07-19 Martin Baulig <martin@ximian.com>
10833 * exceptions-amd64.c (throw_exception): Call
10834 mono_debugger_throw_exception() here like we're doing it on i386.
10836 2005-07-19 Zoltan Varga <vargaz@freemail.hu>
10838 * mini-ia64.c: Add optimized TLS access support.
10840 2005-07-18 Zoltan Varga <vargaz@freemail.hu>
10842 * mini-exceptions.c: Ongoing IA64 work.
10844 * mini-ia64.c inssel-long.brg: Ongoing IA64 work.
10846 * mini.c: Use the default optimization set when embedding. Fixes
10849 2005-07-11 Zoltan Varga <vargaz@freemail.hu>
10851 * tramp-amd64.c tramp-ia64.c Makefile.am: Move arch independent parts
10852 of trampolines to a separate file.
10854 * mini-trampolines.c: New file.
10856 * mini.h tramp-x86.c: Move arch independent parts of trampolines to a
10859 * tramp-x86.c: Reorganize the trampoline code to be similar to the
10862 * mini-codegen.c: Fix cygwin build.
10864 2005-07-10 Zoltan Varga <vargaz@freemail.hu>
10866 * mini.c: Add some minor changes needed by the IA64 port.
10868 * *-ia64.*: Ongoing IA64 work.
10870 2005-07-09 Zoltan Varga <vargaz@freemail.hu>
10872 * tramp-amd64.c mini-amd64.c: Update after latest AOT changes. Split
10873 trampolines into arch-independent and arch-dependent parts.
10875 * mini-amd64.c (mono_arch_lowering_pass): Fix store_membase_imm -> store_membase_reg rule.
10877 2005-07-08 Zoltan Varga <vargaz@freemail.hu>
10879 * cpu-amd64.md: Merge the xp-regalloc-branch for amd64.
10881 * mini-ops.h mini-amd64.h mini-amd64.c inssel-amd64.brg Makefile.am: Merge
10882 the xp-regalloc-branch for amd64.
10884 * mini-x86.h mini-x86.c cpu-pentium.md Makefile.am: Merge the
10885 xp-regalloc-branch for x86.
10887 2005-07-07 Zoltan Varga <vargaz@freemail.hu>
10889 * inssel.brg (OP_THROW_OR_NULL): Allways rethrow the abort exception.
10891 2005-07-06 Martin Baulig <martin@ximian.com>
10894 (mono_jit_compile_method_inner): Call mono_get_inflated_method().
10895 (mono_jit_runtime_invoke): Likewise.
10897 2005-07-05 Zoltan Varga <vargaz@freemail.hu>
10899 * aot.c (mono_compile_assembly): Allocate the GOT in the .bss segment
10902 * aot.c: Add new mono_aot_get_method_from_token () function to load AOT methods
10903 without loading their metadata. Reorganize the file format so exception handling+
10904 debug info is kept separate from normal method info. Create MonoJitInfo
10905 structures for methods lazily.
10907 * tramp-x86.c (x86_aot_trampoline): Use the new from_token method to avoid
10909 (x86_class_init_trampoline): Patch AOT class init trampolines too.
10911 * mini.c (mini_init): Install the new mono_aot_find_jit_info hook.
10913 * mini.c (mono_method_to_ir): Reduce the number of class init trampoline calls
10916 * mini.h: Bump AOT file version.
10918 2005-07-04 Zoltan Varga <vargaz@freemail.hu>
10920 * mini-x86.c (peephole_pass): Fix the loadi1/loadi2 rules.
10922 2005-07-01 Raja R Harinath <rharinath@novell.com>
10924 * Makefile.am (check-local): Call semdel-wrapper.
10926 2005-06-29 Zoltan Varga <vargaz@freemail.hu>
10928 * mini-x86.c: Revert the last change as it seems to break the build..
10930 2005-06-28 Zoltan Varga <vargaz@freemail.hu>
10932 * mini-x86.c (peephole_pass): Fix the loadi1/loadi2 rules.
10934 * mini-x86.c (mono_arch_cpu_init): Fix setting of fp precision in the VC build.
10936 2005-06-27 Ben Maurer <bmaurer@ximian.com>
10938 * mini.c (NEW_AOTCONST): make sure to call mono_get_got_var
10939 outside of the macro, so strange stuff doesn't happen with gcc4
10940 (NEW_AOTCONST_TOKEN): Likewise.
10942 2005-06-28 Martin Baulig <martin@ximian.com>
10944 * mini.c (mini_class_is_system_array): New static method; use this
10945 instead of `klass->parent == mono_defaults.array_class' everywhere
10946 since this also works for the new generic array class.
10948 2005-06-26 Ben Maurer <bmaurer@ximian.com>
10950 * inssel.brg: Remove warnings.
10952 2005-06-24 Zoltan Varga <vargaz@freemail.hu>
10954 * mini-ia64.c: Ongoing IA64 work.
10956 * basic-float.cs: Add float->i1 conversion test.
10958 * iltests.il: Add conv.u4 test.
10960 2005-06-23 Zoltan Varga <vargaz@freemail.hu>
10962 * inssel-long.brg: Fix bug caused by last change.
10964 2005-06-23 Geoff Norton <gnorton@customerdna.com>
10966 * mini-x86.h: Add __APPLE__ to the SC_* redefines with the other
10967 BSDs. Allows the x86 JIT to work on OSX86
10969 2005-06-22 Zoltan Varga <vargaz@freemail.hu>
10971 * inssel-long.brg: Use OP_LSHR_UN_IMM instead of OP_SHR_UN_IMM in
10974 * mini-ia64.c: Ongoing IA64 work.
10976 2005-06-19 Zoltan Varga <vargaz@freemail.hu>
10978 * mini-ia64.c: Ongoing IA64 work.
10980 * driver.c: Clean up jit_code_hash as well when using --regression.
10982 * inssel-long.brg: Fix long->i4/u4 conversion rules.
10984 * basic-long.cs: Add tests for long->u4 conversion.
10986 2005-06-18 Ben Maurer <bmaurer@ximian.com>
10988 * mini.c: Take mono_get_domainvar out of macros. This makes sure
10989 that we do not depend on undefined C behavior: the order stuff
10990 gets evaluated within an expression. Fixes mono when compiled on
10993 2005-06-18 Zoltan Varga <vargaz@freemail.hu>
10995 * *-ia64.*: Ongoing IA64 work.
10997 * aot.c: Lower memory usage while loading AOT methods.
10999 * tramp-x86.c: Avoid allocating+freeing MonoJitInfo structures.
11001 * mini.h: Bump AOT file format version.
11003 2005-06-17 Zoltan Varga <vargaz@freemail.hu>
11005 * mini.c (mono_method_to_ir): Allow STACK_PTR as input to SWITCH.
11007 2005-06-16 Sebastien Pouliot <sebastien@ximian.com>
11009 * declsec.c: Fixed APTC to check for FullTrust on caller assembly (and
11010 not on callee assembly). Fixed some comments.
11012 2005-06-16 Zoltan Varga <vargaz@freemail.hu>
11014 * aot.c (mono_compile_assembly): Mark the "methods" symbol as a function so
11015 it gets proper disassembly.
11016 (emit_method_info): Remove some dead code.
11018 * mini.c (mini_method_compile): Allways allocate the GOT var in
11019 mono_method_to_ir for emulating opcodes.
11021 2005-06-13 Zoltan Varga <vargaz@freemail.hu>
11023 * mini.c (mono_jit_free_method): Remove the method from the JitInfo table
11024 before freeing the code memory. Fixes #74990.
11026 * objects.cs: Add regression test for #74992.
11028 * liveness.c: Extend live ranges of arguments to the beginning of the
11029 method. Fixes #74992.
11031 * exceptions-ia64.c mini-ia64.h: Modify ip during exception handling
11032 so it points into the faulting instruction.
11034 2005-06-12 Zoltan Varga <vargaz@freemail.hu>
11036 * jit-icalls.c (mono_imul_ovf): Add exception handling.
11038 * *-ia64.*: Ongoing IA64 work.
11040 * mini.c (mini_init): Fix signature of mono_delegate_ctor.
11042 2005-06-11 Zoltan Varga <vargaz@freemail.hu>
11044 * mini-ia64.h exceptions-ia64.c: Ongoing IA64 work.
11046 * *-ia64.*: Ongoing IA64 work.
11048 2005-06-10 Zoltan Varga <vargaz@freemail.hu>
11050 * basic-long.cs: Add tests for add/sub.ovf.
11052 * basic.cs: Add tests for sub.ovf.
11054 * *-ia64.*: Ongoing IA64 work.
11056 2005-06-09 Zoltan Varga <vargaz@freemail.hu>
11058 * *-ia64.*: Ongoing IA64 work.
11060 * basic.cs: Add conv.ovf.i4.un test.
11062 2005-06-09 Massimiliano Mantione <massi@ximian.com>
11064 * mini.c: (remove_block_if_useless) Fixed bug 75061.
11066 2005-06-08 Gonzalo Paniagua Javier <gonzalo@ximian.com>
11068 * mini.c: no SIGUSR2 on windows. Remove it for PLATFORM_WIN32.
11070 2005-06-07 Zoltan Varga <vargaz@freemail.hu>
11072 * *-ia64.*: Ongoing IA64 work.
11074 2005-06-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
11077 * mini.c: added the ability to toggle trace on/off using SIGUSR2.
11079 2005-06-04 Zoltan Varga <vargaz@freemail.hu>
11081 * mini-ia64.c mini-ia64.h: Fix cleanup of memory stack.
11083 2005-06-03 Zoltan Varga <vargaz@freemail.hu>
11085 * mini-amd64.c (emit_call): Fix yet another bug in the near call optimization.
11087 * mini-amd64.c (amd64_patch): Add an assert to check that the destination
11088 of a call is callable by a near call.
11090 2005-05-31 Zoltan Varga <vargaz@freemail.hu>
11092 * mini-ia64.c: Ongoing IA64 work.
11094 2005-05-29 Zoltan Varga <vargaz@freemail.hu>
11096 * genmdesc.c: Make the generated array non-static.
11098 * inssel-long.brg: Fix LSHR_IMM rule.
11100 * *-ia64.*: Ongoing IA64 work.
11102 * *-ia64.*: Ongoing IA64 work.
11104 2005-05-28 Zoltan Varga <vargaz@freemail.hu>
11106 * *-ia64.*: Ongoing IA64 work.
11108 * *-ia64.*: Ongoing IA64 work.
11110 * mini-ia64.c: Ongoing IA64 work.
11112 * *-ia64.* jit-icalls.c mini-codegen.c: Ongoing IA64 work.
11114 2005-05-28 Zoltan Varga <vargaz@freemail.hu>
11116 * objects.cs basic-calls.cs: Move some tests to objects.cs.
11118 * objects.cs basic-long.cs: Move some tests to objects.cs.
11120 2005-05-26 Zoltan Varga <vargaz@freemail.hu>
11122 * *-ia64.*: Ongoing IA64 work.
11124 * iltests.il: Add a new test.
11126 * mini.c (mono_method_to_ir): Initialize valuetypes when created using
11127 newobj. Fixes #75042.
11129 2005-05-22 Zoltan Varga <vargaz@freemail.hu>
11131 * *-ia64.*: Ongoing IA64 work.
11133 * *-ia64.*: Ongoing IA64 work.
11135 * *-ia64.*: Ongoing IA64 work.
11137 * basic.cs objects.cs: Move tests accessing static variables as well.
11139 * basic.cs objects.cs: Move test_0_pin_string to objects.cs.
11141 2005-05-21 Zoltan Varga <vargaz@freemail.hu>
11143 * mini.c (SIG_HANDLER_SIGNATURE): Fix warning.
11145 * driver.c: Always print failed tests.
11147 * mini-codegen.c: Use cfg->frame_reg instead of a macro for the
11150 * *ia64*: Ongoing IA64 work.
11152 2005-05-20 Zoltan Varga <vargaz@freemail.hu>
11154 * basic.cs: Add tests for add.ovf. Fix warnings.
11156 2005-05-18 Miguel de Icaza <miguel@novell.com>
11158 * driver.c (mono_main): Avoid crash if no argument is passed to
11159 --break; Do not use g_error, but f_printf. And fix all other
11160 ocurrences of the same crash.
11162 2005-05-17 Zoltan Varga <vargaz@freemail.hu>
11164 * mini.h mini.c: Generalize the existing uses of the MONO_DEBUG env variable
11165 and add a new one: aborting when a SIGSEGV is raised while in unmanaged code.
11168 2005-05-14 Zoltan Varga <vargaz@freemail.hu>
11170 * *-ia64.*: Add beginnings of IA64 backend.
11172 * Makefile.am mini-arch.h mini-codegen.c: Add IA64 support.
11174 2005-05-13 Zoltan Varga <vargaz@freemail.hu>
11176 * inssel-long.brg: Add missing ulong->{i1, i2} checked conversions.
11179 * basic-long.cs exceptions.cs: Add new tests. Fix some warnings.
11181 * mini-amd64.c: Fix a warning.
11183 2005-05-10 Zoltan Varga <vargaz@freemail.hu>
11185 * mini-amd64.c (mono_arch_output_basic_block): Fix stack space leakage
11186 in float_neg. Fixes #74897.
11188 * mini-amd64.c (emit_call): Fix another near call bug.
11190 2005-05-06 Sebastien Pouliot <sebastien@ximian.com>
11192 * declsec.c: Keep the appdomain information in the structure. Added a
11193 missing "return FALSE" for Unmanaged if FullTrust is set (or else the
11194 value gets overwritten).
11195 * declsec.h: Set the default MonoArray for the the stack to 6. Added
11196 an MonoAppDomain member to MonoSecurityFrame.
11197 * mini-exceptions.c: Do not use a glist to keep GC allocated objects
11198 used in the stack walk. Now use a MonoArray which grow (double) when
11201 2005-05-05 Lluis Sanchez Gual <lluis@novell.com>
11203 * mini.c: Re-enabled runtime cleanup, since running threads should
11204 now properly stop when exiting.
11206 2005-05-05 Zoltan Varga <vargaz@freemail.hu>
11208 * mini-codegen.c: New file contaning the arch-independent local
11209 register allocator. Not used by any architectures yet.
11211 * mini.h linear-scan.c: Merge some changes from the
11212 mini-xp-local-regalloc branch.
11214 2005-04-28 Zoltan Varga <vargaz@freemail.hu>
11216 * mini-amd64.c (emit_call): Fix calls to native functions when the
11217 runtime is compiled as a shared library. Fixes #74756.
11219 * mini.c (mono_method_to_ir): Assert if ldsfld and friends are used
11220 on a literal field. Fixes #74751.
11222 2005-04-25 Raja R Harinath <rharinath@novell.com>
11224 * Makefile.am (RUNTIME): Add MONO_CFG_DIR.
11226 2005-04-23 Zoltan Varga <vargaz@freemail.hu>
11228 * objects.cs: Add missing null casting test.
11230 2005-04-22 Zoltan Varga <vargaz@freemail.hu>
11232 * mini-exceptions.c (mono_find_jit_info): Fix native offset calculation
11233 in wrapper methods. Also rename 'address' variable to 'offset'.
11235 2005-04-20 Zoltan Varga <vargaz@freemail.hu>
11237 * mini.c debug-mini.c aot.c tramp-x86.c driver.c: Fix some gcc 4.0
11240 * Makefile.am (MCS): Use -unsafe instead of --unsafe.
11242 * aot.c: Applied patch from "The Software Team" <software@solmersa.com>. Make AOT compilation
11245 Mon Apr 18 16:20:32 CEST 2005 Paolo Molaro <lupus@ximian.com>
11247 * exceptions-ppc.c: update code to handle stack traces (fixes bug #74452).
11249 2005-04-17 Zoltan Varga <vargaz@freemail.hu>
11251 * mini-x86.c (mono_emit_stack_alloc): Initialize the whole allocated area not
11252 just the last bytes.
11254 2005-04-17 Zoltan Varga <vargaz@freemail.hu>
11256 * aot.c (mono_compile_assembly): Fix warning.
11258 * mini-exceptions.c (ves_icall_get_frame_info): Fix bug introduced
11259 by the _MSC_VER stuff.
11261 2005-04-16 Zoltan Varga <vargaz@freemail.hu>
11263 * inssel-long.brg: Fix #74588.
11265 * cpu-amd64.md: Fix #74591.
11267 * iltests.il: Add new regression tests.
11269 2005-04-13 Zoltan Varga <vargaz@freemail.hu>
11271 * trace.c (mono_trace_enter_method): Print enums as an int, not as a
11274 2005-04-11 Zoltan Varga <vargaz@freemail.hu>
11276 * mini-x86.c (setup_stack): Unconditionally call pthread_attr_init ().
11278 * exceptions-x86.c mini-x86.h mini-x86.c: Applied some freebsd patches
11279 from Bill Middleton <flashdict@gmail.com>.
11281 2005-04-10 Zoltan Varga <vargaz@freemail.hu>
11283 * arrays.cs: Add new regression test. Fix warnings.
11285 2005-04-09 Zoltan Varga <vargaz@freemail.hu>
11287 * mini-amd64.c (mono_arch_output_basic_block): Fix stack alignment
11288 and leakage in CKFINITE.
11290 * exceptions-amd64.c (mono_arch_get_throw_exception_by_name): Change
11291 this to a null op since it is called on amd64 too.
11293 * exceptions-amd64.c (get_throw_trampoline): Align stack.
11295 * exceptions-amd64.c (mono_arch_get_throw_exception_by_name): Remove
11296 body since this is not used on amd64.
11298 * mini-amd64.h (MONO_ARCH_NO_EMULATE_LONG_SHIFT_OPS): Remove duplicate define.
11300 * mini-amd64.c: Remove obsolete fixmes.
11302 * mini.c (print_method_from_ip): Fix debugging support.
11304 2005-2-1 Massimiliano Mantione <massi@ximian.com>
11306 * ssapre.c: Fix a subtle bug about availability, and limit SSAPRE
11307 so that expressions that don't give much gain are not reduced.
11308 * ssapre.h: Likewise.
11310 2005-04-04 Zoltan Varga <vargaz@freemail.hu>
11312 * exceptions-x86.c (mono_arch_find_jit_info): Remove last SC_EBP reference.
11314 * mini-x86.c (mono_emit_stack_alloc): Fix localloc under windows.
11316 * mini-x86.h exceptions-x86.c: Hopefully fix compilation on *BSD.
11318 2005-04-01 Zoltan Varga <vargaz@freemail.hu>
11320 * mini-sparc.c mini-sparc.h: Add asserts when running with sigaltstack.
11322 * exceptions-x86.c (mono_arch_monoctx_to_sigctx): Fix cygwin build.
11324 2005-03-31 Zoltan Varga <vargaz@freemail.hu>
11326 * mini-x86.c: If sigaltstack support is enabled, perform win32 style
11329 * mini.h (mono_arch_sigctx_to_monoctx): New arch-specific function.
11331 * mini.h (mono_arch_monoctx_to_sigctx): New arch-specific function.
11333 * mini.c: sigaltstack support requires MONO_ARCH_USE_SIGACTION.
11335 * mini-x86.h mini-x86.c exceptions-x86.c: Add support for
11336 MONO_ARCH_USE_SIGACTION. Fixes #74252.
11338 * mini-x86.h: Enable MONO_ARCH_USE_SIGACTION on linux.
11340 * mini-x86.c: Fix up stack overflow handling.
11342 * exceptions.cs: Add new regression test.
11344 2005-03-30 Zoltan Varga <vargaz@freemail.hu>
11346 * mini-x86.c (mono_arch_emit_prolog): Adjust stack after calls to
11347 mono_jit_thread_attach.
11349 * mini.c (mono_method_to_ir): Verify called method is not abstract.
11351 2005-03-29 Zoltan Varga <vargaz@freemail.hu>
11353 * mini.c (mono_method_to_ir): Applied Ben's patch from bug #61441 to
11354 avoid calling constructors using callvirt.
11356 * inssel.brg: Fix #74073.
11358 2005-03-29 Sebastien Pouliot <sebastien@ximian.com>
11360 * aot.c, mini.h: Added mono-compiler.h header to allow/ease
11361 compilation with non-GCC compilers.
11362 * mini-exceptions.c, mini-x86.c|h: Patches to make compilation of mono
11363 possible using VS.NET. Adapted from the work of J Lothian (for VC6).
11365 Tue Mar 29 11:43:01 CEST 2005 Paolo Molaro <lupus@ximian.com>
11367 * inssel.brg, arrays.cs: fix long standing 64 bit issue in access to
11368 klass->interface_offsets (will likely fix bug#74073).
11370 2005-03-29 Zoltan Varga <vargaz@freemail.hu>
11372 * mini-amd64.c (mono_arch_is_int_overflow): Fix rex handling.
11374 2005-03-28 Zoltan Varga <vargaz@freemail.hu>
11376 * mini-amd64.c (mono_arch_output_basic_block): Fix order of parameters
11377 to amd64_div_reg_size ().
11379 * mini-amd64.c (mono_arch_emit_exceptions): Emit a near call here too.
11381 2005-03-27 Zoltan Varga <vargaz@freemail.hu>
11383 * cpu-amd64.md (store_membase_reg): Fix length of storer8 opcodes.
11385 2005-03-24 Zoltan Varga <vargaz@freemail.hu>
11387 * driver.c: Turn off automatic command line globbing under windows. Fixes #73763.
11389 2005-03-24 Zoltan Varga <vargaz@freemail.hu>
11391 * mini.c (mono_method_to_ir): Remove debugging stuff left in by mistake.
11393 * mini.c (mono_precompile_assembly): Load and precompile referenced
11394 assemblies as well. Fixes #74015.
11396 2005-03-23 Zoltan Varga <vargaz@freemail.hu>
11398 * cpu-amd64.md (sin): Fix up maximum lengths of some opcodes.
11400 2005-03-23 Sebastien Pouliot <sebastien@ximian.com>
11402 * declsec.c: Skip linkdemand checks for intra-corlib calls. This skips
11403 a lot of checks and (anyway) permissions cannot work until corlib is
11406 Wed Mar 23 14:29:49 CET 2005 Paolo Molaro <lupus@ximian.com>
11408 * mini-ppc.c: fixed ABI issue on sysv/ppc.
11410 Tue Mar 22 19:03:17 CET 2005 Paolo Molaro <lupus@ximian.com>
11412 * tramp-ppc.c, exceptions-ppc.c: added missing icache flush
11413 calls (fixes bug#72824).
11415 Tue Mar 22 16:28:48 CET 2005 Paolo Molaro <lupus@ximian.com>
11417 * mini.c: fix tail recursion elimination (see test in bug#73936).
11419 2005-03-21 Zoltan Varga <vargaz@freemail.hu>
11421 * mini-amd64.c (mono_arch_output_basic_block): Add inline versions of
11422 some fp functions in sse2 mode.
11424 2005-03-20 Zoltan Varga <vargaz@freemail.hu>
11426 * mini-x86.c (emit_tls_get): Move tls handling into a separate helper function.
11428 2005-03-19 Zoltan Varga <vargaz@freemail.hu>
11430 * mini.h mini.c: Add mono_get_jit_tls_key ().
11432 * mini-x86.c: Enable fast TLS support on windows.
11434 2005-03-17 Sebastien Pouliot <sebastien@ximian.com>
11436 * declsec.c: Renamed aptc to allowpartiallytrustedcallers.
11437 * mini.c: Check for p/invoke method when generating code. If a
11438 p/invoke method, or it's class, isn't decorated with [Suppress
11439 UnmanagedCodeSecurity] then generate code to call System.Security.
11440 UnmanagedDemand (only if the security manager is active).
11442 2005-03-16 Zoltan Varga <vargaz@freemail.hu>
11444 * tramp-amd64.c (create_specific_trampoline): Revert parts of the
11445 last change as it seems to cause strange crashes.
11447 Wed Mar 16 16:24:11 CET 2005 Paolo Molaro <lupus@ximian.com>
11449 * *.c: handle unsafe function pointers where needed.
11451 2005-03-16 Zoltan Varga <vargaz@freemail.hu>
11453 * mini.c (mono_jit_free_method): Remove the fixme too.
11455 2005-03-15 Miguel de Icaza <miguel@novell.com>
11457 * mini.c: As discussed, make the code actually free the delegate
11458 thunk now, to enable the debugging of delegate problems, use
11459 MONO_DEBUG=1 when running Mono.
11461 This takes also care of parts of the leaks as seen by Joe.
11463 2005-03-15 Zoltan Varga <vargaz@freemail.hu>
11465 * mini-amd64.c (mono_arch_setup_jit_tls_data): Enable
11466 thread_tls_offset calculation.
11468 2005-03-14 Sebastien Pouliot <sebastien@ximian.com>
11470 * declsec.c: Reworked linkdemand checks for icall. The previous code
11471 was using the declaration code (untrusted) and didn't work as expected
11472 with the CLR 2.0. We're now more compatible with 2.0 than 1.x for this
11475 2005-03-13 Zoltan Varga <vargaz@freemail.hu>
11477 * iltests.il: Add new localloc test.
11479 * mini-amd64.c: Handle large stack allocations the same way as on
11480 windows if stack overflow handling is working.
11482 * mini-amd64.c: Allocate the signal stack using mmap.
11484 * mini.c (sigsegv_signal_handler): Fix reading of context.
11486 * mini-exceptions.c: Fix up stack overflow handling.
11488 * mini-amd64.h mini-amd64.c: Fix up stack overflow handling.
11490 * tramp-amd64.c (create_specific_trampoline): Optimize trampoline size.
11492 * exceptions-amd64.c (mono_amd64_exceptions_init): Remove this.
11494 * mini.h mini.c tramp-*.c: Move common trampoline code to mini.c.
11496 * mini-x86.h mini-x86.c mini-amd64.h mini-amd64.c: Get rid of the
11497 tramp_init functions as they are no longer needed.
11499 2005-03-12 Zoltan Varga <vargaz@freemail.hu>
11501 * tramp-amd64.c (mono_amd64_tramp_init): Fix typo.
11503 * tramp-amd64.c (mono_amd64_tramp_init): Init AOT trampoline as well.
11505 * mini-amd64.h mini-amd64.c (mono_amd64_exceptions_init): Remove this.
11507 * mini.c mini-*.h: Remove OUT_OF_LINE_BBLOCK defines since all arches
11510 * mini-ops.h: Add OP_LMUL_IMM.
11512 * mini.c jit-icalls.cmini-amd64.h mini-amd64.c cpu-amd64.md: Implement
11513 long mul/div opcodes as intrinsic.
11515 * mini-amd64.c (emit_call): Handle the case when the callee might be
11518 2005-03-11 Zoltan Varga <vargaz@freemail.hu>
11520 * mini-amd64.c (mono_arch_get_vcall_slot_addr): Reorder cases to be
11523 * mini-amd64.c (mono_arch_get_vcall_slot_addr): Fix ordering of cases.
11525 * aot.c (mono_aot_load_method): Get rid of bogus make_writable call.
11527 2005-03-09 Ben Maurer <bmaurer@ximian.com>
11529 * mini.c (mono_codegen): Don't leak here, to help people running
11532 2005-03-08 Zoltan Varga <vargaz@freemail.hu>
11534 * mini-amd64.c (mono_arch_output_basic_block): Fix int->float
11535 conversions in sse2 mode.
11537 * basic-float.cs: Add regression test.
11539 * mini-amd64.c: Reenable sse2.
11541 2005-03-07 Zoltan Varga <vargaz@freemail.hu>
11543 * mini-amd64.c: Disable sse2 until some regressions are fixed.
11545 2005-03-07 Joerg Rosenkranz <joergr@voelcker.com>
11547 * driver.c: Copyright text should include 2005.
11549 2005-03-07 Zoltan Varga <vargaz@freemail.hu>
11551 * cpu-amd64.md (load_membase): Fix more max lengths.
11553 2005-03-06 Zoltan Varga <vargaz@freemail.hu>
11555 * cpu-amd64.md (load_membase): Fix max length.
11557 * mini-ops.h: Add OP_F<xx>_MEMBASE opcodes.
11559 * inssel.brg: Add MONO_EMIT_BIALU_MEMBASE macro.
11561 * cpu-amd64.md inssel-amd64.brg mini-amd64.h mini-amd64.brg: Finish SSE2
11562 support and enable it by default. Also add OP_F<xxx>_MEMBASE opcodes.
11564 * basic-float.cs: Add rounding regression test.
11566 * mini-amd64.c (INST_IGNORES_CFLAGS): Add more instructions.
11568 2005-03-04 Neale Ferguson <NealeFerguson@earthlink.net>
11570 * inssel-s390.brg, mini-s390.c: Add support for passing/returning small
11571 structures in registers for pinvoke wrappers.
11573 2005-03-04 Zoltan Varga <vargaz@freemail.hu>
11575 * mini-exceptions.c (ves_icall_get_trace): Return wrapper info as well.
11577 2005-03-03 Zoltan Varga <vargaz@freemail.hu>
11579 * mini.h mini.c mini-x86.c: Pass the domain of the native->managed
11580 wrapper to mono_jit_thread_attach.
11582 * mini.c (mini_jit_thread_attach): New jit icall.
11584 * mini-x86.c (mono_arch_emit_prolog): Attach to the VM in
11585 native->managed wrappers.
11587 * exceptions.cs: Add new regression test.
11589 * mini.c (optimize_branches): Check regions in the cbranch to throw
11590 block case as well. Fixes #73242.
11592 Tue Mar 1 18:35:27 CET 2005 Paolo Molaro <lupus@ximian.com>
11594 * mini.c: thread safety fixes.
11596 2005-02-27 Zoltan Varga <vargaz@freemail.hu>
11598 * tramp-amd64.c (amd64_magic_trampoline): Disable the method_ptr
11599 patching stuff, since delegates use jump trampolines so there is
11602 * tramp-amd64.c (create_trampoline_code): Pass NULL as 'code' in
11605 * tramp-amd64.c: Fix build.
11607 * mini-x86.c tramp-x86.c: Moved get_vtable_slot_addr into mini-x86.c and rename
11608 it to mono_arch_.... Add get_delegate_method_ptr implementation for x86.
11610 * mini-amd64.h mini.h mini-amd64.c tramp-amd64.c (mono_amd64_get_vcall_slot_addr):
11611 Rename this to mono_arch....
11612 (mono_amd64_get_delegate_method_ptr_addr): Ditto.
11614 * mini-amd64.c (mono_amd64_get_delegate_method_ptr_addr): New helper function.
11616 * mini-amd64.c (emit_call): If both the caller and the callee is
11617 guaranteed to have 32 bit addresses, emit a normal call.
11619 * tramp-amd64.c: Adapt to changes in mini-amd64.c.
11621 * tramp-amd64.c (amd64_magic_trampoline): Remove patching of trampolines.
11622 * tramp-amd64.c (amd64_magic_trampoline): Add support for patching the
11623 method_ptr inside delegates.
11625 2005-02-26 Zoltan Varga <vargaz@freemail.hu>
11627 * mini.c (mono_jit_free_method): Free the method info even if the native code is
11628 invalidated. Fixes #73001.
11630 * mini.c: Add a proper icall wrapper for mono_delegate_ctor.
11632 * mini-x86.c: Only use stdcall for pinvokes on windows.
11634 Thu Feb 24 15:22:30 CET 2005 Paolo Molaro <lupus@ximian.com>
11636 * mini.c, mini.h: make mono_lmf_addr a fast-access thread var.
11637 * mini-x86.c: remove unreliable __thread var offset detection,
11638 use the correct accessors and enable by default.
11640 2005-02-23 Zoltan Varga <vargaz@freemail.hu>
11642 * mini.c (mono_jit_free_method): Fix memory leak.
11644 2005-02-22 Zoltan Varga <vargaz@freemail.hu>
11646 * mini.c (mono_method_to_ir): Allocate a GOT var for THROW and RETHROW.
11648 2005-02-21 Zoltan Varga <vargaz@freemail.hu>
11650 * cpu-amd64.md: Fix lengths of atomic opcodes.
11652 Mon Feb 21 16:52:20 CET 2005 Paolo Molaro <lupus@ximian.com>
11654 * driver.c: try to not imply using ICU is any good.
11656 2005-02-20 Zoltan Varga <vargaz@freemail.hu>
11658 * mini-amd64.c (mono_arch_get_inst_for_method): Implement more
11659 functions as inline ops.
11661 * mini-ops.h inssel-amd64.brg cpu-amd64.md mini-amd64.c: Implement
11662 some Interlocked functions as inline ops.
11664 * mini.c (move_basic_block_to_end): Fix bug in last patch.
11666 * mini.h (MonoBasicBlock): Reorganize fields a bit.
11668 * mini-ops.h inssel.brg: Add OP_NOT_REACHED.
11670 * mini.c: Add support for OP_NOT_TAKEN.
11672 * mini-amd64.h mini-amd64.c: Add support for passing/returning small
11673 structures in registers for pinvoke wrappers.
11675 * mini-amd64.c: Fix warnings.
11677 2005-02-19 Zoltan Varga <vargaz@freemail.hu>
11679 * mini.h (MonoCompile): Add 'ret_var_is_local' field.
11681 * mini.h mini.c (mono_arch_create_vars): Add new arch specific hook.
11683 * mini.c (NEW_RETLOADA): If the ret variable is a local, use its
11684 address instead of loading the address from it.
11686 * mini-x86.c: Add support for returning small structs in registers
11687 on Win32. Fixes part of #70864.
11689 2005-02-18 Zoltan Varga <vargaz@freemail.hu>
11691 * trace.c (get_token): Improve error checking.
11693 2005-02-17 Zoltan Varga <vargaz@freemail.hu>
11695 * jit-icalls.c (mono_ldvirtfn): Explicitly check for a NULL obj here.
11697 2005-02-17 Sebastien Pouliot <sebastien@ximian.com>
11699 * mini.h: Moved MONO_EXCEPTION_* enum to metadata/class-internals.h so
11700 it can be reused for MonoClass.
11701 * mini.c: Renamed MONO_EXCEPTION_SECURITY to MONO_EXCEPTION_SECURITY
11704 2005-02-15 Sebastien Pouliot <sebastien@ximian.com>
11706 * mini.c: Fixed 2 cases where I sent a MonoMethod to managed code
11707 instead of a MonoReflectionMethod. The method information wasn't used
11708 when displaying SecurityException details (but will be now).
11710 2005-02-15 Atsushi Enomoto <atsushi@ximian.com>
11712 * Makefile.am : windows build fix.
11714 2005-02-14 Zoltan Varga <vargaz@freemail.hu>
11716 * iltests.il: Add new regression test.
11718 * mini.c (mono_method_to_ir): Allocate a GOT var in CEE_NEWOBJ. Fixes
11721 2004-02-13 Sebastien Pouliot <sebastien@ximian.com>
11723 * mini.c: Moved linkdemand check into helper function check_linkdemand
11724 to allow reuse for all intructions (CALL, CALLVIRT, NEWOBJ, JMP,
11727 2004-02-13 Sebastien Pouliot <sebastien@ximian.com>
11729 * declsec.c: Added statistics counter for different kinds of
11731 * mini.h: Added CAS statistic counters to MonoJitStats. Removed unused
11732 (and commented) declaration.
11733 * mini.c: Added statistics counter for security Demand code
11734 generation. Added display of security statistics.
11736 2005-02-13 Zoltan Varga <vargaz@freemail.hu>
11738 * declsec.c (mono_declsec_linkdemand_aptc): Applied patch from Robert Jordan (robertj@gmx.net).
11739 Fix compilation errors under gcc-2.95.
11741 2005-02-12 Ben Maurer <bmaurer@ximian.com>
11743 * mini.c, driver.c: Use the new jit trampoline hashtable
11745 Fri Feb 11 18:47:11 CET 2005 Paolo Molaro <lupus@ximian.com>
11747 * mini.c, jit-icalls.c: use the managed implementation of memcpy, too.
11749 2005-02-11 Martin Baulig <martin@ximian.com>
11751 * debug-mini.c (mono_debug_close_method): Free the line number array.
11753 2005-02-10 Zoltan Varga <vargaz@freemail.hu>
11755 * aot.c: Break up large methods into smaller ones. Share GOT slots for
11758 * mini.h: Bump AOT file format version.
11760 2005-02-10 Sebastien Pouliot <sebastien@ximian.com>
11762 * declsec.c: Added LinkDemand support and it's special cases for ECMA,
11764 * declsec.h: Added macros to get/set lazyly initialized security
11765 informations about assemblies. Added new enum for different type of
11766 possible LinkDemand violation. Added function to check LinkDemands.
11767 * mini.h: Added a field to MonoCompile to hold any security violation
11768 detected when JITting a method (so it can be thrown later).
11769 * mini.c: Added LinkDemand checks in mono_method_to_ir for CEE_CALL
11770 and CEE_CALLVIRT. Added code to throw exception at the end of
11771 mini_method_compile (note: the exception is unhandled right now).
11773 Thu Feb 10 15:49:44 CET 2005 Paolo Molaro <lupus@ximian.com>
11775 * mini.c, jit-icalls.c: use the managed implementation of
11776 memset for initobj and memset, to avoid managed <-> unmanaged
11779 2005-02-10 Zoltan Varga <vargaz@freemail.hu>
11781 * inssel.brg (mini_emit_virtual_call): Disable the virtual->nonvirtual
11782 optimization if it would need a GOT var.
11784 * basic.cs: Add tests for constant propagation and switch statements.
11786 * ssa.c: Fix out-of-range constant propagation and switch statements.
11788 2005-02-09 <vargaz@freemail.hu>
11790 * inssel-x86.brg (reg): Align the allocation size in the localloc(imm) case too.
11792 2005-02-08 Zoltan Varga <vargaz@freemail.hu>
11794 * cpu-amd64.md (load_membase): Fix max length of load_membase.
11796 Tue Feb 8 18:21:11 CET 2005 Paolo Molaro <lupus@ximian.com>
11798 * mini.c: update to new signature of mono_class_get_allocation_ftn().
11800 2005-02-06 Neale Ferguson <NealeFerguson@earthlink.net>
11802 * cpu-s390.md, mini-s390.c: Correct bug with register usage on certain
11803 arithmetic operations.
11805 Sun Feb 6 07:10:12 EST 2005 Paolo Molaro <lupus@ximian.com>
11807 * mini-ppc.c: add a workaround for broken user code that
11808 DllImports vararg functions with non-vararg signatures.
11810 2005-02-05 Zoltan Varga <vargaz@freemail.hu>
11812 * mini.c (mono_jit_compile_method_inner): Add detection and a
11813 meaningfull error message for assemblies written in Managed C++.
11815 * tramp-amd64.c mini-amd64.h: Add support for
11816 create_trampoline_from_token ().
11818 * aot.c mini-x86.c abcremoval.c: Applied patch from
11819 Robert Jordan (robertj@gmx.net). Fix compilation errors under gcc-2.95.
11821 2005-02-04 Zoltan Varga <vargaz@freemail.hu>
11823 * mini.h mini.c mini-x86.h tramp-x86.c: Add a new kind of trampoline
11824 which takes a MonoImage/token as parameter instead of a MonoMethod.
11826 * aot.c: Use the new trampoline for initializing vtables.
11828 * aot.c: Add support for ldfld/stfld_remote wrappers.
11830 * mini-ops.h cpu-pentium.md inssel-x86.brg mini-x86.c: Add optimized
11831 rules for compare <MEM>, IMM.
11833 * mini.h (MONO_AOT_FILE_VERSION): Bump it.
11835 * aot.c: Handle inherited finalizers correctly.
11837 2005-02-03 Zoltan Varga <vargaz@freemail.hu>
11839 * inssel.brg (stmt): Add a missing _setup_... ().
11841 * aot.c: Save some parts of the class state to the AOT file and use it
11842 to recompute that state when a class is initialized.
11844 * mini.c: Install AOT hooks into the runtime.
11846 * mini.h: Bump AOT file format version.
11848 * mini.c (mono_method_to_ir): Initialize pointer type locals correctly.
11851 * iltests.il: Add new test.
11853 Wed Feb 2 16:53:59 CET 2005 Paolo Molaro <lupus@ximian.com>
11855 * mini.c: fix typo.
11857 Wed Feb 2 16:37:13 CET 2005 Paolo Molaro <lupus@ximian.com>
11859 * mini.c: setup the statistical profiler in the thread attach
11860 callback to cope with the new single thread code.
11862 Wed Feb 2 15:43:58 CET 2005 Paolo Molaro <lupus@ximian.com>
11864 * mini-ppc.c: ensure we have enough room for the profiler
11865 calls (fixed bug#72084).
11867 2005-02-02 Zoltan Varga <vargaz@freemail.hu>
11869 * aot.c: Get rid of the MonoAotMethod structure and the hashtable holding
11872 2005-2-1 Massimiliano Mantione <massi@ximian.com>
11874 * driver.c: Re-enabled SSAPRE (two commits, I was just dumb).
11876 2005-2-1 Massimiliano Mantione <massi@ximian.com>
11878 * ssapre.c: Fixed an issue with down safety (this allows IronPython
11879 to succesfully execute parrotbench).
11880 * ssapre.h: Likewise.
11882 2005-2-1 Massimiliano Mantione <massi@ximian.com>
11884 * ssa.c: In mono_ssa_rename_vars, forced the creation of a new SSA
11885 variable for stores to method arguments (fixes a SSAPRE issue).
11887 Tue Feb 1 15:52:26 CET 2005 Paolo Molaro <lupus@ximian.com>
11889 * mini.c: handle value types in dup, fixes gen-112.cs.
11891 Tue Feb 1 11:45:19 CET 2005 Paolo Molaro <lupus@ximian.com>
11893 * mini-ppc.c, cpu-g4.md, tramp-ppc.c: use a slower code
11894 sequence for calls in dynamic methods to avoid thunks.
11896 Tue Feb 1 11:44:01 CET 2005 Paolo Molaro <lupus@ximian.com>
11898 * mini.c: correctly remove dynamic methods from the hashtable.
11900 2005-1-20 Massimiliano Mantione <massi@ximian.com>
11902 * driver.c: Disabled SSAPRE until fix the bug that appears
11903 in IronPython's parrotbench.
11905 2005-01-31 Zoltan Varga <vargaz@freemail.hu>
11907 * aot.c (mono_compile_assembly): Get rid of Skip (other) messages.
11909 * mini.c (mono_method_to_ir): Revert the previous change.
11911 * mini.c (mono_method_to_ir): Do not inline ldfld and stfld wrappers
11912 when AOT compiling.
11914 * tramp-x86.c (x86_magic_trampoline): Avoid calls to
11915 mono_jit_info_table_find () etc. when running under valgrind.
11917 * inssel.brg: Fix warnings.
11919 * mini-exceptions.c: Fix warnings.
11921 2005-01-31 Martin Baulig <martin@ximian.com>
11923 * driver.c (compile_all_methods_thread_main): Don't try to compile
11924 generic methods or anything which has type parameters.
11926 2005-01-30 Zoltan Varga <vargaz@freemail.hu>
11928 * aot.c: Avoid costly calls to mono_method_full_name in tracing code and fix memory leaks.
11930 * TestDriver.cs: Add --verbose flags.
11932 * graph.c ssa.c: Fix 64 bit warnings.
11934 * abcremoval.h ssapre.h abcremoval.c ssapre.c mini.c tramp-amd64.c
11935 trace.c mini-exceptions.c linear-scan.c inssel-amd64.brg inssel.brg:
11936 Fix 64 bit warnings.
11938 * mini-amd64.c (mono_arch_output_basic_block): Fix uninitialized
11939 variable not spotted by gcc.
11941 * mini-amd64.c inssel-amd64.brg: Applied patch from
11942 Willibald Krenn <Willibald.Krenn@gmx.at>. Clean up usage of
11943 X86_COMPARE_MEMBASE opcodes.
11945 * exceptions-amd64.c (mono_arch_find_jit_info): Fix AMD64 build.
11947 2005-01-29 Ben Maurer <bmaurer@ximian.com>
11949 * *: MonoMethod->signature might be NULL now. You *MUST* use
11950 mono_method_signature.
11952 2005-01-28 Zoltan Varga <vargaz@freemail.hu>
11954 * driver.c (compile_all_methods_thread_main): Compile the methods
11955 without invoking cctors.
11957 Fri Jan 28 18:28:26 CET 2005 Paolo Molaro <lupus@ximian.com>
11959 * mini.c: remove ben's "optimizations" to dup+stloc (bug #71905).
11960 * basic-calls.cs: test for the above.
11962 2005-01-28 Zoltan Varga <vargaz@freemail.hu>
11964 * mini.c mini-exceptions.c aot.c exceptions-*.c: Update after
11965 MonoJitInfo changes.
11967 2005-01-27 Zoltan Varga <vargaz@freemail.hu>
11969 * mini-exceptions.c (mono_handle_exception): Compute the stack trace
11970 eagerly if it contains dynamic methods.
11972 * mini-exceptions.c (ves_icall_System_Exception_get_trace): New icall.
11974 * mini-exceptions.c (mono_handle_exception): Avoid computing the stack
11975 trace, it is now computed by an icall from trace_ips.
11977 * mini-exceptions.c: Fix a warning.
11979 Thu Jan 27 13:38:34 CET 2005 Paolo Molaro <lupus@ximian.com>
11981 * mini-exceptions.c: don't bother getting stack trace info if
11982 it's not going to be used.
11984 2005-01-27 Raja R Harinath <rharinath@novell.com>
11986 * Makefile.am (common_sources): Add ssapre-cee-ops.h and
11989 2005-01-26 Zoltan Varga <vargaz@freemail.hu>
11991 * mini.c (remove_block_if_useless): Only print debug stuff with -v -v.
11993 * aot.c: Avoid calling mono_method_get_header () if not needed.
11995 * mini.h: Bump AOT file format version.
11997 * mini.c (mono_emit_native_call): Allocate a GOT var here.
11999 * mini.c (mono_print_tree): Print more info for calls.
12001 2005-01-26 Sebastien Pouliot <sebastien@ximian.com>
12003 * declsec.h: Remove warning by adding missing include for marshal.h
12005 2005-01-26 Martin Baulig <martin@ximian.com>
12007 * mini.c (mono_method_to_ir): In CEE_UNBOX_ANY, don't increase
12010 2005-01-25 Zoltan Varga <vargaz@freemail.hu>
12012 * mini-amd64.c (mono_arch_call_opcode): Add missing MONO_SSA_LOAD/STORE
12015 * ssa.c (mono_ssa_compute): Fix crashes when using AOT.
12017 * aot.c (mono_compile_assembly): Fix a warning.
12019 2005-01-25 Sebastien Pouliot <sebastien@ximian.com>
12021 * declsec.c: Look for security attributes on the original MonoMethod
12022 (and not the wrapped one). This fix permissions on icalls.
12024 2005-01-23 Zoltan Varga <vargaz@freemail.hu>
12026 * mini-amd64.c (mono_arch_allocate_vars): Use mono_allocate_stack_slots ().
12028 * mini.c (mono_allocate_stack_slots): Add a fixme.
12030 * mini-x86.c (mono_arch_allocate_vars): Use mono_allocate_stack_slots ().
12032 Sun Jan 23 16:16:48 CET 2005 Paolo Molaro <lupus@ximian.com>
12034 * inssel.brg: optimize casts of sealed types (more
12035 optimizations waiting for fixes in remoting).
12037 2005-01-23 Zoltan Varga <vargaz@freemail.hu>
12039 * inssel.brg (stmt): Add another dummy rule.
12041 * driver.c: Fix warnings.
12043 * driver.c (mono_main): If running under valgrind, instruct glib to use
12044 the system allocation functions so valgrind can track the memory
12045 allocated by the g_... functions.
12047 * inssel.brg (stmt): Add DUMMY rule for OP_DUMMY_STORE.
12049 * mini-ops.h: Add OP_DUMMY_STORE opcode.
12051 * mini.h (MONO_BBLOCK_IS_IN_REGION): New helper macro.
12053 * liveness.c: Handle OP_DUMMY_STORE. Enable register allocation for
12054 variables in try regions.
12056 * mini.c (mini_method_compile): Don't disable optimizations on large
12057 methods when AOT compiling.
12059 * mini.c (mono_allocate_stack_slots): New arch independent method to
12060 allocate stack slots. Not yet used.
12062 2005-01-22 Ben Maurer <bmaurer@ximian.com>
12064 * debug-mini.c (mono_debug_close_method): Plug some leaks.
12066 Sat Jan 22 13:41:51 EST 2005 Paolo Molaro <lupus@ximian.com>
12068 * mini-ppc.c: make the branch info relative as the code
12069 buffer can be reallocated.
12071 2005-01-22 Sebastien Pouliot <sebastien@ximian.com>
12073 * aot.c: Allow decoding of the new MONO_PATCH_INFO_DECLSEC.
12074 * driver.c: Removed the AOT/security restriction. Now initialize the
12075 security manager (in metadata) if --security is used.
12076 * mini.c|h: Add the MONO_PATCH_INFO_DECLSEC code to use the index,
12077 rather than the pointer to declarative security, when AOT is used.
12079 Sat Jan 22 09:35:19 EST 2005 Paolo Molaro <lupus@ximian.com>
12081 * mini.h, mini-ppc.h, mini-ppc.c: updated to use out of line
12082 basic blocks, reduced intrinsic exception throwing code size.
12084 2005-01-22 Miguel de Icaza <miguel@ximian.com>
12086 * driver.c (mini_usage): Reorder the usage screen.
12088 2005-01-21 Zoltan Varga <vargaz@freemail.hu>
12090 * mini.c (mono_resolve_patch_target): Fix warning.
12092 2005-01-20 Zoltan Varga <vargaz@freemail.hu>
12094 * mini-x86.c (mono_arch_local_regalloc): Fix bug introduced by
12097 * mini-amd64.c (mono_arch_local_regalloc): Ditto.
12099 * mini-amd64.c (mono_arch_local_regalloc): Revert last patch as it
12100 breaks the amd64 build.
12102 * mini-x86.c (mono_arch_local_regalloc): Fix bug in div/rem
12103 register allocation. Fixes #71454.
12105 * mini-amd64.c (mono_arch_local_regalloc): Ditto.
12107 * arrays.cs: Add new regression test.
12109 2005-1-20 Massimiliano Mantione <massi@ximian.com>
12111 * ssapre.c: Turned usage of snprintf to GString.
12112 * ssapre.h: disabled MONO_APPLY_SSAPRE_TO_SINGLE_METHOD
12113 (I left it on by mistake in my previous commit).
12115 Thu Jan 20 12:00:45 CET 2005 Paolo Molaro <lupus@ximian.com>
12117 * mini.c, cfold.c, basic-calls.cs: preserve side effects
12118 on cond branch optimization (fixes bug# 71515).
12120 2005-1-20 Massimiliano Mantione <massi@ximian.com>
12122 * abcremoval.c: Fixed bug 71062.
12123 * abcremoval.h: Likewise.
12125 2005-1-20 Massimiliano Mantione <massi@ximian.com>
12127 * mini.c: Added a new functionality to optimize_branches, the removal
12128 of useless basic blocks, and fixed some problem in the removal of
12129 critical edges; some utility functions added for both purposes.
12130 * ssapre.c: Added complex expression support, and fixed bug 70637.
12131 * ssapre.h: Likewise.
12132 * ssapre-cee-ops.h: Added file with list of "CEE_*" opcodes
12134 * ssapre-mini-ops.h: Likewise, but for "OP_*" opcodes.
12135 * driver.c: Re-enabled SSAPRE.
12137 2005-01-19 Martin Baulig <martin@ximian.com>
12139 * mini.c (mono_method_to_ir): Call mono_get_inflated_method() on
12140 the result of mono_get_method_constrained().
12142 2005-01-18 Neale Ferguson <NealeFerguson@earthlink.net>
12144 * exceptions-s390.c tramp-s390.c: Allocate code using the global code
12147 2005-01-18 Geoff Norton <gnorton@customerdna.com>
12149 * jit-icalls.c (mono_llmult_ovf): Fix other overflow conditions to
12150 be detected. Fixes #59296.
12152 2005-01-18 Zoltan Varga <vargaz@freemail.hu>
12154 * mini-amd64.c (mono_arch_output_basic_block): Remove some assertions
12155 which can happen. Fixes #71361.
12157 2005-01-18 Zoltan Varga <vargaz@freemail.hu>
12159 * exceptions-sparc.c tramp-sparc.c: Allocate code using the global code
12162 2005-01-17 Zoltan Varga <vargaz@freemail.hu>
12164 * mini.c (mono_create_jump_trampoline): Revert last change as it causes
12165 appdomain-unload.exe to fail.
12167 * mini.c: Fix some memory leaks.
12169 Mon Jan 17 16:16:23 CET 2005 Paolo Molaro <lupus@ximian.com>
12171 * inssel.brg: handle the new size of rank, idepth, max_interface_id.
12172 Fixed bug and sped up some codepaths.
12174 2005-01-17 Zoltan Varga <vargaz@freemail.hu>
12176 * mini.c: Fix some memory leaks.
12178 * exceptions.cs basic-long.cs: Add test for checked ulong->int
12181 * inssel-long.brg: Implement long_conv_to_ovf_i4_un. Fixes #71319.
12183 * inssel-long.brg: Fix conv.ovf.i8 when run on an int32. Fixes
12186 * iltests.il: Add regression test for #71320.
12188 2005-01-16 Zoltan Varga <vargaz@freemail.hu>
12190 * mini.c (mono_codegen): Fix installation of profiler hooks.
12192 * mini-sparc.c mini-amd64.c: Don't allocate stack space for dead vars.
12194 Sun Jan 16 12:19:35 CET 2005 Paolo Molaro <lupus@ximian.com>
12196 * mini.h, mini.c, cfold.c: optimize access to enum
12197 readonly fields, too. Eval conditional branches if possible
12198 to perform unreachable code removal in more cases.
12200 2005-01-15 Zoltan Varga <vargaz@freemail.hu>
12202 * tramp-amd64.c exceptions-amd64.c: Use the new global code manager.
12204 * mini.c (mono_global_codeman_reserve): New function to allocate code memory from a global
12207 * tramp-x86.c mini-x86.c exceptions-x86.c: Allocate all code memory so mono works with
12208 WinXP DEP. Fixes #71244.
12210 2005-01-14 Zoltan Varga <vargaz@freemail.hu>
12212 * inssel.brg: Allways convert CEE_CONV_OVF_I4 to a move on 64 bit platforms. Fixes #71236.
12214 2005-01-13 Zoltan Varga <vargaz@freemail.hu>
12216 * mini-x86.c (mono_arch_output_basic_block): Fix OP_ATOMIC_ADD_NEW_I4.
12218 2005-01-11 Zoltan Varga <vargaz@freemail.hu>
12220 * mini-exceptions.c exceptions-ppc.c aot.c: Cope with MonoJitInfo
12223 * mini.h: Bump AOT version.
12225 * mini.h (MonoCompile): Change exvar to a hash table.
12227 * mini.c: Allocate a separate exvar for each handler block.
12229 * mini.c: Get rid of the computation of filter_lengths, its not needed.
12231 * mini.c inssel.brg: Change OP_THROW_OR_NULL to compare the current
12232 ex var with the pending exception and only throw if the two are equal.
12235 * exceptions.cs: Add tests for rethrow and nested catch clauses.
12237 * mini-x86.c: Fix warnings.
12239 * Makefile.am (common_sources): Move mini-exceptions.c here as it is
12240 used by all the ports now.
12242 * aot.c: Add write-symbols and save-temps options.
12244 2005-01-10 Zoltan Varga <vargaz@freemail.hu>
12246 * mini-x86.c: Add support for returning structs in registers from pinvoke functions on WIN32.
12248 Mon Jan 10 16:11:16 EST 2005 Neale Ferguson <nealeferguson@earthlink.net>
12250 * mini-ops.h, inssel-s390.brg, cpu-s390.md: Support OP_ATOMIC__xxx
12253 * tramp-s390.c: Check vtable slot belongs to the domain.
12255 * mini-exceptions.c, exceptions-s390.c: Standardize exception handling
12256 as per other platforms.
12258 * mini-s390.c, mini-s390.h: Enable out-of-line bblock support.
12260 Mon Jan 10 18:53:05 CET 2005 Paolo Molaro <lupus@ximian.com>
12262 * driver.c: we don't run the Main() code in a subthread anymore.
12264 Mon Jan 10 17:54:16 CET 2005 Paolo Molaro <lupus@ximian.com>
12266 * mini.c: added experimental rtc support in the statistical
12267 profiler: if the user has the permission, more accurate statistics
12268 are gathered. Run with: MONO_RTC=4096 mono --profiler=default:stat ....
12269 The MONO_RTC value must be restricted to what the linux rtc allows:
12270 power of two from 64 to 8192 Hz.
12272 2005-01-10 Zoltan Varga <vargaz@freemail.hu>
12274 * mini-x86.c (mono_arch_emit_exceptions): Fix #71121.
12276 Mon Jan 10 05:20:49 EST 2005 Paolo Molaro <lupus@ximian.com>
12278 * mini-ppc.c: better icache flush for smp.
12280 2005-01-09 Zoltan Varga <vargaz@freemail.hu>
12282 * mini-amd64.c (emit_move_return_value): Fix memory leak.
12284 * mini-x86.c (get_call_info): Add the get_call_info () code from the
12285 amd64 port, not yet used.
12287 2005-01-07 Zoltan Varga <vargaz@freemail.hu>
12289 * mini.c (mono_method_to_ir): Disable inlining of ldfld wrappers with
12292 2005-01-07 Sebastien Pouliot <sebastien@ximian.com>
12294 * driver.c: Added --security option to activate the security manager.
12295 Right now this will allow code generation for declarative demands and
12296 is disabled when AOT is specified.
12297 * mini.c: Add code generation for declarative security demands.
12298 * mini.h: Add mono_use_security_manager as an extern gboolean.
12300 2005-01-07 Zoltan Varga <vargaz@freemail.hu>
12302 * aot.c (mono_compile_assembly): Speed up compilation a bit by
12303 emitting more dense assembly code.
12305 * mini-sparc.c mini-sparc.h exceptions-sparc.c: Enable optimized corlib
12306 exception throwing stuff.
12308 2005-01-06 Zoltan Varga <vargaz@freemail.hu>
12310 * mini-sparc.c (mono_arch_emit_exceptions): Fix typo in previous patch. Remove
12313 * mini-amd64.c (mono_arch_emit_exceptions): Remove duplicate epilog stuff
12314 left in by mistake.
12316 * driver.c (EXCLUDED_FROM_ALL): Disable SSAPRE until bug #70637 is
12319 * mini-sparc.h mini-sparc.c: Enable out-of-line bblock support.
12321 * tramp-*.c: Only patch vtable slots if the object is in the current
12322 domain. Fixes appdomain-unload.exe.
12324 * mini-amd64.c mini-amd64.h: Enable out-of-line bblock support.
12326 * mini-amd64.c (mono_arch_local_regalloc): Port regalloc fix from
12329 2005-01-05 Zoltan Varga <vargaz@freemail.hu>
12331 * mini.c (reverse_branch_op): New helper function.
12333 * mini.c (optimize_branches): Run the new optimization only on
12334 platforms which support it. Also reverse all kinds of branches.
12336 * mini.h (MonoBasicBlock): Add 'out_of_line' field.
12338 * mini.c (mono_method_to_ir): Set 'out_of_line' for bblocks which have
12341 * mini.c (optimize_branches): Reverse not-equals branches if the false
12342 bblock is a throw. This happens a lot of time with argument checking in
12345 * mini.c (mono_codegen): Add support for placing basic blocks after
12346 the function epilogue.
12348 * mini-x86.c mini-x86.h: Add support for placing basic blocks after the
12351 2005-01-05 Miguel de Icaza <miguel@ximian.com>
12353 * mini.c (setup_stat_profiler): Only set this up if the platform
12354 supports ITIMER_PROF.
12356 2005-01-05 Zoltan Varga <vargaz@freemail.hu>
12358 * mini-x86.c (mono_arch_local_regalloc): Fix a bug introduced by the
12361 * inssel.brg: Fix a warning.
12363 Wed Jan 5 16:40:18 CET 2005 Paolo Molaro <lupus@ximian.com>
12365 * mini.c: added support for statistical profiler
12366 (run with: --profile=default:stat).
12368 2005-01-04 Zoltan Varga <vargaz@freemail.hu>
12370 * mini-x86.h (MONO_ARCH_ENABLE_EMIT_STATE_OPT): Enable this on x86.
12372 * mini-x86.c cpu-pentium.md: More fixes for usage of global registers.
12374 * mini-amd64.c (mono_arch_local_regalloc): Port some regalloc fixes
12375 related to global registers from the amd64 port.
12377 2005-01-03 Zoltan Varga <vargaz@freemail.hu>
12379 * mini.c (mono_method_to_ir): Handle MONO_CLASSCONST.
12381 * mini-amd64.c (mono_arch_local_regalloc): Fix some regalloc problems
12382 with global registers.
12383 (mono_arch_output_basic_block): Fix SWITCH in the AOT case.
12385 * aot.c (emit_method_code): Fix the 'method emitted as' messages.
12387 2004-12-31 Zoltan Varga <vargaz@freemail.hu>
12389 * debug-mini.c (encode_value): Fix off-by-one.
12391 * aot.c (encode_value): Likewise.
12393 * mini.c (mono_method_to_ir): Disable AOT for methods containing LDPTR.
12395 2004-12-30 Zoltan Varga <vargaz@freemail.hu>
12397 * mini.c linear-scan.c: Add a workaround for the mcs crash when using
12400 * aot.c (mono_aot_load_method): Free up patch info if no longer needed.
12402 * aot.c (emit_method_info): Increase size of temp buffer.
12404 * mini-x86.c cpu-pentium.md mini.c: Load fp constants differently in
12407 2004-12-28 Zoltan Varga <vargaz@freemail.hu>
12409 * aot.c (emit_method_info): Fix build.
12411 * aot.c: Further rework of the AOT file format to reduce the size of
12412 the method info data.
12414 * mini.h: Bump AOT file format version.
12416 2004-12-27 Martin Baulig <martin@ximian.com>
12418 * mini.c (mini_get_method): New static method; call
12419 mono_get_method_full() and mono_get_inflated_method().
12420 (mono_method_to_ir): Use mini_get_method() instead of
12421 mono_get_method_full().
12423 2004-12-26 Patrik Torstensson <patrik.torstensson@gmail.com>
12425 * mini-x86.c (atomic ops): fixed bug interlocked bug #70784.
12427 2004-12-25 Zoltan Varga <vargaz@freemail.hu>
12429 * inssel.brg (ldind_to_load_membase): Handle CEE_LDIND_I8.
12431 * inssel-amd64.brg: Add some optimization rules.
12433 2004-12-24 Ben Maurer <bmaurer@ximian.com>
12435 * aot.c: Remove the use of MonoGHashTable and other GC stuff. The
12436 standard not GC'd stuff is fine.
12438 2004-12-24 Zoltan Varga <vargaz@freemail.hu>
12440 * aot.c: Rework the AOT file format to get rid of most of the global
12441 symbols. This reduces the size of the mscorlib.dll.so by 1MB.
12443 * mini.h: Bump AOT file format version.
12445 2004-12-23 Zoltan Varga <vargaz@freemail.hu>
12447 * mini.h: Bump AOT file format version.
12449 * aot.c (mono_aot_is_got_entry): New function to determine if an
12450 address is inside a GOT.
12452 * aot.c mini-x86.c tramp-x86.c: Make all patches use the GOT.
12454 * cpu-pentium.md: Increase the maximum size of some instructions which
12455 might involve a got access.
12457 * mini.c (get_method_from_ip): Another debug helper function.
12459 * mini.c: Call mono_get_got_var () in a couple places. Handle the case
12460 when got var accesses are created during the decompose phase.
12462 * mini-sparc.c: Change mono_compile_aot to cfg->compile_aot.
12464 * mini.h mini.c mini-x86.c aot.c mini-sparc.c: Add a 'compile_corlib'
12465 argument mini_compile_method and to MonoCompile, and use this to
12466 determine whenever a given method is compiled for AOT. This allows the
12467 other methods compiled during AOT compilation to be free of AOT stuff,
12468 so the backends does not need to add special support for them by
12469 creating a fake GOT etc.
12471 * mini-x86.c (mono_arch_patch_code): Remove fake got stuff as it is no
12474 2004-12-21 Ben Maurer <bmaurer@ximian.com>
12476 * mini.c (mono_method_to_ir): It turns out that some of the
12477 x-appdomain wrappers are lax with types, so just ignore this for
12480 * inssel.brg (OP_CHECK_ARRAY_TYPE): Optimize this by only looking
12481 at the vtable->klass. If it is non-shared code we can just use the
12484 Tue Dec 21 17:43:06 CET 2004 Paolo Molaro <lupus@ximian.com>
12486 * mini-ppc.c: access MonoDomain from tls, too.
12488 2004-12-21 Sebastien Pouliot <sebastien@ximian.com>
12490 * declsec.c: Removed unused variable (and related warning ;-)
12492 2004-12-21 Ben Maurer <bmaurer@ximian.com>
12494 * iltests.il: New test for LDELEMA on an array of ref types.
12496 * mini.c (CEE_LDELEMA): We need to emit OP_CHECK_ARRAY_TYPE for
12497 all ldelema's on reftypes.
12498 (check_call_signature): Remove the OP_CHECK_ARRAY_TYPE from here,
12499 it was the wrong place to put it.
12501 * mini-x86.c (mono_arch_output_basic_block): Just use ecx as the
12502 register to pop to make this cleaner, at the request of Paolo.
12504 2004-12-20 Ben Maurer <bmaurer@ximian.com>
12506 * mini-ops.h (OP_GETHASHCODE): New op.
12508 * inssel.brg (OP_GETHASHCODE): Emit code for the new opcode
12510 * mini.c (mini_get_inst_for_method): Create the intrinsic hash
12513 For a microbenchmark, this reduces the cost of Hashtable.get_Item
12516 * mini-x86.c (mono_arch_output_basic_block): Rather than
12524 The first is 3 bytes while the second is 1. This saves 36 kb on
12525 mscorlib, quite a big saving. When bootstraping mcs, I was able to
12526 see a small boost because of icache locality.
12528 * cfold.c (FOLD_BINOPCOMM): Kill add foo, 0
12530 Mon Dec 20 12:19:40 EST 2004 Paolo Molaro <lupus@ximian.com>
12532 * Makefile.am, mini-ppc.h, mini-exceptions.c, exceptions-ppc.c:
12533 started code sharing with the generic code.
12535 Mon Dec 20 11:08:06 EST 2004 Paolo Molaro <lupus@ximian.com>
12537 * mini-ppc.c, cpu-g4.md: added code for direct access to
12540 Mon Dec 20 10:58:28 EST 2004 Paolo Molaro <lupus@ximian.com>
12542 * mini-ops.h, inssel-x86.brg, cpu-amd64.md, inssel.brg, inssel-amd64.brg,
12543 mini-amd64.c, mini-x86.c, cpu-pentium.md: renamed OP_X86_TLS_GET
12546 2004-12-20 Sebastien Pouliot <sebastien@ximian.com>
12548 * declsec.c|h: Added functions to cache the declarative stack modifiers
12549 in MonoJitInfo and to create a security frame from a MonoJitInfo
12551 * mini.c: Initialize jinfo->cas_inited to FALSE when MonoJitInfo is
12552 created. Register internal calls for System.Security.SecurityFrame::
12553 _GetSecurityFrame and _GetSecurityStack.
12554 * mini.h: Added definition for new icalls (in mini-exceptions.c) and
12555 the definitions for the new stack walk/callback mechanism.
12556 * mini-exceptions.c: Added internal call GetSecurityFrame (to get the
12557 first security frame for LinkDemands and InheritanceDemands) and
12558 GetSecurityStack for Demands. Both use the new mono_walk_stack code
12560 * mini-x86.h, mini-amd64.h, mini-sparc.h: Architecture specific stack
12561 walk initialization (lupus).
12563 2004-12-20 Ben Maurer <bmaurer@ximian.com>
12565 * mini.c (mono_method_to_ir): In CEE_DUP, handle the dup / stloc
12567 (handle_loaded_temps): Do not create a temporary variable for
12568 things that we know are temps. They will never be modified.
12569 (mono_spill_call): Set MONO_INST_IS_TEMP
12570 (mono_emulate_opcode): ditto
12572 (mono_method_to_ir.CEE_DUP): ditto
12574 2004-12-19 Ben Maurer <bmaurer@ximian.com>
12576 * mini.c (type_to_eval_stack_type): Make this handle the void type
12577 (mono_emit_call_args): set the call->type with type_to_eval_stack_type
12578 (emit_tree): use ip_in_bb to special case some common idioms
12579 Update all callers to pass in the IP.
12580 (mono_method_to_ir): Make CEE_CALL* do the above as well.
12582 This gives us a nice 2% speedup in mcs bootstrap.
12584 * mini-x86.c (peephole_pass): Peephole pass to make
12593 * mini.c (ip_in_bb): new method.
12594 (mono_method_to_ir): use this method rather than doing the hash
12597 * linear-scan.c (mono_linear_scan): When expiring actives, you
12598 don't need to keep around variables that expire on this
12599 instruction. This makes it so that:
12602 store (ebx add (ebx, 1))
12606 2004-12-19 Zoltan Varga <vargaz@freemail.hu>
12608 * mini.c (mono_method_to_ir): Optimize the common ldobj+stloc
12609 combination to avoid doing two copies. Fix up problems with previous
12612 * mini.c: Fix 64 bit warnings.
12614 * mini-x86.c (INST_IGNORES_CFLAGS): Add OP_STOREI4_MEMBASE_REG.
12616 2004-12-17 Zoltan Varga <vargaz@freemail.hu>
12618 * mini-amd64.h mini-amd64.c exceptions-amd64.c: Port exception handling
12619 changes from the x86 code.
12621 * mini.h: Add prototype for mono_arch_get_throw_corlib_exception ().
12623 2004-12-16 Zoltan Varga <vargaz@freemail.hu>
12625 * mini-x86.c (mono_arch_emit_epilog): Optimize the corlib exception
12626 throwing code to reduce its size, unify the AOT and non-aot code and
12627 get rid of relocations in the AOT case.
12629 * mini-x86.h mini.c exceptions-x86.c
12630 (mono_arch_get_throw_corlib_exception): New arch specific function to
12631 raise corlib exceptions which doesn't require relocations in the
12634 * aot.c (emit_method): Handle PATCH_INFO_NONE as well.
12636 2004-12-15 Zoltan Varga <vargaz@freemail.hu>
12638 * mini.c (mono_emit_method_call): Only allocate the got var when it is
12641 * mini-x86.c (mono_arch_patch_code): Add missing PATCH_INFO_METHOD_REL
12644 2004-12-14 Patrik Torstensson <patrik.torstensson@gmail.com>
12646 * mini-x86.c, cpu-pentium.md, inssel-x86.brg: Fixed bug
12647 with add function when used from Inc/dec atomic
12648 functions. Re-enabled optimization on x86.
12649 * mini-ops.h: renamed atomic_add functions to
12650 allow _add to match the Interlocked::Add and
12651 _add_next to match Interlocked::Inc/Dec.
12653 2004-12-15 Massimiliano Mantione <massi@ximian.com>
12655 * mini.c: Fixed a subtle bug in mono_method_to_ir, about the
12656 linking of BBs to the end BB, and enabled SSAPRE also with
12657 consprop and copyprop (which was prevented by that bug).
12659 2004-12-14 Patrik Torstensson <patrik.torstensson@gmail.com>
12661 * mini-x86.c: disabling the Interlocked optimizing code.
12663 2004-12-14 Zoltan Varga <vargaz@freemail.hu>
12665 * aot.c (load_aot_module): Move reading of got_addr after the AOT
12666 file version check.
12668 2004-12-14 Patrik Torstensson <patrik.torstensson@gmail.com>
12670 * mini-x86.c, inssel-x86.brg, cpu-pentium.md: removed _imm
12671 interlocked optimization due lack of support on x86, rewrote
12672 exchange to take into account that base may be in eax.
12674 xsp works again; activated Interlocked optimizing code.
12676 2004-12-14 Zoltan Varga <vargaz@freemail.hu>
12678 * mini.h (MONO_AOT_FILE_VERSION): Bump AOT file version.
12680 2004-12-13 Zoltan Varga <vargaz@freemail.hu>
12682 * mini-ops.h: Add new opcodes.
12684 * mini.h: Add new patch types. Add got_var to MonoCompile.
12686 * mini.h mini-x86.c mini-amd64.c aot.c: Rename
12687 mono_arch_get_aot_patch_offset () to mono_arch_get_patch_offset () and
12688 make it work with all kinds of patchable code.
12690 * inssel.brg inssel-x86.brg: Add new rules dealing with computing the
12691 address of the GOT, and referencing entries in the GOT.
12693 * mini.c: Add code to load the GOT address if needed by an opcode.
12695 * aot.c mini-x86.h mini-x86.c cpu-pentium.md: Add support for position
12696 independent AOT code on the x86 using an elf-style Global Offset Table.
12698 2004-12-14 Raja R Harinath <rharinath@novell.com>
12700 * Makefile.am (RUNTIME): Set MONO_SHARED_DIR.
12702 2004-12-13 Gonzalo Paniagua Javier <gonzalo@ximian.com>
12704 * mini-x86.c: disabling the Interlocked optimizing code. It segfaults
12707 2004-12-13 Patrik Torstensson <patrik.torstensson@gmail.com>
12709 * mini-x86.c,mini-ops.h,inssel-x86.brg,cpu-pentium.md: Implementation
12710 of Interlocked:Increment/Decrement/Add as inline ops.
12711 (mini-x86.c (mono_arch_get_inst_for_method and mono_arch_output_basic_block))
12713 2004-12-12 Geoff Norton <gnorton@customerdna.com>
12715 * exceptions-ppc.c: Reorder code so gcc3.4 can compile it
12716 * mini-ppc.c: Unify mono_arch_patch_code with changes in r37636.
12718 2004-12-12 Duncan Mak <duncan@ximian.com>
12720 * mini-ppc.c (mono_arch_patch_code): Hopefully made this build
12721 again. `patch_info->table_size' is no longer valid after Zoltan's
12724 2004-12-12 Martin Baulig <martin@ximian.com>
12726 * mini.c (mono_method_to_ir): Only call mono_debug_init_method()
12727 if we are the "real" method, ie. not an inlined method inside it.
12729 2004-12-11 Ben Maurer <bmaurer@ximian.com>
12731 * mini.c (CEE_LDSFLD): Make sure that the vtable has been init'd
12732 before we look in the special fields table. This fixes
12733 ../tests/thread-static-init.cs.
12735 2004-12-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
12737 * mini.c: return immediately after setting OP_ARRAY_RANK or CEE_LDLEN
12738 for Array get_Rank and get_Length. Fixes bug #70465.
12740 2004-12-11 Zoltan Varga <vargaz@freemail.hu>
12742 * mini.h mini.c aot.c: Put the bblock table for a SWITCH patch into a
12743 separate structure to reduce the size of MonoJumpInfo.
12745 Fri Dec 10 18:09:22 CET 2004 Paolo Molaro <lupus@ximian.com>
12747 * mini.c, mini.h, aot.c, driver.c: allow disabling the aot code.
12749 2004-12-10 Patrik Torstensson <patrik.torstensson@gmail.com>
12751 * mini.c (mini_get_inst_for_method): Changed to allow ports
12752 to return a MonoInst instead of opcode
12753 (renamed mini_get_opcode_for_method to better reflect the new functionality)
12755 * mini-[x86|s390|s390x|ppc|sparc].c (mono_arch_get_inst_for_method):
12756 Allow ports to return a created MonoInst instead of op-code, will enable
12758 (renamed mini_get_opcode_for_method to better reflected the functionality)
12760 2004-12-09 Zoltan Varga <vargaz@freemail.hu>
12762 * mini.c (NEW_AOTCONST): Share some code between the different NEW_AOTCONST macros.
12764 2004-12-08 Zoltan Varga <vargaz@freemail.hu>
12766 * mini.c jit-icalls.c: Pass generic_context to mono_ldtoken_wrapper.
12769 2004-12-08 Martin Baulig <martin@ximian.com>
12771 * mini.c (mono_method_to_ir): In CEE_CALLVIRT, use `fsig->signature'
12772 if we're a CEE_CONSTRAINED call. Fixes gen-118.cs.
12774 2004-12-08 Zoltan Varga <vargaz@freemail.hu>
12776 * mini-sparc.c (mono_arch_output_basic_block): Implement OP_FCONV_TO_<X>
12779 * exceptions.cs: Disable some tests which depend on properties of x86 fp
12782 2004-12-08 Raja R Harinath <rharinath@novell.com>
12784 * Makefile.am (CLEANFILES): Add *.exe, *.dll.
12786 2004-12-07 Zoltan Varga <vargaz@freemail.hu>
12788 * mini-sparc.c (mono_arch_output_basic_block): Fix LOCALLOC_IMM
12789 bug introduced by the previous patch.
12791 Tue Dec 7 11:44:39 CET 2004 Paolo Molaro <lupus@ximian.com>
12793 * mini-ppc.c, objectc.cs: handle large structs passed by value
12794 (fixes bug #69972).
12796 Tue Dec 7 10:43:31 CET 2004 Paolo Molaro <lupus@ximian.com>
12798 * mini-ppc.c: OP_ARGLIST implementation from
12799 Geoff Norton <gnorton@customerdna.com>.
12801 Tue Dec 7 10:14:25 CET 2004 Paolo Molaro <lupus@ximian.com>
12803 * inssel-x86.brg, inssel-ppc.brg: fix reference to register
12804 in stmt: OP_OUTARG_VT (reg) (should fix bug #69785).
12806 Tue Dec 7 10:06:39 CET 2004 Paolo Molaro <lupus@ximian.com>
12808 * exceptions-ppc.c: avoid calling ppc_patch in exception trampolines.
12810 2004-12-01 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
12812 * inssel-s390.brgi, mini-ops.h, mini-s390.c : Add stubs for support of tls offset
12815 2004-12-06 Zoltan Varga <vargaz@freemail.hu>
12817 * mini-sparc.c: Zero out localled-ed memory.
12819 * iltests.il: Add tests for zeroing out localloc-ed memory.
12821 2004-12-04 Martin Baulig <martin@ximian.com>
12823 * mini.c (mono_method_to_ir): In CEE_CALLVIRT, use the new
12824 mono_method_get_signature_full().
12826 2004-12-03 Massimiliano Mantione <massi@ximian.com>
12828 * mini.c: Added removal of critical edges (prerequisite for SSAPRE),
12829 and some utility functions (always for SSAPRE), integrated SSAPRE.
12830 * mini.h: Likewise.
12831 * driver.c: Added ssapre option.
12832 * ssa.c: Small fix on OP_ARG handling.
12833 * ssapre.c, ssapre.h: Added files containing SSAPRE implementation.
12834 * Makefile.am: Likewise.
12836 2004-12-02 Zoltan Varga <vargaz@freemail.hu>
12838 * tramp-x86.c (mono_arch_create_jit_trampoline): Remove code which is
12839 now in the xp code.
12841 * mini.c (mini_init): Register mono_thread_force_interruption_checkpoint
12844 2004-12-01 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
12846 * inssel-s390.brg : Add OP_OUTARG_VT (OP_REFANYTYPE (reg)) rule.
12848 * cpu-s390.md : Increase instruction length of oparglist.
12850 * mini-s390.c : Implement vararg and TYPEDEBYREF support.
12852 2004-11-30 Martin Baulig <martin@ximian.com>
12854 * mini.c (mono_method_to_ir): In CEE_CALLVIRT, added support for
12855 virtual generic methods. We call a special helper_compile_generic_method()
12856 icall to retrieve the method from the vtable, inflate and compile
12857 it and then do a CEE_CALLI. Thanks a lot to Paolo for this idea.
12859 * jit-icalls.c (helper_compile_generic_method): New JIT icall.
12861 2004-11-30 Zoltan Varga <vargaz@freemail.hu>
12863 * mini-sparc.c: Fix up vararg corner cases. Fixes #70019.
12865 2004-11-29 Zoltan Varga <vargaz@freemail.hu>
12867 * cpu-sparc.md mini-sparc.c (long_conv_to_ovf_i): Fill missing delay slot.
12870 2004-11-27 Ben Maurer <bmaurer@ximian.com>
12872 * inssel.brg (CEE_SWITCH): The AOT stuff Zoltan added is only for
12873 platforms with PIC aot.
12875 2004-11-28 Martin Baulig <martin@ximian.com>
12877 * mini.c (mono_method_to_ir): In CEE_DUP, added handle_stobj().
12880 2004-11-28 Martin Baulig <martin@ximian.com>
12882 * mini-x86.c (mono_arch_call_opcode): Use the original type, not
12883 the result of mono_type_get_underlying_type() to check whether
12886 2004-11-26 Martin Baulig <martin@ximian.com>
12889 (mono_method_to_ir): Use `!method->signature->has_type_parameters'
12892 2004-11-26 Zoltan Varga <vargaz@freemail.hu>
12894 * mini-amd64.c (mono_arch_emit_this_vret_args): Handle this and vret
12895 the same way as the other arguments so they won't get clobbered.
12897 * mini-amd64.c (mono_arch_output_basic_block): Avoid doing virtual
12898 calls through R11 since it is clobbered by the trampoline code.
12900 2004-11-26 Raja R Harinath <rharinath@novell.com>
12902 * Makefile.am: Consistently use $(RUNTIME) rather than ./mono to
12903 pick up in-tree mscorlib.dll.
12905 2004-11-25 Zoltan Varga <vargaz@freemail.hu>
12907 * aot.c: Rename MonoAOTModule->cleanup to out_of_date.
12909 * mini-amd64.c aot.c: Switch to PIC relative AOT code. References to
12910 runtime data/code are now stored in a table similar to the GOT in ELF.
12911 This allows the code itself to be position independent.
12913 * aot.c: Fix loading of referenced assemblies after the lazy assembly
12916 * aot.c: Attach ELF type (object/function) directives to all global
12919 * tramp-amd64.c (amd64_magic_trampoline): Patch RIP relative calls too.
12921 * inssel.brg (SWITCH): Emit an AOT_CONST in the aot case.
12923 * mini-amd64.h: Turn on PIC AOT code.
12925 * mini.h (mono_arch_get_aot_patch_offset): New arch specific function
12926 returning the offset within an OP_AOTCONST instruction where the GOT
12927 offset needs to be added.
12929 * mini.h: Bump AOT file format version.
12931 2004-11-25 Martin Baulig <martin@ximian.com>
12933 * mini.c (mono_method_to_ir): In CEE_CALL, don't allow calling any
12934 uninflated generic methods.
12936 2004-11-25 Martin Baulig <martin@ximian.com>
12938 * mini.c (mono_method_to_ir): Don't allow any uninflated generic methods.
12940 2004-11-24 Martin Baulig <martin@ximian.com>
12942 * minit.c (type_to_eval_stack_type): Set `inst->klass' to the
12943 original klass (this only applies for generic instances).
12945 2004-11-24 Martin Baulig <martin@ximian.com>
12947 * mini.c (mono_method_to_ir): Use `STACK_OBJ' instead of
12948 `ldind_type [CEE_LDIND_REF]' (which would be beyond the end of
12951 2004-11-24 Zoltan Varga <vargaz@freemail.hu>
12953 * mini.c (mono_method_to_ir): Disable inlining for methods containing
12954 localloc. Fixes #69678.
12956 * iltests.il (test_0_localloc_inline): Add regression test for #69678.
12958 2004-11-23 Zoltan Varga <vargaz@freemail.hu>
12960 * mini-amd64.c (mono_arch_output_basic_block): Set %al to the number of
12961 used SSE registers on pinvoke calls. Fixes #69774.
12963 2004-11-23 Geoff Norton <gnorton@customerdna.com>
12965 * inssel-ppc.brg, mini-ppc.c: Use mono_class_from_mono_type instead of
12966 vt->inst_vtype->data.klass. This fixes generic structs and bug #69766
12968 2004-11-23 Raja R Harinath <rharinath@novell.com>
12970 * Makefile.am (MCS,ILASM): Don't refer to runtime/ directory.
12971 Refer directly to the mcs/ tree.
12973 2004-11-19 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
12975 * mini-s390.c, tramp-s390.c, mini-s390.h: Add LMF processing for trampolines.
12976 Check if a trampoline for a synchronized method is required.
12978 Fri Nov 19 17:34:21 CET 2004 Paolo Molaro <lupus@ximian.com>
12980 * mini-ppc.c, cpu-g4.md: set to zero the memory allocated
12981 with localloc if needed. Throe arithmetric exception in
12982 div an rem if needed. Implement ovf checks in OP_LCONV_TO_OVF_I.
12983 Adapted from a patch by Geoff Norton <gnorton@customerdna.com>.
12985 2004-11-19 Geoff Norton <gnorton@customerdna.com>
12987 * mini-ppc.c: Call mono_type_get_underlying_type to unwrap generic
12988 types before switching on type. Fixes #69622.
12990 2004-11-19 Raja R Harinath <rharinath@novell.com>
12992 * Makefile.am (check-local): New. Integrate into 'make check'.
12993 (MCS,RUNTIME): Define using in-tree mono and mcs.
12995 (%.exe): Use $(ILASM).
12997 Fri Nov 19 14:54:07 CET 2004 Paolo Molaro <lupus@ximian.com>
12999 * mini-ppc.c: adjust initial prolog size (bug #69691).
13001 2004-11-18 Zoltan Varga <vargaz@freemail.hu>
13003 * cpu-pentium.md (localloc): Increase max instruction len. Fixes
13006 2004-11-17 Raja R Harinath <rharinath@novell.com>
13008 * Makefile.am (clean-local): Rename from 'clean'.
13010 2004-11-15 Nelae Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
13012 * mini.c, mini-x86.c, mini-amd64.c, exceptions-s390.c: Add siginfo_t parameter
13013 to mono_arch_is_int_overflow.
13014 * exceptions-s390.c: Add mono_arch_is_int_overflow routine to discern between
13017 2004-11-15 Sebastien Pouliot <sebastien@ximian.com>
13019 * declsec.c|h: New files to support declarative security attributes.
13020 Added function to check if a method has (applicable) security.
13021 * mini.c|h: Add check for declarative security attributes in
13022 mono_method_check_inlining.
13023 * Makefile.am: Added declsec.c and declsec.h to the build.
13025 Mon Nov 15 11:53:46 CET 2004 Paolo Molaro <lupus@ximian.com>
13027 * mini.c, mini.h: update to keep dynamic code info per-domain.
13029 2004-11-12 Zoltan Varga <vargaz@freemail.hu>
13031 * mini.c mini-*.h: Get rid of MONO_ARCH_HAVE_RETHROW since all architectures support it now.
13032 (mini_init): Get rid of it from here too.
13034 Thu Nov 11 20:17:17 CET 2004 Paolo Molaro <lupus@ximian.com>
13036 * mini-ppc.c, mini-ppc,h, cpu-g5.md, exceptions-ppc.c:
13037 implemented OP_RETHROW (patch by Geoff Norton
13038 <gnorton@customerdna.com>).
13040 2004-11-10 Geoff Norton <gnorton@customerdna.com>
13042 * tramp-ppc.c (ppc_magic_trampoline): Don't trampoline methods
13043 between appdomains. Fixes appdomain-unload on PPC.
13045 2004-10-26 Lluis Sanchez Gual <lluis@novell.com>
13047 * exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
13048 mini-exceptions.c: handle the new wrapper types.
13049 * mini.c: The CEE_ISINST and CEE_CASTCLASS opcodes now take the
13050 token value as a MonoClass* when compiling a wrapper.
13051 mono_jit_create_remoting_trampoline now takes an additional
13052 MonoRemotingTarget parameter.
13054 2004-11-10 Martin Baulig <martin@localhost>
13056 * mini.c (mono_method_to_ir): Use `generic_container->context'
13057 rather than creating a new one.
13059 2004-11-09 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
13061 * exceptions-s390.c, mini-s390, cpu-s390.md: Add support for OP_RETHROW.
13063 * inssel-390.md, mini-s390.c: Correct register allocation for globals.
13065 2004-11-09 Zoltan Varga <vargaz@freemail.hu>
13067 * aot.c (mono_aot_init): Add MONO_AOT_CACHE env variable to turn on
13068 the experimental aot cache stuff.
13070 Tue Nov 9 17:30:20 CET 2004 Paolo Molaro <lupus@ximian.com>
13072 * aot.c, mini.c, exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
13073 mini-exceptions.c: update to exception clause structure changes.
13075 2004-11-08 Zoltan Varga <vargaz@freemail.hu>
13077 * exceptions-x86.c (throw_exception): Fix warnings.
13079 * mini-x86.h mini-x86.c cpu-pentium.md exceptions-x86.c: Add support
13082 2004-11-08 Zoltan Varga <vargaz@freemail.hu>
13084 * exceptions-sparc.c (get_throw_exception): Really fix this.
13086 2004-11-07 Ben Maurer <bmaurer@ximian.com>
13088 * tramp-*.c: we no longer support icalls without wrappers, so
13089 a bit of code can be removed here
13091 2004-11-07 Zoltan Varga <vargaz@freemail.hu>
13093 * exceptions-sparc.c (get_throw_exception): Fix more bugs in previous
13096 * cpu-sparc.md: Add op_rethrow.
13098 * exceptions-sparc.c (get_throw_exception): Fix bug in previous patch.
13100 * mini-sparc.h mini-sparc.c exceptions-sparc.c: Add support for OP_RETHROW.
13102 * mini.h: Add mono_arch_get_rethrow_exception () arch specific function.
13103 * mini-ops.h: Add OP_RETHROW.
13105 * mini.c inssel.brg: Distinguish between THROW and RETHROW.
13107 * cpu-amd64.c mini-amd64.c exceptions-amd64.c: Add support for OP_RETHROW.
13109 2004-11-05 Geoff Norton <gnorton@customerdna.com>
13111 * helpers.c: Change otool arguments from -V -v -t to -v -t on Darwin
13112 Makes the output much easier to read
13114 2004-11-05 Ben Maurer <bmaurer@ximian.com>
13116 * ssa.c: allocate MonoMethodVar.uses from the mempool. First, this
13117 prevents another huge leak when compiling with ssa. Secondly, the
13118 performance of doing this rather than freeing the lists is much
13119 better. GList does a lock every time you allocate a list link,
13120 so that it can use a memory pool. So, it is better to just use
13121 a memory pool of our own.
13123 * ssa.c, linear-scan.c: replace g_list_remove_link with
13124 g_list_delete. The remove one does not free the GList, so we were
13125 leaking memory. On -O=all --compile-all with corlib, this cut down
13126 3 MB of allocations.
13128 2004-11-05 Zoltan Varga <vargaz@freemail.hu>
13130 * tramp-sparc.c (mono_arch_create_jit_trampoline): Fix sparc build.
13132 * tramp-amd64.c (mono_arch_create_jit_trampoline): Fix amd64 build.
13134 * mini.h mini.c tramp-*.c: Moved xp parts of JIT trampoline creation
13135 into a new function mono_create_jit_trampoline ().
13137 2004-11-02 Zoltan Varga <vargaz@freemail.hu>
13139 * trace.c (get_spec): Allow tracing of classes without a namespace.
13141 2004-11-02 Sebastien Pouliot <sebastien@ximian.com>
13143 * mini.c: Fix pointer overwrite in mini_method_compile.
13145 2004-11-2 Geoff Norton <gnorton@customerdna.com>
13147 * inssel-ppc.brg (OP_OUTARG_VT (CEE_LDOBJ (base))):
13148 The darwin ABI needs some special handling for 1 and 2 byte structs
13149 Lets use lbz/lhz instead of lwz everywhere.
13150 * mini-ppc.c (calculate_sizes): The Darwin ABI needs from special handling
13151 for 1 and 2 byte structs and struct which are size >= 3 || size % 4 != 0.
13152 Use stb/sth for the former, and put the latter always on stack instead of in
13153 argument registers.
13155 2004-10-30 Zoltan Varga <vargaz@freemail.hu>
13157 * trace.c (is_filenamechar): Add '_'.
13159 2004-10-29 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
13161 * mini-s390.c: Fix prolog length to allow for large trace requirements.
13163 * exceptions-s390.c: Remove dwarf unwinding stuff that was unused.
13165 2004-10-29 Zoltan Varga <vargaz@freemail.hu>
13167 * Makefile.am (libgc_libs): Do some automake magic so libmono/mono
13168 depends on libmonogc. Fixes #68805.
13170 2004-10-26 Miguel de Icaza <miguel@ximian.com>
13172 * mini.c (mono_jit_free_method): Provide extra information for
13173 this error. Currently this leaks, but will be turned into a
13174 developer option in the future.
13176 2004-10-26 Zoltan Varga <vargaz@freemail.hu>
13178 * driver.c (mono_main): Applied patch from Willibald Krenn <willibald.krenn@gmx.at>. Make --graph work for icalls and pinvoke methods.
13180 2004-10-25 Zoltan Varga <vargaz@freemail.hu>
13182 * aot.c (mono_aot_load_method): Align PATCH_INFO_R8 on an 8 byte
13183 boundary. Fixes reading of PATCH_INFO_R4 and R8.
13184 (mono_aot_load_method): Do not allocate MonoAotMethod in the GC heap.
13186 2004-10-24 Zoltan Varga <vargaz@freemail.hu>
13188 * mini-amd64.c (mono_arch_patch_code): Fix patching of class init
13189 trampolines for AOT code.
13191 2004-10-22 <vargaz@freemail.hu>
13193 * aot.c (mono_compile_assembly): Disable AOT for methods containing calls to methods of
13194 constructed types. Fixes #68136.
13196 2004-10-21 Martin Baulig <martin@ximian.com>
13198 * exceptions-x86.c (throw_exception): Call mono_debugger_throw_exception();
13199 if it returns true, unwind the stack to the call instruction.
13201 2004-10-21 <vargaz@freemail.hu>
13203 * aot.c: Reorganize the AOT file format to avoid relocations. Fix warnings.
13205 * mini.h: Bump AOT version number.
13207 * objects.cs: Add another test for unbox trampolines.
13209 * tramp-amd64.c (amd64_magic_trampoline): Disable patching of trampolines for
13212 2004-10-20 <vargaz@freemail.hu>
13214 * driver.c: Add SHARED to the set of optimizations tested.
13216 * tramp-amd64.c (amd64_magic_trampoline): Patch trampoline code as well.
13218 * mini.c (mono_method_to_ir): Mark the domainvar as volatile when it is implicitly
13219 used by CEE_NEWARR.
13221 * ssa.c (mono_ssa_deadce): Do not optimize away accesses to volatile variables.
13223 2004-10-20 Martin Baulig <martin@ximian.com>
13225 * mini-exceptions.c (mono_handle_exception): Call
13226 mono_debugger_handle_exception() to tell the debugger about
13227 catch/finally clauses.
13229 2004-10-18 Zoltan Varga <vargaz@freemail.hu>
13231 * exceptions-amd64.c (mono_arch_find_jit_info): Pop arguments of the stack.
13233 * mini-amd64.c (mono_amd64_get_vcall_slot_addr): Handle extended registers. Fixes
13236 2004-10-15 Geoff Norton <gnorton@customerdna.com>
13238 * mini-ppc.c (calculate_sizes): Marshal valuetypes for pinvoke
13239 methods as their native size, fixed bug #57543, #57545.
13240 * mini-ppc.c (mono_arch_output_basic_block): Use mulli for imm16 types
13241 This saves a temporary register and mullw call down into 1 (minor perf
13242 increase for cases like sum = sum * 5; This use to translate into:
13245 It now translates to
13248 2004-10-15 Zoltan Varga <vargaz@freemail.hu>
13250 * trace.c (mono_trace_eval): Use mono_method_desc_full_match. Fixes
13253 2004-10-11 Martin Baulig <martin@ximian.com>
13255 * mini.c (mono_method_to_ir): If we're a generic method, get the
13256 MonoGenericContainer from our MonoMethodNormal and create a
13257 MonoGenericContext from it.
13259 2004-10-08 Zoltan Varga <vargaz@freemail.hu>
13261 * inssel-long32.brg (OP_LCONV_TO_OVF_I2): Fix CONV_I1 -> CONV_I2.
13263 * basic-long.cs: Add test for checked i8->i2 cast.
13265 Wed Oct 6 12:40:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
13267 * inssel-ppc.brg: added a couple of speedup rules.
13269 2004-10-05 Zoltan Varga <vargaz@freemail.hu>
13271 * Makefile.am (genmdesc_LDADD): Don't link this against libmetadata
13272 to speed up rebuilds.
13274 2004-10-04 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
13276 * mini-s390.c: Minor fix to OP_OR_IMM.
13278 2004-10-03 Zoltan Varga <vargaz@freemail.hu>
13280 * tramp-sparc.c (sparc_magic_trampoline): Handle appdomain stuff
13281 better. Fixes appdomain-unload.exe on sparc.
13283 2004-10-02 Massimiliano Mantione <massi@ximian.com>
13285 * ssa.c: Fixed casts to unsigned where the value was of 64 bits in
13286 simulate_long_compare, patch by will@exomi.com (Ville-Pertti Keinonen),
13289 2004-10-02 Zoltan Varga <vargaz@freemail.hu>
13291 * jit-icalls.c: Handle a nonexisting trunc function more correctly.
13293 2004-09-30 Lluis Sanchez Gual <lluis@novell.com>
13295 * mini.c: Always generate a field read/write wrapper for members
13296 of the class MarshalByRefObject since the actual instance could
13299 2004-09-28 Lluis Sanchez Gual <lluis@novell.com>
13301 * mini.c: Use mono_thread_exit() to stop threads, instead of ExitThread.
13303 2004-09-28 Zoltan Varga <vargaz@freemail.hu>
13305 * driver.c mini.h trace.c: Move the setting of the main assembly into
13306 a separate function called mono_trace_set_assembly () and call it after
13307 actually loading the main assembly. Fixes #66872.
13309 2004-09-25 Zoltan Varga <vargaz@freemail.hu>
13311 * mini-amd64.h mini-amd64.c tramp-amd64.c: Allocate trampoline memory
13312 using the code manager.
13314 2004-09-24 Zoltan Varga <vargaz@freemail.hu>
13316 * tramp-amd64.c mini-amd64.h: Add support for MONO_ARCH_HAVE_INVALIDATE_METHOD.
13318 2004-09-23 Zoltan Varga <vargaz@freemail.hu>
13320 * cpu-amd64.md: Fix bug in previous patch.
13322 * cpu-amd64.md: Fix instruction lengths of membase opcodes. Fixes
13325 Wed Sep 22 19:03:20 CEST 2004 Paolo Molaro <lupus@ximian.com>
13327 * mini.h, exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
13328 mini-exceptions.c: updates for changed stack walk interface.
13330 2004-09-21 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
13332 * mini-s390.c, cpu-s390.md: Minor changes to OP_ARGLIST handling
13334 2004-09-17 Zoltan Varga <vargaz@freemail.hu>
13336 * mini.c (mono_method_to_ir): Fix LDSTR in dynamic methods. Fixes #66132.
13338 2004-09-13 Zoltan Varga <vargaz@freemail.hu>
13340 * driver.c (mini_regression_list): Do not call mono_assembly_close
13341 since assemblies can't be unloaded.
13343 2004-09-11 Zoltan Varga <vargaz@freemail.hu>
13345 * cpu-amd64.md: Fix more instruction lengths.
13347 * cpu-amd64.md: Fix lengths of some instructions.
13349 2004-09-11 Ben Maurer <bmaurer@users.sourceforge.net>
13351 * inssel.brg: Make the array ldelema check aot friendly.
13353 2004-09-11 Zoltan Varga <vargaz@freemail.hu>
13355 * mini-amd64.c (mono_arch_get_argument_info): Fix stack_unwind test.
13357 * cpu-amd64.md inssel-long.brg inssel-amd64.brg: Small optimizations.
13359 2004-09-10 Zoltan Varga <vargaz@freemail.hu>
13361 * mini-x86.c: Fix build.
13363 * mini-sparc.c mini-x86.c mini-amd64.c: Use the new
13364 mono_type_get_underlying_type () helper function to simplify code.
13366 2004-09-09 Martin Baulig <martin@ximian.com>
13368 * mini-amd64.c: Don't access `type->data.klass' directly, call
13369 mono_class_from_mono_type() instead since the type may be a
13372 2004-09-09 Martin Baulig <martin@ximian.com>
13374 * mini-amd64.c (get_call_info): Fix support for generic instances.
13375 (add_valuetype): Use mono_class_from_mono_type() to get the class
13376 since we can be a generic instance.
13378 Thu Sep 9 01:43:53 PDT 2004 Paolo Molaro <lupus@ximian.com>
13380 * mini-ppc.c, mini.h, regalloc.c, regalloc.h: powerpc speedups.
13382 2004-09-07 Ben Maurer <bmaurer@users.sourceforge.net>
13384 * liveness.c: reset spill costs on each scan: bug 62107
13386 2004-09-07 Bernie Solomon <bernard@ugsolutions.com>
13388 * exceptions-sparc.c (mono_arch_find_jit_info): remove
13389 unnecessary line that doesn't compile
13391 2004-09-07 Zoltan Varga <vargaz@freemail.hu>
13393 * mini.c mini.h mini-x86.h tramp-x86.c: Instead of freeing delegate
13394 trampolines, make them call an error function so people can fix their
13397 2004-09-06 Martin Baulig <martin@ximian.com>
13399 * mini.c (mono_method_to_ir): When initializing locals, handle a
13400 generic instances like a valuetype if it's a valuetype and like a
13401 class if it's a class.
13403 2004-09-06 Zoltan Varga <vargaz@freemail.hu>
13405 * exceptions-x86.c (mono_arch_find_jit_info): Pop arguments off the
13406 stack. Fixes #64674.
13408 * exceptions.cs: Add test for unwinding of call arguments.
13410 Mon Sep 6 05:50:02 PDT 2004 Paolo Molaro <lupus@ximian.com>
13412 * mini-*.c, mini-ops.h, inssel-long32.brg: introduced
13413 OP_ADDCC_IMM and OP_SUBCC_IMM (add/sub immediate that will
13414 set the carry/borrow flag). The sparc and s390 implementations
13415 can now use optimized versions (and simplify the code). ppc bugfixes.
13417 2004-09-06 Zoltan Varga <vargaz@freemail.hu>
13419 * exceptions-ppc.c (mono_arch_find_jit_info): Fix memory leak.
13421 2004-09-05 Zoltan Varga <vargaz@freemail.hu>
13423 * inssel-amd64.brg: Remove leftover 32 bit rule.
13425 * mini-amd64.c (mono_arch_instrument_prolog): Fix tracing support.
13427 2004-09-04 Zoltan Varga <vargaz@freemail.hu>
13429 * mini-exceptions.c (mono_find_jit_info): Refactor common code from
13430 mono_arch_find_jit_info functions into a new function. Fix a memory
13433 * exceptions-x86.c exceptions-amd64.c exceptions-sparc.c: Remove
13436 2004-09-02 Zoltan Varga <vargaz@freemail.hu>
13438 * exceptions.cs inssel-long32.brg: Handle the OP_LCONV_TO_OVF_I2 case
13441 * exceptions.cs: Add array size tests.
13443 * mini.c: Allocate a separate icall wrapper for each arity of
13444 mono_array_new_va. Fixes #59509.
13446 * exceptions.cs: Add testcase for 64578.
13448 * inssel-long32.brg: Fix OP_LCONV_TO_OVF_I1 rule. Fixes #64578.
13450 * trace.c (is_filenamechar): Allow 0..9 in strings. Fixes #65094.
13452 2004-09-02 Martin Baulig <martin@ximian.com>
13454 * mini.c (mono_method_to_ir): When initializing the locals, call
13455 handle_initobj() on the generic instance itself, not its
13458 2004-09-02 Zoltan Varga <vargaz@freemail.hu>
13460 * mini.h (MonoJitDynamicMethodInfo): New structure, extension of
13461 MonoJitInfo for dynamic methods.
13463 * mini.c: Rename trampoline_hash_mutex to jit_mutex.
13465 * mini.c: Add support for freeing JIT data for dynamic methods.
13467 2004-09-01 Martin Baulig <martin@ximian.com>
13469 * mini-x86.c (is_regsize_var): Added support for generic
13471 (mono_arch_emit_prolog): Make this compile again, use
13472 `x86_push_imm_template (code)'.
13474 2004-08-30 Ben Maurer <bmaurer@users.sourceforge.net>
13476 * mini-x86.c: make all push_imm instructions that get
13477 patched always emit the long form
13479 2004-08-30 Zoltan Varga <vargaz@freemail.hu>
13481 * mini.c (mono_create_jump_trampoline): Store the jump trampolines
13482 in a per-domain hash.
13484 * mini-amd64.c (merge_argument_class_from_type): Handle generic
13487 2004-08-29 Zoltan Varga <vargaz@freemail.hu>
13489 * mini-amd64.c cpu-amd64.md inssel-amd64.brg mini-amd64.h: Ongoing SSE
13492 * mini-amd64.c cpu-amd64.md inssel-amd64.brg mini-amd64.h: More SSE
13495 * mini-amd64.c cpu-amd64.md: Implement checked int<->uint casts.
13496 Beginnings of SSE2 support.
13498 * exceptions.cs: Add more tests for checked int<->uint casts.
13500 2004-08-28 Martin Baulig <martin@ximian.com>
13502 * mini-x86.c (mono_arch_instrument_epilog): Added support for
13506 (mono_type_to_ldind, mono_type_to_stind, type_to_eval_stack_type):
13507 Handle generic instances recursively.
13509 2004-08-27 Ben Maurer <bmaurer@users.sourceforge.net>
13511 * iltests.il: test for conv.u8 on a constant
13513 2004-08-27 Ben Maurer <bmaurer@users.sourceforge.net>
13515 * inssel-long32.brg: c&p rules for LCONV_x4 (membase) and
13516 LCONV_x4 (shrun_32 (membase)).
13518 2004-08-27 Ben Maurer <bmaurer@users.sourceforge.net>
13520 * inssel-x86.brg: c&p rules for push/setret of long
13522 2004-08-26 Ben Maurer <bmaurer@users.sourceforge.net>
13524 * inssel-x86.brg: c&p rules for compare (base, regvar) and
13525 compare (regvar, base)
13527 * inssel-x86.brg: more burg love
13529 * inssel.brg: more cleanup
13531 * inssel-x86.brg, inssel-long32.brg: burg cleanup.
13533 2004-08-26 Ben Maurer <bmaurer@users.sourceforge.net>
13535 * basic-long.cs, basic-calls.cs: new tests for optimization.
13537 2004-08-26 Zoltan Varga <vargaz@freemail.hu>
13539 * mini-amd64.c (read_tls_offset_from_method): Fix typo in previous
13542 2004-08-25 Zoltan Varga <vargaz@freemail.hu>
13544 * mini-amd64.c (read_tls_offset_from_method): Add another case.
13546 2004-08-25 Bernie Solomon <bernard@ugsolutions.com>
13548 * inssel.brg (mini_emit_memcpy): use
13549 NO_UNALIGNED_ACCESS to disable memcpy optimization
13551 2004-08-25 Zoltan Varga <vargaz@freemail.hu>
13553 * mini-amd64.c: Handle generic types in various places.
13555 * mini.c (mono_method_to_ir): Handle generic types in init locals.
13557 2004-08-24 Zoltan Varga <vargaz@freemail.hu>
13559 * mini.c (handle_box): Fix warning.
13561 * mini-amd64.c (mono_arch_local_regalloc): Fix regalloc problem.
13563 * mini-amd64.h: Enable the emit_state optimization.
13565 * mini-ops.h cpu-amd64.md: Add new amd64_test_null opcode.
13567 * mini-amd64.c: Add some new 64 bit peephole opts.
13569 * inssel.brg (mini_emit_memcpy): Optimize for 64 bit architectures.
13571 * cpu-amd64.md: sreg1 of div instructions must be %rax.
13573 * mini-amd64.c: Register allocator fixes.
13575 * mini.c: Add an optimization to emit_state to avoid allocation of new
13576 registers on some platforms.
13578 2004-08-23 Zoltan Varga <vargaz@freemail.hu>
13580 * inssel-x86.brg inssel-amd64: Add yet another missing tree->dreg assignment.
13582 * mini-x86.c (mono_arch_local_regalloc): Fix bug in long register
13583 allocation. Fixes #63085.
13585 * basic-long.cs: Add new regression test.
13587 * mini-amd64.c: Register allocator improvements.
13589 2004-08-21 Zoltan Varga <vargaz@freemail.hu>
13591 * mini-amd64.c (read_tls_offset_from_method): Add another code
13594 * tramp-amd64.c (amd64_class_init_trampoline): Use a more efficient
13595 instruction sequence for nullifying class init trampolines.
13597 * objects.cs: Add new regalloc test.
13599 * mini-amd64.c inssel-amd64.brg: Optimize parameter passing.
13601 2004-08-20 Zoltan Varga <vargaz@freemail.hu>
13603 * mini-amd64.c (mono_arch_call_opcode): Refactor this a little.
13605 * mini-amd64.c (mono_arch_regalloc_cost): Adjust regalloc costs for
13608 * driver.c: Fix profiling after TLS changes.
13610 * driver.c (mono_main): Set mono_stats.enabled if needed.
13612 * mini.c (handle_alloc): New helper function used by CEE_NEWOBJ and
13615 2004-08-20 Ben Maurer <bmaurer@users.sourceforge.net>
13617 * mini-x86.c: use a 1 op rather than a 2 op tls access
13618 instruction -> faster.
13620 2004-08-20 Zoltan Varga <vargaz@freemail.hu>
13622 * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Merge changes from
13625 2004-08-19 Bernie Solomon <bernard@ugsolutions.com>
13627 * exceptions-sparc.c (throw_exception): fix typo
13629 2004-08-19 Ben Maurer <bmaurer@users.sourceforge.net>
13631 * mini-x86.c, cpu-pentium.md, inssel-x86.brg:
13632 set tree->dreg correctly with tls. Allow any
13633 register to be used.
13635 * mini-x86.c (read_tls_offset_from_method): add new code
13636 generation pattern seen with GCC.
13639 Thu Aug 19 17:26:55 CEST 2004 Paolo Molaro <lupus@ximian.com>
13641 * mini-exceptions.c, exceptions-x86.c, exceptions-amd64.c,
13642 exceptions-ppc.c, exceptions-s390.c, exceptions-s390x.c,
13643 exceptions-sparc.c: fix some performance issues in exception
13644 handling and setting of the stack trace for exceptions that were
13647 2004-08-18 Zoltan Varga <vargaz@freemail.hu>
13649 * mini-amd64.c inssel-amd64.brg cpu-amd64.md: Merge changes from
13652 * mini-amd64.c (mono_arch_is_int_overflow): Handle all possible
13655 2004-08-18 Ben Maurer <bmaurer@users.sourceforge.net>
13657 This patch inlines tls access, when possible.
13659 * mini.h: new arch functions for TLS intrinsics.
13660 All platforms updated with a stub.
13662 * mini.c: use the new intrinsics
13664 * mini-x86.c, cpu-pentium.md, inssel-x86.brg, mini-ops.h:
13665 arch specific intrinsic for tls variables
13667 2004-08-18 Zoltan Varga <vargaz@freemail.hu>
13669 * Makefile.am (libmono_la_LDFLAGS): Enable creating of libmono dll
13672 2004-08-17 Ben Maurer <bmaurer@users.sourceforge.net>
13674 * mini.c: thread local allocation
13676 2004-08-16 Zoltan Varga <vargaz@freemail.hu>
13678 * mini-amd64.h (MONO_ARCH_NO_EMULATE_LONG_SHIFT_OPS): Enable.
13680 * Makefile.am: Link against the static version of libmonogc.
13682 * Makefile.am: Link the static versions of the convenience libraries
13683 into the mono executable.
13685 * mini-x86.h mini-x86.c: Throw the correct exception on integer overflow.
13687 2004-08-15 Zoltan Varga <vargaz@freemail.hu>
13689 * mini.h mini.c mini-amd64.h mini-amd64.c: Throw the correct exception
13690 on integer overflow.
13692 * mini-amd64.c: Reorganize function call code.
13694 * mini-amd64.c (peephole_pass): Merge changes from mini-x86.c.
13696 2004-08-14 Ben Maurer <bmaurer@ximian.com>
13698 * inssel-x86.brg: use xor eax,eax.
13700 * basic.cs: new tests
13702 2004-08-14 Zoltan Varga <vargaz@freemail.hu>
13704 * mini-amd64.c (mono_arch_emit_epilog): Use RIP relative addressing
13705 in exception throwing code.
13707 2004-08-14 Ben Maurer <bmaurer@ximian.com>
13709 * inssel-x86.brg: use xor esi,esi.
13711 2004-08-14 Zoltan Varga <vargaz@freemail.hu>
13713 * driver.c (mono_main): Call mono_trace_parse_options earlier so it
13714 can trace methods compiled during mini_init () too.
13716 * cpu-amd64.md mini-amd64.c (mono_arch_output_basic_block): Handle
13719 2004-08-14 Ben Maurer <bmaurer@ximian.com>
13721 * Makefile.am: static link on x86 (r=zoltan)
13723 2004-08-14 Zoltan Varga <vargaz@freemail.hu>
13725 * tramp-amd64.c (amd64_magic_trampoline): Avoid patching the trampoline
13726 code since it causes some programs to fail.
13728 2004-08-12 Zoltan Varga <vargaz@freemail.hu>
13730 * mini-amd64.c (bb_is_loop_start): Merge changes from mini-x86.c.
13732 2004-08-11 Bernie Solomon <bernard@ugsolutions.com>
13734 * mini.c: ovfops_op_map - add STACK_OBJ case for
13736 * basic.cs: add test_0_pin_string as test
13739 2004-08-11 Bernie Solomon <bernard@ugsolutions.com>
13741 * Makefile.am: build C# if srcdir != builddir
13743 Tue Aug 10 19:23:47 CEST 2004 Paolo Molaro <lupus@ximian.com>
13745 * dominators.c, mini.h, mini-x86.c: fix loop alignment with
13746 fall-through blocks.
13748 Tue Aug 10 16:18:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
13750 * driver.c: enable loop by default again and include abcrem in -O=all.
13752 2004-08-08 Zoltan Varga <vargaz@freemail.hu>
13754 * iltests.il: Add some localloc tests.
13756 * mini.c (mono_method_to_ir): Set stack type of LOCALLOC correctly.
13758 * inssel-amd64.brg inssel-x86.brg: Set dreg of LOCALLOC correctly.
13761 * inssel-amd64.brg: Add some optimizations.
13763 * mini-amd64.c (mono_arch_setup_jit_tls_data): Add tls offset detection
13766 * Makefile.am: Statically link mono against libmono on AMD64.
13768 * mini-amd64.c inssel-amd64.brg: Optimizations.
13770 2004-08-07 Zoltan Varga <vargaz@freemail.hu>
13772 * mini-amd64.c (mono_arch_emit_prolog): Optimize lmf saving a bit.
13774 * tramp-amd64.c: Patch calling code in trampolines.
13776 2004-08-06 Zoltan Varga <vargaz@freemail.hu>
13778 * mini-amd64.c: pinvoke struct passing fixes.
13780 2004-08-05 Bernie Solomon <bernard@ugsolutions.com>
13782 * mini-sparc.c: redo change, make mono_arch_cpu_init call
13783 mono_arch_cpu_optimizazions so sparcv9 is initialized when embedded
13785 2004-08-05 Duncan Mak <duncan@ximian.com>
13787 * mini.c: Renamed CEE_STELEM to CEE_STELEM_ANY and CEE_LDELEM to
13790 2004-08-05 Zoltan Varga <vargaz@freemail.hu>
13792 * mini-amd64.c (emit_move_return_value): Move return value for normal
13795 2004-08-05 Martin Baulig <martin@ximian.com>
13797 * mini.c (ret_type_to_call_opcode): Don't use a `t' variable for
13798 `type->type'; just modify `type' itself when dealing with enums
13799 and generic instances.
13800 (check_call_signature): Make `simple_type' a `MonoType *'.
13802 2004-08-05 Zoltan Varga <vargaz@freemail.hu>
13804 * mini.c: Use OP_PADD to add offsets to addresses.
13806 * mini-amd64.h: Disable SIGSEGV_ON_ALTSTACK.
13808 2004-08-04 Bernie Solomon <bernard@ugsolutions.com>
13810 * mini-sparc.c (mono_arch_emit_epilog): fix check
13811 for folding last op into restore instruction
13813 2004-08-05 Zoltan Varga <vargaz@freemail.hu>
13815 * exceptions-amd64.c (mono_arch_get_throw_exception_by_name): Allocate
13816 helper methods using the code manager.
13818 * exceptions-amd64.c (mono_arch_get_throw_exception): Fix maximum length.
13820 * mini-amd64.c (mono_arch_allocate_vars): Fix tls offset detection.
13822 Tue Aug 3 23:50:00 EST 2004 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
13824 * mini-s390x.c mini-s390x.h tramp-s390x.c inssel-s390x.brg
13825 cpu-s390x.md exceptions-s390x.c Makefile.am: S/390 64-bit JIT
13827 * mini-s390.c: fix tail processing
13829 Tue Aug 3 01:35:44 PDT 2004 Paolo Molaro <lupus@ximian.com>
13831 * mini-ppc.c: mul.ovf.un exception name fix.
13833 2004-08-03 Martin Baulig <martin@ximian.com>
13835 * mini-x86.c (mono_arch_call_opcode): Correctly handle generic
13836 instances; before jumping to `handle_enum', also modify `ptype'.
13838 2004-08-02 Bernie Solomon <bernard@ugsolutions.com>
13840 * cpu-sparc.md: fcall maximal length too small.
13842 2004-08-02 Zoltan Varga <vargaz@freemail.hu>
13844 * mini-amd64.c mini.h: Add initial support for passing/returning
13845 structures to/from pinvoked methods.
13847 Mon Aug 2 11:59:35 PDT 2004 Paolo Molaro <lupus@ximian.com>
13849 * mini-ppc.c: reg allocator fix.
13851 2004-07-31 Zoltan Varga <vargaz@freemail.hu>
13853 * mini-amd64.c (mono_arch_output_basic_block): Fix OP_X86_PUSH_OBJ.
13855 * inssel.brg: Optimize memset on 64 bit machines.
13857 * mini-amd64.c: Fix some vararg cases.
13859 2004-07-30 Neale Ferguson <Neale.Ferguson@SoftwareAG-usa.com>
13861 * mini-s390.c: Corrected macro in emit_float_to_int
13863 * s390-abi.cs: Tests to exercise the s390 ABI
13865 2004-07-30 Zoltan Varga <vargaz@freemail.hu>
13867 * exceptions-amd64.c (mono_arch_find_jit_info): Fix restoring of
13870 * basic.cs: Add a test for add.ovf.un.
13872 2004-07-30 Bernie Solomon <bernard@ugsolutions.com>
13874 * mini-sparc.c: add case for OP_IDIV_UN
13876 2004-07-30 Zoltan Varga <vargaz@freemail.hu>
13878 * mini-amd64.c mini-amd64.h mini.c: Add support for vararg pinvoke calls.
13880 * mini-amd64.c cpu-amd64.md: Ongoing JIT work.
13882 2004-07-30 Ben Maurer <bmaurer@ximian.com>
13884 * basic.cs: regression tests.
13886 * inssel-x86.brg: Disable cmp BYTE PTR [eax], imm, it causes various
13889 2004-07-30 Zoltan Varga <vargaz@freemail.hu>
13891 * basic.cs: Add a new test.
13893 * mini-amd64.c aot.c cpu-amd64.md: Add support for tracing, profiling
13894 and AOT. Various fixes and optimizations.
13896 * inssel.brg (CALL_REG): Add 64 bit versions of call_reg rules.
13898 Fri Jul 30 15:49:26 CEST 2004 Paolo Molaro <lupus@ximian.com>
13900 * mini-ppc.c: make sure temp regs are not used for global reg
13903 2004-07-29 Bernie Solomon <bernard@ugsolutions.com>
13905 * cpu-sparc.md: conv_i8 fix for 64bits
13907 * mini-sparc.c: add cases for OP_IXXX codes for 64bits
13909 2004-07-29 Ben Maurer <bmaurer@ximian.com>
13911 * cpu-pentium.md, mini-x86.c, inssel-x86.brg, mini-ops.h:
13912 add opcode for cmp BYTE PTR [eax], imm.
13914 * inssel.brg: Make memcpy and memset takes bases.
13916 2004-07-28 Zoltan Varga <vargaz@freemail.hu>
13918 * *-amd64.*: More AMD64 work.
13920 2004-07-28 Ben Maurer <bmaurer@ximian.com>
13922 * cpu-pentium.md, inssel-x86.brg, mini-ops.h, mini-x86.c:
13923 add a compare-not-equal opcode.
13925 2004-07-28 Lluis Sanchez Gual <lluis@novell.com>
13927 * mini.c: Use mono_init_from_assembly instead of mono_init.
13929 2004-07-28 Zoltan Varga <vargaz@freemail.hu>
13931 * mini.c: Fix opcode mapping for STACK_MP on 64 bit platforms.
13933 * mini.c (CEE_NEWOBJ): Call mono_array_new_va using the correct signature.
13935 * mini.c: Use MONO_ARCH_SIGACTION on AMD64 as well.
13937 * inssel.brg: 64 bit fixes.
13939 * mini.h (MonoCallInst): Add some AMD64 specific data.
13941 * mini.h: Add some OP_P opcodes.
13943 2004-07-28 Ben Maurer <bmaurer@ximian.com>
13945 * basic.cs: tests for 61797 and 61740
13947 Tue Jul 27 16:05:19 CEST 2004 Paolo Molaro <lupus@ximian.com>
13949 * mini-ppc.c, mini-sparc.c, mini-s390.c: keep track of line
13950 numbers in the debug info (spotted by Geoff Norton, <gnorton@customerdna.com>).
13952 2004-07-24 Zoltan Varga <vargaz@freemail.hu>
13954 * mini-sparc.c (mono_arch_output_basic_block): Add CEE_CONV_U8/I8.
13956 * *-amd64*.*: Ongoing AMD64 work.
13958 2004-07-23 Zoltan Varga <vargaz@freemail.hu>
13960 * inssel-long.brg: Implement CONV_I8/CONV_U8 in the backends.
13962 * *-amd64*: Ongoing AMD64 work.
13964 * mini-arch.h: Add AMD64 support.
13966 * mini-sparc.c (mono_arch_is_inst_imm): New arch dependent function.
13968 * mini.h: Add new arch dependent function mono_arch_is_inst_imm.
13970 * mini-ops.h: Add new opcodes.
13972 * Makefile.am: Add AMD64 support.
13974 * inssel.brg inssel-long32.brg inssel-long.brg: Move mul/div and shift
13975 rules into the inssel-long*.brg files.
13977 * *-amd64.*: Add beginnings of AMD64 backend.
13979 2004-07-22 Ben Maurer <bmaurer@ximian.com>
13981 * mini.c (print_dfn): commenting out the code that prints
13982 the cil. With -O=deadce, this makes -v -v crash.
13984 * cpu-pentium.md: make checkthis have a length of 2
13986 2004-04-21 Bernie Solomon <bernard@ugsolutions.com>
13988 * mini-sparc.h: fix implementations of __builtin
13989 functions for Sun compiler for V9.
13991 2004-07-16 Ben Maurer <bmaurer@ximain.com>
13993 * mini.c: use the new stelem.ref wrapper
13994 * exceptions.cs, arrays.cs: new stelem.ref tests
13996 Wed Jul 14 19:08:41 CEST 2004 Paolo Molaro <lupus@ximian.com>
13998 * mini-ppc.c, exceptions-ppc.c: cleanups and fixes (the
13999 new XSP should work with these changes).
14001 2004-07-14 Ben Maurer <bmaurer@ximain.com>
14003 * inssel-{long32,x86,}.brg: trivial optimizations.
14005 Mon Jul 12 20:25:57 CEST 2004 Paolo Molaro <lupus@ximian.com>
14007 * mini.c: load value when emitting box operation in
14010 2004-07-12 Ben Maurer <bmaurer@ximian.com>
14012 * mini-x86.c (OP_CHECK_THIS): cmp DWORD PTR [eax], eax
14013 is one byte shorter than cmp DWORD PTR [eax], 0.
14015 Mon Jul 12 17:47:00 CEST 2004 Paolo Molaro <lupus@ximian.com>
14017 * inssel-ppc.brg: arguments on the stack are always
14018 relative to the stack pointer (spotted by Neale Ferguson).
14020 2004-07-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
14022 * exceptions-x86.c: delay appending the method name to the trace until
14023 after mono_jit_info_table_find is called, as this gets the real
14026 2004-07-09 Ben Maurer <bmaurer@ximian.com>
14028 * aot.c: register roots
14030 2004-07-09 Atsushi Enomoto <atsushi@ximian.com>
14032 * aot.c : I could just use PLATFORM_WIN32 flag.
14034 2004-07-09 Atsushi Enomoto <atsushi@ximian.com>
14036 * aot.c : Reverting the previous fix. This time it broke linux build.
14038 2004-07-09 Atsushi Enomoto <atsushi@ximian.com>
14040 * aot.c : quick cygwin build fix. mkdir() with two args does not exist.
14042 2004-07-08 Zoltan Varga <vargaz@freemail.hu>
14044 * mini.c (handle_stack_args): Remove some more debugging code.
14046 * mini.c (handle_stack_args): Remove debug output left in by mistake.
14048 * driver.c mini.h aot.c: Allow additional options to be specified with
14049 --aot and pass them to mono_compile_assembly.
14051 * aot.c: Add experimental code to AOT compile all loaded assemblies
14052 on demand and save the code into a cache in the filesystem.
14054 * aot.c: Add support for more wrapper methods.
14056 * mini.c (handle_stack_args): Handle some corner cases. Fixes
14059 * cpu-*.md: Remove removed opcodes.
14061 * mini.h mini.c: Move JIT icall handling to icall.c. Replace usage of
14062 CEE_MONO_PROC<x> with CEE_MONO_ICALL. Move registration of marshalling
14063 related icalls to marshal.c.
14065 2004-07-06 Zoltan Varga <vargaz@freemail.hu>
14067 * mini-ops.h: Add OP_SAVE_LMF and OP_RESTORE_LMF.
14069 * Makefile.am (EXTRA_DIST): Add inssel-long[32].brg.
14071 * inssel.brg: Fix warning. Add rules for SAVE_LMF and RESTORE_LMF.
14073 2004-07-06 Ben Maurer <bmaurer@ximian.com>
14074 * liveness.c: If liveness is recomputated we need to reset the information
14075 for each variable. This way, if the liveness range has been narrowed
14076 by optimizations that happened after the last computation, we can return
14079 For example, if you have
14084 // Tons of code that does not affect i
14090 i = 0 is dead code and will be removed by SSA. However, when
14091 linear scan gets to the code, i will still appear to be live
14092 throughout the entire block. This prevents good register allocation.
14094 2004-07-06 Martin Baulig <martin@ximian.com>
14096 * debug-mini.c (mono_debug_init_method): Allow
14097 MONO_WRAPPER_MANAGED_TO_NATIVE wrappers.
14098 (mono_debug_add_icall_wrapper): New method.
14100 * mini.c (mono_icall_get_wrapper): Call mono_debug_add_icall_wrapper().
14102 2004-07-05 Zoltan Varga <vargaz@freemail.hu>
14104 * mini.c (optimize_branches): Fix linking of bblocks in branch->branch
14107 2004-07-03 Zoltan Varga <vargaz@freemail.hu>
14109 * aot.c (mono_aot_load_method): Fix loading of debug info.
14111 2004-07-02 Zoltan Varga <vargaz@freemail.hu>
14113 * aot.c: Add logging support.
14115 2004-07-01 Zoltan Varga <vargaz@freemail.hu>
14117 * mini.h: Add prototype for mono_print_method_from_ip.
14119 * mini.c: 64 bit fixes. Use LCOMPARE for comparing longs.
14121 * inssel.brg: 64 bit fixes.
14123 * inssel.brg inssel-long32.brg: Move 32 bit arithmetic rules to
14126 * Makefile.am: Add SPARC64 support.
14128 2004-07-02 Zoltan Varga <vargaz@freemail.hu>
14130 * aot.c: Fix alignment problems on 32 bit platforms.
14132 2004-07-01 Zoltan Varga <vargaz@freemail.hu>
14134 * helpers.c (mono_disassemble_code): Pass -xarch=v9 to assembler on
14137 * aot.c: Add SPARC64 support. Reorganize patch table to fix alignment
14140 * mini.h: Bump AOT file version. Some 64 bit fixes.
14142 2004-06-30 Zoltan Varga <vargaz@freemail.hu>
14144 * inssel-sparc.brg: Add new rule to avoid register moves.
14146 * inssel.brg: Add ldind_to_load_membase helper function.
14148 2004-06-30 Ben Maurer <bmaurer@ximian.com>
14150 * mini.c: OffsetToStringData intrinsic.
14152 2004-06-30 Zoltan Varga <vargaz@freemail.hu>
14154 * ssa.c: Handle OP_LCOMPARE the same as OP_COMPARE.
14156 * objects.cs exceptions.cs basic.cs basic-long.cs basic-calls.cs: New
14159 * mini-ops.h cpu-sparc.md mini-sparc.h mini-sparc.c exceptions-sparc.c tramp-sparc.c inssel-long.brg: Add SPARC64 support.
14160 Mon Jun 28 18:05:09 CEST 2004 Paolo Molaro <lupus@ximian.com>
14162 * mini.c: reinstated mono_compile_get_interface_var()
14163 on x86, too, since the change breaks the Gtk# build there as well.
14165 Fri Jun 25 17:36:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
14167 * driver.c: remove loop from the default optimizations: it seems to
14168 interact badly with some of the other options (see bug #60613).
14170 2004-06-25 Zoltan Varga <vargaz@freemail.hu>
14172 * mini.c mini-x86.h mini-x86.c: Applied patch from Guenter Feldmann
14173 (fld@informatik.uni-bremen.de): Add Solaris x86 support.
14175 Tue Jun 22 21:29:11 CEST 2004 Paolo Molaro <lupus@ximian.com>
14177 * mini-ppc.c, cpu-g4.md: small updates to be able to compile
14178 vararg-using methods.
14180 2004-06-21 Martin Baulig <martin@ximian.com>
14182 * mini/mini-exceptions.c
14183 (mono_handle_exception): Added `gpointer original_ip' argument.
14184 After calling mono_unhandled_exception(), call
14185 mono_debugger_unhandled_exception() and if that returns true,
14186 restore the context and return.
14188 Mon Jun 21 19:26:40 CEST 2004 Paolo Molaro <lupus@ximian.com>
14190 * mini-ppc.c: prefer the use of relative branches so
14191 they won't need to be patched in aot code (patch from Patrick Beard).
14193 Mon Jun 21 19:03:18 CEST 2004 Paolo Molaro <lupus@ximian.com>
14195 * aot.c: patch from Patrick Beard to make the output assembly
14196 more correct for the MacOSX assembler. Small tweak to
14197 generate sane images on Linux/PPC, too.
14199 Fri Jun 18 18:24:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
14201 * mini.c, mini.h, mini-ppc.c: handle varargs methods with a special
14202 case until bug #59509 is fixed (shows up in #60332).
14204 Tue Jun 15 16:36:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
14206 * mini.c: make sure the needed wrappers are compiled, too, with
14209 Mon Jun 14 18:36:08 CEST 2004 Paolo Molaro <lupus@ximian.com>
14211 * driver.c: remove NPTL reference in --version output.
14213 Sun Jun 13 17:25:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
14215 * aot.c: patch from Patrick Beard (pcbeard@mac.com) to
14216 generate valid assembly for the Mach-O assembler.
14218 Sun Jun 13 15:59:38 CEST 2004 Paolo Molaro <lupus@ximian.com>
14220 * driver.c: don't include abcrem in the all optimization specifier
14221 since it slows down jit compilation too much for now.
14223 2004-06-12 Ben Maurer <bmaurer@users.sourceforge.net>
14225 * mini.c: use BIGMUL only if both operands have the same signage.
14226 * iltests.il: Test for bug 60056. (errors related to signage in
14231 Thu Jun 10 16:06:42 CEST 2004 Paolo Molaro <lupus@ximian.com>
14233 * mini.c, aot.c: memory leak fixes.
14235 Tue Jun 8 16:37:15 CEST 2004 Paolo Molaro <lupus@ximian.com>
14237 * inssel-long32.brg: implemented a few missing ulong cast opcodes.
14239 Tue Jun 8 15:36:30 CEST 2004 Paolo Molaro <lupus@ximian.com>
14241 * Makefile.am: remove the -static hack completely, it links in
14242 statically glib as well.
14244 Sat Jun 5 16:32:33 CEST 2004 Paolo Molaro <lupus@ximian.com>
14246 * iltests.il, mini.c: fixed bug#59580 in branch optimization.
14247 * exceptions.cs: make it compile with new mcs/csc.
14249 2004-06-03 Massimiliano Mantione <massi@ximian.com>
14250 * cpu-pentium.md basic-float.cs Fixed bug on fpu spills (see bug 54467),
14251 and added relevant test case.
14253 Mon May 31 19:41:46 CEST 2004 Paolo Molaro <lupus@ximian.com>
14255 * mini.c revert Zoltan's fix to bug#58863 on ppc, since it causes
14256 regressions in gtk-sharp.
14258 2004-05-29 Zoltan Varga <vargaz@freemail.hu>
14260 * exceptions.cs: New regression tests.
14262 * jit-icalls.c (mono_llmult_ovf): Fix some boundary conditions.
14264 Sat May 29 10:45:58 CEST 2004 Paolo Molaro <lupus@ximian.com>
14266 * mini.c: emit castclass/isinst in their own trees (bug #54209/59057).
14268 2004-05-28 Zoltan Varga <vargaz@freemail.hu>
14270 * mini-sparc.h (MONO_ARCH_NEED_DIV_CHECK): Define this.
14272 * cpu-sparc.md mini-sparc.c: Add overflow detection to div opcodes.
14274 2004-05-28 Patrik Torstensson <totte@hiddenpeaks.com>
14276 * mini.c (mono_jit_runtime_invoke): Init class in this
14277 method instead of trusting mono_jit_compile_method to
14278 do the work (because wrappers can be in object class)
14280 2004-05-27 Zoltan Varga <vargaz@freemail.hu>
14282 * mini-sparc.c (mono_arch_output_basic_block): Fix sub.imm.
14284 * basic-long.cs: New regression test.
14286 Thu May 27 15:50:52 CEST 2004 Paolo Molaro <lupus@ximian.com>
14288 * cpu-g4.md, mini-ppc.c: fixes to long add/sub ovf opcodes
14289 and div/rem checks.
14291 Thu May 27 12:36:53 CEST 2004 Paolo Molaro <lupus@ximian.com>
14293 * Makefile.am: fix miguel's change to build mono statically against
14294 libmono (track build dependencies).
14296 2004-05-26 Zoltan Varga <vargaz@freemail.hu>
14298 * cfold.c: Some glib versions do not have G_MININT32.
14300 2004-05-26 Massimiliano Mantione <massi@ximian.com>
14302 * mini-x86.c cpu-pentium.md Makefile.am basic-math.cs: Fixed problem
14303 with precision of tan, atan, sin and cos, and implemented related
14304 regressions tests (fixes bug 54467, but one new problem appeared and
14307 2004-05-26 Zoltan Varga <vargaz@freemail.hu>
14309 * cfold.c (FOLD_BINOPZ): Avoid division by zero.
14311 * exceptions.cs: Add test for constant folding && division by zero.
14313 * driver.c mini.h mini.c mini-x86.c: Revert most of the previous patch
14314 since driver.c is in libmono too, so the optimization was useless.
14316 * driver.c mini.h mini.c mini-x86.c: Moved the mono_lmf_addr TLS
14317 variable to driver.c so the compiler can emit more efficient code to
14320 2004-05-26 Gonzalo Paniagua Javier <gonzalo@ximian.com>
14322 * Makefile.am: don't distribute generated inssel.[ch] files.
14324 2004-05-25 Zoltan Varga <vargaz@freemail.hu>
14326 * mini.c (mono_jit_compile_method_with_opt): Really emit icall wrappers
14327 into the default appdomain. Fixes #58707.
14329 * jit-icalls.c: Remove the broken approximation for truncl, doing
14330 no conversion is better.
14332 * mini.c (handle_stack_args): Avoid reusing variables for stack slots.
14335 Tue May 25 14:33:56 CEST 2004 Paolo Molaro <lupus@ximian.com>
14337 * mini-ops.h, mini-ppc.c, cpu-g4.md, inssel-ppc.brg: eliminate the use
14338 of the mcrxr instruction which is not available on some processors
14339 even if it's documented to be. Implement add and sub overflow correctly
14340 (still not complete for long unsigned). Speed up icalls a bit.
14342 2004-05-25 13:01 CET Patrik Torstenson <totte@hiddenpeaks.com>
14344 * mini.c (mono_jit_compile_method_with_opt): Make sure that
14345 we run .cctor in the current domain instead of target_domain.
14347 Fixes bug #58558, .cctor not being called in -O=shared.
14349 Tue May 25 12:46:50 CEST 2004 Paolo Molaro <lupus@ximian.com>
14351 * mini-ppc.h, jit-icalls.c: added explicit checks for divide by zero.
14353 2004-05-24 Ben Maurer <bmaurer@users.sourceforge.net>
14355 * mini-x86.c (EMIT_COND_BRANCH): If an OP_LABEL has an offset
14356 which can be done with an imm8, do it that way.
14357 (mono_arch_output_basic_block): ditto for a jmp
14358 (mono_arch_emit_prolog): Computate maximum offset of a label.
14360 2004-05-24 18:18 CET Patrik Torstenson <totte@hiddenpeaks.com>
14362 * mini-x86.c (mono_arch_local_regalloc): the reg allocator
14363 now tries to allocate prefered physical reg's for virtual
14364 regs. This reduces the number of emited spills/loads with
14365 20-30% on our core assemblies.
14367 Mon May 24 18:21:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
14369 * jit-icalls.c: truncl() is not needed and trunc() is
14370 the correct thing to do anyway (bug #58287).
14372 2004-05-24 Zoltan Varga <vargaz@freemail.hu>
14374 * mini-sparc.c (mono_arch_flush_icache): Call sync_instruction_memory
14377 Mon May 24 12:49:45 CEST 2004 Paolo Molaro <lupus@ximian.com>
14379 * driver.c: enable loop optimizations by default.
14381 Mon May 24 11:13:46 CEST 2004 Paolo Molaro <lupus@ximian.com>
14383 * mini-x86.c: fix calc of max loop size when aligning loops start.
14385 2004-05-23 Zoltan Varga <vargaz@freemail.hu>
14387 * ssa.c (mono_ssa_cprop): Allocate carray dynamically instead of on
14390 2004-05-22 Zoltan Varga <vargaz@freemail.hu>
14392 * mini-sparc.c (mono_arch_output_basic_block): ADD_IMM and SUB_IMM
14395 * basic-long.cs: Add tests for add/subtract of immediates with carry.
14397 * mini.c exceptions-x86.c: Remove MONO_USE_EXC_TABLES stuff.
14399 * mini.c (inline_method): Allways inline some wrappers even if the cost
14400 is too large. Fixes #58785.
14402 * mini.c: Add support for MARSHAL_CONV_FTN_DEL.
14404 2004-05-21 Zoltan Varga <vargaz@freemail.hu>
14406 * mini-sparc.c exceptions-sparc.c: Applied patch from Mark Crichton
14407 (crichton@gimp.org). Beginning of support for sparc/linux.
14409 * mini-sparc.c: Optimize retrieval of LMF address.
14411 Fri May 21 08:00:12 EDT 2004 Paolo Molaro <lupus@ximian.com>
14413 * exceptions-ppc.c: handle alloca in methods with clauses.
14415 Fri May 21 07:35:30 EDT 2004 Paolo Molaro <lupus@ximian.com>
14417 * mini-ppc.c: cleanups, off-by-one fixes, avoid recursive thunks.
14419 2004-05-20 Lluis Sanchez Gual <lluis@ximian.com>
14421 * mini.c: Delegate most of the abort signal work to
14422 mono_thread_request_interruption, which also handles Stop and Suspend
14425 2004-05-20 Zoltan Varga <vargaz@freemail.hu>
14427 * mini.c mini.h: Allow inlining of icall wrappers if the backend
14428 supports the save/restore lmf opcodes.
14430 2004-05-19 Zoltan Varga <vargaz@freemail.hu>
14432 * mini-x86.c (mono_arch_setup_jit_tls_data): Handle code generated
14433 by gcc-3.4 as well.
14435 * mini-x86.h mini-x86.c tramp-x86.c: Optimize lmf restoring code.
14437 2004-05-18 Zoltan Varga <vargaz@freemail.hu>
14439 * mini.h mini.c (mini_method_compile): Only run abc removal pass on
14440 methods which contain array accesses.
14442 * mini.c (CEE_LDTOKEN): Handle this instruction correctly on bb
14443 boundaries. Fixes #58537.
14445 * iltests.il: Add regression test for #58537.
14447 2004-05-18 Patrik Torstensson <totte@hiddenpeaks.com>
14449 * mini-x86.c (mono_arch_local_regalloc): Last part of
14450 fix for bug #58633 (releasing register to early).
14452 2004-05-18 Miguel de Icaza <miguel@ximian.com>
14454 * basic-long.cs: Add new regression test.
14456 2004-05-18 Patrik Torstensson <totte@hiddenpeaks.com>
14458 * mini-x86.c (mono_arch_local_regalloc): Avoid releasing a
14459 register too early on the chain.
14461 2004-05-18 Zoltan Varga <vargaz@freemail.hu>
14463 * mini.c (create_helper_signature): Use a helper function to reduce
14464 the code which needs to be written. Also set the calling convention of
14465 icalls on windows. Fixes #57840.
14467 Tue May 18 11:05:18 CEST 2004 Paolo Molaro <lupus@ximian.com>
14469 * mini.h, exceptions-x86.c, exceptions-sparc.c, exceptions-s390.c,
14470 exceptions-ppc.c: added helper function to get the instruction address
14471 from a signal handler context.
14473 2004-05-17 Ben Maurer <bmaurer@users.sourceforge.net>
14475 * helpers.c: use g_get_tmp_dir. Invokes happyness
14478 2004-05-17 Ben Maurer <bmaurer@users.sourceforge.net>
14480 * helpers.c: Add new env variable to pass args to objdump.
14481 Specifically for those of us who love -Mintel. r=miguel, gonzalo.
14483 2004-05-17 Radek Doulik <rodo@ximian.com>
14485 * Makefile.am (common_sources): added abcremoval.h so it get
14486 disted and daily mono packages on go-mono.com will build again
14488 2004-05-17 Massimiliano Mantione <massi@ximian.com>
14490 * abcremoval.c: Fixed coding style, added copyright header.
14492 * abcremoval.h: Fixed style and moved prototype to mini.h, added copyright header.
14494 * mini.h: Added prototype for abc removal main function.
14496 * build_relations_propagation_table.pl: Added copyright header.
14498 2004-05-16 Patrik Torstensson <totte@hiddenpeaks.com>
14500 * basic-long.cs: reg test for complex ceq_long bug.
14502 2004-05-16 Patrik Torstensson <totte@hiddenpeaks.com>
14504 * mini-x86.c (mono_arch_local_regalloc): Correctly free
14505 reg in long and clob case (bug #58343). Fixed/added comments.
14507 2004-05-14 Ben Maurer <bmaurer@users.sourceforge.net>
14509 * mini.c (mono_jit_runtime_invoke): Follow new convention
14510 of calling the invoke method with an function pointer.
14512 2004-05-14 Zoltan Varga <vargaz@freemail.hu>
14514 * ChangeLog: Fix author of memory leak patch.
14516 Fri May 14 15:13:06 CEST 2004 Paolo Molaro <lupus@ximian.com>
14518 * Makefile.am: fix make dist as well...
14521 2004-05-14 Massimiliano Mantione <massi@ximian.com>
14523 * cfold.c: Made so that conversions from pointer to int4 are no-ops
14524 on archs where pointers are 4 bytes long.
14526 * Makefile.am: Added abcremoval.c source file.
14528 * abcremoval.c: Added abcremoval.c.
14530 * abcremoval.h: Added abcremoval.h.
14532 * build_relations_propagation_table.pl: Added build_relations_propagation_table.pl.
14534 * inssel.brg: Enabled bounds check removal.
14536 * mini.c: Added support for abcrem optimization.
14538 * mini.h: Added abcrem optimization label.
14540 * driver.c: Added support for abcrem optimization.
14542 * propagated_relations_table.def: Added propagated_relations_table.def.
14544 Fri May 14 14:30:13 CEST 2004 Paolo Molaro <lupus@ximian.com>
14546 * mini.c, cfold.c: fix style.
14548 Fri May 14 14:28:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
14550 * mini.c: handle issue with the low-level implementation of
14551 some long opcodes (bug #54209).
14553 2004-05-13 Ben Maurer <bmaurer@users.sourceforge.net>
14555 * basic.cs: test for my new cmov stuff.
14557 2004-05-13 Patrik Torstensson
14559 * mini-x86.c: added OP_X86_COMPARE_MEMBASE_IMM peephole
14560 opt and added peephole documentation.
14562 Thu May 13 11:41:49 CEST 2004 Paolo Molaro <lupus@ximian.com>
14564 * tramp-ppc.c: rewrote the generic trampoline code.
14566 2004-05-11 Patrik Torstensson
14568 * mini-x86.c: optimize long shl/shr asm code (one less branch)
14570 2004-05-11 Zoltan Varga <vargaz@freemail.hu>
14572 * basic.cs basic-long.cs objects.cs: Make these compile under MS csc.
14574 * mini.h mini.c dominators.c: Applied patch from Derek Woo
14575 (derek@eecg.toronto.edu): Fix memory leaks in loop optimizations.
14577 * mini.c: Add new icalls for AsAny marshalling.
14579 Tue May 11 16:00:38 CEST 2004 Paolo Molaro <lupus@ximian.com>
14581 * tramp-ppc.c, mini-ppc.c: more cleanups.
14583 2004-05-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
14585 * mini.c: no warnings.
14587 Tue May 11 13:59:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
14589 * mini-ppc.c, mini.c: use mono_resolve_patch_target ().
14591 2004-05-11 Lluis Sanchez Gual <lluis@ximian.com>
14593 * mini.c: In the thread abort signal handler, if the thread is in the
14594 process of being stoped, don't throw the Abort exception, just stop the
14597 Tue May 11 12:15:24 CEST 2004 Paolo Molaro <lupus@ximian.com>
14599 * tramp-ppc.c: removed old code.
14601 Tue May 11 12:02:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
14603 * mini.h, mini-ppc.c, cfold.c: export mono_is_power_of_two().
14604 do some simple speed optimizations on ppc.
14606 Mon May 10 17:21:00 CEST 2004 Paolo Molaro <lupus@ximian.com>
14608 * mini-ppc.c, cpu-g4.md: fixes to handle large stack frames
14609 and large offsets in load/store.
14611 2004-05-07 Zoltan Varga <vargaz@freemail.hu>
14613 * mini-x86.c (mono_arch_local_regalloc): Remove the previous fix, since
14614 it causes regressions.
14616 2004-05-07 Zoltan Varga <vargaz@freemail.hu>
14618 * mini-sparc.c: Fix vararg support + add beginnings of sigaltstack
14621 Fri May 7 13:25:50 CEST 2004 Paolo Molaro <lupus@ximian.com>
14623 * jit-icalls.c: remove warnings.
14624 * inssel-x86.brg, inssel.brg, mini-x86.c, cfold.c: some simple
14625 speedups for unsafe code.
14627 2004-05-07 Ben Maurer <bmaurer@users.sourceforge.net>
14629 * inssel.brg: Optimize Stind.[ui][12]. r=zoltan.
14631 2004-05-06 Zoltan Varga <vargaz@freemail.hu>
14633 * basic-calls.cs: Add new regression test.
14635 * mini.c (mono_runtime_install_handlers): Use SA_ONSTACK since it is
14638 * mini.c (mono_method_to_ir): Handle opcode emulation for *_OVF opcodes.
14640 * mini-x86.c (mono_arch_local_regalloc): Free new_dest register when it
14643 2004-05-06 Patrik Torstensson
14645 * mini-x86.[c|h], inssel-x86.brg, cpu-pentium.md, mini.c: enabled
14646 long reg allocation in any reg (not only eax:edx) and implemented
14647 long shl/shr ops in asm instead of helpers.
14649 2004-05-05 Zoltan Varga <vargaz@freemail.hu>
14651 * mini-sparc.h: Fix warnings.
14653 * exceptions-sparc.c (mono_arch_find_jit_info): Pop unused lfm off the
14656 * mini-exceptions.c (mono_handle_exception): Call the filter in a
14657 separate statement for clarity.
14659 * mini-sparc.c: Update status.
14661 2004-05-04 Zoltan Varga <vargaz@freemail.hu>
14663 * mini-exceptions.c (ves_icall_get_frame_info): Flush register windows
14666 Mon May 3 22:58:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
14668 * inssel-ppc.brg: another small pre-release workaround:
14669 we don't do overflow detection for long_sub_un.
14671 Sun May 2 20:12:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
14673 * mini.c, mini-ops, inssel-long32.brg: speedup ulong >> 32
14674 (also works around a weird ppc bug: 57957).
14676 Sat May 1 16:56:10 EDT 2004 Paolo Molaro <lupus@ximian.com>
14678 * tramp-ppc.c: trampoline fixes.
14680 Fri Apr 30 15:54:26 EDT 2004 Paolo Molaro <lupus@ximian.com>
14682 * mini-ppc.c: fixed typos.
14684 Thu Apr 29 20:15:41 CEST 2004 Paolo Molaro <lupus@ximian.com>
14686 * mini-ppc.c, exceptions-ppc.c: more code saves registers
14687 at the top of the stack. Fixed typos. Use a frame registers
14688 for all the methods with exception clauses.
14690 Thu Apr 29 18:52:09 CEST 2004 Paolo Molaro <lupus@ximian.com>
14692 * exceptions-ppc.c: restore fp registers.
14694 Thu Apr 29 18:26:56 CEST 2004 Paolo Molaro <lupus@ximian.com>
14696 * mini-ppc.c, exceptions-ppc.c: save the registers in reverse
14697 order from the stack top (moved the stack room to save the
14698 return value for trace after the param area). Fixed corruption
14699 in restoring registers on unwind.
14701 Thu Apr 29 16:47:15 CEST 2004 Paolo Molaro <lupus@ximian.com>
14703 * mini-ppc.c, cpu-g4.md: fixed unisgned -> double conversion.
14705 Thu Apr 29 13:50:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
14707 * exceptions-ppc.c, mini-ppc.h, mini-ppc.c: fixed localloc
14708 and prolog/epilog for methods that use it. Allow
14709 enough param area room for varargs methods. Fix miguel's
14710 breakage in exception handling.
14712 Thu Apr 29 12:06:51 CEST 2004 Paolo Molaro <lupus@ximian.com>
14714 * Makefile.am: run genmdesc only on current arch.
14716 2004-04-29 Gonzalo Paniagua Javier <gonzalo@ximian.com>
14718 * exceptions-x86.c:
14719 * mini-x86.h: fix the build on windows.
14721 2004-04-28 Zoltan Varga <vargaz@freemail.hu>
14723 * 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.
14725 * exceptions-sparc.c exceptions-ppc.c exceptions-s390.c mini-ppc.h mini-s390.h mini-sparc.h: Fix up ports after changes.
14727 * mini-exceptions.c: New file.
14729 * mini.c mini-exceptions.c mini-x86.h exceptions-x86.c Makefile.am:
14730 Move some parts of the x86 exception handling code to an
14731 arch-independent file so it can be shared with other ports.
14733 Tue Apr 27 12:15:59 CEST 2004 Paolo Molaro <lupus@ximian.com>
14735 * trace.c, cpu-g4.md, inssel-ppc.brg, mini-ppc.c: some fixes for FP code.
14737 2004-04-26 David Waite <mass@akuma.org>
14739 * driver.c: remove comma from end of enumeration declaration
14741 2004-04-26 Jackson Harper <jackson@ximian.com>
14743 * driver.c: parse config file before loading first assembly. This
14744 allows the user gac to be enabled/disabled.
14746 2004-04-23 Miguel de Icaza <miguel@ximian.com>
14748 * mini-ppc.c (ppc_patch): Replaced the branch code patching with a
14749 simpler mechanism: we do not care what is encoded initially
14750 (branch absolute or relative), we care about the code and its
14751 target. I kept the old code for reference for now.
14753 The new code tries first to determine if the jump is anywhere in
14754 the -/+32 absolute meg range, if it succeeds, it encodes using the
14755 absolute branch; If not, it tried to find something in the
14756 relative range, if not, it uses the handle_thunk code.
14758 Fri Apr 23 14:20:40 EDT 2004 Paolo Molaro <lupus@ximian.com>
14760 * exceptions-ppc.c: use the correct ip register on macosx.
14762 Thu Apr 22 13:23:16 EDT 2004 Paolo Molaro <lupus@ximian.com>
14764 * exceptions.c, mini.c, mini-ppc.h: adapt code to macosx.
14766 Thu Apr 22 18:08:37 CEST 2004 Paolo Molaro <lupus@ximian.com>
14768 * mini-ppc.c, cpu-g4.md: made the branch macros more flexible.
14769 Raise exception on integer divide by zero by hand since the hw
14770 doesn't support it. Handle NaNs in FP compares.
14772 Thu Apr 22 16:10:31 CEST 2004 Paolo Molaro <lupus@ximian.com>
14774 * exceptions-ppc.c, mini-ppc.h, mini.c: simplified some
14775 code reducing duplication between the platforms and enabled
14776 signal exception handling (on linux for now).
14778 Wed Apr 21 12:27:48 EDT 2004 Paolo Molaro <lupus@ximian.com>
14780 * exceptions-ppc.c: more macosx support.
14782 Wed Apr 21 16:38:28 CEST 2004 Paolo Molaro <lupus@ximian.com>
14784 * mini-ppc.h, mini-ppc.c, cpu-g4.md: enable bigmul optimization.
14786 Wed Apr 21 16:20:32 CEST 2004 Paolo Molaro <lupus@ximian.com>
14788 * mini.h, mini-ppc.c, cpu-g4.md: support for implicit exceptions.
14790 2004-04-19 Ben Maurer <bmaurer@users.sourceforge.net>
14792 * iltests.il: more tests.
14794 2004-04-19 Zoltan Varga <vargaz@freemail.hu>
14796 * mini-*.c (mono_arch_get_allocatable_int_vars): Skip written-only
14799 Mon Apr 19 19:39:47 CEST 2004 Paolo Molaro <lupus@ximian.com>
14801 * mini-ppc.c: some fixes to bootstrap mcs/corlib/etc.
14803 2004-04-19 Zoltan Varga <vargaz@freemail.hu>
14805 * liveness.c: Mark variables as volatile in all basic blocks reachable
14806 from exception clauses.
14808 2004-04-18 Zoltan Varga <vargaz@freemail.hu>
14810 * exceptions.cs (test_0_rethow_stacktrace): Make this work with
14813 2004-04-18 Ben Maurer <bmaurer@users.sourceforge.net>
14815 * iltests.il, basic.cs: more tests for regalloc.
14817 2004-04-17 Ben Maurer <bmaurer@users.sourceforge.net>
14819 * iltests.il: Some tests for register allocation modifications
14822 2004-04-16 Zoltan Varga <vargaz@freemail.hu>
14824 * exceptions.cs: Add regression test for bug #56782.
14826 * exceptions-*.c (mono_arch_handle_exception): Do not overwrite the
14827 original stack trace if an exception is rethrown. Fixes #56782. Oh,
14828 the beauty of fixing the same thing in 5 different files...
14830 2004-04-15 Zoltan Varga <vargaz@freemail.hu>
14832 * mini.c (mono_method_to_ir): Do not compute coverage for inlined
14835 2004-04-14 Zoltan Varga <vargaz@freemail.hu>
14837 * mini.c: Add support for STRWLPARRAY marshalling convention.
14839 Wed Apr 14 18:15:55 CEST 2004 Paolo Molaro <lupus@ximian.com>
14841 * exceptions-ppc.c: missing fixes in mono_jit_walk_stack (need
14842 to init the context to setup the regs pointer).
14844 Wed Apr 14 17:59:09 CEST 2004 Paolo Molaro <lupus@ximian.com>
14846 * exceptions-ppc.c: more exceptions work.
14848 Wed Apr 14 17:46:22 CEST 2004 Paolo Molaro <lupus@ximian.com>
14850 * mini.c: avoid reusing the same MonoInst on multiple trees: this is
14853 2004-04-13 Miguel de Icaza <miguel@ximian.com>
14855 * inssel-x86.brg (reg): Add new rules for add, sub and mul that
14856 can use the memory directly.
14858 * cpu-pentium.md: Update documentation from a post from Zoltan.
14860 add x86_add_membase, x86_sub_membase, x86_mul_membase
14862 2004-04-13 Miguel de Icaza <miguel@ximian.com>
14864 * mini-ppc.c: Remove unused definitions FLOAT_REGS and
14865 GENERAL_REGS they were also hardcoded for all PPC ports.
14867 (add_general): Use PPC_NUM_REG_ARGS instead of GENERAL_REGS.
14869 Remove hard-coded limit for floating point registers, use
14870 PPC_LAST_FPARG_REG instead in MONO_TYPE_R4 and MONO_TYPE_R8.
14872 Notice that in MacOS X calling conventions you can fit a lot more
14873 floating point values in registers, so I should update the PInvoke
14874 test to excercise the passing of floating point values on the
14875 stack (currently broken).
14877 2004-04-06 Miguel de Icaza <miguel@ximian.com>
14879 * tramp-ppc.c (create_trampoline_code): Added
14880 JUMP_TRAMPOLINE_SIZE.
14881 (ppc_magic_trampoline): Follow the pattern from
14882 x86_magic_trampoline: if code is set to zero, return.
14883 (create_trampoline_code): Always pass MonoMethod to the jump
14884 trampoline, before it was passing a null.
14885 (mono_arch_create_jump_trampoline): Implement the jump stub, could
14886 share the code with mono_arch_create_jit_trampoline.
14888 * mini-ppc.c (mono_arch_output_basic_block): CEE_JMP opcode
14890 (mono_arch_patch_code): MONO_PATCH_INFO_METHOD_JUMP patch type
14893 * cpu-g4.md: Added length for jmp instruction, the worst case
14894 scenario is 92 bytes (4 mandatory bytes, potential 19 registers
14897 2004-04-08 Zoltan Varga <vargaz@freemail.hu>
14899 * aot.c (mono_compile_assembly): Add back unlink removed by mistake.
14901 2004-04-07 Zoltan Varga <vargaz@freemail.hu>
14903 * mini.c: Only set bblock->real_offset when adding a new bblock, and
14904 before each IL instruction.
14906 * mini.c (CEE_BOX): Fix warnings.
14908 2004-04-07 Gonzalo Paniagua Javier <gonzalo@ximian.com>
14910 * mini.c: removed a few unused vars and extra whitespace.
14912 2004-04-05 Ben Maurer <bmaurer@users.sourceforge.net>
14914 * inssel.brg (MONO_EMIT_BOUNDS_CHECK): a new macro to emit bounds
14916 (MONO_EMIT_BOUNDS_CHECK_IMM): the above, but when you know the
14918 (OP_GETCHR): use the above
14919 (CEE_LDELEMA): use the above.
14921 * inseel-x86.brg (MONO_EMIT_BOUNDS_CHECK): a faster and smaller
14922 version of the generic impl.
14923 (MONO_EMIT_BOUNDS_CHECK_IMM): the same
14924 (CEE_LDELEMA): use the above.
14926 2004-04-05 Zoltan Varga <vargaz@freemail.hu>
14928 * inssel-long32.brg (CEE_CONV_OVF_I8): Sign extend the i4 value to i8.
14931 * iltests.il: Added new regression test for #56317.
14933 2004-04-05 Zoltan Varga <vargaz@freemail.hu>
14935 * mini-x86.c (mono_arch_setup_jit_tls_data): Use pthread_attr_get_np
14936 under NetBSD. Fixes #56450.
14938 * liveness.c (update_gen_kill_set): Fix previous patch.
14940 2004-04-04 Gonzalo Paniagua Javier <gonzalo@ximian.com>
14942 * mini-x86.h: SA_STACK defined as SA_ONSTACK. Fixed build under NetBSD.
14944 2004-04-02 Zoltan Varga <vargaz@freemail.hu>
14946 * mini.c (mono_method_to_ir): Avoid handle_loaded_temps in
14947 ldsfld and ldsflda.
14949 * inssel-sparc.brg: Add more optimizations.
14951 * mini-sparc.c: Replace multiply/divide with shifts if possible.
14953 2004-04-01 Martin Baulig <martin@ximian.com>
14955 * mini.c (handle_box): New static function; moved the
14956 implementation of CEE_BOX here.
14957 (mono_method_to_ir): Added `constrained_call' variable.
14958 (mono_method_to_ir:CEE_CONSTRAINED_): Set it.
14959 (mono_method_to_ir:CEE_CALL): If `constrained_call' is set, use
14960 mono_method_get_constrained() to get the method.
14962 2004-04-01 Martin Baulig <martin@ximian.com>
14964 * mini.c (TYPE_PARAM_TO_TYPE, TYPE_PARAM_TO_CLASS): Removed.
14965 (MTYPE_PARAM_TO_TYPE, MTYPE_PARAM_TO_CLASS): Removed.
14966 (mono_method_to_ir): We don't need these macros anymore since
14967 mono_class_get_full() already takes care of it.
14969 2004-03-31 Gonzalo Paniagua Javier <gonzalo@ximian.com>
14971 * aot.c: set aot_verbose to 0, fixed format string that caused sigsegv,
14972 use @function (as doesn't accept #function here) and check the return
14973 value of system and stop if fails.
14975 2004-03-31 Gonzalo Paniagua Javier <gonzalo@ximian.com>
14977 * mini.c: set the timeout to 2s when calling mono_domain_finalize.
14979 2004-03-31 Zoltan Varga <vargaz@freemail.hu>
14981 * mini-ppc.c (mono_arch_patch_code): Fix ppc build.
14983 * inssel-sparc.brg mini-sparc.c aot.c: Implement AOT support.
14985 * inssel-long32.brg (OP_LNEG): Use ADC instead of ADD here. Fixes
14988 * basic-long.cs: Add test for negation of Int64.MinValue.
14990 2004-03-30 Zoltan Varga <vargaz@freemail.hu>
14992 * mini-sparc.c: Update status.
14994 * mini-sparc.c tramp-sparc.c: Save lmf in trampolines.
14996 * exceptions-sparc.c: Fix return value in filters.
14998 * inssel-sparc.brg: Fix register allocation in some rules.
15000 2004-03-28 Martin Baulig <martin@ximian.com>
15002 * mini.c (mmono_method_to_ir): In CEE_STELEM, do a handle_stobj()
15005 2004-03-28 Zoltan Varga <vargaz@freemail.hu>
15007 * mini-x86.c (mono_arch_patch_code): Fix warnings.
15009 * mini-x86.c (mono_arch_output_basic_block): Fix CEE_MUL_OVF_UN if
15010 dreg is not EAX. Thanks to Willibard Krenn for spotting this. Also
15011 remove unused conv_u4 opcode.
15013 * mini-x86.c: Remove valgrind workaround since it slows down things
15014 even when mono is not run under valgrind.
15016 2004-03-26 Zoltan Varga <vargaz@freemail.hu>
15018 * mini-sparc.c: Update status.
15020 * inssel-sparc.brg: Add some optimizations.
15022 * inssel-sparc.brg mini-sparc.c: Rework branch instructions to allow
15023 future delay slot filling. Add support for varargs, tail calls and JMP.
15025 * inssel.brg mini-ops.h mini.c: Use OP_REFANYTYPE instead of
15026 CEE_REFANYTYPE, since CEE_REFANYTYPE needs a prefix to be unique.
15028 * inssel.brg: Fix register allocation in OP_ARGLIST.
15030 * inssel.brg: Fix warnings.
15032 2004-03-25 Martin Baulig <martin@ximian.com>
15034 * mini.c (inflate_generic_field): Removed.
15035 (mini_get_method): Removed, use mono_get_method_full(),
15036 (mini_get_class): Removed, use mono_class_get_full().
15037 (mono_method_to_ir): Pass our generic context to
15038 mono_field_from_token().
15040 2004-03-25 Martin Baulig <martin@ximian.com>
15042 * mini.c (mini_get_class): Take a `MonoGenericContext *' instead
15043 of a `MonoMethod *'.
15044 (mini_get_method): Take a `MonoGenericContext *' instead
15045 of a `MonoMethod *'.
15046 (TYPE_PARAM_TO_TYPE, MTYPE_PARAM_TO_TYPE): mono_method_to_ir() has
15047 a new local variable called `generic_context' which holds the
15048 current `MonoGenericContext *'; use it to lookup things.
15050 2004-03-24 Martin Baulig <martin@ximian.com>
15052 * mini.c (mini_get_class): New static method; if we're inside a
15053 generic instance, inflate the class if neccessary.
15054 (mono_method_to_ir): Use mini_get_class() instead of mono_class_get().
15056 2004-03-24 Zoltan Varga <vargaz@freemail.hu>
15058 * iltests.il: New regression test for #55976.
15060 * mini.c (mono_method_to_ir): Empty the stack in endfinally. Fixes
15063 2004-03-23 Zoltan Varga <vargaz@freemail.hu>
15065 * exceptions-sparc.c (mono_sparc_handle_exception): Remove debugging
15068 2004-03-23 Zoltan Varga <vargaz@freemail.hu>
15070 * liveness.c: Consider SSA stores as well as loads when making vars
15073 * exceptions.cs: New regression tests for register allocation.
15075 2004-03-22 Lluis Sanchez Gual <lluis@ximian.com>
15077 * mini-ppc.c, tramp-ppc.c: Added lock for accessing the domain code manager.
15078 * mini.c: Removed domain lock from mono_jit_compile_method_with_opt. Use
15079 domain lock only to protect puntual access to data structures.
15080 Added access lock for sighash, jit_icall_hash_name,
15081 jit_icall_hash_addr and domain->code_mp.
15083 2004-03-20 Zoltan Varga <vargaz@freemail.hu>
15085 * driver.c: Print SIGSEGV handling method.
15087 * mini-x86.c (mono_arch_free_jit_tls_data): Add missing ifdef.
15089 * mini.c (setup_jit_tls_data): Handle case when this is called
15090 multiple times for a thread.
15092 * mini-x86.c cpu-pentium.md: Fix floating point branch opcodes so fbxx
15093 is different from fbxx_un. Fixes #54303. Also use constants instead of
15094 magic numbers in a lot of places.
15096 2004-03-19 Zoltan Varga <vargaz@freemail.hu>
15098 * exceptions.cs: Fix cctor test when --regression is used.
15100 Thu Mar 18 19:57:56 CET 2004 Paolo Molaro <lupus@ximian.com>
15102 * mini-ppc.c, exceptions-ppc.c: basic exceptions support
15105 Thu Mar 18 19:56:19 CET 2004 Paolo Molaro <lupus@ximian.com>
15107 * inssel-ppc.brg: fixed register assignments for some rules.
15109 2004-03-17 Zoltan Varga <vargaz@freemail.hu>
15111 * exceptions.cs: Add test for exceptions in static constructors.
15113 * mini.c (mono_jit_compile_method_with_out): Move the calling of
15114 static constructors outside the domain lock. Fixes #55720.
15116 2004-03-17 Martin Baulig <martin@ximian.com>
15118 * mini.c (get_generic_field_inst): Removed, this'll never happen.
15119 (inflate_generic_field): Take the `MonoMethod *' instead of the
15120 `MonoClass *' and added support for generic method.
15121 (mono_method_to_ir): In CEE_LDSFLD and CEE_STSFLD, assert we never
15122 have a `field->parent->gen_params', only inflate the field if it's
15123 an open constructed type.
15125 2004-03-17 Zoltan Varga <vargaz@freemail.hu>
15127 * exceptions-x86.c (mono_arch_handle_exception): Allocate a new
15128 exception object instead of the preconstructed ones.
15130 2004-03-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
15132 * mini.c: reverted changed to sigsegv_signal_handler commited
15133 accidentally in the previous patch.
15135 2004-03-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
15138 (mono_method_to_ir): CEE_CALLVIRT, abort if no method. It hanged when
15139 running --aot with an old assembly.
15141 2004-03-16 Zoltan Varga <vargaz@freemail.hu>
15143 * mini-sparc.c (mono_arch_instrument_epilog): Fix handling of floating
15146 * mini-sparc.c: Add support for v9 branches with prediction.
15148 2004-03-15 Bernie Solomon <bernard@ugsolutions.com>
15150 * mini.c (mini_init): #warning is GNUC only
15152 * mini-sparc.h: implement __builtin_frame_address
15153 and __builtin_return_address for Sun C compiler
15155 2004-03-15 Zoltan Varga <vargaz@freemail.hu>
15157 * exceptions-sparc.c (mono_arch_has_unwind_info): Add missing function.
15159 2004-03-14 Zoltan Varga <vargaz@freemail.hu>
15161 * basic-calls.cs: Add test for unaligned byref long argument passing.
15163 * mini-ops.h: Add sparcv9 compare and branch instructions.
15165 * inssel-sparc.brg mini-sparc.h mini-sparc.c cpu-sparc.md: Use some
15166 v9 instructions if we have a v9 cpu.
15168 * mini-sparc.c (mono_arch_get_global_int_regs): Use unused input
15169 registers for global allocation.
15171 * exceptions-sparc.c: Fixes.
15173 2004-03-11 Zoltan Varga <vargaz@freemail.hu>
15175 * liveness.c (mono_analyze_liveness): Optimized version.
15177 * inssel-sparc.brg cpu-sparc.md: Ongoing sparc work.
15179 * mini-sparc.h mini-sparc.c tramp-sparc.c exceptions-sparc.c: Ongoing
15182 * basic-float.cs basic-calls.cs: New regression tests.
15184 2004-03-10 Zoltan Varga <vargaz@freemail.hu>
15186 * mini-x86.h: Define SIGSEGV_ON_ALTSTACK only if we have a working
15187 sigaltstack implementation.
15189 * mini-x86.c (mono_arch_setup_jit_tls_data): Fix previous patch.
15191 * mini-x86.c (mono_arch_setup_jit_tls_data): Turn off the sigaltstack
15192 stuff if SIGSEGV_ON_ALTSTACK is not defined.
15194 2004-03-09 Zoltan Varga <vargaz@freemail.hu>
15196 * mini.c: Fix warnings.
15198 * mini.c (mono_resolve_patch_target): New function which contains the
15199 arch independent part of the patching process.
15201 * mini-x86.c (mono_arch_patch_code): Move arch independent parts of the
15202 patching code to a separate function.
15204 2004-03-09 Bernie Solomon <bernard@ugsolutions.com>
15206 * mini.c (add_signal_handler): ifdef out on Windows
15208 2004-03-08 Zoltan Varga <vargaz@freemail.hu>
15210 * mini-sparc.h mini-sparc.c inssel-sparc.brg exceptions-sparc.c
15211 cpu-sparc.md: Add exception handling support + other fixes.
15213 * driver.c: Print --help output to stdout. Fixes #55261. Also fix
15214 typed GC detection in --version.
15216 * basic.cs exceptions.cs: New regression tests.
15218 * mini.h mini-x86.h mini-ppc.h: Add MonoCompileArch structure where
15219 the arch specific code can store data during a compilation.
15221 * mini-ops.h: Add OP_SETFRET.
15223 * mini.c (mini_get_ldelema_ins): Instead of allways calling the same
15224 function, register a separate icall for each arity, so the icalls can
15227 * mini.c (mono_print_tree): Print negative offsets in a more readable
15230 * mini.c: Make signal handling work on sparc.
15232 * mini.c (mini_init): Add emulation for lconv_to_r8_un.
15234 * inssel-long32.brg: Fix OP_LSUB_OVF_UN rule.
15236 * jit-icalls.c: Emulate truncl by aintl on solaris.
15238 * jit-icalls.c (mono_lconv_to_r8_un): New icall emulation function.
15240 2004-03-05 Zoltan Varga <vargaz@freemail.hu>
15242 * mini.c (mini_init): fconv_to_ovf can raise exceptions.
15244 2004-03-04 Lluis Sanchez Gual <lluis@ximian.com>
15246 * mini.c: In CEE_ISINST and CEE_CASTCLASS, if the type is an interface or
15247 a MarshalByRef type, inline a method that performs the check, taking into
15248 account that the object can be a proxy. Also implemented tow new opcodes:
15249 CEE_MONO_CISINST and CEE_MONO_CCASTCLASS.
15250 * inssel.brg: Implemented two new opcodes, mini-ops.h: OP_CISINST and
15251 OP_CCASTCLASS, which implement CEE_MONO_CISINST and CEE_MONO_CCASTCLASS.
15253 Tue Mar 2 17:23:48 CET 2004 Paolo Molaro <lupus@ximian.com>
15255 * mini-ppc.c: if a relative branch displacement is too big
15256 but it points to and area reachable with an absolute branch,
15259 Tue Mar 2 16:59:40 CET 2004 Paolo Molaro <lupus@ximian.com>
15261 * mini.c: optimize small copies in cpblk.
15263 2004-03-01 Zoltan Varga <vargaz@freemail.hu>
15265 * basic-calls.cs basic-float.cs: New regression tests.
15267 * mini-sparc.c inssel-sparc.brg mini-ops.h: Access local variables at
15268 negative offsets from %fp. Implement localloc. Fix local register
15269 allocation. Fix the case when the this argument needs to be saved to
15270 the stack. Implement some missing opcodes.
15272 2004-02-26 Zoltan Varga <vargaz@freemail.hu>
15274 * mini.c (mini_method_compile): Reenable global regalloc in methods
15275 with exception handlers.
15277 * linear-scan.c (mono_varlist_sort): Fix warning.
15279 * linear-scan.c (mono_linear_scan): Fix computation of used_regs.
15281 * mini-x86.c (mono_arch_regalloc_cost): Reenable precise computation of
15284 * liveness.c: Make all variables uses in exception clauses volatile, to
15285 prevent them from being allocated to registers. Fixes #42136.
15287 2004-02-25 Zoltan Varga <vargaz@freemail.hu>
15289 * mini-x86.c (mono_arch_regalloc_cost): Revert this change since it
15290 causes regressions.
15292 * mini.h linear-scan.c mini-x86.c mini-sparc.c mini-ppc.c: Add 'cfg'
15293 argument to mono_arch_regalloc_cost.
15295 * mini-x86.c (mono_arch_regalloc_cost): Compute regalloc costs
15298 2004-02-24 Zoltan Varga <vargaz@freemail.hu>
15300 * mini.h mini-x86.c mini-ppc.c mini-sparc.c linear-scan.c:
15301 Make the cost of allocating a variable to a register arch dependent.
15303 * basic-calls.cs: Fix compilation of tests.
15305 * mini.h mini.c tramp-x86.c mini-x86.c: Add mono_running_on_valgrind ()
15306 helper function to cut back on the number of #ifdefs needed.
15308 * mini-ppc.c: Fix compilation.
15310 * basic-calls.cs: New regression tests.
15312 * mini-sparc.c (mono_sparc_is_virtual_call): New helper function.
15314 * tramp-sparc.c (create_specific_trampoline): Use g5 register instead
15315 of l0 since that is callee saved.
15317 * tramp-sparc.c (sparc_magic_trampoline): Apply unbox trampoline only
15320 * mini-sparc.c: Ongoing work + flag virtual calls with a special kind
15321 of delay instruction.
15323 * inssel.brg (OP_CHECK_THIS): Set tree->sreg1 and dreg correctly.
15325 * mini.h (MonoCallInst): Add 'virtual' flag.
15327 * inssel.brg (mini_emit_virtual_call): Set 'virtual' flag.
15329 2004-02-23 Zoltan Varga <vargaz@freemail.hu>
15331 * *.cs: New regression tests.
15333 * mini-sparc.c inssel-sparc.brg: Update after latest changes. Ongoing sparc
15336 * mini.c (mono_runtime_install_handlers): Fix build.
15338 * mini.h (MonoJitTlsData): Add 'stack_size', 'signal_stack' and
15339 'signal_stack_size' members.
15341 * mini.h mini.c mini-x86.h mini-x86.c: Run sigsegv handlers on an
15342 alternate signal stack.
15344 * exceptions-x86.c: Add stack overflow handling.
15346 * mini.h mini.c mini-x86.c mini-ppc.c trace.h trace.c: Move tracing
15347 functions to arch independent code.
15349 * mini.c (mono_print_tree): Print more detailed info for load_membase
15352 2004-02-23 Martin Baulig <martin@ximian.com>
15354 * mini.c (mini_get_method): Set `gmethod->generic_inst'.
15356 Sun Feb 22 22:25:19 CET 2004 Paolo Molaro <lupus@ximian.com>
15358 * mini-x86.c: fixed reg allocation for div/rem.
15360 2004-02-22 Miguel de Icaza <miguel@ximian.com>
15362 * driver.c (mono_main): Report some configuratio options on --version.
15364 Fri Feb 20 11:01:44 PST 2004 Paolo Molaro <lupus@ximian.com>
15366 * mini-ppc.c: fixed clt.un, cgt.un. Optimized calls to functions
15367 low in the address space. Correctly flush memory in thunks where we
15368 output native code.
15370 2004-02-20 Martin Baulig <martin@ximian.com>
15372 * mini.c (mini_get_method): New static method; inflate all generic
15373 methods and methods in open generic instances.
15374 (mono_method_to_ir): Use mini_get_method() instead of mono_get_method().
15375 (ret_type_to_call_opcode): Added support for MONO_TYPE_GENERICINST.
15377 2004-02-19 Zoltan Varga <vargaz@freemail.hu>
15379 * mini-sparc.c (mono_arch_patch_code): Update after domain->code_mp changes.
15381 * tramp-sparc.c (mono_arch_create_jump_trampoline): Set ji->method.
15383 2004-02-19 Bernie Solomon <bernard@ugsolutions.com>
15385 * helpers.c (mono_disassemble_code): use Sun's dis if not using gcc
15387 * mini-sparc.c (flushi mono_arch_output_basic_block): make
15388 it compile using Sun's compiler.
15390 2004-02-19 Zoltan Varga <vargaz@freemail.hu>
15392 * 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.
15394 * basic-calls.cs basic-float.cs basic-long.cs objects.cs: New regression tests.
15396 Tue Feb 17 21:41:20 CET 2004 Paolo Molaro <lupus@ximian.com>
15398 * aot.c, mini-x86.c, mini.c: use the code manager instead of a mempool to hold native
15400 * mini-ppc.c: handle calls outside of the allowed range with thunks
15401 allocated using the code manager.
15402 * tramp-ppc.c: use the code manager to hold generated native code.
15403 Fixed the magic trampoline to just patch vtable entries.
15405 2004-02-17 Zoltan Varga <vargaz@freemail.hu>
15407 * inssel.brg inssel-x86.brg: Move call(immediate) rules to the platform
15410 2004-02-16 Zoltan Varga <vargaz@freemail.hu>
15412 * tramp-ppc.c (mono_arch_create_jump_trampoline): Fix compilation on
15415 * mini-x86.c: Call mono_arch_get_lmf_addr instead of mono_get_lmf_addr
15416 if we have a working __thread implementation.
15418 * mini-ops.h cpu-pentium.md mini-x86.c inssel-x86.brg: Remove
15419 OP_CALL_IMM opcodes, since the CALL opcodes handles immediates as well.
15421 2004-02-15 Zoltan Varga <vargaz@freemail.hu>
15423 * mini-x86.c: Fix compilation under gcc 2.
15425 2004-02-14 Zoltan Varga <vargaz@freemail.hu>
15427 * mini.c (mono_codegen): Avoid infinite loop when an icall wrapper
15428 contains a call to the wrapped function.
15430 * mini-ops.h cpu-pentium.md mini-x86.c inssel-x86.brg: Add
15431 OP_<CALL>_IMM opcodes, and use them under X86.
15433 * mini.c (mono_jit_find_compiled_method): Fix warning.
15435 * cpu-pentium.md: Fix length of opcodes which use x86_alu_membase_imm.
15437 * jit-icalls.c (mono_ldftn_nosync): New JIT icall.
15439 * tramp-x86.c (mono_arch_create_jump_trampoline): Move arch independent
15440 functionality to mini.c.
15442 * mini.c (mono_create_jump_trampoline): New function to create a jump
15443 trampoline. Return a compiled method instead of a trampoline if it
15444 exists. Add a cache for jump trampolines.
15446 * mini.c (mono_jit_find_compiled_method): New function to return a
15447 compiled method if it exists.
15449 * mini-x86.c: Call mono_create_jump_trampoline instead of
15450 mono_arch_create_jit_trampoline.
15452 * jit-icalls.c (mono_ldftn): Do not compile the method. Instead, return
15453 a jump trampoline. Fixes #52092.
15455 2004-02-11 Zoltan Varga <vargaz@freemail.hu>
15457 * debug-mini.c (mono_init_debugger): Remove call to mono_verify_corlib,
15458 which is not up-to-date. Add check_corlib_version () instead.
15460 * mini.c (mini_init): Call mono_thread_attach () so embedders do not
15463 * mini.c (mono_runtime_install_handlers): Remove check for valgrind
15464 since newer valgrind versions do not need it.
15466 * mini.c (mono_jit_compile_method_with_opt): New helper function to
15467 compile a method with a given set of optimizations.
15469 * mini.c: Compile icall wrappers on-demand instead of at startup.
15471 * mini-sparc.c mini-ppc.c: Call mono_icall_get_wrapper to obtain the
15472 wrapper for an icall.
15474 2004-02-10 Zoltan Varga <vargaz@freemail.hu>
15476 * mini.c (mono_method_to_ir): Handle switch with non-empty stack. Fixes
15479 * iltests.il: Add test for non-empty stack before switch instruction.
15481 2004-02-02 Zoltan Varga <vargaz@freemail.hu>
15483 * mini.c: Add support for new stringbuilder marshalling conventions.
15485 * mini.c (mono_method_to_ir): Fix stack management of generic CEE_BOX.
15487 2004-02-01 Martin Baulig <martin@ximian.com>
15489 * mini.c (MTYPE_PARAM_TO_TYPE): Method type arguments are stored
15490 in `ginst->mtype_argv'.
15492 2004-01-31 Miguel de Icaza <miguel@ximian.com>
15494 * mini.c: Add comments, replace CEE_XXX+128 with OP_XXX to
15495 facilitate grepping.
15497 Wed Jan 28 14:04:58 CET 2004 Paolo Molaro <lupus@ximian.com>
15499 * mini.c: fixed buglet in initobj generic implementation for references.
15501 Fri Jan 23 16:10:44 EST 2004 Paolo Molaro <lupus@ximian.com>
15503 * Makefile.am: make the version script conditional.
15504 * jit-icalls.c: handle missing truncl().
15506 2004-01-23 Zoltan Varga <vargaz@freemail.hu>
15508 * exceptions.cs: Add more tests for double->int conversion.
15510 * jit-icalls.c (mono_fconv_ovf_i8): Call truncl before comparison, so
15511 we don't throw exceptions when converting 1.1 to a long. Fixes #53250.
15513 Fri Jan 23 17:12:08 CET 2004 Paolo Molaro <lupus@ximian.com>
15515 * driver.c: make --verbose --version emit an error
15516 if the loaded corlib doesn't match the runtime version.
15518 Mon Jan 19 17:44:50 CET 2004 Paolo Molaro <lupus@ximian.com>
15520 * mini-ppc.h: export ppc_patch().
15521 * mini-ppc.c: call convention fixes. Added assert in ppc_patch().
15522 * tramp-ppc.c: call convention fixes: Linux/PPC support should be
15523 on par or better than on MacOSX.
15525 2004-01-19 Zoltan Varga <vargaz@freemail.hu>
15527 * mini.c tramp-x86.c tramp-sparc.c: Updated after changes to
15528 mono_lookup_pinvoke_call.
15530 * mini-x86.c: Under windows, the default pinvoke calling convention is
15531 stdcall. Fixes #52834.
15533 * mini.c (optimize_branches): Add an upper bound to the number of
15534 iterations to prevent infinite loops on strange loops. Fixes #53003.
15536 2004-01-16 Zoltan Varga <vargaz@freemail.hu>
15538 * inssel.brg: Add vectors<->one dimensional array checking to CASTCLASS
15539 and ISINST. Fixes #52093.
15541 * objects.cs (test_0_vector_array_cast): New tests.
15543 2004-01-15 Zoltan Varga <vargaz@freemail.hu>
15545 * jit-icalls.c (helper_stelem_ref_check): New jit icall for array type
15546 checking in Array.Set ().
15548 * mini.c (method_to_ir): Add array type checking in Array.Set (). Fixes
15551 * object.cs (test_0_multi_array_cast): New regression test.
15553 Thu Jan 15 16:30:24 CET 2004 Paolo Molaro <lupus@ximian.com>
15555 * exceptions-ppc.c: fix build on Linux/PPC.
15557 2004-01-14 Zoltan Varga <vargaz@freemail.hu>
15559 * tramp-x86.c (x86_magic_trampoline): Disable code patching when
15560 running under valgrind.
15561 (x86_magic_trampoline): Fix build bustage.
15563 * debug-mini.c: Modify the debug info serialize/deserialize code so it handles
15564 negative values as well. This is needed for the encoding of the line number
15565 info, since sometimes the line numbers are not in increasing order.
15567 2004-01-13 Zoltan Varga <vargaz@freemail.hu>
15569 * cpu-pentium.md (localloc): Increase the size of the localloc
15570 instruction since it is a loop under Win32.
15572 * debug-mini.c (record_line_number): Get rid of unneccesary memory
15575 2004-01-09 Zoltan Varga <vargaz@freemail.hu>
15577 * exceptions-ppc.c exceptions-x86.c exceptions-sparc.c
15578 tramp-x86.c tramp-ppc.c tramp-sparc.c: Applied patch from
15579 Max Horn (max@quendi.de). Fix file names in comments.
15581 2004-01-03 Zoltan Varga <vargaz@freemail.hu>
15583 * ssa.c (mono_ssa_rename_vars): Allocate new_stack on the heap to
15584 avoid stack overflow.
15585 (replace_usage): Avoid uninitialized variable warnings.
15587 * mini.c (mono_method_to_ir): Avoid disabling SSA for array operations
15588 and taking the address of valuetype variables.
15590 2004-01-03 Patrik Torstensson
15592 * mini-x86.c: renamed fpflags to flags in RegTrack, going to be used
15593 for other purposes than FP later on.
15595 2004-01-02 Zoltan Varga <vargaz@freemail.hu>
15597 * mini.c (mono_method_to_ir): Prevent register allocation for arguments
15600 Fri Jan 2 13:37:25 CET 2004 Paolo Molaro <lupus@ximian.com>
15602 * mini-ops.h, mini.c, inssel.brg: Object.GetType () speedup.
15604 2003-12-30 Patrik Torstensson <p@rxc.se>
15606 * mini-x86.h: Decreased number of availiable fp regs.
15607 Solves corner cases with FP spilling.
15609 2003-12-23 Patrik Torstensson <p@rxc.se>
15611 * mini-x86.c, mini-ops.h, cpu-pentium.md: Added support
15612 for floating point stack tracking / spilling on x86.
15615 * basic-float.cs: added float mul overflow test.
15617 2003-12-23 Zoltan Varga <vargaz@freemail.hu>
15619 * mini.c (mono_method_to_ir): Add workaround for bug #51126.
15621 Sun Dec 21 19:53:16 CET 2003 Paolo Molaro <lupus@ximian.com>
15623 * mini.h, mini-ppc.c, mini-ppc.h: small cleanups and
15624 supports for cond branches that overflow the immediate
15625 overflow offset. mcs can compile simple programs.
15627 Fri Dec 19 21:17:16 CET 2003 Paolo Molaro <lupus@ximian.com>
15629 * exceptions-ppc.c: exception handling support wip:
15630 finally handlers get run on exception.
15632 2003-12-19 Zoltan Varga <vargaz@freemail.hu>
15634 * aot.c (mono_aot_get_method_inner): Avoid loading AOT code while
15637 Fri Dec 19 17:58:28 CET 2003 Paolo Molaro <lupus@ximian.com>
15639 * cpu-g4.md, mini-ppc.c, exceptions-ppc.c, mini-ppc.h:
15640 initial support for stack walking and unwinding.
15642 2003-12-18 Zoltan Varga <vargaz@freemail.hu>
15644 * driver.c (mono_main): Make corlib-out-of-sync message more
15645 descriptive. Also remove verify_corlib call.
15647 Wed Dec 17 15:31:41 CET 2003 Paolo Molaro <lupus@ximian.com>
15649 * mini.c: make CEE_NEWARR calls and other emulated opcodes
15650 not overlap with other call's arguments, too.
15652 Wed Dec 17 12:49:23 CET 2003 Paolo Molaro <lupus@ximian.com>
15654 * mini.h, mini.c, mini-ppc.c, mini-sparc.c, mini-x86.c:
15655 move to arch-specific code the choice of arch-specific
15656 intrinsics (from Laurent Morichetti (l_m@pacbell.net)).
15657 * mini.c: ensure emulation calls will not interleave
15660 Wed Dec 17 12:27:26 CET 2003 Paolo Molaro <lupus@ximian.com>
15662 * tramp-ppc.c, basic-calls.cs: rework trampolines so that
15663 the magic trampoline stack frame is dropped before executing
15666 Mon Dec 15 18:13:57 CET 2003 Paolo Molaro <lupus@ximian.com>
15668 * mini-ppc.c, cpu-g4.md, inssel-ppc.brg: fixed some opcode lengths
15669 and integer to fp conversions. Added support for overflowing
15670 arguments on the stack. Reserve a couple more registers as temps.
15671 Added support for aot compilation (as output still needs to be
15674 Sat Dec 13 17:49:10 CET 2003 Paolo Molaro <lupus@ximian.com>
15676 * mini-ppc.c, basic-long.cs: fix jumps to known labels.
15677 Don't overwrite return register in some corner cases.
15679 2003-12-13 Zoltan Varga <vargaz@freemail.hu>
15681 * mini.h mini.c driver.c mini-x86.c mini-ppc.c aot.c: Do not run
15682 static constructors when AOT compiling.
15684 * driver.c (mono_main): Call mono_check_corlib_version.
15686 Sat Dec 13 10:31:12 CET 2003 Paolo Molaro <lupus@ximian.com>
15688 * cpu-g4.md, basic.cs: fixed div target register.
15690 Sat Dec 13 09:45:56 CET 2003 Paolo Molaro <lupus@ximian.com>
15692 * mini-ppc.c, basic.cs: shl_imm fix with test.
15694 Fri Dec 12 21:25:14 CET 2003 Paolo Molaro <lupus@ximian.com>
15696 * inssel-ppc.brg, mini-ppc.h, mini-ppc.c: support for passing
15697 structures by value. Misc fixes.
15698 * objects.cs: more tests.
15700 Fri Dec 12 10:11:49 CET 2003 Paolo Molaro <lupus@ximian.com>
15702 * mini-ppc.c: lconv.ovf.i implemented.
15704 2003-12-10 Gonzalo Paniagua Javier <gonzalo@ximian.com>
15707 (mini_init): don't error out if someone already called g_thread_init.
15709 Tue Dec 9 17:27:14 CET 2003 Paolo Molaro <lupus@ximian.com>
15711 * exceptions-x86.c, exceptions-ppc.c: allow the exception object
15712 to be any type per the spec. Fix abnormal memory usage when
15713 the same object is repeatedly thrown.
15715 Tue Dec 9 15:39:54 CET 2003 Paolo Molaro <lupus@ximian.com>
15717 * mini.c: check for overruns in IL code.
15719 2003-12-09 Zoltan Varga <vargaz@freemail.hu>
15721 * TODO: Add/remove some todo entries.
15723 2003-12-08 Zoltan Varga <vargaz@freemail.hu>
15725 * driver.c (mono_main): Call mono_verify_corlib.
15727 2003-12-07 Lluis Sanchez Gual <lluis@ximian.com>
15729 * inssel.brg: In CEE_ISINST and CEE_CASTCLASS, removed check for proxy.
15730 This has been moved to mini.c
15731 * mini.c: in mono_method_to_ir, CEE_ISINST and CEE_CASTCLASS cases, if the
15732 type being casted is marshalbyref it could be a proxy, so instead of
15733 emitting the type check code, emit a call to a runtime method that will
15734 perform the check by calling CanCastTo if needed.
15736 2003-12-06 Zoltan Varga <vargaz@freemail.hu>
15738 * mini-x86.c (mono_arch_emit_prolog): Fix stack space allocation for
15739 methods with large stack frames under Win32.
15741 2003-12-04 Zoltan Varga <vargaz@freemail.hu>
15743 * Makefile.am: Distribute regression tests.
15745 * mini-x86.c (mono_arch_get_allocatable_int_vars): Sort the var list
15746 at the end instead of inserting each variable into the sorted list.
15748 * linear-scan.c (mono_varlist_sort): New helper function.
15750 Wed Dec 3 20:46:28 CET 2003 Paolo Molaro <lupus@ximian.com>
15752 * mini.c: ensure arguments and locals are within bounds.
15754 Wed Dec 3 17:59:10 CET 2003 Paolo Molaro <lupus@ximian.com>
15756 * mini-ppc.c, cpu-g4.md, basic.cs, basic-long.cs: more tests and
15759 2003-12-03 Zoltan Varga <vargaz@freemail.hu>
15761 * mini.c (mono_cprop_copy_values): Fix crash.
15763 * aot.c: Set verbosity back to 0.
15765 Wed Dec 3 15:42:27 CET 2003 Paolo Molaro <lupus@ximian.com>
15767 * regalloc.c: complete memory leak fix by Laurent Morichetti
15770 2003-12-03 Zoltan Varga <vargaz@freemail.hu>
15772 * driver.c (main_thread_handler): Revert the previous patch.
15774 * tramp-x86.c (x86_class_init_trampoline): Avoid patching when running
15777 * mini-x86.c (mono_arch_local_regalloc): Do not allocate transient
15778 memory from the memory pool.
15780 * driver.c (main_thread_handler): Turn on all optimizations when
15783 * mini.c (mono_find_jit_opcode_emulation): Turn emul_opcode_hash into
15784 an array for better performance.
15786 * regalloc.c (mono_regstate_assign): Fix memory leak.
15788 * debug-mini.c (mono_debug_serialize_debug_info): New function to
15789 serialize the debug info.
15791 * debug-mini.c (mono_debug_add_aot_method): New function to load the
15792 debug info from the serialized representation.
15794 * aot.c: Save debug info into the generated file and load it when
15797 * mini.h (MONO_AOT_FILE_VERSION): Bump version number.
15799 Mon Dec 1 16:54:05 CET 2003 Paolo Molaro <lupus@ximian.com>
15801 * mini-ppc.c, tramp-ppc.c: save FP arguments in the trampoline.
15802 More FP-related fixes.
15804 Sun Nov 30 19:13:52 CET 2003 Paolo Molaro <lupus@ximian.com>
15806 * mini-ppc.c, cpu-g4.md, inssel-ppc.brg: fixed finally handlers
15807 and register allocation buglet. Hello world now runs.
15809 Fri Nov 28 23:03:05 CET 2003 Paolo Molaro <lupus@ximian.com>
15811 * cpu-g4.md, inssel-ppc.brg, mini-ppc.c: better long return support.
15812 * tramp-ppc.c: fixed class init trampoline.
15813 * inssel-ppc.brg, mini.c, jit-icalls.c, mini-ppc.h: more emulation.
15815 Fri Nov 28 16:36:29 CET 2003 Paolo Molaro <lupus@ximian.com>
15817 * cpu-g4.md, inssel-ppc.brg, jit-icalls.c, mini-ppc.c, mini-ppc.h,
15818 mini.c: more ppc changes/fixes.
15820 2003-11-27 Zoltan Varga <vargaz@freemail.hu>
15822 * mini.c (mono_method_to_ir): Fix tail calls with valuetype arguments.
15823 Also optimize the case when the arguments are the same in the caller
15826 * iltests.il: Add tests for tail calls with valuetype arguments.
15828 Thu Nov 27 21:06:37 CET 2003 Paolo Molaro <lupus@ximian.com>
15830 * mini-ppc.c: fixes for struct return type.
15832 Thu Nov 27 19:02:07 CET 2003 Paolo Molaro <lupus@ximian.com>
15834 * mini.h, mini.c, mini-x86.c, mini-ppc.c, mini-sparc.c: move
15835 mono_spillvar_offset() to arch-specific code.
15837 Thu Nov 27 18:30:42 CET 2003 Paolo Molaro <lupus@ximian.com>
15839 * mini-ppc.h, mini-ppc.c: handle some different ABI call convention issues.
15841 2003-11-27 Zoltan Varga <vargaz@freemail.hu>
15843 * exceptions-x86.c: Fix stack space leaks.
15845 * exceptions-x86.c (mono_arch_find_jit_info): Restore callee saved
15846 registers from the lmf if the method has save_lmf set.
15848 2003-11-26 Zoltan Varga <vargaz@freemail.hu>
15850 * tramp-x86.c (x86_magic_trampoline): Avoid patching in the addresses
15851 of icall wrappers into InvokeInDomain, since these are now per-domain.
15853 Wed Nov 26 20:15:04 CET 2003 Paolo Molaro <lupus@ximian.com>
15855 * mini-ppc.h, mini-x86.h, mini.c, inssel-ppc.brg, jit-icalls.c:
15856 make some opcode emulation and intrinsic ops enabled/disabled
15857 according to the architecture. More fixes.
15859 Wed Nov 26 19:59:09 CET 2003 Paolo Molaro <lupus@ximian.com>
15861 * mini-ppc.c, mini-sparc.c, cpu-g4.md: more bug fixes.
15863 Wed Nov 26 19:18:29 CET 2003 Paolo Molaro <lupus@ximian.com>
15865 * mini.h, inssel.brg, mini-x86.c, mini-ppc.c, mini-sparc.c: move
15866 arch-specific handling for 'this' and struct return type to
15867 arch-specific code.
15869 2003-11-26 Gonzalo Paniagua Javier <gonzalo@ximian.com>
15871 * aot.c: prevent divide by zero error when reporting (it happened with
15872 Accessibility.dll).
15874 2003-11-25 Zoltan Varga <vargaz@freemail.hu>
15876 * mini.h (inst_switch): Remove unused macro.
15878 2003-11-25 Gonzalo Paniagua Javier <gonzalo@ximian.com>
15881 (load_aot_module): free 'info->methods' and 'info' properly. No more
15882 "free(): invalid pointer blah" messages when you have an old aot
15885 2003-11-21 Lluis Sanchez Gual <lluis@ximian.com>
15887 * jit-icalls.c, mini.c: Added support for context static fields.
15889 2003-11-18 Zoltan Varga <vargaz@freemail.hu>
15891 * mini.c (mono_method_blittable): Methods which set LastError are not
15892 blittable either. Fixes #51108.
15894 Tue Nov 18 16:41:37 CET 2003 Paolo Molaro <lupus@ximian.com>
15896 * mini.c: flush icache.
15897 * cpu-g4.md, mini-ppc.c, inssel.brg: more fixes. Trace support.
15899 2003-11-18 Zoltan Varga <vargaz@freemail.hu>
15901 * mini.c (mono_type_blittable): OBJECT is not blittable. Fixes #47842.
15903 2003-11-17 Zoltan Varga <vargaz@freemail.hu>
15905 * tramp-x86.c (x86_class_init_trampoline): Make code patching thread
15908 * mini-x86.c (mono_arch_call_opcode): Disable AOT for methods with
15911 * inssel.brg (CEE_MKREFANY): Fix AOT case.
15913 2003-11-16 Zoltan Varga <vargaz@freemail.hu>
15915 * mini-x86.c (mono_arch_local_regalloc): Fix regalloc for div
15916 instruction when the result is discarded.
15918 * iltests.il (test_0_div_regalloc): New regression test.
15920 * arrays.cs: Fix compilation error.
15922 Fri Nov 14 21:34:06 CET 2003 Paolo Molaro <lupus@ximian.com>
15924 * inssel-x86.brg, inssel-float.brg, mini-ops.h: move x86-specific
15925 float rules to inssel-x86.brg: sane architectures with FP registers
15926 don't need to implement these rules.
15928 Fri Nov 14 20:52:12 CET 2003 Paolo Molaro <lupus@ximian.com>
15930 * mini-ppc.c, cpu-g4.md, inssel-ppc.brg: updates and fixes to the ppc port.
15932 Fri Nov 14 17:58:27 CET 2003 Paolo Molaro <lupus@ximian.com>
15934 * mini.h, inssel-long32.brg: fixed endianess issues in int64
15935 implementation of 32 bit systems.
15937 Thu Nov 13 16:14:41 CET 2003 Paolo Molaro <lupus@ximian.com>
15939 * exceptions-ppc.c: fix build on Linux/ppc from Jeroen@xs4all.nl
15940 (Jeroen Zwartepoorte).
15942 2003-11-12 Zoltan Varga <vargaz@freemail.hu>
15944 * mini.c (mono_method_to_ir): Use CEE_JMP only if the signature of
15945 the caller and the callee matches.
15947 * mini.c (mono_method_to_ir): Add comment.
15949 * mini-x86.c (mono_arch_output_basic_block): Use mono_signbit, since
15950 signbit is missing on some platforms.
15952 2003-11-06 Zoltan Varga <vargaz@freemail.hu>
15954 * mini.h (mono_arch_setup_jit_tls_data): New arch specific function.
15956 * mini.c (setup_jit_tls_data): Call the new function.
15958 * mini-x86.c mini-ppc.c mini-sparc.c: Define the new function.
15960 * mini-x86.c: Add experimental support for fast access to the lmf
15961 structure under NPTL/Linux 2.6.x.
15963 2003-11-06 Martin Baulig <martin@ximian.com>
15965 * ldscript: Make `GC_push_all_stack', `GC_start_blocking',
15966 `GC_end_blocking' and 'gc_thread_vtable' public; they're used by
15969 2003-11-02 Martin Baulig <martin@ximian.com>
15971 * mini.c (inflate_generic_field): New static method.
15972 (mono_method_to_ir): In CEE_LDFLD and CEE_LDSFLD: if we're a
15973 generic instance and the field is declared in a generic type, call
15974 inflate_generic_field() to inflate it. Fixes gen-28.cs.
15976 2003-10-31 Zoltan Varga <vargaz@freemail.hu>
15978 * mini.h mini.c (mono_method_same_domain): New function to return
15979 whenever the caller and the callee are in the same domain.
15981 * tramp-x86.c (x86_magic_trampoline): Use the new function.
15983 2003-10-30 Martin Baulig <martin@ximian.com>
15985 * mini.c (MTYPE_PARAM_TO_TYPE, MTYPE_PARAM_TO_CLASS): New macros;
15986 similar to TYPE_PARAM_TO_TYPE and TYPE_PARAM_TO_CLASS, but for
15988 (mono_method_to_ir): Added support for MONO_TYPE_MVAR; similar to
15989 MONO_TYPE_VAR, we the actual types from MTYPE_PARAM_TO_CLASS().
15991 2003-10-29 Zoltan Varga <vargaz@freemail.hu>
15993 * mini.c mini-ops.h inssel.brg: Implement undeniable exception
15996 * mini.c (sigusr1_signal_handler): Move creation of the thread abort
15997 object here, so it is in the correct appdomain etc.
15999 2003-10-27 Zoltan Varga <vargaz@freemail.hu>
16001 * mini.c (mono_jit_compile_method_inner): Lookup icalls here if not
16003 (mono_method_to_ir): Avoid freeing the type created returned from
16004 mono_type_create_from_typespec, since it is put into an internal cache
16005 by the function. Fixes pointer.exe.
16007 * mini.c tramp-x86.c tramp-sparc.c tramp-ppc.c: Use the normal
16008 trampolines for icalls and pinvokes as well. Fixes #33569.
16010 2003-10-24 Zoltan Varga <vargaz@freemail.hu>
16012 * mini.c: Update after appdomain changes.
16014 * mini.c (mono_jit_compile_method_inner): Allways compile native
16015 method wrappers in the root domain, since there can only be one
16016 instance of them, whose address is stored in method->info.
16018 2003-10-16 Zoltan Varga <vargaz@freemail.hu>
16020 * mini.c (mono_runtime_install_handlers): Get rid of the MONO_VALGRIND
16021 environment variable. Instead detect automatically whenever running
16022 under valgrind using the magic macro RUNNING_ON_VALGRIND from
16025 2003-10-16 Miguel de Icaza <miguel@ximian.com>
16027 * trace.c, trace.h: New files that implement the new trace option
16030 * driver.c: Document new --trace options.
16032 * exceptions-ppc.c, exceptions-x86.c, mini-ppc.c, mini-sparc.c,
16035 - if (mono_jit_trace_calls)
16036 + if (mono_jit_trace_calls != NULL && mono_trace_eval (method))
16038 * mini.h: prototypes.
16040 2003-10-15 Zoltan Varga <vargaz@freemail.hu>
16042 * mini.c (mono_method_to_ir): Fix initialization of typedbyref locals.
16044 * mini.c inssel.brg: Implement typedefbyref opcodes.
16046 * mini.c (mono_jit_compile_method): Remove unused local variable.
16048 * mini.c (mono_jit_compile_method_inner): Ditto.
16050 2003-10-12 Zoltan Varga <vargaz@freemail.hu>
16052 * tramp-x86.c (x86_class_init_trampoline): Fix build.
16054 * tramp-x86.c (x86_class_init_trampoline): Thread safety fixes.
16056 2003-10-10 Zoltan Varga <vargaz@freemail.hu>
16058 * mini.c (mono_no_aot): Remove unused global variable.
16060 * mini.c: Thread safety fixes.
16062 2003-10-09 Zoltan Varga <vargaz@freemail.hu>
16064 * mini.c (mono_create_class_init_trampoline): Add a lock around
16065 class_init_hash_addr.
16067 * arrays.cs (test_0_newarr_emulation): Add new regression test for
16070 * mini.c: Decompose the NEWARR instruction before decomposing its
16071 arguments. Fixes #30073.
16073 2003-10-08 Zoltan Varga <vargaz@freemail.hu>
16075 * mini-x86.c (mono_arch_emit_epilog): Add support for stdcall calling
16078 2003-10-06 Zoltan Varga <vargaz@freemail.hu>
16080 * mini.c (mono_method_to_ir): Allow wrapper data for CEE_LDELEMA.
16082 * inssel-x86.brg (OP_LOCALLOC): Fix register assignment for localloc.
16084 * driver.c: Add support for compiling icall wrappers to --compile.
16086 2003-10-05 Zoltan Varga <vargaz@freemail.hu>
16088 * inssel.brg: The empty value in class->interface_offsets is -1, not
16091 2003-10-03 Zoltan Varga <vargaz@freemail.hu>
16093 * objects.cs: New test for 'is' operator on an array of interfaces.
16095 Wed Oct 1 19:40:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
16097 * tramp-ppc.c: update trampoline code to support jumps
16098 and class initialization.
16100 2003-09-30 Zoltan Varga <vargaz@freemail.hu>
16102 * mini.c (mono_jit_compile_method): Fix reading of freed memory.
16104 * inssel.brg (OP_UNBOXCAST): Fix #46027.
16106 * inssel.brg (OP_UNBOX): Remove unused rule.
16108 * mini.h mini.c inssel-x86.brg: Allocate one SP variable for each
16109 region instead of one for each method. Fixes #47813.
16111 2003-09-29 Zoltan Varga <vargaz@freemail.hu>
16113 * exceptions.cs (test_0_nested_finally): New regression test for
16114 nested exception handlers.
16116 * mini.c (mono_jit_runtime_invoke): Fix for the previous fix.
16118 * mini.c (mono_method_to_ir): Avoid inlining tail calls.
16120 * mini.c (mono_method_to_ir): Fix tail recursion in the presence of
16123 * mini.c (mono_method_check_inlining): Make the inlining limit
16124 configurable by an environment variable.
16126 * mini.c (mono_jit_runtime_invoke): Add Gonzalo's fix for #36545.
16128 * mini.h: Bump AOT file version.
16130 * mini.h mini.c aot.c mini-x86.c: For relocations which refer to a
16131 token, store the image along with the token, since the token might not
16132 refer to the same image as the method containing the relocation,
16133 because of inlining.
16135 2003-09-27 Zoltan Varga <vargaz@freemail.hu>
16137 * mini.c (mono_precompile_assemblies): New function to compile
16138 all methods in all loaded assemblies.
16140 * mini.h driver.c: Added new optimization flag MONO_OPT_PRECOMP.
16142 * regalloc.h regalloc.c (MonoRegState): Change the type of
16143 iassign and fassign to int*, since they can contain large negative
16144 values if the register is spilled. Also added some comments. Fixes
16147 * exceptions-x86.c (seh_handler): Fix handling of system exceptions
16148 under Win32. Fixes #42964.
16150 2003-09-26 Zoltan Varga <vargaz@freemail.hu>
16152 * mini.h (MONO_PATCH_INFO_WRAPPER): New patch type.
16154 * aot.c: Added support for AOT compiling methods which contain calls
16155 to wrappers. Currently, only remoting-invoke-with-check wrappers are
16158 * driver.c (compile_all_methods): Run the compilation in a thread
16159 managed by mono. Fixes #44023.
16161 * mini.c (mono_codegen): Print full method name in verbose output.
16163 * mini-x86.c (mono_arch_patch_code): Fix warning.
16165 * mini-x86.c (mono_arch_patch_code): Allways create a trampoline for
16166 jumps, since the method we are jumping to might be domain-specific.
16168 * aot.c: Added support for MONO_PATCH_INFO_METHOD_JUMP.
16170 Tue Sep 23 10:50:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
16172 * inssel.brg: string chars are unsigned.
16174 2003-09-15 Zoltan Varga <vargaz@freemail.hu>
16176 * TODO: New todo item.
16178 * tramp-x86.c (x86_class_init_trampoline): New trampoline function
16179 which calls mono_runtime_class_init and patches the call site to
16180 avoid further calls.
16181 (mono_arch_create_class_init_trampoline): New arch specific function
16182 to create a class init trampoline.
16183 (create_trampoline_code): Generalized so it can create
16184 class init trampolines as well.
16186 * mini.c (helper_sig_class_init_trampoline): New helper variable.
16187 (mono_create_class_init_trampoline): New function to create and cache
16188 class init trampolines.
16189 (mono_find_class_init_trampoline_by_addr): New function to lookup the
16190 vtable given the address of a class init trampoline. Used by the
16192 (mono_codegen): Generate a call to a trampoline instead of
16193 mono_runtime_class_init in LDSFLD[A].
16194 (mono_codegen): Add relocations for the new trampoline.
16196 * mini.h mini-x86.c aot.c: Added a new relocation type:
16197 MONO_PATCH_INFO_CLASS_INIT.
16199 * mini.h: Bump AOT version number.
16201 * aot.c: Create a copy of the loaded code instead of using the original
16202 so methods which call each other will be close in memory, improving
16205 * exceptions-x86.c (mono_arch_has_unwind_info): Back out the previous
16206 patch since it breaks the regression tests.
16208 * exceptions-x86.c (mono_arch_has_unwind_info): Added explicit check
16209 for the register saving instruction sequence since the
16210 frame_state_for function in glibc 2.3.2 don't seem to detect it.
16212 2003-09-14 Zoltan Varga <vargaz@freemail.hu>
16214 * TODO: Fix todo item && remove another.
16216 2003-09-12 Zoltan Varga <vargaz@freemail.hu>
16218 * mini-x86.c (mono_arch_patch_code): Fix tail calls broken by a
16221 * aot.c: Moved the check for MONO_LASTAOT into the initialization
16222 function of the module.
16224 * mini.h mini.c aot.c: Added a new optimization flag OPT_AOT for
16225 turning on/off the usage of AOT code. Got rid of mono_no_aot and the
16226 --no-aot command line option.
16228 2003-09-11 Zoltan Varga <vargaz@freemail.hu>
16230 * helpers.c (mono_disassemble_code): Make this work under cygwin. Patch
16231 by Bernie Solomon (bernard@ugsolutions.com).
16233 * inssel.brg: Refactor the interface offset table related code into
16234 its separate functions and add support for the AOT case.
16236 2003-09-10 Zoltan Varga <vargaz@freemail.hu>
16238 * aot.c (mono_aot_get_method_inner): Fix memory leak.
16240 * aot.c: Added mono_aot_verbose variable and made all debugging
16241 output depend on the value of this variable.
16243 * aot.c (mono_aot_get_method_inner): Avoid dynamic allocation of
16244 method_label and info_label.
16246 * mini.h mini-x86.c aot.c: Added a new relocation type
16247 MONO_PATCH_INFO_IID for klass->interface_id.
16249 * mini.h mini.c driver.c aot.c: Changed mono_aot_get_method to return
16250 the MonoJitInfo structure.
16252 * mini.c (mono_jit_compile_method): Avoid using non-shared AOT in
16253 a non-root appdomain in shared mode.
16255 Tue Sep 9 16:33:07 CEST 2003 Paolo Molaro <lupus@ximian.com>
16257 * aot.c: make aot loader less verbose. Remove free of unused variable.
16259 2003-09-08 Zoltan Varga <vargaz@freemail.hu>
16261 * aot.c (mono_aot_get_method_inner): Fix MONO_PATCH_INFO_IMAGE.
16263 * .cvsignore: Added *.dll.
16265 * mini.c (mono_print_tree_nl): New function callable while debugging.
16267 * mini.c (mono_print_code): Export this.
16269 * tramp-x86.c (x86_magic_trampoline): Tell valgrind to recompile the
16272 2003-09-05 Zoltan Varga <vargaz@freemail.hu>
16274 * mini.h (MonoCompile): Added 'jit_info' field.
16276 * mini.c (mini_method_compile): Save the generated MonoJitInfo into
16277 the cfg structure, since it is needed by the AOT compiler.
16279 * mini.h (MONO_AOT_FILE_VERSION): Bump version number.
16281 * aot.c: A major rewrite. Changes include:
16282 - save exception tables for methods which have them.
16283 - cache failed lookups in aot_get_method () to avoid the (slow) calls
16284 to g_module_symbol.
16285 - reworked the file format so it is now much smaller and needs
16286 fewer relocation entries.
16288 2003-09-04 Zoltan Varga <vargaz@freemail.hu>
16290 * aot.c (load_aot_module): Fix build bustage on platforms without
16293 2003-09-04 Martin Baulig <martin@ximian.com>
16295 * Makefile.am (INCLUDES): Added $(LIBGC_CFLAGS).
16297 2003-09-04 Zoltan Varga <vargaz@freemail.hu>
16299 * TODO: Some new optimization ideas.
16301 * aot.c: Move AOT module loading logic here from mono_assembly_open.
16303 * aot.c: Save the optimization flags used to compile the code into
16306 * mini.h mini-x86.c mini.c aot.c: Added new types of relocations to
16307 support emitting domain specific code.
16309 * mini.h mini.c aot.c: Modified the JIT so the generated AOT code is
16310 no longer domain neutral. It can be made domain neutral by compiling
16311 with --optimize=shared.
16313 * aot.c (mono_aot_get_method_inner): Allow sharing of AOT methods
16314 between appdomains.
16316 * driver.c mini.h mini.c: New --no-aot debugging option which disables
16317 loading of AOT code.
16319 * inssel-x86.brg: Added missing AOTCONST -> OUTARG_VT rule.
16321 * tramp-x86.c (x86_magic_trampoline): Avoid patching the calling method
16322 if there is no domain neutrality information.
16324 2003-09-01 Zoltan Varga <vargaz@freemail.hu>
16326 * aot.c (mono_compile_assembly): Emit a symbol containing the file
16327 format version into the generated library.
16329 * mini-x86.c (mono_arch_patch_code): Do not emit the address of the
16330 callee method into the caller since one of them could be shared.
16332 * mini.h mini-x86.c aot.c: Added two new relocations so throwing
16333 system exceptions from AOT code now works.
16335 * tramp-x86.c (x86_magic_trampoline): Avoid patching the calling
16336 method if it is domain neutral and the callee is not.
16338 * graph.c (cfg_emit_one_loop_level): Fix warning.
16340 2003-08-30 Zoltan Varga <vargaz@freemail.hu>
16342 * aot.c (mono_compile_assembly): Oops. Remove debugging cruft from
16345 2003-08-29 Zoltan Varga <vargaz@freemail.hu>
16347 * mini.c (mini_init): Call mono_marshal_init () explicitly since it
16348 is needed by code which is executed before mono_runtime_init ().
16349 Thanks to Bernie Solomon (bernard@ugsolutions.com) for noticing this.
16351 * mini.c (mono_thread_abort): Fix warning.
16352 (mono_jit_compile_method): Call static constructor in the AOT case too.
16354 * aot.c (mono_compile_assembly): Fix warning.
16356 2003-08-28 Gonzalo Paniagua Javier <gonzalo@ximian.com>
16358 * mini.c: register a SIGINT handler if MONO_DEBUG is defined.
16360 2003-08-28 Zoltan Varga <vargaz@freemail.hu>
16362 * inssel.brg (OP_UNBOXCAST): Add support for the AOT case.
16364 * cpu-pentium.md: Fix the length of call opcodes so they include the
16365 ESP restoring instruction. Fixes #47968.
16367 2003-08-28 Martin Baulig <martin@ximian.com>
16369 * mini-x86.c (mono_arch_call_opcode): Added support for
16370 MONO_TYPE_GENERICINST.
16372 * mini.c (check_call_signature): Added support for MONO_TYPE_GENERICINST.
16374 2003-08-27 Zoltan Varga <vargaz@freemail.hu>
16376 * Makefile.am (BUILT_SOURCES): Fix compilation on platforms without
16377 a JIT. Patch by Bernie Solomon (bernard@ugsolutions.com).
16379 * mini.c jit-icalls.c tramp-x86.c tramp-ppc.c tramp-sparc.c: Get rid of
16382 2003-08-26 Martin Baulig <martin@ximian.com>
16384 * mini.c (get_basic_blocks): Added `unsigned char **pos' argument;
16385 when reporting an error, set this to the actual error location.
16386 (mono_method_to_ir): Report the correct error location if
16387 get_basic_blocks() returned an error.
16389 2003-08-25 Zoltan Varga <vargaz@freemail.hu>
16391 * mini.c (mono_type_blittable): OBJECT is not blittable.
16392 (mono_method_blittable): Methods which have marshalling descriptors
16393 are not blittable either. Fixes #47842.
16395 2003-08-22 Zoltan Varga <vargaz@freemail.hu>
16397 * driver.c mini.c: Use an environment variable instead of a global
16398 variable. Also fix the build.
16400 * mini.c (mini_init): Call g_thread_init () to make glib thread-safe.
16401 Fixes #47682. Thanks to Laurent Morichetti (l_m@pacbell.net) for
16404 * driver.c mini.c: Added --with-valgrind option to turn off some
16405 code which prevents mono from running under valgrind.
16407 * mini.c (mono_emit_call_args): Fixed warning.
16409 * mini.c (mono_emulate_opcode): Fixed warning.
16411 Thu Aug 21 19:10:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
16413 * inssel.brg: 64bit fixes from Laurent Morichetti <l_m@pacbell.net>.
16414 * linear-scan.c, mini-ppc.h, mini-sparc.h, mini-x86.h, mini.h,
16415 regalloc.c, regalloc.h: specify available registers in arch-specific
16416 code and support floats in the regallocator (patch by Laurent Morichetti
16419 Wed Aug 20 19:02:22 CEST 2003 Paolo Molaro <lupus@ximian.com>
16421 * mini.c: mono_thread_current() can be called only after
16422 mono_runtime_init(): rearrange code to not call it early on.
16424 Wed Aug 20 13:14:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
16426 * mini.c: allocate jump tables in the code mempools.
16428 Wed Aug 20 13:04:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
16430 * mini.c, mini.h: make sure per-thread data allocated by the jit is
16433 2003-08-10 Miguel de Icaza <miguel@ximian.com>
16435 * cpu-pentium.md (ldtoken): Change the length for mul.ovf.un from
16436 12 to 16. This fixes bug #47453.
16439 Thu Aug 7 15:59:35 CEST 2003 Paolo Molaro <lupus@ximian.com>
16441 * mini-ppc.c: fixed indexed load and unsigned compares.
16443 2003-08-06 Lluis Sanchez Gual <lluis@ximian.com>
16445 * mini.c: reenabled installation of handler for
16446 thread abort signal.
16448 Tue Aug 5 12:21:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
16450 * cprop.c, mini-x86.c, cpu-pentium.md: fix buglets spotted
16451 by Laurent Morichetti <l_m@pacbell.net>. Disabled local cprop
16452 until it's fixed and actually useful.
16454 Mon Aug 4 12:12:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
16456 * inssel-long32.brg: couple more opcodes implemented.
16458 Thu Jul 31 22:43:02 EDT 2003 Mark Crichton <crichton@gimp.org>
16460 * mini-sparc.c: Even more opcodes implemeted.
16462 Thu Jul 31 19:36:03 EDT 2003 Mark Crichton <crichton@gimp.org>
16464 * mini-sparc.c: More opcodes implemented.
16466 Thu Jul 31 15:16:26 EDT 2003 Mark Crichton <crichton@gimp.org>
16468 * mini-sparc.c: More opcodes implemented.
16470 Wed Jul 30 22:31:02 EDT 2003 Mark Crichton <crichton@gimp.org>
16472 * inssel-sparc.brg: Add some needed rules. Direct
16474 * Makefile.am: Use inssel-sparc.brg
16475 * exceptions-sparc.c: 0xdeadbeef/0xdecafbad to keep
16476 an assert happy for now.
16478 Wed Jul 30 20:44:07 EDT 2003 Mark Crichton <crichton@gimp.org>
16480 * mini-sparc.c: Fixed compile errors.
16481 * exceptions-sparc.c: Same. We now produce a mono binary
16482 on sparc-linux. Yea.
16484 Wed Jul 30 14:10:12 EDT 2003 Mark Crichton <crichton@gimp.org>
16486 * mini-sparc.c: Renamed registers. Also some macro cleanups.
16487 * exceptions-sparc.c, tramp-sparc.c: Various compile fixes.
16488 They compile, but do not work.
16490 Wed Jul 30 17:52:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
16492 * Makefile.am, cpu-sparc.md, exceptions-sparc.c, mini-sparc.c,
16493 mini-sparc.h, tramp-sparc.c: Beginning of sparc support
16494 from Mark Crichton <crichton@gimp.org> and Christopher Taylor
16497 Tue Jul 29 12:43:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
16499 * mini.c: more opcodes implemented and better support for generics.
16501 Fri Jul 25 18:51:45 CEST 2003 Paolo Molaro <lupus@ximian.com>
16503 * cpu-g4.md, cpu-pentium.md: updates for new instructions.
16504 * mini.c, mini.h: first cut at generics support: some new instructions
16505 added and changed the behaviour of some of the existing ones.
16507 2003-07-21 Miguel de Icaza <miguel@ximian.com>
16509 * mini.c: Removed definition of metadata_shared mutex here.
16511 Tue Jul 22 15:21:24 CEST 2003 Paolo Molaro <lupus@ximian.com>
16513 * mini-x86.c: make vararg calls work for instance methods.
16515 Fri Jul 18 19:26:20 CEST 2003 Paolo Molaro <lupus@ximian.com>
16517 * mini.c, mini.h, mini-x86.c, mini-ppc.c: mono_arch_call_opcode()
16518 returns the arguments in a separte list, now.
16520 Fri Jul 18 13:16:18 CEST 2003 Paolo Molaro <lupus@ximian.com>
16522 * aot.c, mini.c: updates for array type representation changes.
16524 Fri Jul 18 11:28:28 CEST 2003 Paolo Molaro <lupus@ximian.com>
16526 * mini.c: register function to perform jit shutdown.
16528 Thu Jul 17 16:02:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
16530 * mini.c: use a faster allocator if possible.
16532 Thu Jul 17 16:00:39 CEST 2003 Paolo Molaro <lupus@ximian.com>
16534 * aot.c: some cleanups and portability changes.
16536 Wed Jul 2 11:08:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
16538 * mini.c: use faster allocation for CEE_BOX if possible.
16540 Mon Jun 30 19:16:33 CEST 2003 Paolo Molaro <lupus@ximian.com>
16542 * mini.c, mini-ops.h, inssel.brg, mini-x86.c: optimized access to fields.
16543 Moved inlined mempcy code to its own function so that is can be
16544 reused. Added an inline memset function as well (optimized initobj).
16545 * cpu-pentium.md, inssel-x86.brg: add and use lea_membase.
16547 Fri Jun 27 11:19:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
16549 * mini.c, mini-ops.h, inssel.brg: optimized a couple of Array methods.
16551 Wed Jun 25 13:19:25 CEST 2003 Paolo Molaro <lupus@ximian.com>
16553 * mini.c, mini.h, mini.x86.c, mini-ppc.c: added facility so that
16554 arch code can setup the cpu for CLR execution, if needed.
16555 We use it on x86 to set the precision of FP operations.
16557 Tue Jun 17 19:02:55 CEST 2003 Paolo Molaro <lupus@ximian.com>
16559 * mini.c: disable some optimizations if we can guess they'll cost too
16560 much for a given method.
16562 2003-06-17 Zoltan Varga <vargaz@freemail.hu>
16564 * mini.h mini.c: Rework last patch based on suggestions by Paolo.
16566 2003-06-17 Zoltan Varga <vargaz@freemail.hu>
16567 * mini.h mini.c mini-x86.c: Added instruction level coverage
16568 info collection support.
16570 Mon Jun 16 18:13:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
16572 * driver.c, mini-ppc.c, mini-x86.c, mini.c, mini.h: the coverage stuff
16573 is now implemented in the profiling API. Get rid of a couple of
16574 unnecessary global variables.
16576 2003-06-15 Nick Drochak <ndrochak@gol.com>
16578 * basic-long.cs: tests for negative values for bigmul, and unsigned.
16579 * cpu-g4.md: add op_bigmul and op_bigmul_un
16580 * cpu_pentium.md: add op_bigmul_un
16581 * inssel-long32.brg: add rule for unsigned bigmul
16582 * mini-ops.h: define OP_BIGMUL_UN
16583 * mini-x86.c: THE BUG: handle (un)signed properly
16584 * mini.c: choose unsigned opcode if needed.
16585 This set of patches fixes bug #44291
16587 2003-06-13 Dietmar Maurer <dietmar@ximian.com>
16589 * mini.c (optimize_branches): improved to handle all kinds of
16590 conditional branches.
16592 Wed Jun 11 18:01:06 CEST 2003 Paolo Molaro <lupus@ximian.com>
16594 * mini.c, mini.h, jit-icalls.c: speedup emulation of opcodes that
16595 don't raise exceptions.
16597 Tue Jun 10 19:00:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
16599 * tramp-x86.c, tramp-ppc.c, debug-mini.c: move arch-specific code
16600 to arch-specific files.
16602 2003-06-09 Martin Baulig <martin@ximian.com>
16604 * Makefile.am (libs): Added $(LIBGC_LIBS).
16606 Mon Jun 9 20:21:47 CEST 2003 Paolo Molaro <lupus@ximian.com>
16608 * cpu-pentium.md, mini-x86.c: fix (well, actually implement) OP_TAN
16609 and OP_ATAN (fixes bug#44293).
16611 Mon Jun 9 19:00:56 CEST 2003 Paolo Molaro <lupus@ximian.com>
16613 * Makefile.am, mini-x86.c: rename cpu description array to
16614 pentium_desc, since some compilers define the 'pentium' preprocessor
16617 2003-05-28 Dietmar Maurer <dietmar@ximian.com>
16619 * mini.c (mini_select_instructions): add explicit branch if the
16620 following block is not the false target of a conditional branch -
16621 we need this with any optimization that reorder or remove bblocks
16623 * mini.c (optimize_branches): bug fixes
16625 2003-06-06 Dietmar Maurer <dietmar@ximian.com>
16627 * mini.c (mono_method_to_ir): inline static readonly fields
16629 * ssa.c (fold_tree): start cfold support for long (very simple
16632 * cfold.c (mono_constant_fold_inst): opt. CEE_CONV_I8 (OP_ICONST)
16634 Fri Jun 6 11:41:18 CEST 2003 Paolo Molaro <lupus@ximian.com>
16636 * inssel.brg: fixed memcpy (bug #44219).
16638 2003-06-05 Dick Porter <dick@ximian.com>
16640 * driver.c: Set the glib log levels to not abort if g_message
16643 g_set_prgname() has to happen before mini_init() so that the
16644 process handle gets the info.
16646 Thu Jun 5 20:11:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
16648 * driver.c: add intrins to the default optimizations to get wider
16651 Wed Jun 4 19:47:57 CEST 2003 Paolo Molaro <lupus@ximian.com>
16653 * mini.h: some large basic blocks will overflow a 16-bit
16654 integers for symbolic registers.
16656 2003-06-04 Dietmar Maurer <dietmar@ximian.com>
16658 * mini-x86.c (mono_arch_output_basic_block): revert previous fprem changes.
16659 (mono_arch_output_basic_block): fix bug 43499
16661 Wed Jun 4 13:13:52 CEST 2003 Paolo Molaro <lupus@ximian.com>
16663 * mini.c: kill duplicated definition of mono_debug_format.
16665 Wed Jun 4 13:09:51 CEST 2003 Paolo Molaro <lupus@ximian.com>
16667 * mini-x86.c, arrays.cs: fixed register allocation bug.
16669 2003-06-04 Dietmar Maurer <dietmar@ximian.com>
16671 * mini-x86.c (mono_arch_output_basic_block): use IEEE compatible fprem1
16673 * mini.c (mini_get_opcode_for_method): inline IEEERemainder
16675 2003-06-04 Gonzalo Paniagua Javier <gonzalo@ximian.com>
16678 (print_method_from_ip): also print source location information if
16681 2003-06-02 Dietmar Maurer <dietmar@ximian.com>
16683 * mini.c (mono_find_block_region): bug fix in region code
16684 (mini_method_compile): enable removing unreachable code again, but
16685 only in methods without exception clauses.
16687 Fri May 30 18:40:24 CEST 2003 Paolo Molaro <lupus@ximian.com>
16689 * mini.c, mini-ops.h, cpu-pentium.md, inssel.brg, mini-x86.c, mini.h:
16690 Implemented arglist opcode and handling of TypedReference type.
16691 Fixed x86 call convention when a structure is returned.
16692 Minimal support for calling static vararg methods.
16694 2003-05-30 Dietmar Maurer <dietmar@ximian.com>
16696 * mini.c (mini_method_compile): always remove unreachable code,
16697 because the code in them may be inconsistent (access to dead
16698 variables for example).
16700 Thu May 29 11:44:49 CEST 2003 Paolo Molaro <lupus@ximian.com>
16702 * driver.c, debug-mini.c: warning fixes.
16704 Wed May 28 11:19:15 CEST 2003 Paolo Molaro <lupus@ximian.com>
16706 * Makefile.am, jit.h, mini.h: install header for embedding mono.
16708 Tue May 27 17:56:12 CEST 2003 Paolo Molaro <lupus@ximian.com>
16710 * mini.c: thread-static fields are registered in mono_class_vtable(),
16711 so ensure the function is called before checking for them.
16713 2003-05-27 Dietmar Maurer <dietmar@ximian.com>
16715 * mini.c (optimize_branches): fix for bug 43586
16717 * jit-icalls.c (mono_llmult_ovf): added an additional check for
16718 overflow (fixes Bug #43639)
16720 Tue May 27 11:33:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
16722 * mini.c, objects.cs: allow the use of stobj for primitive types.
16724 Tue May 27 10:33:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
16726 * mini.c: be less strict about argument checking until we support
16727 running the verifier.
16729 2003-05-27 Nick Drochak <ndrochak@gol.com>
16731 * basic-long.cs: tests for (ulong)int * (ulong)int also
16732 * mini.c: use the same trick for (ulong)int * (ulong)int
16734 2003-05-27 Nick Drochak <ndrochak@gol.com>
16736 * basic-long.cs: add regression test for (long)int * (long)int
16737 * cpu-pentium.md: add op_bigmul specification
16738 * inssel-long32.brg: add OP_BIGMUL rule
16739 * mini-ops.h: add OP_BIGMUL
16740 * mini-x86.c: register allocator: handle case where src1 needs to be
16742 * mini.c: substitute special BIGMUL opcode in the tree for
16743 (long)int * (long)int
16745 Mon May 26 20:20:13 CEST 2003 Paolo Molaro <lupus@ximian.com>
16747 * jit-icalls.c: call the type ctor on field access if needed.
16749 Mon May 26 15:21:21 CEST 2003 Paolo Molaro <lupus@ximian.com>
16751 * mini-ops.h, mini.c, inssel.brg, exceptions.cs: validate arguments passed
16752 to a method (including results of ldelema, bug#43207).
16754 2003-05-26 Dietmar Maurer <dietmar@ximian.com>
16756 * graph.c (cfg_emit_one_loop_level): loop over all blocks. use
16757 colors to show exception handler blocks.
16759 * inssel-x86.brg (OP_OUTARG_VT): dont push zero sized structures
16760 (fix for pinvoke7.cs).
16762 Mon May 26 12:11:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
16764 * mini.h, mini.c: ensure correct initialization order for types that
16765 require it. Prepare for lazy compilation of jit icall wrappers.
16766 Provide a name for opcode emulation to reduce unneeded mallocing.
16768 Fri May 23 16:08:54 CEST 2003 Paolo Molaro <lupus@ximian.com>
16770 * mini-x86.c: better register restoring code and profiling
16771 support for tail calls.
16773 Fri May 23 15:30:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
16775 * mini.h, driver.c: prepare for leaf methods optimization.
16777 Fri May 23 15:28:32 CEST 2003 Paolo Molaro <lupus@ximian.com>
16779 * mini.c: get targets of branches before converting a method.
16781 2003-05-23 Dietmar Maurer <dietmar@ximian.com>
16783 * mini.c (optimize_branches): added some experimental code (disbaled)
16785 2003-05-22 Dietmar Maurer <dietmar@ximian.com>
16787 * mini.c (optimize_branches): fix branch to branch optimization
16789 * exceptions-x86.c (mono_arch_handle_exception): bug fix.
16791 * mini-x86.c (mono_arch_output_basic_block): cleanup up exception code
16793 * inssel-x86.brg: added OP_START_HANDLER, CEE_ENDFINALLY, OP_ENDFILTER
16795 * mini-x86.c (mono_arch_allocate_vars): only reserve space for lmf
16798 2003-05-21 Dietmar Maurer <dietmar@ximian.com>
16800 * mini.c (mono_method_to_ir): call handle_loaded_temps before inlining.
16801 enable use of interface variables again.
16803 * mini-x86.c (mono_arch_get_allocatable_int_vars): dont allocate
16804 I1 to registers because there is no simply way to sign extend 8bit
16805 quantities in caller saved registers on x86.
16807 * inssel-float.brg: set costs of some rules to 2 so
16808 that monobure always select the arch. specific ones if supplied,
16809 regardless of the order we pass the files to monoburg.
16811 Tue May 20 17:19:14 CEST 2003 Paolo Molaro <lupus@ximian.com>
16813 * mini.c, mini-x86.c: since the magic trampoline for jumps
16814 can't patch the code directly, we do it as soon as the
16815 method gets compiled.
16817 Tue May 20 16:02:52 CEST 2003 Paolo Molaro <lupus@ximian.com>
16819 * mini-x86.c, mini.h: introduce a new patching method
16820 to support CEE_JMP and tail calls.
16821 * mini.c: obey tail.call. Don't precompile methods target
16823 * tramp-x86.c: new trampoline code to handle methods
16824 reached through a jump.
16826 2003-05-20 Dietmar Maurer <dietmar@ximian.com>
16828 * mini-x86.c (mono_arch_get_allocatable_int_vars): allocate 8/16
16829 bit values to registers
16831 2003-05-19 Dietmar Maurer <dietmar@ximian.com>
16833 * mini.c (mono_compile_get_interface_var): share interface
16834 variables if possible.
16836 2003-05-16 Martin Baulig <martin@ximian.com>
16838 * debug-mini.c (mono_init_debugger): New function to initialize
16839 the debugger. This is not in the debugger since it needs to
16840 access some of mini's internals.
16842 2003-05-16 Dietmar Maurer <dietmar@ximian.com>
16844 * mini.c (mono_method_to_ir): inlining fixes/cleanups
16846 Fri May 16 13:27:23 CEST 2003 Paolo Molaro <lupus@ximian.com>
16848 * mini.c, mini-opts.h, inssel.brg: inline small memcpy
16849 for value type handling.
16851 2003-05-16 Dietmar Maurer <dietmar@ximian.com>
16853 * mini.c (mono_method_to_ir): inline LDFLD/STFLD wrappers
16854 (mono_method_check_inlining): enable inlining of all kinds of wrappers
16856 2003-05-15 Lluis Sanchez Gual <lluis@ideary.com>
16858 * mini.c: fixed little bug in CEE_NEWOBJ case when calling
16859 the constructor through a proxy.
16861 Thu May 15 17:17:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
16863 * jit-icalls.c, inssel.brg: fixes to array element address
16866 2003-05-15 Dietmar Maurer <dietmar@ximian.com>
16868 * mini-x86.c (is_regsize_var): allocate pointer to registers
16870 Thu May 15 13:04:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
16872 * driver.c: fixed typo, added intrins to the set of optimizations
16873 tested with regressions.
16875 Thu May 15 11:57:42 CEST 2003 Paolo Molaro <lupus@ximian.com>
16877 * mini-ops.h, mini.c, inssel.brg: optimize access to 2D arrays.
16878 * jit-icalls.c, exceptions.cs: fixed index out of range checks, added
16881 2003-05-14 Dietmar Maurer <dietmar@ximian.com>
16883 * inssel.brg: remove some common pop instructions without side effects
16885 Wed May 14 12:40:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
16887 * inssel-x86.brg: fixed thinko in int to double conversions.
16889 Wed May 14 12:01:58 CEST 2003 Paolo Molaro <lupus@ximian.com>
16891 * mini.c, jit-icalls.c: added runtime thread-static variable support.
16893 Tue May 13 22:02:06 CEST 2003 Paolo Molaro <lupus@ximian.com>
16895 * inssel-long32.brg: two more missing instructions.
16897 2003-05-13 Dietmar Maurer <dietmar@ximian.com>
16899 * mini.c (mono_emit_call_args): set the cil_code for all arguments
16900 if not already set.
16902 2003-05-12 Zoltan Varga <vargaz@freemail.hu>
16904 * mini-x86.c (mono_arch_output_basic_block): Handle negative zero
16907 * basic-float.cs: Added tests for negative zero.
16909 Sun May 11 14:56:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
16911 * inssel-long32.brg, basic-long.cs, exceptions.cs: handle
16912 a couple of missing operations for long casts, with test cases.
16914 2003-05-11 Gonzalo Paniagua Javier <gonzalo@ximian.com>
16916 * exceptions-x86.c: fixed small leaks in mono_arch_handle_exception.
16918 2003-05-09 Dietmar Maurer <dietmar@ximian.com>
16920 * mini-x86.c (mono_arch_emit_prolog): avoid reallocs with better
16921 code size estimation.
16923 2003-05-08 Dietmar Maurer <dietmar@ximian.com>
16925 * mini.c (mono_jit_create_remoting_trampoline): make it work with
16926 abstract methods (fix bug 42542)
16928 * aot.c: add ability to handle array types
16930 2003-05-08 Zoltan Varga <vargaz@freemail.hu>
16932 * mini.c: Call the _specific versions of the object allocation
16933 functions if possible.
16935 Tue May 6 17:18:33 CEST 2003 Paolo Molaro <lupus@ximian.com>
16937 * driver.c: call setlocale ().
16939 Tue May 6 14:38:22 CEST 2003 Paolo Molaro <lupus@ximian.com>
16941 * mini.h, mini.c, aot.c, debug-mini.c, exceptions.c: build fixes for
16944 2003-05-05 Dietmar Maurer <dietmar@ximian.com>
16946 * mini.c (optimize_branches): dont touch code inside exception clauses (fix bug 38136)
16948 * exceptions-x86.c (ves_icall_get_frame_info): also skip remoting
16949 wrappers (fix bug 42122)
16951 2003-05-04 Martin Baulig <martin@ximian.com>
16953 * mini.h (mono_jit_init, mono_jit_cleanup): Added prototypes.
16955 * driver.c: s/MONO_OPT_SAHRED/MONO_OPT_SHARED/g.
16956 s/mini_set_defaults/mono_set_defaults/g.
16958 2003-05-04 Martin Baulig <martin@ximian.com>
16960 * driver.c: s/mini_parse_default_optimizations/mono_parse_default_optimizations/g.
16962 Sun May 4 11:48:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
16964 * inssel-long32.brg: add missing lreg: OP_LCONV_TO_U8 (lreg) rule
16965 (reported by Don Roberts).
16967 Fri May 2 18:36:45 CEST 2003 Paolo Molaro <lupus@ximian.com>
16969 * mini.c: temporarily work around two bugs for this release.
16971 Fri May 2 17:37:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
16973 * Makefile.am: avoid linking libmono with GMODULE_LIBS, because
16974 that contains -export-dynamic and it makes using the ld script
16976 * mini.h, main.c, driver.c: s/mini_main/mono_main/g.
16978 Fri May 2 12:52:32 CEST 2003 Paolo Molaro <lupus@ximian.com>
16980 * mini.h, mini-x86.c, driver.c: disable optimizations not available on a
16983 Thu May 1 15:28:21 CEST 2003 Paolo Molaro <lupus@ximian.com>
16985 * mini.c: make sure leave calls all the needed finally blocks,
16986 even when the target jumps out of multiple exception clauses.
16988 Thu May 1 15:18:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
16990 * ldscript, Makefile.am: add linker script to reduce the number of
16991 exported symbols (should also fix the issues with libwine defining
16992 some of the same symbols in io-layer).
16994 2003-05-01 Zoltan Varga <vargaz@freemail.hu>
16996 * driver.c (mini_main): Avoid assertion when no file name is given on
16999 Wed Apr 30 15:33:11 CEST 2003 Paolo Molaro <lupus@ximian.com>
17001 * driver.c: added --version/-V command line option.
17002 Added the inline optimization in the regression tests.
17004 Wed Apr 30 15:16:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
17006 * mini.c, basic-calls.cs: when inlining, save arguments to locals according
17007 to the type in the method signature (fixes bug#42134).
17009 Wed Apr 30 12:38:44 CEST 2003 Paolo Molaro <lupus@ximian.com>
17011 * mini.c: when inlining, check this is not null only when needed (bug #42135).
17013 Wed Apr 30 11:44:36 CEST 2003 Paolo Molaro <lupus@ximian.com>
17015 * mini-ppc.h, tramp-pcc.c: type fixes from Max Horn <max@quendi.de>.
17017 2003-04-30 Gonzalo Paniagua Javier <gonzalo@ximian.com>
17019 * driver.c: fixed bug #42100.
17021 2003-04-29 Dietmar Maurer <dietmar@ximian.com>
17023 * mini.c (mono_method_to_ir): UNBOX need to CAST objects first
17025 Mon Apr 28 17:03:14 CEST 2003 Paolo Molaro <lupus@ximian.com>
17027 * mini.c: moved most of the code required to do inlining to its own
17028 function so it can be reused. Inline also ctors if appropriate.
17030 2003-04-28 Zoltan Varga <vargaz@freemail.hu>
17032 * Makefile.am: Link with -export-dynamic so shared libs loaded by
17033 the runtime can call mono API functions.
17035 2003-04-27 Martin Baulig <martin@ximian.com>
17037 * debug-mini.c (mono_debug_init_method): Added
17038 `guint32 breakpoint_id' argument; if the method has a breakpoint,
17039 send a notification to the debugger.
17041 * mini.c (mono_method_to_ir): Don't insert a breakpoint if we're
17042 running in the Mono Debugger, just pass the breakpoint number to
17043 mono_debug_init_method().
17045 * tramp-x86.c, tramp-ppc.c: Removed the breakpoint trampolines.
17047 Sun Apr 27 13:18:04 CEST 2003 Paolo Molaro <lupus@ximian.com>
17049 * mini.c: allow some more unsafe compares.
17051 Sat Apr 26 11:55:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
17053 * mini-x86.c, Makefile.am: make distcheck works (partially from
17054 a patch by Richard Lee <r.h.lee@attbi.com>).
17055 * regset.c, regset.h: removed, they are unused.
17057 2003-04-25 Dick Porter <dick@ximian.com>
17059 * driver.c: Usage reports the name as 'mono' not 'mini'
17060 * exceptions-x86.c: Build and run on freebsd
17062 Thu Apr 24 17:09:03 CEST 2003 Paolo Molaro <lupus@ximian.com>
17064 * Makefile.am: install the program with the 'mono' name and
17065 the library as libmono instead of mini and libmini.
17067 Thu Apr 24 17:08:07 CEST 2003 Paolo Molaro <lupus@ximian.com>
17069 * driver.c: provide the APIs for the embedding interface of the old jit.
17071 2003-04-23 Dietmar Maurer <dietmar@ximian.com>
17073 * jit-icalls.c (helper_stelem_ref): impl. (fix bug 41775)
17075 2003-04-23 Martin Baulig <martin@ximian.com>
17077 * tramp-x86.c, tramp-ppc.c: Reenable the debugger breakpoint interface.
17079 * driver.c: Added `--debug' command line argument to enable
17082 2003-04-23 Martin Baulig <martin@ximian.com>
17084 * debug.[ch]: Removed. The code is now in
17085 ../metadata/mono-debug.[ch] and mono-debug-debugger.[ch].
17087 * debug-stabs.c, debug-dwarf2.c: Removed; nobody used this for the
17090 2003-04-22 Dietmar Maurer <dietmar@ximian.com>
17092 * mini.c (mono_method_to_ir): set the cil_code address (fix bug 41525)
17094 2003-04-17 Gonzalo Paniagua Javier <gonzalo@ximian.com>
17097 (mini_cleanup): moved mono_runtime_cleanup call after the call to
17098 mono_domain_finalize.
17099 (mini_method_compile): use mono_method_profile* if the the option is
17102 2003-04-17 Zoltan Varga <vargaz@freemail.hu>
17104 * tramp-x86.c (mono_arch_create_jit_trampoline): Subsitute synchronized
17105 methods with their wrapper.
17107 * tramp-ppc.c (mono_arch_create_jit_trampoline): Subsitute synchronized
17108 methods with their wrapper.
17110 * jit-icalls.c (mono_ldvirtfn): Subsitute synchronized methods with
17113 * mini.c (mono_method_to_ir): Subsitute synchronized methods with their
17116 * mini.c (mono_method_check_inlining): Avoid inlining synchronized
17119 2003-04-17 Dietmar Maurer <dietmar@ximian.com>
17121 * exceptions-x86.c (mono_arch_handle_exception): fix for bug 36252
17123 2003-04-16 Dietmar Maurer <dietmar@ximian.com>
17125 * mini.c (mono_compile_create_var): use g_malloc/g_realloc instead
17126 of the mempool. This is slightly faster and uses less memory
17128 Wed Apr 16 12:53:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
17130 * mini.c: avoid O(n) allocation for variables.
17132 Tue Apr 15 19:13:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
17134 * mini.c: handle items on the stack after inlining methods.
17136 Tue Apr 15 14:17:57 CEST 2003 Paolo Molaro <lupus@ximian.com>
17138 * mini.c: make the method->opcode optimization dependent
17139 on MONO_OPT_INSTRINS and do it lazily.
17141 Tue Apr 15 14:15:39 CEST 2003 Paolo Molaro <lupus@ximian.com>
17143 * driver.c: print overall results at the end of regression run.
17145 Tue Apr 15 11:18:46 CEST 2003 Paolo Molaro <lupus@ximian.com>
17147 * inssel.brg: don't overwrite symbolic registers.
17149 Mon Apr 14 17:41:34 CEST 2003 Paolo Molaro <lupus@ximian.com>
17151 * inssel-x86.brg: fix conversion from long to float.
17153 2003-04-11 Dietmar Maurer <dietmar@ximian.com>
17155 * mini.c (mini_init): use an opcode for get_Chars (OP_GETCHR)
17157 2003-04-10 Zoltan Varga <vargaz@freemail.hu>
17159 * mini.c (mono_type_blittable): MONO_TYPE_OBJECT is blittable.
17161 * driver.c: Added --print-vtable option as in the old JIT.
17163 Thu Apr 10 17:43:49 CEST 2003 Paolo Molaro <lupus@ximian.com>
17165 * inssel-long32.brg, exceptions.cs: fix conversions from long, too.
17167 Thu Apr 10 16:27:43 CEST 2003 Paolo Molaro <lupus@ximian.com>
17169 * inssel.brg, basic.cs: fixed checked conversions to byte and short.
17171 2003-04-09 Zoltan Varga <vargaz@freemail.hu>
17173 * mini.c regalloc.c regalloc.h: Fix memory leak.
17175 2003-04-09 Dietmar Maurer <dietmar@ximian.com>
17177 * aot.c (mono_aot_get_method): register all used strings
17179 Wed Apr 9 15:22:18 CEST 2003 Paolo Molaro <lupus@ximian.com>
17181 * mini.c: always intern strings references with ldstr at compile time.
17183 Tue Apr 8 11:41:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
17185 * Makefile.am: add BUILT_SOURCES.
17187 Mon Apr 7 16:31:34 CEST 2003 Paolo Molaro <lupus@ximian.com>
17189 * driver.c: give a better error message when the assembly to execute
17190 doesn't have an entry point.
17192 2003-04-07 Dietmar Maurer <dietmar@ximian.com>
17194 * Makefile.am: added hack for automake
17196 * mono/mini/mini.c (mono_save_args): always copy arguments to keep
17199 * mono/mini/ssa.c (mono_ssa_avoid_copies): don't optimize calls
17201 22003-04-07 Martin Baulig <martin@ximian.com>
17203 * Makefile.am: Added Makefile.am.
17205 * debugger-main.c: Removed, this is now in the debugger where it
17208 * mini.pc.in: Call this package `mini' for the moment.