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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gdb-7.1/] [opcodes/] [sh64-opc.h] - Diff between revs 227 and 816

Go to most recent revision | Only display areas with differences | Details | Blame | View Log

Rev 227 Rev 816
/* Declarations for SH64 opcodes.
/* Declarations for SH64 opcodes.
   Copyright (C) 2000, 2001, 2002, 2005, 2007 Free Software Foundation, Inc.
   Copyright (C) 2000, 2001, 2002, 2005, 2007 Free Software Foundation, Inc.
 
 
   This file is part of the GNU opcodes library.
   This file is part of the GNU opcodes library.
 
 
   This library is free software; you can redistribute it and/or modify
   This library is free software; you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
   it under the terms of the GNU General Public License as published by
   the Free Software Foundation; either version 3, or (at your option)
   the Free Software Foundation; either version 3, or (at your option)
   any later version.
   any later version.
 
 
   It is distributed in the hope that it will be useful, but WITHOUT
   It is distributed in the hope that it will be useful, but WITHOUT
   ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
   ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
   or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
   or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public
   License for more details.
   License for more details.
 
 
   You should have received a copy of the GNU General Public License
   You should have received a copy of the GNU General Public License
   along with this file; see the file COPYING.  If not, write to the
   along with this file; see the file COPYING.  If not, write to the
   Free Software Foundation, 51 Franklin Street - Fifth Floor, Boston,
   Free Software Foundation, 51 Franklin Street - Fifth Floor, Boston,
   MA 02110-1301, USA.  */
   MA 02110-1301, USA.  */
 
 
