&& (FUNCTION_ARG_PADDING (MODE, TYPE) \
== (BYTES_BIG_ENDIAN ? upward : downward)))))
-/* Under the old (i.e., 32 and O64 ABIs) all BLKmode objects are
- returned in memory. Under the new (N32 and 64-bit MIPS ABIs) small
- structures are returned in a register. Objects with varying size
- must still be returned in memory, of course. */
-#undef RETURN_IN_MEMORY
-#define RETURN_IN_MEMORY(TYPE) \
- ((mips_abi == ABI_32 || mips_abi == ABI_O64) \
- ? TYPE_MODE (TYPE) == BLKmode \
- : ((int_size_in_bytes (TYPE) \
- > (2 * UNITS_PER_WORD)) \
- || (int_size_in_bytes (TYPE) == -1)))
-
#undef FUNCTION_VALUE
#define FUNCTION_VALUE(VALTYPE, FUNC) mips_function_value (VALTYPE, FUNC)
#define OBJECT_FORMAT_ELF
/* Default to -mips3. */
+#ifndef TARGET_DEFAULT
#define TARGET_DEFAULT MASK_FLOAT64|MASK_64BIT
+#endif
+
+#ifndef MIPS_ISA_DEFAULT
#define MIPS_ISA_DEFAULT 3
+#endif
/* This should change to n32 when it is supported in gas. */
+#ifndef MIPS_ABI_DEFAULT
#define MIPS_ABI_DEFAULT ABI_O64
+#endif
/* Until we figure out what MIPS ELF targets normally use, just do
stabs in ELF. */
return ((GET_MODE_SIZE (mode) + UNITS_PER_FPREG - 1) / UNITS_PER_FPREG);
}
+int
+mips_return_in_memory (type)
+ tree type;
+{
+ /* Under the old (i.e., 32 and O64 ABIs) all BLKmode objects are
+ returned in memory. Under the new (N32 and 64-bit MIPS ABIs) small
+ structures are returned in a register. Objects with varying size
+ must still be returned in memory, of course. */
+
+ if (mips_abi == ABI_32 || mips_abi == ABI_O64)
+ return (TYPE_MODE (type) == BLKmode);
+ else
+ return ((int_size_in_bytes (type) > (2 * UNITS_PER_WORD))
+ || (int_size_in_bytes (type) == -1));
+}
+
+
+
\f
#ifdef TARGET_IRIX6
/* Output assembly to switch to section NAME with attribute FLAGS. */
(set_attr "length" "4,8,4,4,8,8,8,8,4,8,4,4")])
(define_insn "movdf_internal2"
- [(set (match_operand:DF 0 "nonimmediate_operand" "=d,d,d,R,To,*d")
- (match_operand:DF 1 "general_operand" "dG,R,ToF,d,d,*f"))]
+ [(set (match_operand:DF 0 "nonimmediate_operand" "=d,d,d,R,To,d,f,f")
+ (match_operand:DF 1 "general_operand" "dG,R,ToF,d,d,f,d,f"))]
"(TARGET_SOFT_FLOAT || TARGET_SINGLE_FLOAT) && !TARGET_MIPS16
&& (register_operand (operands[0], DFmode)
|| register_operand (operands[1], DFmode)
|| (GET_CODE (operands[1]) == CONST_INT && INTVAL (operands[1]) == 0)
|| operands[1] == CONST0_RTX (DFmode))"
"* return mips_move_2words (operands, insn); "
- [(set_attr "type" "move,load,load,store,store,xfer")
+ [(set_attr "type" "move,load,load,store,store,xfer,load,move")
(set_attr "mode" "DF")
- (set_attr "length" "8,8,16,8,16,8")])
+ (set_attr "length" "8,8,16,8,16,8,8,4")])
(define_insn ""
[(set (match_operand:DF 0 "nonimmediate_operand" "=d,y,d,d,d,R,To")