OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [branches/] [stable_0_1_x/] [or1ksim/] [cpu/] [or1k/] [opcode/] [or32.h] - Diff between revs 1338 and 1341

Go to most recent revision | Show entire file | Details | Blame | View Log

Rev 1338 Rev 1341
Line 59... Line 59...
  /* A string of characters which describe the operands.
  /* A string of characters which describe the operands.
     Valid characters are:
     Valid characters are:
     ,() Itself.  Characters appears in the assembly code.
     ,() Itself.  Characters appears in the assembly code.
     rA  Register operand.
     rA  Register operand.
     rB  Register operand.
     rB  Register operand.
     rD  Register operand.
     rD  Register operand (destination).
     I   An immediate operand, range -32768 to 32767.
     I   An immediate operand, range -32768 to 32767.
     J   An immediate operand, range . (unused)
     J   An immediate operand, range . (unused)
     K   An immediate operand, range 0 to 65535.
     K   An immediate operand, range 0 to 65535.
     L   An immediate operand, range 0 to 63.
     L   An immediate operand, range 0 to 63.
     M   An immediate operand, range . (unused)
     M   An immediate operand, range . (unused)
Line 72... Line 72...
  char *args;
  char *args;
 
 
  /* Opcode and operand encoding. */
  /* Opcode and operand encoding. */
  char *encoding;
  char *encoding;
 
 
#if defined HAS_EXECUTION && !SIMPLE_EXECUTION
#if defined(HAS_EXECUTION) && !SIMPLE_EXECUTION
  char *function_name;
  char *function_name;
#else /* defined HAS_EXECUTION && !SIMPLE_EXECUTION */
#else /* defined HAS_EXECUTION && !SIMPLE_EXECUTION */
  void (*exec)();
  void (*exec)();
#endif /* defined HAS_EXECUTION && !SIMPLE_EXECUTION */
#endif /* defined HAS_EXECUTION && !SIMPLE_EXECUTION */
 
 
  unsigned int flags;
  unsigned int flags;
};
};
 
 
 
/* This operand is the last in the list */
#define OPTYPE_LAST (0x80000000)
#define OPTYPE_LAST (0x80000000)
 
/* This operand marks the end of the operand sequence (for things like I(rD)) */
#define OPTYPE_OP   (0x40000000)
#define OPTYPE_OP   (0x40000000)
 
/* The operand specifies a register index */
#define OPTYPE_REG  (0x20000000)
#define OPTYPE_REG  (0x20000000)
 
/* The operand must be sign extended */
#define OPTYPE_SIG  (0x10000000)
#define OPTYPE_SIG  (0x10000000)
 
/* Operand is a relative address, the `I' in `I(rD)' */
#define OPTYPE_DIS  (0x08000000)
#define OPTYPE_DIS  (0x08000000)
 
/* The operand is a destination */
#define OPTYPE_DST  (0x04000000)
#define OPTYPE_DST  (0x04000000)
 
/* Which bit of the operand is the sign bit */
#define OPTYPE_SBIT (0x00001F00)
#define OPTYPE_SBIT (0x00001F00)
 
/* Amount to shift the instruction word right to get the operand */
#define OPTYPE_SHR  (0x0000001F)
#define OPTYPE_SHR  (0x0000001F)
#define OPTYPE_SBIT_SHR (8)
#define OPTYPE_SBIT_SHR (8)
 
 
/* MM: Data how to decode operands.  */
/* MM: Data how to decode operands.  */
extern struct insn_op_struct {
extern struct insn_op_struct {

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.