Commit 21ab0038d184a4ac51f62b607e0ac3f8d58bce40 wip/jit
authorMichel Pollet <buserror@gmail.com>
Wed, 10 Jan 2018 09:52:39 +0000 (09:52 +0000)
committerMichel Pollet <buserror@gmail.com>
Wed, 10 Jan 2018 10:06:22 +0000 (10:06 +0000)
Merging that changes from the main branch

Signed-off-by: Michel Pollet <buserror@gmail.com>
2 files changed:
simavr/sim/sim_core.c
simavr/sim/sim_core_jit.h

index 23ba093b3808468bfad120aeeb2cd90c0d28c725..11438393f00ec4d66bbaabd262e7ccc261e2655d 100644 (file)
@@ -1416,11 +1416,11 @@ run_one_again:
                case 0xf000: {
                        switch (opcode & 0xfe00) {
                                case 0xf100: {  /* simavr special opcodes */
-                                       if (opcode == 0xf1f1) { // AVR_OVERFLOW_OPCODE
+                                       if (opcode == 0xf1f1) emit { // AVR_OVERFLOW_OPCODE
                                                printf("FLASH overflow, soft reset\n");
                                                new_pc = 0;
                                                TRACE_JUMP();
-                                       }
+                                       } end_emit;
                                }       break;
                                case 0xf000:
                                case 0xf200:
index 80d4fe901c6b3c9cef3734924794cffe3fbd38c5..4ad749704c8507c174538252034cd6f4d2887613 100644 (file)
@@ -872,6 +872,15 @@ jit_generate(opcode, 0+F_OP,
 
                case 0xf000: {
                        switch (opcode & 0xfe00) {
+                               case 0xf100: {  /* simavr special opcodes */
+                                       if (opcode == 0xf1f1)  { // AVR_OVERFLOW_OPCODE
+jit_generate(opcode, 0+F_JUMP+F_NO_PC,
+"printf(\"FLASH overflow, soft reset\\n\");\n"
+"new_pc = 0;\n"
+"TRACE_JUMP();\n"
+);
+                                       } break;
+                               }       break;
                                case 0xf000:
                                case 0xf200:
                                case 0xf400: