static int mips_4320 = -1;
/* end-sanitize-vr4320 */
-/* start-sanitize-vr5400 */
+/* start-sanitize-cygnus */
/* Whether NEC vr5400 instructions are permitted. */
static int mips_5400 = -1;
-/* end-sanitize-vr5400 */
+/* end-sanitize-cygnus */
/* start-sanitize-r5900 */
/* Whether Toshiba r5900 instructions are permitted. */
static int mips_5900 = -1;
/* Whether the processor uses hardware interlocks to protect reads
from the GPRs, and thus does not require nops to be inserted. */
#define gpr_interlocks (mips_opts.isa >= 2 || mips_3900)
-/* start-sanitize-vr5400 */
+/* start-sanitize-cygnus */
#undef gpr_interlocks
#define gpr_interlocks (mips_opts.isa >= 2 || mips_3900 || mips_5400)
-/* end-sanitize-vr5400 */
+/* end-sanitize-cygnus */
/* As with other "interlocks" this is used by hardware that has FP
/* start-sanitize-vr4320 */ \
|| mips_cpu == 4320 \
/* end-sanitize-vr4320 */ \
- /* start-sanitize-vr5400 */ \
+ /* start-sanitize-cygnus */ \
|| mips_cpu == 5400 \
- /* end-sanitize-vr5400 */ \
+ /* end-sanitize-cygnus */ \
)
/* MIPS PIC level. */
|| strcmp (cpu, "mips64vr5000") == 0)
mips_cpu = 5000;
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
else if (strcmp (cpu, "r5400") == 0
|| strcmp (cpu, "mips64vr5400") == 0)
mips_cpu = 5400;
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
/* start-sanitize-r5900 */
else if (strcmp (cpu, "r5900") == 0
mips_opts.isa = 3;
else if (mips_cpu == 5000
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
|| mips_cpu == 5400
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
|| mips_cpu == 8000
|| mips_cpu == 10000)
mips_opts.isa = 4;
mips_4320 = (mips_cpu == 4320);
/* end-sanitize-vr4320 */
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
if (mips_5400 < 0)
mips_5400 = (mips_cpu == 5400);
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
/* start-sanitize-r5900 */
if (mips_5900 < 0)
|| (mips_5900
&& (insn.insn_mo->membership & INSN_5900) != 0)
/* end-sanitize-r5900 */
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
|| (mips_5400
&& (insn.insn_mo->membership & INSN_5400) != 0)
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
|| (mips_3900
&& (insn.insn_mo->membership & INSN_3900) != 0))
/* start-sanitize-r5900 */
&& imm_expr.X_add_number >= -0x8000
&& imm_expr.X_add_number < 0x8000)
{
- macro_build ((char *) NULL, &icnt, &expr1,
+ macro_build ((char *) NULL, &icnt, &imm_expr,
mask == M_SGE_I ? "slti" : "sltiu",
"t,r,j", dreg, sreg, (int) BFD_RELOC_LO16);
used_at = 0;
case '-': break;
case '+': break;
/* end-sanitize-r5900 */
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
case 'e': USE_BITS (OP_MASK_VECBYTE, OP_SH_VECBYTE); break;
case '%': USE_BITS (OP_MASK_VECALIGN, OP_SH_VECALIGN); break;
case '[': break;
case ']': break;
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
default:
as_bad (_("internal: bad mips opcode (unknown operand type `%c'): %s %s"),
c, opc->name, opc->args);
/* start-sanitize-r5900 */
|| (mips_5900 && (insn->membership & INSN_5900) != 0)
/* end-sanitize-r5900 */
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
|| (mips_5400 && (insn->membership & INSN_5400) != 0)
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
|| (mips_3900 && (insn->membership & INSN_3900) != 0))
ok = true;
else
return;
case ')': /* these must match exactly */
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
case '[':
case ']':
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
/* start-sanitize-r5900 */
case '-':
case '+':
else
imm_reloc = BFD_RELOC_HI16;
}
+ else if (imm_expr.X_op == O_constant)
+ imm_expr.X_add_number &= 0xffff;
}
if (*args == 'i')
{
case 'u': /* upper 16 bits */
c = my_getSmallExpression (&imm_expr, s);
- if (imm_expr.X_op == O_constant
- && (imm_expr.X_add_number < 0
- || imm_expr.X_add_number >= 0x10000))
- as_bad (_("lui expression not in range 0..65535"));
imm_reloc = BFD_RELOC_LO16;
if (c)
{
else
imm_reloc = BFD_RELOC_HI16;
}
+ else if (imm_expr.X_op == O_constant)
+ imm_expr.X_add_number &= 0xffff;
}
+ if (imm_expr.X_op == O_constant
+ && (imm_expr.X_add_number < 0
+ || imm_expr.X_add_number >= 0x10000))
+ as_bad (_("lui expression not in range 0..65535"));
s = expr_end;
continue;
ip->insn_opcode |= regno << OP_SH_CCC;
continue;
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
case 'e': /* must be at least one digit */
my_getExpression (&imm_expr, s);
check_absolute_expr (ip, &imm_expr);
s = expr_end;
continue;
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
default:
as_bad (_("bad char = '%c'\n"), *args);
internalError ();
{"no-m1900", no_argument, NULL, OPTION_NO_M3900},
/* end-sanitize-tx19 */
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
#define OPTION_M5400 (OPTION_MD_BASE + 28)
{"m5400", no_argument, NULL, OPTION_M5400},
#define OPTION_NO_M5400 (OPTION_MD_BASE + 29)
{"no-m5400", no_argument, NULL, OPTION_NO_M5400},
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
/* start-sanitize-tx49 */
#define OPTION_M4900 (OPTION_MD_BASE + 30)
{"m4900", no_argument, NULL, OPTION_M4900},
|| strcmp (p, "5k") == 0
|| strcmp (p, "5K") == 0)
mips_cpu = 5000;
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
else if (strcmp (p, "5400") == 0)
mips_cpu = 5400;
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
/* start-sanitize-r5900 */
else if (strcmp (p, "5900") == 0)
mips_cpu = 5900;
/* start-sanitize-vr4320 */
&& mips_cpu != 4320
/* end-sanitize-vr4320 */
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
&& mips_cpu != 5400
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
&& mips_cpu != 5000))
{
as_bad (_("ignoring invalid leading 'v' in -mcpu=%s switch"), arg);
break;
/* end-sanitize-vr4320 */
- /* start-sanitize-vr5400 */
+ /* start-sanitize-cygnus */
case OPTION_M5400:
mips_5400 = 1;
break;
mips_5400 = 0;
break;
- /* end-sanitize-vr5400 */
+ /* end-sanitize-cygnus */
case OPTION_M3900:
mips_3900 = 1;
break;
else
proc_rootP = procP;
proc_lastP = procP;
+
+ symbolP->bsym->flags |= BSF_FUNCTION;
+
numprocs++;
}
demand_empty_rest_of_line ();