* src/vm/jit/jit.cpp: Eliminate one instance of useless cache flushing.
[cacao.git] / src / vm / jit / show.cpp
index d4dad98c7c069427575e10ea835afc917db2e0b7..6210c59b98da1b3f56bb2926af711d5d27f9b20b 100644 (file)
@@ -30,7 +30,7 @@
 
 #include "vm/types.h"
 
-#include "mm/memory.h"
+#include "mm/memory.hpp"
 
 #include "threads/lock.hpp"
 
@@ -45,7 +45,7 @@
 #include "vm/jit/show.hpp"
 #include "vm/jit/disass.h"
 #include "vm/jit/stack.h"
-#include "vm/jit/parse.h"
+#include "vm/jit/parse.hpp"
 
 #if defined(ENABLE_DEBUG_FILTER)
 # include <sys/types.h>
@@ -192,7 +192,7 @@ void show_method(jitdata *jd, int stage)
        }
 
        if (stage >= SHOW_PARSE) {
-               printf("Exceptions (Number: %d):\n", jd->exceptiontablelength);
+               printf("Exceptions (number=%d):\n", jd->exceptiontablelength);
                for (ex = jd->exceptiontable; ex != NULL; ex = ex->down) {
                        printf("    L%03d ... ", ex->start->nr );
                        printf("L%03d  = ", ex->end->nr);
@@ -214,7 +214,7 @@ void show_method(jitdata *jd, int stage)
                for (i = 0; i < jd->localcount; i++) {
                        printf("   %3d: ", i);
 
-#if defined(ENABLE_JIT) && defined(ENABLE_DISASSEMBLER)
+#if defined(ENABLE_JIT)
 # if defined(ENABLE_INTRP)
                        if (!opt_intrp) {
 # endif
@@ -225,7 +225,7 @@ void show_method(jitdata *jd, int stage)
 # if defined(ENABLE_INTRP)
                        }
 # endif
-#endif /* defined(ENABLE_JIT) && defined(ENABLE_DISASSEMBLER) */
+#endif /* defined(ENABLE_JIT) */
                }
                printf("\n");
        }
@@ -311,12 +311,12 @@ void show_method(jitdata *jd, int stage)
                int max;
 
                max = rd->memuse;
-               printf("Stack slots: (memuse=%d", rd->memuse);
+               printf("Stack slots (memuse=%d", rd->memuse);
                if (irstage >= SHOW_CODE) {
                        printf(", stackframesize=%d", cd->stackframesize);
                        max = cd->stackframesize;
                }
-               printf(")\n");
+               printf("):\n");
                for (i = 0; i < max; ++i) {
                        printf("    M%02d = 0x%02x(sp): ", i, i * 8);
                        for (j = 0; j < jd->vartop; ++j) {
@@ -333,6 +333,13 @@ void show_method(jitdata *jd, int stage)
                printf("\n");
        }
 
+       if (!code->patchers->empty()) {
+               int number = code->patchers->size();
+               printf("Patcher References (number=%d):\n", number);
+               patcher_list_show(code);
+               printf("\n");
+       }
+
 #if defined(ENABLE_REPLACEMENT)
        if (code->rplpoints) {
                printf("Replacement Points:\n");
@@ -793,7 +800,7 @@ void show_allocation(s4 type, s4 flags, s4 regoff)
 
 #if defined(SUPPORT_COMBINE_INTEGER_REGISTERS)
        if (IS_2_WORD_TYPE(type)) {
-# if defined(ENABLE_JIT) && defined(ENABLE_DISASSEMBLER)
+# if defined(ENABLE_JIT)
 #  if defined(ENABLE_INTRP)
                if (opt_intrp)
                        printf("%3d/%3d", GET_LOW_REG(regoff),
@@ -810,7 +817,7 @@ void show_allocation(s4 type, s4 flags, s4 regoff)
        } 
 #endif /* defined(SUPPORT_COMBINE_INTEGER_REGISTERS) */
 
-#if defined(ENABLE_JIT) && defined(ENABLE_DISASSEMBLER)
+#if defined(ENABLE_JIT)
 # if defined(ENABLE_INTRP)
        if (opt_intrp)
                printf("%3d", regoff);