jit/jit-rules.h, tools/gen-sel-parser.y: fix some compile issues
in the x86 native back end.
+ * jit/jit-function.c, jit/jit-rules-x86.c, jit/jit-rules-x86.sel,
+ tools/gen-sel-parser.y: more bug fixes for the x86 back end.
+
2004-05-25 Rhys Weatherley <rweather@southern-storm.com.au>
* tools/.cvsignore, tools/Makefile.am, tools/gen-sel-parser.y,
/* Restore the backtrace and "setjmp" contexts and exit */
_jit_unwind_pop_setjmp();
- return 0;
+ return 1;
}
#endif /* !JIT_BACKEND_INTERP */
{
/* If the epilog is the next thing that we will output,
then fall through to the epilog directly */
- if(!(block->next))
+ block = block->next;
+ while(block != 0 && block->first_insn > block->last_insn)
+ {
+ block = block->next;
+ }
+ if(!block)
{
return inst;
}
[] -> {
/* TODO */
}
+
+/*
+ * Stack pushes and pops.
+ */
+
+JIT_OP_PUSH_INT: unary_branch
+ [imm] -> {
+ x86_push_imm(inst, $1);
+ }
+ [local] -> {
+ x86_push_membase(inst, X86_EBP, $1);
+ }
+ [reg] -> {
+ x86_push_reg(inst, $1);
+ }
+
+JIT_OP_PUSH_LONG:
+ [] -> {
+ /* TODO */
+ }
+
+JIT_OP_PUSH_FLOAT32:
+ [] -> {
+ /* TODO */
+ }
+
+JIT_OP_PUSH_FLOAT64:
+ [] -> {
+ /* TODO */
+ }
+
+JIT_OP_PUSH_NFLOAT:
+ [] -> {
+ /* TODO */
+ }
+
+JIT_OP_PUSH_STRUCT:
+ [] -> {
+ /* TODO */
+ }
+
+JIT_OP_POP_STACK:
+ [] -> {
+ x86_alu_reg_imm(inst, X86_ADD, X86_ESP, insn->value1->address);
+ }
+
+JIT_OP_FLUSH_SMALL_STRUCT:
+ [] -> {
+ /* TODO */
+ }
case GENSEL_PATT_IMMS16:
case GENSEL_PATT_IMMU16:
{
- printf("\t\timm_value = %s->is_nint_constant;\n", arg);
+ printf("\t\timm_value = %s->address;\n", arg);
}
break;