+2004-09-02 Richard Sandiford <rsandifo@redhat.com>
+
+ * config/mips/mips.c (mips_classify_symbol, mips_fetch_insns):
+ (mips_restore_gp, mips_set_return_address, mips_expand_prologue)
+ (mips16_fp_args, mips_avoid_hazard): Replace abort with gcc_assert.
+ (build_mips16_call_stub): Likewise. Remove daft CALL_INSN checks.
+ (mips_issue_rate): Remove unreachable abort.
+ (mips_symbolic_constant_p, mips_symbolic_address_p, mips_symbol_insns)
+ (mips_output_move, mips_relational_operand_ok_p, mips_arg_info)
+ (mips_block_move_straight, print_operand_address, mips_file_start)
+ (mips_initial_elimination_offset, mips16_fp_args, dump_constants_1)
+ (mips_output_conditional_branch, mips_expand_builtin_direct)
+ (mips_expand_builtin_compare): Replace abort with gcc_unreachable.
+ * config/mips/mips.md (rotr<mode>3, consttable_float): Replace abort
+ with gcc_assert.
+
2004-09-02 Richard Sandiford <rsandifo@redhat.com>
* config/mips/mips.md (*lea_high64): Change split condition to
return SYMBOL_GENERAL;
}
- if (GET_CODE (x) != SYMBOL_REF)
- abort ();
+ gcc_assert (GET_CODE (x) == SYMBOL_REF);
if (CONSTANT_POOL_ADDRESS_P (x))
{
case SYMBOL_GOTOFF_LOADGP:
return false;
}
- abort ();
+ gcc_unreachable ();
}
case SYMBOL_64_LOW:
return true;
}
- abort ();
+ gcc_unreachable ();
}
/* Check whether the offset is a 16- or 32-bit value. */
return mips_split_p[type] ? 2 : 1;
}
- abort ();
+ gcc_unreachable ();
}
/* Return true if X is a legitimate $sp-based address for mode MDOE. */
int
mips_fetch_insns (rtx x)
{
- if (GET_CODE (x) != MEM)
- abort ();
-
+ gcc_assert (GET_CODE (x) == MEM);
return mips_address_insns (XEXP (x, 0), GET_MODE (x));
}
retval[3] = COPNUM_AS_CHAR_FROM_REGNUM (REGNO (src));
return retval;
}
- abort ();
+ gcc_unreachable ();
}
\f
/* Restore $gp from its save slot. Valid only when using o32 or
{
rtx address, slot;
- if (!TARGET_ABICALLS || !TARGET_OLDABI)
- abort ();
+ gcc_assert (TARGET_ABICALLS && TARGET_OLDABI);
address = mips_add_offset (pic_offset_table_rtx,
frame_pointer_needed
return sleu_operand (cmp1, VOIDmode);
default:
- abort ();
+ gcc_unreachable ();
}
}
rtx slot_address;
compute_frame_size (get_frame_size ());
- if (((cfun->machine->frame.mask >> 31) & 1) == 0)
- abort ();
+ gcc_assert ((cfun->machine->frame.mask >> 31) & 1);
slot_address = mips_add_offset (scratch, stack_pointer_rtx,
cfun->machine->frame.gp_sp_offset);
{
rtx part = adjust_address (src, BLKmode, offset);
if (!mips_expand_unaligned_load (regs[i], part, bits, 0))
- abort ();
+ gcc_unreachable ();
}
}
{
rtx part = adjust_address (dest, BLKmode, offset);
if (!mips_expand_unaligned_store (part, regs[i], bits, 0))
- abort ();
+ gcc_unreachable ();
}
/* Mop up any left-over bytes. */
break;
default:
- abort ();
+ gcc_unreachable ();
}
/* Now decide whether the argument must go in an even-numbered register.
output_addr_const (file, x);
return;
}
- abort ();
+ gcc_unreachable ();
}
\f
/* When using assembler macros, keep track of all of small-data externs
case ABI_O64: abi_string = "abiO64"; break;
case ABI_EABI: abi_string = TARGET_64BIT ? "eabi64" : "eabi32"; break;
default:
- abort ();
+ gcc_unreachable ();
}
/* Note - we use fprintf directly rather than called named_section()
because in this way we can avoid creating an allocated section. We
break;
default:
- abort ();
+ gcc_unreachable ();
}
if (TARGET_MIPS16 && to == HARD_FRAME_POINTER_REGNUM)
from the stack pointer, so use the frame pointer as a
temporary. We should always be using a frame pointer
in this case anyway. */
- if (!frame_pointer_needed)
- abort ();
-
+ gcc_assert (frame_pointer_needed);
emit_move_insn (hard_frame_pointer_rtx, stack_pointer_rtx);
emit_insn (gen_sub3_insn (hard_frame_pointer_rtx,
hard_frame_pointer_rtx,
unsigned int f;
/* This code only works for the original 32 bit ABI and the O64 ABI. */
- if (!TARGET_OLDABI)
- abort ();
+ gcc_assert (TARGET_OLDABI);
if (from_fp_p)
s = "mfc1";
}
}
else
- abort ();
+ gcc_unreachable ();
++gparg;
++fparg;
/* This code will only work for o32 and o64 abis. The other ABI's
require more sophisticated support. */
- if (!TARGET_OLDABI)
- abort ();
+ gcc_assert (TARGET_OLDABI);
/* We can only handle SFmode and DFmode floating point return
values. */
- if (fpret && GET_MODE (retval) != SFmode && GET_MODE (retval) != DFmode)
- abort ();
+ if (fpret)
+ gcc_assert (GET_MODE (retval) == SFmode || GET_MODE (retval) == DFmode);
/* If we're calling via a function pointer, then we must always call
via a stub. There are magic stubs provided in libgcc.a for each
insn = emit_call_insn (insn);
/* Put the register usage information on the CALL. */
- if (GET_CODE (insn) != CALL_INSN)
- abort ();
CALL_INSN_FUNCTION_USAGE (insn) =
gen_rtx_EXPR_LIST (VOIDmode,
gen_rtx_USE (VOIDmode, gen_rtx_REG (Pmode, 2)),
insn = gen_call_value_internal (retval, fn, arg_size);
insn = emit_call_insn (insn);
- if (GET_CODE (insn) != CALL_INSN)
- abort ();
-
CALL_INSN_FUNCTION_USAGE (insn) =
gen_rtx_EXPR_LIST (VOIDmode,
gen_rtx_USE (VOIDmode, gen_rtx_REG (word_mode, 18)),
}
default:
- abort ();
+ gcc_unreachable ();
}
}
case HAZARD_DELAY:
set = single_set (insn);
- if (set == 0)
- abort ();
+ gcc_assert (set != 0);
*delayed_reg = SET_DEST (set);
break;
}
}
default:
- abort ();
+ gcc_unreachable ();
}
/* NOTREACHED */
default:
return 1;
}
-
- abort ();
-
}
/* Implements TARGET_SCHED_FIRST_CYCLE_MULTIPASS_DFA_LOOKAHEAD. This should
break;
default:
- abort ();
+ gcc_unreachable ();
}
return target;
}
break;
default:
- abort ();
+ gcc_unreachable ();
}
/* If the comparison sets more than one register, we define the result