case 0: processor_mask = PROCESSOR_V850; break;
/* start-sanitize-v850e */
case bfd_mach_v850e: processor_mask = PROCESSOR_V850E; break;
- case bfd_mach_v850eq: processor_mask = PROCESSOR_V850EQ; break;
+ case bfd_mach_v850ea: processor_mask = PROCESSOR_V850EA; break;
/* end-sanitize-v850e */
}
}
{"call_table_data", v850_call_table_data, 0},
{"call_table_text", v850_call_table_text, 0},
{"v850e", set_machine, bfd_mach_v850e},
- {"v850eq", set_machine, bfd_mach_v850eq},
+ {"v850ea", set_machine, bfd_mach_v850ea},
/* end-sanitize-v850e */
{ NULL, NULL, 0}
};
break;
}
- skip_white_space();
+ skip_white_space ();
}
return NULL;
FILE * stream;
{
fprintf (stream, "V850 options:\n");
- fprintf (stream, "\t-mwarn_signed_overflow Warn if signed immediate values overflow\n");
- fprintf (stream, "\t-mwarn_unsigned_overflow Warn if unsigned immediate values overflow\n");
+ fprintf (stream, "\t-mwarn-signed-overflow Warn if signed immediate values overflow\n");
+ fprintf (stream, "\t-mwarn-unsigned-overflow Warn if unsigned immediate values overflow\n");
fprintf (stream, "\t-mv850 The code is targeted at the v850\n");
/* start-sanitize-v850e */
fprintf (stream, "\t-mv850e The code is targeted at the v850e\n");
- fprintf (stream, "\t-mv850eq The code is targeted at the v850eq\n");
+ fprintf (stream, "\t-mv850ea The code is targeted at the v850ea\n");
/* end-sanitize-v850e */
}
char * arg;
{
if (c != 'm')
- return 0;
+ {
+ fprintf (stderr, "unknown command line option: -%c%s\n", c, arg);
+ return 0;
+ }
- if (strcmp (arg, "warn_signed_overflow") == 0)
+ if (strcmp (arg, "warn-signed-overflow") == 0)
{
warn_signed_overflows = TRUE;
}
- else if (strcmp (arg, "warn_unsigned_overflow") == 0)
+ else if (strcmp (arg, "warn-unsigned-overflow") == 0)
{
warn_unsigned_overflows = TRUE;
}
machine = bfd_mach_v850e;
processor_mask = PROCESSOR_V850E;
}
- else if (strcmp (arg, "v850eq") == 0)
+ else if (strcmp (arg, "v850ea") == 0)
{
- machine = bfd_mach_v850eq;
- processor_mask = PROCESSOR_V850EQ;
+ machine = bfd_mach_v850ea;
+ processor_mask = PROCESSOR_V850EA;
}
/* end-sanitize-v850e */
else
- return 0;
+ {
+ fprintf (stderr, "unknown command line option: -%c%s\n", c, arg);
+ return 0;
+ }
return 1;
}
flagword applicable;
/* start-sanitize-v850e */
- if (strncmp (TARGET_CPU, "v850eq", 6) == 0)
+ if (strncmp (TARGET_CPU, "v850ea", 6) == 0)
{
if (machine == -1)
- machine = bfd_mach_v850eq;
+ machine = bfd_mach_v850ea;
if (processor_mask == -1)
- processor_mask = PROCESSOR_V850EQ;
+ processor_mask = PROCESSOR_V850EA;
}
else if (strncmp (TARGET_CPU, "v850e", 5) == 0)
{
errmsg = NULL;
while (*str == ' ' || *str == ',' || *str == '[' || *str == ']')
- ++str;
+ ++ str;
if (operand->flags & V850_OPERAND_RELAX)
relaxable = 1;
case BFD_RELOC_32:
if ((operand->flags & V850E_IMMEDIATE32) == 0)
{
- errmsg = "use bigger instruction";
+ errmsg = "immediate operand is too large";
goto error;
}
{
if ((operand->flags & V850E_IMMEDIATE32) == 0)
{
- errmsg = "use bigger instruction";
+ errmsg = "immediate operand is too large";
goto error;
}
&& ex.X_add_number == 0)
{
errmsg = "register r0 cannot be used here";
+
+ /* Force an error message to be generated by
+ skipping over any following potential matches
+ for this opcode. */
+ opcode += 3;
+
+ if (* input_line_pointer == ']')
+ ++ input_line_pointer;
}
}
else if ((operand->flags & V850_OPERAND_SRG) != 0)
if (((insn & 0x07e0) == 0x0200)
&& ex.X_op == O_constant
&& (ex.X_add_number < (- (1 << (operand->bits - 1))) || ex.X_add_number > ((1 << operand->bits) - 1)))
- errmsg = "use bigger instruction";
+ errmsg = "immediate constant is too large";
/* end-sanitize-v850e */
}
insn = (*operand->insert) (insn, val, & message);
if (message != NULL)
{
- if (file == (char *) NULL)
- as_warn (message);
+ if ((operand->flags & V850_OPERAND_SIGNED)
+ && ! warn_signed_overflows
+ && strstr (message, "out of range") != NULL)
+ {
+ /* skip warning... */
+ }
+ else if ((operand->flags & V850_OPERAND_SIGNED) == 0
+ && ! warn_unsigned_overflows
+ && strstr (message, "out of range") != NULL)
+ {
+ /* skip warning... */
+ }
else
- as_warn_where (file, line, message);
+ {
+ if (file == (char *) NULL)
+ as_warn (message);
+ else
+ as_warn_where (file, line, message);
+ }
}
}
else