All pastes #1228430 Raw Edit

Untitled

public diff v1 · immutable
#1228430 ·published 2008-10-16 15:19 UTC
rendered paste body
Index: inssel.brg===================================================================--- inssel.brg	(revision 116003)+++ inssel.brg	(working copy)@@ -781,6 +781,10 @@ stmt: OP_NOP "0" { } +stmp: OP_HARD_NOP "0" {+	mono_bblock_add_inst (s->cbb, tree);+}+ stmt: OP_BREAK "0" { 	mono_bblock_add_inst (s->cbb, tree); }Index: mini.c===================================================================--- mini.c	(revision 116003)+++ mini.c	(working copy)@@ -5233,6 +5233,7 @@ 	MonoDeclSecurityActions actions; 	GSList *class_inits = NULL; 	gboolean dont_verify, dont_verify_stloc, readonly = FALSE;+	gboolean use_hard_nops = FALSE; 	int context_used;  	/* serialization and xdomain stuff may need access to private fields and methods */@@ -5276,6 +5277,9 @@ 	if (!dont_verify && mini_method_verify (cfg, method_definition)) 		goto exception_exit; +	if (mono_debug_using_mono_debugger ())+		use_hard_nops = TRUE;+ 	if (sig->is_inflated) 		generic_context = mono_method_get_context (method); 	else if (generic_container)@@ -5683,7 +5687,10 @@  		switch (*ip) { 		case CEE_NOP:-			MONO_INST_NEW (cfg, ins, OP_NOP);+			if (use_hard_nops)+				MONO_INST_NEW (cfg, ins, OP_HARD_NOP);+			else+				MONO_INST_NEW (cfg, ins, OP_NOP); 			ip++; 			MONO_ADD_INS (bblock, ins); 			break;Index: mini-amd64.c===================================================================--- mini-amd64.c	(revision 116003)+++ mini-amd64.c	(working copy)@@ -3347,6 +3347,9 @@ 			x86_prefix (code, X86_REP_PREFIX); 			x86_nop (code); 			break;+		case OP_HARD_NOP:+			x86_nop (code);+			break; 		case OP_NOP: 		case OP_DUMMY_USE: 		case OP_DUMMY_STORE:Index: ChangeLog===================================================================--- ChangeLog	(revision 116003)+++ ChangeLog	(working copy)@@ -1,3 +1,12 @@+2008-10-16  Martin Baulig  <martin@ximian.com>++	* mini-ops.h, cpu-amd64.md, cpu-x86.md: Added new `debugger_nop' opcode.++	* inssel.brg: Add `OP_DEBUGGER_NOP'.++	* mini.c: In `CEE_NOP': generate a `OP_DEBUGGER_NOP' instruction+	when running inside the debugger.+ 2008-10-15  Rodrigo Kumpera  <rkumpera@novell.com>  	* simd-intrinsics.c (get_simd_vreg): Using sreg1 of OP_XMOVEIndex: cpu-x86.md===================================================================--- cpu-x86.md	(revision 116003)+++ cpu-x86.md	(working copy)@@ -310,6 +310,7 @@ memory_barrier: len:16  relaxed_nop: len:2+hard_nop: len:1  # Linear IR opcodes nop: len:0Index: mini-x86.c===================================================================--- mini-x86.c	(revision 116003)+++ mini-x86.c	(working copy)@@ -2375,6 +2375,9 @@ 			x86_prefix (code, X86_REP_PREFIX); 			x86_nop (code); 			break;+ 		case OP_HARD_NOP:+			x86_nop (code);+			break;  		case OP_NOP:  		case OP_DUMMY_USE:  		case OP_DUMMY_STORE:Index: mini-ops.h===================================================================--- mini-ops.h	(revision 116003)+++ mini-ops.h	(working copy)@@ -5,6 +5,7 @@ MINI_OP(OP_OBJADDR,	"objaddr", NONE, NONE, NONE) MINI_OP(OP_VTADDR,	"vtaddr", NONE, NONE, NONE) MINI_OP(OP_NOP,     "nop", NONE, NONE, NONE)+MINI_OP(OP_HARD_NOP,    "hard_nop", NONE, NONE, NONE) MINI_OP(OP_RELAXED_NOP,     "relaxed_nop", NONE, NONE, NONE) MINI_OP(OP_PHI,		"phi", IREG, NONE, NONE) MINI_OP(OP_FPHI,	"fphi", FREG, NONE, NONE)Index: cpu-amd64.md===================================================================--- cpu-amd64.md	(revision 116003)+++ cpu-amd64.md	(working copy)@@ -383,6 +383,7 @@ int_ble_un: len:8  relaxed_nop: len:2+hard_nop: len:1  # Linear IR opcodes nop: len:0