Browse Source

Remove obsolete opcodes which violate "_jit_load_opcode"'s rules.

cache-refactoring
Rhys Weatherley 21 years ago
parent
commit
26f4046e17
  1. 3
      ChangeLog
  2. 34
      include/jit/jit-opcode.h
  3. 16
      jit/jit-interp.c
  4. 2
      jit/jit-opcode.c

3
ChangeLog

@ -4,6 +4,9 @@
* jit/Makefile.am, jit/jit-cpuid-x86.c, jit/jit-cpuid-x86.h:
add an API for querying the x86 "cpuid" information.
* include/jit/jit-opcode.h, jit/jit-interp.c, jit/jit-opcode.c:
remove obsolete opcodes which violate "_jit_load_opcode"'s rules.
2004-06-08 Miroslaw Dobrzanski-Neumann <mne@mosaic-ag.com>
* jit/jit-alloc.c: fix ROUND_END_PTR so that it adds the size

34
include/jit/jit-opcode.h

@ -479,36 +479,34 @@ extern "C" {
#define JIT_OP_LOAD_ELEMENT_SHORT 0x0186
#define JIT_OP_LOAD_ELEMENT_USHORT 0x0187
#define JIT_OP_LOAD_ELEMENT_INT 0x0188
#define JIT_OP_LOAD_ELEMENT_UINT 0x0189
#define JIT_OP_LOAD_ELEMENT_LONG 0x018A
#define JIT_OP_LOAD_ELEMENT_ULONG 0x018B
#define JIT_OP_LOAD_ELEMENT_FLOAT32 0x018C
#define JIT_OP_LOAD_ELEMENT_FLOAT64 0x018D
#define JIT_OP_LOAD_ELEMENT_NFLOAT 0x018E
#define JIT_OP_STORE_ELEMENT_BYTE 0x018F
#define JIT_OP_STORE_ELEMENT_SHORT 0x0190
#define JIT_OP_STORE_ELEMENT_INT 0x0191
#define JIT_OP_STORE_ELEMENT_LONG 0x0192
#define JIT_OP_STORE_ELEMENT_FLOAT32 0x0193
#define JIT_OP_STORE_ELEMENT_FLOAT64 0x0194
#define JIT_OP_STORE_ELEMENT_NFLOAT 0x0195
#define JIT_OP_LOAD_ELEMENT_LONG 0x0189
#define JIT_OP_LOAD_ELEMENT_FLOAT32 0x018A
#define JIT_OP_LOAD_ELEMENT_FLOAT64 0x018B
#define JIT_OP_LOAD_ELEMENT_NFLOAT 0x018C
#define JIT_OP_STORE_ELEMENT_BYTE 0x018D
#define JIT_OP_STORE_ELEMENT_SHORT 0x018E
#define JIT_OP_STORE_ELEMENT_INT 0x018F
#define JIT_OP_STORE_ELEMENT_LONG 0x0190
#define JIT_OP_STORE_ELEMENT_FLOAT32 0x0191
#define JIT_OP_STORE_ELEMENT_FLOAT64 0x0192
#define JIT_OP_STORE_ELEMENT_NFLOAT 0x0193
/*
* Block operations.
*/
#define JIT_OP_MEMCPY 0x0196
#define JIT_OP_MEMMOVE 0x0197
#define JIT_OP_MEMSET 0x0198
#define JIT_OP_MEMCPY 0x0194
#define JIT_OP_MEMMOVE 0x0195
#define JIT_OP_MEMSET 0x0196
/*
* Allocate memory from the stack.
*/
#define JIT_OP_ALLOCA 0x0199
#define JIT_OP_ALLOCA 0x0197
/*
* The number of opcodes in the above list.
*/
#define JIT_OP_NUM_OPCODES 0x019A
#define JIT_OP_NUM_OPCODES 0x0198
/*
* Opcode information.

16
jit/jit-interp.c

@ -3846,14 +3846,6 @@ void _jit_run_function(jit_function_interp_t func, jit_item *args,
}
VMBREAK;
VMCASE(JIT_OP_LOAD_ELEMENT_UINT):
{
/* Load an unsigned 32-bit integer value from an array */
VM_STK_UINT1 = VM_LOAD_ELEM(jit_uint);
VM_MODIFY_PC_AND_STACK(1, 1);
}
VMBREAK;
VMCASE(JIT_OP_LOAD_ELEMENT_LONG):
{
/* Load a signed 64-bit integer value from an array */
@ -3862,14 +3854,6 @@ void _jit_run_function(jit_function_interp_t func, jit_item *args,
}
VMBREAK;
VMCASE(JIT_OP_LOAD_ELEMENT_ULONG):
{
/* Load an unsigned 64-bit integer value from an array */
VM_STK_ULONG1 = VM_LOAD_ELEM(jit_ulong);
VM_MODIFY_PC_AND_STACK(1, 1);
}
VMBREAK;
VMCASE(JIT_OP_LOAD_ELEMENT_FLOAT32):
{
/* Load a 32-bit float value from an array */

2
jit/jit-opcode.c

@ -495,9 +495,7 @@ jit_opcode_info_t const jit_opcodes[JIT_OP_NUM_OPCODES] = {
{"load_element_short", F_(INT, PTR, INT)},
{"load_element_ushort", F_(INT, PTR, INT)},
{"load_element_int", F_(INT, PTR, INT)},
{"load_element_uint", F_(INT, PTR, INT)},
{"load_element_long", F_(LONG, PTR, INT)},
{"load_element_ulong", F_(LONG, PTR, INT)},
{"load_element_float32", F_(FLOAT32, PTR, INT)},
{"load_element_float64", F_(FLOAT64, PTR, INT)},
{"load_element_nfloat", F_(NFLOAT, PTR, INT)},

Loading…
Cancel
Save