projects
/
deliverable
/
binutils-gdb.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
gdb/infrun: move a 'regcache_read_pc' call down to first use
[deliverable/binutils-gdb.git]
/
opcodes
/
m32c-ibld.c
diff --git
a/opcodes/m32c-ibld.c
b/opcodes/m32c-ibld.c
index 4d201c6bd477f6419fc35119455fc44f7e36a799..c1fca2e169813ff752f7a819f19f9054149fbb0f 100644
(file)
--- a/
opcodes/m32c-ibld.c
+++ b/
opcodes/m32c-ibld.c
@@
-1,10
+1,10
@@
+/* DO NOT EDIT! -*- buffer-read-only: t -*- vi:set ro: */
/* Instruction building/extraction support for m32c. -*- C -*-
THIS FILE IS MACHINE GENERATED WITH CGEN: Cpu tools GENerator.
- the resultant file is machine generated, cgen-ibld.in isn't
/* Instruction building/extraction support for m32c. -*- C -*-
THIS FILE IS MACHINE GENERATED WITH CGEN: Cpu tools GENerator.
- the resultant file is machine generated, cgen-ibld.in isn't
- Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2005, 2006, 2007,
- 2008, 2010 Free Software Foundation, Inc.
+ Copyright (C) 1996-2020 Free Software Foundation, Inc.
This file is part of libopcodes.
This file is part of libopcodes.
@@
-138,7
+138,7
@@
insert_normal (CGEN_CPU_DESC cd,
if (length == 0)
return NULL;
if (length == 0)
return NULL;
- if (word_length >
32
)
+ if (word_length >
8 * sizeof (CGEN_INSN_INT)
)
abort ();
/* For architectures with insns smaller than the base-insn-bitsize,
abort ();
/* For architectures with insns smaller than the base-insn-bitsize,
@@
-155,7
+155,7
@@
insert_normal (CGEN_CPU_DESC cd,
{
long minval = - (1L << (length - 1));
unsigned long maxval = mask;
{
long minval = - (1L << (length - 1));
unsigned long maxval = mask;
-
+
if ((value > 0 && (unsigned long) value > maxval)
|| value < minval)
{
if ((value > 0 && (unsigned long) value > maxval)
|| value < minval)
{
@@
-193,7
+193,7
@@
insert_normal (CGEN_CPU_DESC cd,
{
long minval = - (1L << (length - 1));
long maxval = (1L << (length - 1)) - 1;
{
long minval = - (1L << (length - 1));
long maxval = (1L << (length - 1)) - 1;
-
+
if (value < minval || value > maxval)
{
sprintf
if (value < minval || value > maxval)
{
sprintf
@@
-208,12
+208,19
@@
insert_normal (CGEN_CPU_DESC cd,
#if CGEN_INT_INSN_P
{
#if CGEN_INT_INSN_P
{
- int shift;
+ int shift
_within_word, shift_to_word, shift
;
+ /* How to shift the value to BIT0 of the word. */
+ shift_to_word = total_length - (word_offset + word_length);
+
+ /* How to shift the value to the field within the word. */
if (CGEN_INSN_LSB0_P)
if (CGEN_INSN_LSB0_P)
- shift
= (word_offset + start + 1)
- length;
+ shift
_within_word = start + 1
- length;
else
else
- shift = total_length - (word_offset + start + length);
+ shift_within_word = word_length - start - length;
+
+ /* The total SHIFT, then mask in the value. */
+ shift = shift_to_word + shift_within_word;
*buffer = (*buffer & ~(mask << shift)) | ((value & mask) << shift);
}
*buffer = (*buffer & ~(mask << shift)) | ((value & mask) << shift);
}
@@
-442,7
+449,7
@@
extract_normal (CGEN_CPU_DESC cd,
return 1;
}
return 1;
}
- if (word_length >
32
)
+ if (word_length >
8 * sizeof (CGEN_INSN_INT)
)
abort ();
/* For architectures with insns smaller than the insn-base-bitsize,
abort ();
/* For architectures with insns smaller than the insn-base-bitsize,
@@
-469,11
+476,14
@@
extract_normal (CGEN_CPU_DESC cd,
{
unsigned char *bufp = ex_info->insn_bytes + word_offset / 8;
{
unsigned char *bufp = ex_info->insn_bytes + word_offset / 8;
- if (word_length >
32
)
+ if (word_length >
8 * sizeof (CGEN_INSN_INT)
)
abort ();
if (fill_cache (cd, ex_info, word_offset / 8, word_length / 8, pc) == 0)
abort ();
if (fill_cache (cd, ex_info, word_offset / 8, word_length / 8, pc) == 0)
- return 0;
+ {
+ *valuep = 0;
+ return 0;
+ }
value = extract_1 (cd, ex_info, start, length, word_length, bufp, pc);
}
value = extract_1 (cd, ex_info, start, length, word_length, bufp, pc);
}
@@
-602,14
+612,14
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_BIT32RNPREFIXED :
{
long value = fields->f_dst32_rn_prefixed_QI;
case M32C_OPERAND_BIT32RNPREFIXED :
{
long value = fields->f_dst32_rn_prefixed_QI;
- value = (((((
((~ (value))) << (1
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
+ value = (((((
~ (((value) << (1))
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
errmsg = insert_normal (cd, value, 0, 0, 16, 2, 32, total_length, buffer);
}
break;
case M32C_OPERAND_BIT32RNUNPREFIXED :
{
long value = fields->f_dst32_rn_unprefixed_QI;
errmsg = insert_normal (cd, value, 0, 0, 16, 2, 32, total_length, buffer);
}
break;
case M32C_OPERAND_BIT32RNUNPREFIXED :
{
long value = fields->f_dst32_rn_unprefixed_QI;
- value = (((((
((~ (value))) << (1
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
+ value = (((((
~ (((value) << (1))
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
errmsg = insert_normal (cd, value, 0, 0, 8, 2, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 0, 8, 2, 32, total_length, buffer);
}
break;
@@
-619,7
+629,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_BITBASE16_16_U16 :
{
long value = fields->f_dsp_16_u16;
case M32C_OPERAND_BITBASE16_16_U16 :
{
long value = fields->f_dsp_16_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
break;
@@
-665,7
+675,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
break;
{
long value = fields->f_dsp_16_s16;
break;
{
long value = fields->f_dsp_16_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-697,7
+707,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
break;
{
long value = fields->f_dsp_16_u16;
break;
{
long value = fields->f_dsp_16_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-716,7
+726,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
break;
{
long value = fields->f_dsp_16_u16;
break;
{
long value = fields->f_dsp_16_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-805,7
+815,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
break;
{
long value = fields->f_dsp_32_u16;
break;
{
long value = fields->f_dsp_32_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 32, 0, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 32, 0, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-827,7
+837,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DSP_16_S16 :
{
long value = fields->f_dsp_16_s16;
case M32C_OPERAND_DSP_16_S16 :
{
long value = fields->f_dsp_16_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, buffer);
}
break;
@@
-837,7
+847,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DSP_16_U16 :
{
long value = fields->f_dsp_16_u16;
case M32C_OPERAND_DSP_16_U16 :
{
long value = fields->f_dsp_16_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
break;
@@
-849,7
+859,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
}
{
long value = fields->f_dsp_16_u16;
}
{
long value = fields->f_dsp_16_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-867,7
+877,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
}
{
long value = fields->f_dsp_16_u16;
}
{
long value = fields->f_dsp_16_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-922,7
+932,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
break;
{
long value = fields->f_dsp_32_u16;
break;
{
long value = fields->f_dsp_32_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 32, 0, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 32, 0, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-940,7
+950,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
break;
{
long value = fields->f_dsp_32_u16;
break;
{
long value = fields->f_dsp_32_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 32, 0, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 32, 0, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-953,7
+963,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DSP_32_S16 :
{
long value = fields->f_dsp_32_s16;
case M32C_OPERAND_DSP_32_S16 :
{
long value = fields->f_dsp_32_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 16, 32, total_length, buffer);
}
break;
@@
-963,7
+973,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DSP_32_U16 :
{
long value = fields->f_dsp_32_u16;
case M32C_OPERAND_DSP_32_U16 :
{
long value = fields->f_dsp_32_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 32, 0, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 32, 0, 16, 32, total_length, buffer);
}
break;
@@
-987,7
+997,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DSP_40_S16 :
{
long value = fields->f_dsp_40_s16;
case M32C_OPERAND_DSP_40_S16 :
{
long value = fields->f_dsp_40_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 8, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 8, 16, 32, total_length, buffer);
}
break;
@@
-997,7
+1007,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DSP_40_U16 :
{
long value = fields->f_dsp_40_u16;
case M32C_OPERAND_DSP_40_U16 :
{
long value = fields->f_dsp_40_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 32, 8, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 32, 8, 16, 32, total_length, buffer);
}
break;
@@
-1021,7
+1031,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DSP_48_S16 :
{
long value = fields->f_dsp_48_s16;
case M32C_OPERAND_DSP_48_S16 :
{
long value = fields->f_dsp_48_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 16, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 16, 16, 32, total_length, buffer);
}
break;
@@
-1031,7
+1041,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DSP_48_U16 :
{
long value = fields->f_dsp_48_u16;
case M32C_OPERAND_DSP_48_U16 :
{
long value = fields->f_dsp_48_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 32, 16, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 32, 16, 16, 32, total_length, buffer);
}
break;
@@
-1043,7
+1053,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
}
{
long value = fields->f_dsp_48_u16;
}
{
long value = fields->f_dsp_48_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 32, 16, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 32, 16, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-1061,7
+1071,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
}
{
long value = fields->f_dsp_48_u16;
}
{
long value = fields->f_dsp_48_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 32, 16, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 32, 16, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-1077,7
+1087,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DSP_8_S24 :
{
long value = fields->f_dsp_8_s24;
case M32C_OPERAND_DSP_8_S24 :
{
long value = fields->f_dsp_8_s24;
- value = ((((((
USI) (value) >> (16))) | (((value) & (65280))))) | (((EXTQISI (TRUNCSIQI (((value) & (255))))) << (16))
));
+ value = ((((((
((((((USI) (value) >> (16))) & (255))) | (((value) & (65280))))) | (((((value) & (255))) << (16))))) ^ (8388608))) - (8388608
));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 0, 8, 24, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 0, 8, 24, 32, total_length, buffer);
}
break;
@@
-1087,7
+1097,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DSP_8_U16 :
{
long value = fields->f_dsp_8_u16;
case M32C_OPERAND_DSP_8_U16 :
{
long value = fields->f_dsp_8_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 0, 8, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 0, 8, 16, 32, total_length, buffer);
}
break;
@@
-1184,7
+1194,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DST32RNPREFIXEDQI :
{
long value = fields->f_dst32_rn_prefixed_QI;
case M32C_OPERAND_DST32RNPREFIXEDQI :
{
long value = fields->f_dst32_rn_prefixed_QI;
- value = (((((
((~ (value))) << (1
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
+ value = (((((
~ (((value) << (1))
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
errmsg = insert_normal (cd, value, 0, 0, 16, 2, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 0, 16, 2, 32, total_length, buffer);
}
break;
@@
-1205,7
+1215,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_DST32RNUNPREFIXEDQI :
{
long value = fields->f_dst32_rn_unprefixed_QI;
case M32C_OPERAND_DST32RNUNPREFIXEDQI :
{
long value = fields->f_dst32_rn_unprefixed_QI;
- value = (((((
((~ (value))) << (1
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
+ value = (((((
~ (((value) << (1))
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
errmsg = insert_normal (cd, value, 0, 0, 8, 2, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 0, 8, 2, 32, total_length, buffer);
}
break;
@@
-1230,7
+1240,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_IMM_16_HI :
{
long value = fields->f_dsp_16_s16;
case M32C_OPERAND_IMM_16_HI :
{
long value = fields->f_dsp_16_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, buffer);
}
break;
@@
-1245,14
+1255,14
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
}
{
long value = fields->f_dsp_16_u16;
}
{
long value = fields->f_dsp_16_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
break;
{
long value = fields->f_dsp_32_u16;
errmsg = insert_normal (cd, value, 0, 0, 16, 16, 32, total_length, buffer);
}
if (errmsg)
break;
{
long value = fields->f_dsp_32_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 32, 0, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 32, 0, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-1300,7
+1310,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_IMM_32_HI :
{
long value = fields->f_dsp_32_s16;
case M32C_OPERAND_IMM_32_HI :
{
long value = fields->f_dsp_32_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 16, 32, total_length, buffer);
}
break;
@@
-1310,14
+1320,14
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_IMM_32_SI :
{
long value = fields->f_dsp_32_s32;
case M32C_OPERAND_IMM_32_SI :
{
long value = fields->f_dsp_32_s32;
- value = EXTSISI (((((((((UINT) (value) >> (24))) & (255))) | (((((UINT) (value) >> (8))) & (65280))))) | (((((((value)
<< (8))) & (16711680))) | (((((value) << (24))) & (0xff000000
)))))));
+ value = EXTSISI (((((((((UINT) (value) >> (24))) & (255))) | (((((UINT) (value) >> (8))) & (65280))))) | (((((((value)
& (65280))) << (8))) | (((((value) & (255))) << (24
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 32, 32, total_length, buffer);
}
break;
case M32C_OPERAND_IMM_40_HI :
{
long value = fields->f_dsp_40_s16;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 32, 32, total_length, buffer);
}
break;
case M32C_OPERAND_IMM_40_HI :
{
long value = fields->f_dsp_40_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 8, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 8, 16, 32, total_length, buffer);
}
break;
@@
-1345,7
+1355,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_IMM_48_HI :
{
long value = fields->f_dsp_48_s16;
case M32C_OPERAND_IMM_48_HI :
{
long value = fields->f_dsp_48_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 16, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 32, 16, 16, 32, total_length, buffer);
}
break;
@@
-1360,14
+1370,14
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
}
{
long value = fields->f_dsp_48_u16;
}
{
long value = fields->f_dsp_48_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 32, 16, 16, 32, total_length, buffer);
}
if (errmsg)
break;
{
long value = fields->f_dsp_64_u16;
errmsg = insert_normal (cd, value, 0, 32, 16, 16, 32, total_length, buffer);
}
if (errmsg)
break;
{
long value = fields->f_dsp_64_u16;
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
errmsg = insert_normal (cd, value, 0, 64, 0, 16, 32, total_length, buffer);
}
if (errmsg)
errmsg = insert_normal (cd, value, 0, 64, 0, 16, 32, total_length, buffer);
}
if (errmsg)
@@
-1394,14
+1404,14
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_IMM_64_HI :
{
long value = fields->f_dsp_64_s16;
case M32C_OPERAND_IMM_64_HI :
{
long value = fields->f_dsp_64_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 64, 0, 16, 32, total_length, buffer);
}
break;
case M32C_OPERAND_IMM_8_HI :
{
long value = fields->f_dsp_8_s16;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 64, 0, 16, 32, total_length, buffer);
}
break;
case M32C_OPERAND_IMM_8_HI :
{
long value = fields->f_dsp_8_s16;
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 0, 8, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGNED), 0, 8, 16, 32, total_length, buffer);
}
break;
@@
-1482,7
+1492,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_LAB_8_16 :
{
long value = fields->f_lab_8_16;
case M32C_OPERAND_LAB_8_16 :
{
long value = fields->f_lab_8_16;
- value = ((((((((value) - (((pc) + (1))))) & (255))) << (8))) | (((USI) (((((value) - (((pc) + (1))))) & (65
535
))) >> (8))));
+ value = ((((((((value) - (((pc) + (1))))) & (255))) << (8))) | (((USI) (((((value) - (((pc) + (1))))) & (65
280
))) >> (8))));
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGN_OPT)|(1<<CGEN_IFLD_PCREL_ADDR), 0, 8, 16, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0|(1<<CGEN_IFLD_SIGN_OPT)|(1<<CGEN_IFLD_PCREL_ADDR), 0, 8, 16, 32, total_length, buffer);
}
break;
@@
-1596,7
+1606,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_SRC32RNPREFIXEDQI :
{
long value = fields->f_src32_rn_prefixed_QI;
case M32C_OPERAND_SRC32RNPREFIXEDQI :
{
long value = fields->f_src32_rn_prefixed_QI;
- value = (((((
((~ (value))) << (1
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
+ value = (((((
~ (((value) << (1))
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
errmsg = insert_normal (cd, value, 0, 0, 18, 2, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 0, 18, 2, 32, total_length, buffer);
}
break;
@@
-1617,7
+1627,7
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
case M32C_OPERAND_SRC32RNUNPREFIXEDQI :
{
long value = fields->f_src32_rn_unprefixed_QI;
case M32C_OPERAND_SRC32RNUNPREFIXEDQI :
{
long value = fields->f_src32_rn_unprefixed_QI;
- value = (((((
((~ (value))) << (1
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
+ value = (((((
~ (((value) << (1))
))) & (2))) | (((((USI) (value) >> (1))) & (1))));
errmsg = insert_normal (cd, value, 0, 0, 10, 2, 32, total_length, buffer);
}
break;
errmsg = insert_normal (cd, value, 0, 0, 10, 2, 32, total_length, buffer);
}
break;
@@
-1725,8
+1735,9
@@
m32c_cgen_insert_operand (CGEN_CPU_DESC cd,
default :
/* xgettext:c-format */
default :
/* xgettext:c-format */
- fprintf (stderr, _("Unrecognized field %d while building insn.\n"),
- opindex);
+ opcodes_error_handler
+ (_("internal error: unrecognized field %d while building insn"),
+ opindex);
abort ();
}
abort ();
}
@@
-1818,7
+1829,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_16_u16 = value;
}
break;
fields->f_dsp_16_u16 = value;
}
break;
@@
-1843,7
+1854,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 8, 32, total_length, pc, & fields->f_dsp_16_s8);
if (length <= 0) break;
{
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 8, 32, total_length, pc, & fields->f_dsp_16_s8);
if (length <= 0) break;
{
- FLD (f_bitbase32_16_s11_unprefixed) = ((((FLD (f_dsp_16_s8))
<< (3
))) | (FLD (f_bitno32_unprefixed)));
+ FLD (f_bitbase32_16_s11_unprefixed) = ((((FLD (f_dsp_16_s8))
* (8
))) | (FLD (f_bitno32_unprefixed)));
}
}
break;
}
}
break;
@@
-1854,12
+1865,12
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_16_s16 = value;
}
if (length <= 0) break;
{
fields->f_dsp_16_s16 = value;
}
if (length <= 0) break;
{
- FLD (f_bitbase32_16_s19_unprefixed) = ((((FLD (f_dsp_16_s16))
<< (3
))) | (FLD (f_bitno32_unprefixed)));
+ FLD (f_bitbase32_16_s19_unprefixed) = ((((FLD (f_dsp_16_s16))
* (8
))) | (FLD (f_bitno32_unprefixed)));
}
}
break;
}
}
break;
@@
-1881,7
+1892,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_16_u16 = value;
}
if (length <= 0) break;
fields->f_dsp_16_u16 = value;
}
if (length <= 0) break;
@@
-1897,7
+1908,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_16_u16 = value;
}
if (length <= 0) break;
fields->f_dsp_16_u16 = value;
}
if (length <= 0) break;
@@
-1915,7
+1926,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 24, 8, 32, total_length, pc, & fields->f_dsp_24_s8);
if (length <= 0) break;
{
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 24, 8, 32, total_length, pc, & fields->f_dsp_24_s8);
if (length <= 0) break;
{
- FLD (f_bitbase32_24_s11_prefixed) = ((((FLD (f_dsp_24_s8))
<< (3
))) | (FLD (f_bitno32_prefixed)));
+ FLD (f_bitbase32_24_s11_prefixed) = ((((FLD (f_dsp_24_s8))
* (8
))) | (FLD (f_bitno32_prefixed)));
}
}
break;
}
}
break;
@@
-1928,7
+1939,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 8, 32, total_length, pc, & fields->f_dsp_32_s8);
if (length <= 0) break;
{
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 8, 32, total_length, pc, & fields->f_dsp_32_s8);
if (length <= 0) break;
{
- FLD (f_bitbase32_24_s19_prefixed) = ((((FLD (f_dsp_24_u8)) << (3))) | (((((FLD (f_dsp_32_s8))
<< (11
))) | (FLD (f_bitno32_prefixed)))));
+ FLD (f_bitbase32_24_s19_prefixed) = ((((FLD (f_dsp_24_u8)) << (3))) | (((((FLD (f_dsp_32_s8))
* (2048
))) | (FLD (f_bitno32_prefixed)))));
}
}
break;
}
}
break;
@@
-1965,7
+1976,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 0, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 0, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_32_u16 = value;
}
if (length <= 0) break;
fields->f_dsp_32_u16 = value;
}
if (length <= 0) break;
@@
-1990,7
+2001,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_16_s16 = value;
}
break;
fields->f_dsp_16_s16 = value;
}
break;
@@
-2001,7
+2012,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_16_u16 = value;
}
break;
fields->f_dsp_16_u16 = value;
}
break;
@@
-2010,7
+2021,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_16_u16 = value;
}
if (length <= 0) break;
fields->f_dsp_16_u16 = value;
}
if (length <= 0) break;
@@
-2026,7
+2037,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_16_u16 = value;
}
if (length <= 0) break;
fields->f_dsp_16_u16 = value;
}
if (length <= 0) break;
@@
-2072,7
+2083,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 0, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 0, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_32_u16 = value;
}
if (length <= 0) break;
fields->f_dsp_32_u16 = value;
}
if (length <= 0) break;
@@
-2088,7
+2099,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 0, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 0, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_32_u16 = value;
}
if (length <= 0) break;
fields->f_dsp_32_u16 = value;
}
if (length <= 0) break;
@@
-2104,7
+2115,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_32_s16 = value;
}
break;
fields->f_dsp_32_s16 = value;
}
break;
@@
-2115,7
+2126,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 0, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 0, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_32_u16 = value;
}
break;
fields->f_dsp_32_u16 = value;
}
break;
@@
-2142,7
+2153,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 8, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 8, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_40_s16 = value;
}
break;
fields->f_dsp_40_s16 = value;
}
break;
@@
-2153,7
+2164,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 8, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 8, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_40_u16 = value;
}
break;
fields->f_dsp_40_u16 = value;
}
break;
@@
-2180,7
+2191,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 16, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_48_s16 = value;
}
break;
fields->f_dsp_48_s16 = value;
}
break;
@@
-2191,7
+2202,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_48_u16 = value;
}
break;
fields->f_dsp_48_u16 = value;
}
break;
@@
-2200,7
+2211,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_48_u16 = value;
}
if (length <= 0) break;
fields->f_dsp_48_u16 = value;
}
if (length <= 0) break;
@@
-2216,7
+2227,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_48_u16 = value;
}
if (length <= 0) break;
fields->f_dsp_48_u16 = value;
}
if (length <= 0) break;
@@
-2234,7
+2245,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 8, 24, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 8, 24, 32, total_length, pc, & value);
- value = ((((((
USI) (value) >> (16))) | (((value) & (65280))))) | (((EXTQISI (TRUNCSIQI (((value) & (255))))) << (16))
));
+ value = ((((((
((((((USI) (value) >> (16))) & (255))) | (((value) & (65280))))) | (((((value) & (255))) << (16))))) ^ (8388608))) - (8388608
));
fields->f_dsp_8_s24 = value;
}
break;
fields->f_dsp_8_s24 = value;
}
break;
@@
-2245,7
+2256,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 8, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 8, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_8_u16 = value;
}
break;
fields->f_dsp_8_u16 = value;
}
break;
@@
-2396,7
+2407,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 16, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_16_s16 = value;
}
break;
fields->f_dsp_16_s16 = value;
}
break;
@@
-2408,14
+2419,14
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 0, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_16_u16 = value;
}
if (length <= 0) break;
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 0, 16, 32, total_length, pc, & value);
fields->f_dsp_16_u16 = value;
}
if (length <= 0) break;
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 0, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_32_u16 = value;
}
if (length <= 0) break;
fields->f_dsp_32_u16 = value;
}
if (length <= 0) break;
@@
-2461,7
+2472,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_32_s16 = value;
}
break;
fields->f_dsp_32_s16 = value;
}
break;
@@
-2472,7
+2483,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 32, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 0, 32, 32, total_length, pc, & value);
- value = EXTSISI (((((((((UINT) (value) >> (24))) & (255))) | (((((UINT) (value) >> (8))) & (65280))))) | (((((((value)
<< (8))) & (16711680))) | (((((value) << (24))) & (0xff000000
)))))));
+ value = EXTSISI (((((((((UINT) (value) >> (24))) & (255))) | (((((UINT) (value) >> (8))) & (65280))))) | (((((((value)
& (65280))) << (8))) | (((((value) & (255))) << (24
)))))));
fields->f_dsp_32_s32 = value;
}
break;
fields->f_dsp_32_s32 = value;
}
break;
@@
-2480,7
+2491,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 8, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 8, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_40_s16 = value;
}
break;
fields->f_dsp_40_s16 = value;
}
break;
@@
-2507,7
+2518,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 32, 16, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_48_s16 = value;
}
break;
fields->f_dsp_48_s16 = value;
}
break;
@@
-2519,19
+2530,19
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 16, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 32, 16, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_48_u16 = value;
}
if (length <= 0) break;
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 64, 0, 16, 32, total_length, pc, & value);
fields->f_dsp_48_u16 = value;
}
if (length <= 0) break;
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0, 64, 0, 16, 32, total_length, pc, & value);
- value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
))));
+ value = ((((((UHI) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
))));
fields->f_dsp_64_u16 = value;
}
if (length <= 0) break;
{
fields->f_dsp_64_u16 = value;
}
if (length <= 0) break;
{
- FLD (f_dsp_48_s32) = ((((FLD (f_dsp_48_u16)) & (65535))) | (((((FLD (f_dsp_64_u16))
<< (16))) & (0xffff0000
))));
+ FLD (f_dsp_48_s32) = ((((FLD (f_dsp_48_u16)) & (65535))) | (((((FLD (f_dsp_64_u16))
& (65535))) << (16
))));
}
}
break;
}
}
break;
@@
-2553,7
+2564,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 64, 0, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 64, 0, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_64_s16 = value;
}
break;
fields->f_dsp_64_s16 = value;
}
break;
@@
-2561,7
+2572,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 8, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGNED), 0, 8, 16, 32, total_length, pc, & value);
- value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
<< (8))) & (65280
)))))));
+ value = EXTHISI (((HI) (INT) (((((((UINT) (value) >> (8))) & (255))) | (((((value)
& (255))) << (8
)))))));
fields->f_dsp_8_s16 = value;
}
break;
fields->f_dsp_8_s16 = value;
}
break;
@@
-2646,7
+2657,7
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGN_OPT)|(1<<CGEN_IFLD_PCREL_ADDR), 0, 8, 16, 32, total_length, pc, & value);
{
long value;
length = extract_normal (cd, ex_info, insn_value, 0|(1<<CGEN_IFLD_SIGN_OPT)|(1<<CGEN_IFLD_PCREL_ADDR), 0, 8, 16, 32, total_length, pc, & value);
- value = ((((((
USI) (((value) & (65535))) >> (8))) | (((SI) (((((value) & (255))) << (24))) >> (16))
))) + (((pc) + (1))));
+ value = ((((((
((((USI) (((value) & (65280))) >> (8))) | (((((value) & (255))) << (8))))) ^ (32768))) - (32768
))) + (((pc) + (1))));
fields->f_lab_8_16 = value;
}
break;
fields->f_lab_8_16 = value;
}
break;
@@
-2886,20
+2897,21
@@
m32c_cgen_extract_operand (CGEN_CPU_DESC cd,
default :
/* xgettext:c-format */
default :
/* xgettext:c-format */
- fprintf (stderr, _("Unrecognized field %d while decoding insn.\n"),
- opindex);
+ opcodes_error_handler
+ (_("internal error: unrecognized field %d while decoding insn"),
+ opindex);
abort ();
}
return length;
}
abort ();
}
return length;
}
-cgen_insert_fn * const m32c_cgen_insert_handlers[] =
+cgen_insert_fn * const m32c_cgen_insert_handlers[] =
{
insert_insn_normal,
};
{
insert_insn_normal,
};
-cgen_extract_fn * const m32c_cgen_extract_handlers[] =
+cgen_extract_fn * const m32c_cgen_extract_handlers[] =
{
extract_insn_normal,
};
{
extract_insn_normal,
};
@@
-3503,8
+3515,9
@@
m32c_cgen_get_int_operand (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
default :
/* xgettext:c-format */
default :
/* xgettext:c-format */
- fprintf (stderr, _("Unrecognized field %d while getting int operand.\n"),
- opindex);
+ opcodes_error_handler
+ (_("internal error: unrecognized field %d while getting int operand"),
+ opindex);
abort ();
}
abort ();
}
@@
-4102,8
+4115,9
@@
m32c_cgen_get_vma_operand (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
default :
/* xgettext:c-format */
default :
/* xgettext:c-format */
- fprintf (stderr, _("Unrecognized field %d while getting vma operand.\n"),
- opindex);
+ opcodes_error_handler
+ (_("internal error: unrecognized field %d while getting vma operand"),
+ opindex);
abort ();
}
abort ();
}
@@
-4689,8
+4703,9
@@
m32c_cgen_set_int_operand (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
default :
/* xgettext:c-format */
default :
/* xgettext:c-format */
- fprintf (stderr, _("Unrecognized field %d while setting int operand.\n"),
- opindex);
+ opcodes_error_handler
+ (_("internal error: unrecognized field %d while setting int operand"),
+ opindex);
abort ();
}
}
abort ();
}
}
@@
-5266,8
+5281,9
@@
m32c_cgen_set_vma_operand (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED,
default :
/* xgettext:c-format */
default :
/* xgettext:c-format */
- fprintf (stderr, _("Unrecognized field %d while setting vma operand.\n"),
- opindex);
+ opcodes_error_handler
+ (_("internal error: unrecognized field %d while setting vma operand"),
+ opindex);
abort ();
}
}
abort ();
}
}
This page took
0.038416 seconds
and
4
git commands to generate.