s12z-opc.c formatting fixes
Wrap overlong lines, whitespace fixes, and for function definitions start a line with the name of the function. * s12z-opc.c: Formatting.
This commit is contained in:
parent
bac7c5cf92
commit
e7c22a69ac
|
@ -1,3 +1,7 @@
|
|||
2019-12-10 Alan Modra <amodra@gmail.com>
|
||||
|
||||
* s12z-opc.c: Formatting.
|
||||
|
||||
2019-12-08 Alan Modra <amodra@gmail.com>
|
||||
|
||||
* s12z-opc.c (exg_sex_discrim): Don't leak memory on invalid
|
||||
|
|
|
@ -256,7 +256,8 @@ xysp_reg_from_postbyte (uint8_t postbyte)
|
|||
return reg;
|
||||
}
|
||||
|
||||
static struct operand * create_immediate_operand (int value)
|
||||
static struct operand *
|
||||
create_immediate_operand (int value)
|
||||
{
|
||||
struct immediate_operand *op = malloc (sizeof (*op));
|
||||
|
||||
|
@ -267,7 +268,8 @@ static struct operand * create_immediate_operand (int value)
|
|||
return (struct operand *) op;
|
||||
}
|
||||
|
||||
static struct operand * create_bitfield_operand (int width, int offset)
|
||||
static struct operand *
|
||||
create_bitfield_operand (int width, int offset)
|
||||
{
|
||||
struct bitfield_operand *op = malloc (sizeof (*op));
|
||||
|
||||
|
@ -297,7 +299,8 @@ create_register_operand (int reg)
|
|||
return create_register_operand_with_size (reg, -1);
|
||||
}
|
||||
|
||||
static struct operand * create_register_all_operand (void)
|
||||
static struct operand *
|
||||
create_register_all_operand (void)
|
||||
{
|
||||
struct register_operand *op = malloc (sizeof (*op));
|
||||
|
||||
|
@ -307,7 +310,8 @@ static struct operand * create_register_all_operand (void)
|
|||
return (struct operand *) op;
|
||||
}
|
||||
|
||||
static struct operand * create_register_all16_operand (void)
|
||||
static struct operand *
|
||||
create_register_all16_operand (void)
|
||||
{
|
||||
struct register_operand *op = malloc (sizeof (*op));
|
||||
|
||||
|
@ -371,7 +375,8 @@ create_memory_auto_operand (enum op_reg_mutation mutation, int reg)
|
|||
|
||||
|
||||
static void
|
||||
z_ext24_decode (struct mem_read_abstraction_base *mra, int *n_operands, struct operand **operand)
|
||||
z_ext24_decode (struct mem_read_abstraction_base *mra, int *n_operands,
|
||||
struct operand **operand)
|
||||
{
|
||||
uint8_t buffer[3];
|
||||
int status = mra->read (mra, 0, 3, buffer);
|
||||
|
@ -391,7 +396,8 @@ z_ext24_decode (struct mem_read_abstraction_base *mra, int *n_operands, struct o
|
|||
|
||||
|
||||
static uint32_t
|
||||
z_decode_signed_value (struct mem_read_abstraction_base *mra, int offset, short size)
|
||||
z_decode_signed_value (struct mem_read_abstraction_base *mra, int offset,
|
||||
short size)
|
||||
{
|
||||
assert (size >0);
|
||||
assert (size <= 4);
|
||||
|
@ -1003,7 +1009,9 @@ sub_d6_y_x (struct mem_read_abstraction_base *mra ATTRIBUTE_UNUSED,
|
|||
operand[(*n_operands)++] = create_register_operand (REG_X);
|
||||
}
|
||||
|
||||
static void ld_18bit_decode (struct mem_read_abstraction_base *mra, int *n_operands, struct operand **operand);
|
||||
static void
|
||||
ld_18bit_decode (struct mem_read_abstraction_base *mra, int *n_operands,
|
||||
struct operand **operand);
|
||||
|
||||
static enum optr
|
||||
mul_discrim (struct mem_read_abstraction_base *mra, enum optr hint)
|
||||
|
@ -2294,7 +2302,8 @@ loop_primitive_decode (struct mem_read_abstraction_base *mra,
|
|||
|
||||
|
||||
static enum optr
|
||||
shift_discrim (struct mem_read_abstraction_base *mra, enum optr hint ATTRIBUTE_UNUSED)
|
||||
shift_discrim (struct mem_read_abstraction_base *mra,
|
||||
enum optr hint ATTRIBUTE_UNUSED)
|
||||
{
|
||||
size_t i;
|
||||
uint8_t sb;
|
||||
|
@ -2323,7 +2332,8 @@ shift_discrim (struct mem_read_abstraction_base *mra, enum optr hint ATTRIBUTE_
|
|||
|
||||
|
||||
static void
|
||||
shift_decode (struct mem_read_abstraction_base *mra, int *n_operands, struct operand **operands)
|
||||
shift_decode (struct mem_read_abstraction_base *mra, int *n_operands,
|
||||
struct operand **operands)
|
||||
{
|
||||
size_t i;
|
||||
|
||||
|
@ -2505,9 +2515,7 @@ psh_pul_decode (struct mem_read_abstraction_base *mra,
|
|||
if (byte & 0x40)
|
||||
{
|
||||
if ((byte & 0x3F) == 0)
|
||||
{
|
||||
operand[(*n_operands)++] = create_register_all16_operand ();
|
||||
}
|
||||
else
|
||||
for (bit = 5; bit >= 0; --bit)
|
||||
{
|
||||
|
@ -2520,9 +2528,7 @@ psh_pul_decode (struct mem_read_abstraction_base *mra,
|
|||
else
|
||||
{
|
||||
if ((byte & 0x3F) == 0)
|
||||
{
|
||||
operand[(*n_operands)++] = create_register_all_operand ();
|
||||
}
|
||||
else
|
||||
for (bit = 5; bit >= 0; --bit)
|
||||
{
|
||||
|
@ -2535,7 +2541,8 @@ psh_pul_decode (struct mem_read_abstraction_base *mra,
|
|||
}
|
||||
|
||||
static enum optr
|
||||
bit_field_discrim (struct mem_read_abstraction_base *mra, enum optr hint ATTRIBUTE_UNUSED)
|
||||
bit_field_discrim (struct mem_read_abstraction_base *mra,
|
||||
enum optr hint ATTRIBUTE_UNUSED)
|
||||
{
|
||||
int status;
|
||||
bfd_byte bb;
|
||||
|
|
Loading…
Reference in New Issue