#ifndef _SH64_OPC_INCLUDED_H
#ifndef _SH64_OPC_INCLUDED_H
#define _SH64_OPC_INCLUDED_H
#define _SH64_OPC_INCLUDED_H
 
 
typedef enum
typedef enum
{
{
  /* A placeholder.  */
  /* A placeholder.  */
  OFFSET_NONE = 0,
  OFFSET_NONE = 0,
 
 
  /* Bit number for where to insert operand.  */
  /* Bit number for where to insert operand.  */
  OFFSET_4  = 4,
  OFFSET_4  = 4,
  OFFSET_9  = 9,
  OFFSET_9  = 9,
  OFFSET_10 = 10,
  OFFSET_10 = 10,
  OFFSET_20 = 20
  OFFSET_20 = 20
} shmedia_nibble_type;
} shmedia_nibble_type;
 
 
typedef enum {
typedef enum {
  /* First a placeholder.  */
  /* First a placeholder.  */
  A_NONE = 0,
  A_NONE = 0,
 
 
  /* Registers.  */
  /* Registers.  */
  A_GREG_M,
  A_GREG_M,
  A_GREG_N,
  A_GREG_N,
  A_GREG_D,
  A_GREG_D,
  A_FREG_G,
  A_FREG_G,
  A_FREG_H,
  A_FREG_H,
  A_FREG_F,
  A_FREG_F,
  A_DREG_G,
  A_DREG_G,
  A_DREG_H,
  A_DREG_H,
  A_DREG_F,
  A_DREG_F,
  A_FVREG_G,
  A_FVREG_G,
  A_FVREG_H,
  A_FVREG_H,
  A_FVREG_F,
  A_FVREG_F,
  A_FMREG_G,
  A_FMREG_G,
  A_FMREG_H,
  A_FMREG_H,
  A_FMREG_F,
  A_FMREG_F,
  A_FPREG_G,
  A_FPREG_G,
  A_FPREG_H,
  A_FPREG_H,
  A_FPREG_F,
  A_FPREG_F,
  A_TREG_A,
  A_TREG_A,
  A_TREG_B,
  A_TREG_B,
  A_CREG_K,
  A_CREG_K,
  A_CREG_J,
  A_CREG_J,
 
 
  /* This one is only used in a shmedia_get_operand.  */
  /* This one is only used in a shmedia_get_operand.  */
  A_IMMM,
  A_IMMM,
 
 
  /* Copy of previous register.  */
  /* Copy of previous register.  */
  A_REUSE_PREV,
  A_REUSE_PREV,
 
 
  /* Unsigned 5-bit operand.  */
  /* Unsigned 5-bit operand.  */
  A_IMMU5,
  A_IMMU5,
 
 
  /* Signed 6-bit operand.  */
  /* Signed 6-bit operand.  */
  A_IMMS6,
  A_IMMS6,
 
 
  /* Signed operand, 6 bits << 5.  */
  /* Signed operand, 6 bits << 5.  */
  A_IMMS6BY32,
  A_IMMS6BY32,
 
 
  /* Unsigned 6-bit operand.  */
  /* Unsigned 6-bit operand.  */
  A_IMMU6,
  A_IMMU6,
 
 
  /* Signed 10-bit operand.  */
  /* Signed 10-bit operand.  */
  A_IMMS10,
  A_IMMS10,
 
 
  /* Signed operand, 10 bits << 0.  */
  /* Signed operand, 10 bits << 0.  */
  A_IMMS10BY1,
  A_IMMS10BY1,
 
 
  /* Signed operand, 10 bits << 1.  */
  /* Signed operand, 10 bits << 1.  */
  A_IMMS10BY2,
  A_IMMS10BY2,
 
 
  /* Signed operand, 10 bits << 2.  */
  /* Signed operand, 10 bits << 2.  */
  A_IMMS10BY4,
  A_IMMS10BY4,
 
 
  /* Signed operand, 10 bits << 3.  */
  /* Signed operand, 10 bits << 3.  */
  A_IMMS10BY8,
  A_IMMS10BY8,
 
 
  /* Signed 16-bit operand.  */
  /* Signed 16-bit operand.  */
  A_IMMS16,
  A_IMMS16,
 
 
  /* Unsigned 16-bit operand.  */
  /* Unsigned 16-bit operand.  */
  A_IMMU16,
  A_IMMU16,
 
 
  /* PC-relative signed operand, 16 bits << 2, for PTA and PTB insns.  */
  /* PC-relative signed operand, 16 bits << 2, for PTA and PTB insns.  */
  A_PCIMMS16BY4,
  A_PCIMMS16BY4,
 
 
  /* PC relative signed operand, 16 bits << 2, for PT insns.  Also adjusts
  /* PC relative signed operand, 16 bits << 2, for PT insns.  Also adjusts
     the opcode to be PTA or PTB.  */
     the opcode to be PTA or PTB.  */
  A_PCIMMS16BY4_PT,
  A_PCIMMS16BY4_PT,
} shmedia_arg_type;
} shmedia_arg_type;
 
 
typedef struct {
typedef struct {
  char *name;
  char *name;
  shmedia_arg_type arg[4];
  shmedia_arg_type arg[4];
  shmedia_nibble_type nibbles[4];
  shmedia_nibble_type nibbles[4];
  unsigned long opcode_base;
  unsigned long opcode_base;
} shmedia_opcode_info;
} shmedia_opcode_info;
 
 
extern const shmedia_opcode_info shmedia_table[];
extern const shmedia_opcode_info shmedia_table[];
 
 
typedef struct {
typedef struct {
  int cregno;
  int cregno;
  char *name;
  char *name;
} shmedia_creg_info;
} shmedia_creg_info;
 
 
extern const shmedia_creg_info shmedia_creg_table[];
extern const shmedia_creg_info shmedia_creg_table[];
 
 
#define SHMEDIA_LIKELY_BIT    0x00000200
#define SHMEDIA_LIKELY_BIT    0x00000200
#define SHMEDIA_PT_OPC        0xe8000000
#define SHMEDIA_PT_OPC        0xe8000000
#define SHMEDIA_PTB_BIT       0x04000000
#define SHMEDIA_PTB_BIT       0x04000000
#define SHMEDIA_PTA_OPC       0xe8000000
#define SHMEDIA_PTA_OPC       0xe8000000
#define SHMEDIA_PTB_OPC       0xec000000
#define SHMEDIA_PTB_OPC       0xec000000
 
 
/* Note that this is ptrel/u.  "Or" in SHMEDIA_LIKELY_BIT for ptrel/l.  */
/* Note that this is ptrel/u.  "Or" in SHMEDIA_LIKELY_BIT for ptrel/l.  */
#define SHMEDIA_PTREL_OPC     0x6bf50000
#define SHMEDIA_PTREL_OPC     0x6bf50000
#define SHMEDIA_MOVI_OPC      0xcc000000
#define SHMEDIA_MOVI_OPC      0xcc000000
#define SHMEDIA_SHORI_OPC     0xc8000000
#define SHMEDIA_SHORI_OPC     0xc8000000
#define SHMEDIA_ADDI_OPC      0xd0000000
#define SHMEDIA_ADDI_OPC      0xd0000000
#define SHMEDIA_ADD_OPC       0x00090000
#define SHMEDIA_ADD_OPC       0x00090000
#define SHMEDIA_NOP_OPC       0x6ff0fff0
#define SHMEDIA_NOP_OPC       0x6ff0fff0
#define SHMEDIA_TEMP_REG      25
#define SHMEDIA_TEMP_REG      25
 
 
#endif /* _SH64_OPC_INCLUDED_H */
#endif /* _SH64_OPC_INCLUDED_H */
 
 

powered by: WebSVN 2.1.0

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