* pa.c (insn_sets_and_refs_are_delayed): New function.
* pa.h (INSN_SETS_ARE_DELAYED): Use it.
(INSN_REFERENCES_ARE_DELAYED): Likewise.
From-SVN: r25003
+Wed Feb 3 11:56:23 1999 Jeffrey A Law (law@cygnus.com)
+
+ * pa.c (insn_sets_and_refs_are_delayed): New function.
+ * pa.h (INSN_SETS_ARE_DELAYED): Use it.
+ (INSN_REFERENCES_ARE_DELAYED): Likewise.
+
Wed Feb 3 06:24:49 1999 Richard Earnshaw (rearnsha@arm.com)
* config/arm/t-arm-elf (LIBGCC2_CFLAGS): Delete.
/* If we get here, then everything is good. */
return 1;
}
+
+/* Return nonzero if sets and references for INSN are delayed.
+
+ Millicode insns are actually function calls with some special
+ constraints on arguments and register usage.
+
+ Millicode calls always expect their arguments in the integer argument
+ registers, and always return their result in %r29 (ret1). They
+ are expected to clobber their arguments, %r1, %r29, and %r31 and
+ nothing else.
+
+ By considering this effects delayed reorg reorg can put insns
+ which set the argument registers into the delay slot of the millicode
+ call -- thus they act more like traditional CALL_INSNs.
+
+ get_attr_type will try to recognize the given insn, so make sure to
+ filter out things it will not accept -- SEQUENCE, USE and CLOBBER insns
+ in particular. */
+int
+insn_sets_and_refs_are_delayed (insn)
+ rtx insn;
+{
+ return ((GET_CODE (insn) == INSN
+ && GET_CODE (PATTERN (insn)) != SEQUENCE
+ && GET_CODE (PATTERN (insn)) != USE
+ && GET_CODE (PATTERN (insn)) != CLOBBER
+ && get_attr_type (insn) == TYPE_MILLI));
+}
get_attr_type will try to recognize the given insn, so make sure to
filter out things it will not accept -- SEQUENCE, USE and CLOBBER insns
in particular. */
-#define INSN_SETS_ARE_DELAYED(X) \
- ((GET_CODE (X) == INSN \
- && GET_CODE (PATTERN (X)) != SEQUENCE \
- && GET_CODE (PATTERN (X)) != USE \
- && GET_CODE (PATTERN (X)) != CLOBBER \
- && get_attr_type (X) == TYPE_MILLI))
-
-#define INSN_REFERENCES_ARE_DELAYED(X) \
- ((GET_CODE (X) == INSN \
- && GET_CODE (PATTERN (X)) != SEQUENCE \
- && GET_CODE (PATTERN (X)) != USE \
- && GET_CODE (PATTERN (X)) != CLOBBER \
- && get_attr_type (X) == TYPE_MILLI))
+#define INSN_SETS_ARE_DELAYED(X) (insn_sets_and_refs_are_delayed (X))
+#define INSN_REFERENCES_ARE_DELAYED(X) (insn_sets_and_refs_are_delayed (X))
\f
/* Control the assembler format that we output. */
extern int is_function_label_plus_const ();
extern int jump_in_call_delay ();
extern enum reg_class secondary_reload_class ();
+extern int insn_sets_and_refs_are_delayed ();
/* Declare functions defined in pa.c and used in templates. */