Author: zoltan
Date: 2007-05-19 15:57:07 -0400 (Sat, 19 May 2007)
New Revision: 77698
Modified:
trunk/mono/mono/mini/ChangeLog
trunk/mono/mono/mini/mini-codegen.c
Log:
2007-05-19 Zoltan Varga <[EMAIL PROTECTED]>
* mini-codegen.c (mono_local_regalloc): Fix long-shift-regalloc on
amd64.
Modified: trunk/mono/mono/mini/ChangeLog
===================================================================
--- trunk/mono/mono/mini/ChangeLog 2007-05-19 19:51:12 UTC (rev 77697)
+++ trunk/mono/mono/mini/ChangeLog 2007-05-19 19:57:07 UTC (rev 77698)
@@ -1,3 +1,7 @@
+2007-05-19 Zoltan Varga <[EMAIL PROTECTED]>
+
+ * mini-codegen.c (mono_local_regalloc): Fix long-shift-regalloc on
amd64.
+
2007-05-15 Massimiliano Mantione <[EMAIL PROTECTED]>
* inssel.brg: added "mini_emit_load_intf_bit_reg_vtable", and used it
Modified: trunk/mono/mono/mini/mini-codegen.c
===================================================================
--- trunk/mono/mono/mini/mini-codegen.c 2007-05-19 19:51:12 UTC (rev 77697)
+++ trunk/mono/mono/mini/mini-codegen.c 2007-05-19 19:57:07 UTC (rev 77698)
@@ -1138,8 +1138,18 @@
insert_before_ins (ins, tmp, copy);
}
else {
- DEBUG (printf ("\tshortcut assignment
of R%d to %s\n", ins->sreg2, mono_arch_regname (dest_sreg2)));
- assign_ireg (cfg, rs, ins->sreg2,
dest_sreg2);
+ val = rs->vassign [ins->sreg2];
+ if (val == -1) {
+ DEBUG (printf ("\tshortcut
assignment of R%d to %s\n", ins->sreg2, mono_arch_regname (dest_sreg2)));
+ assign_reg (cfg, rs,
ins->sreg2, dest_sreg2, FALSE);
+ } else if (val < -1) {
+ /* FIXME: */
+ g_assert_not_reached ();
+ } else {
+ /* Argument already in hard
reg, need to copy */
+ MonoInst *copy =
create_copy_ins (cfg, dest_sreg2, val, NULL, ip, FALSE);
+ insert_before_ins (ins, tmp,
copy);
+ }
}
} else {
int need_spill = TRUE;
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches