/* pop 3 push 4 dup */
case ICMD_DUP_X2:
- if (IS_2_WORD_TYPE(curstack[-1].type)) {
+ if (IS_2_WORD_TYPE(curstack->prev->type)) {
iptr->opc = ICMD_DUP_X1;
DUP_X1;
}
case ICMD_DUP2_X2:
if (IS_2_WORD_TYPE(curstack->type)) {
- if (IS_2_WORD_TYPE(curstack[-1].type)) {
+ if (IS_2_WORD_TYPE(curstack->prev->type)) {
iptr->opc = ICMD_DUP_X1;
DUP_X1;
}
}
}
else
- if (IS_2_WORD_TYPE(curstack[-2].type)) {
+ if (IS_2_WORD_TYPE(curstack->prev->prev->type)) {
iptr->opc = ICMD_DUP2_X1;
DUP2_X1;
}
xtable *ex;
printf("\n");
- unicode_fprint(stdout, class->name);
+ utf_fprint(stdout, class->name);
printf(".");
- unicode_fprint(stdout, method->name);
+ utf_fprint(stdout, method->name);
printf(" ");
- unicode_fprint(stdout, method->descriptor);
+ utf_fprint(stdout, method->descriptor);
printf ("\n\nMax locals: %d\n", (int) maxlocals);
printf ("Max stack: %d\n", (int) maxstack);
printf("\n");
if (showdisassemble) {
+#ifdef __I386__
+ extern s4 *codestatic;
+ extern int pstatic;
+
+ s4ptr = (s4 *) (method->mcode + dseglen);
+ for (i = 0; i < block[0].mpc; i++, ((s4) s4ptr)++) {
+ disassinstr((s4) s4ptr, i);
+ i = pstatic;
+ s4ptr = codestatic;
+ }
+ printf("\n");
+#else
s4ptr = (s4 *) (method->mcode + dseglen);
for (i = 0; i < block[0].mpc; i += 4, s4ptr++) {
disassinstr(*s4ptr, i);
}
printf("\n");
+#endif
}
case ICMD_PUTSTATIC:
case ICMD_GETSTATIC:
printf(" ");
- unicode_fprint(stdout,
+ utf_fprint(stdout,
((fieldinfo *) iptr->val.a)->name);
break;
case ICMD_IINC:
break;
case ICMD_NEW:
printf(" ");
- unicode_fprint(stdout,
+ utf_fprint(stdout,
((classinfo *) iptr->val.a)->name);
break;
case ICMD_NEWARRAY:
case ICMD_ANEWARRAY:
if (iptr->op1) {
printf(" ");
- unicode_fprint(stdout,
+ utf_fprint(stdout,
((classinfo *) iptr->val.a)->name);
}
break;
printf(" (INTERFACE) ");
else
printf(" (CLASS,%3d) ", c->vftbl->diffval);
- unicode_fprint(stdout, c->name);
+ utf_fprint(stdout, c->name);
}
break;
case ICMD_BUILTIN3:
case ICMD_INVOKESTATIC:
case ICMD_INVOKEINTERFACE:
printf(" ");
- unicode_fprint(stdout,
+ utf_fprint(stdout,
((methodinfo *) iptr->val.a)->class->name);
printf(".");
- unicode_fprint(stdout,
+ utf_fprint(stdout,
((methodinfo *) iptr->val.a)->name);
break;
case ICMD_IFEQ:
}
if (showdisassemble && (!deadcode)) {
+#ifdef __I386__
+ extern s4 *codestatic;
+ extern int pstatic;
+
+ printf("\n");
+ i = bptr->mpc;
+ s4ptr = (s4 *) (method->mcode + dseglen + i);
+
+ if (bptr->next != NULL) {
+ for (; i < bptr->next->mpc; i++, ((s4) s4ptr)++) {
+ disassinstr((s4) s4ptr, i);
+ i = pstatic;
+ s4ptr = codestatic;
+ }
+ printf("\n");
+
+ } else {
+ for (; s4ptr < (s4 *) (method->mcode + method->mcodelength); i++, ((s4) s4ptr)++) {
+ disassinstr((s4) s4ptr, i);
+ i = pstatic;
+ s4ptr = codestatic;
+ }
+ printf("\n");
+ }
+#else
printf("\n");
i = bptr->mpc;
s4ptr = (s4 *) (method->mcode + dseglen + i);
}
printf("\n");
}
+#endif
}
}