--- trunk/src/cpus/generate_head.c 2007/10/08 16:20:32 29 +++ trunk/src/cpus/generate_head.c 2007/10/08 16:20:40 30 @@ -25,7 +25,7 @@ * SUCH DAMAGE. * * - * $Id: generate_head.c,v 1.18 2006/07/20 21:53:00 debug Exp $ + * $Id: generate_head.c,v 1.23 2006/08/11 17:43:30 debug Exp $ */ #include @@ -131,32 +131,25 @@ "#define instr32(n) %s32_instr_ ## n\n\n", a); printf("#endif\n\n"); - printf("/* This is for marking a physical page as containing" - "\n combined instructions: */\n"); - printf("#define combined (cpu->cd.%s.cur_physpage->flags " - "|= COMBINATIONS)\n", a); - printf("\n#define X(n) void %s_instr_ ## n(struct cpu *cpu, \\\n" " struct %s_instr_call *ic)\n", a, a); printf("\n/*\n * nothing: Do nothing.\n *\n" " * The difference between this function and a \"nop\" " "instruction is that\n * this function does not increase " - "the program counter or the number of\n * translated " - "instructions. It is used to \"get out\" of running in " - "translated\n * mode.\n *\n" - " * IMPORTANT NOTE: Do a cpu->running_translated = 0;\n" - " * before setting cpu->cd.%s.next_ic = " - "¬hing_call;\n */\n", a); + "the program counter. It is used to \"get out\" of running in " + "translated\n * mode.\n */\n"); printf("X(nothing)\n{\n"); - printf("\tcpu->n_translated_instrs --;\n"); printf("\tcpu->cd.%s.next_ic --;\n", a); printf("}\n\n"); - /* Ugly special hack for Transputer: */ + /* Ugly special hacks for Transputer and SH[34]: */ if (strcasecmp(argv[1], "transputer") == 0) { printf("static struct %s_instr_call nothing_call = { " "instr(nothing), {0} };\n", a); + } else if (strcasecmp(argv[1], "sh") == 0) { + printf("static struct %s_instr_call nothing_call = { " + "instr(nothing), {0,0} };\n", a); } else { printf("static struct %s_instr_call nothing_call = { " "instr(nothing), {0,0,0} };\n", a);