aboutsummaryrefslogtreecommitdiff
path: root/gcc/expr.h
diff options
context:
space:
mode:
authorBernd Schmidt <bernds@cygnus.co.uk>1999-09-23 11:34:49 +0000
committerBernd Schmidt <crux@gcc.gnu.org>1999-09-23 11:34:49 +0000
commit1c0290eaac40944ba6baed8323b74f42ab7f05c9 (patch)
treef3957a52a53f08158be8aba1c10f20bd084118d7 /gcc/expr.h
parent708d3415cfbb4258becce97364825ee8a6c2b957 (diff)
downloadgcc-1c0290eaac40944ba6baed8323b74f42ab7f05c9.zip
gcc-1c0290eaac40944ba6baed8323b74f42ab7f05c9.tar.gz
gcc-1c0290eaac40944ba6baed8323b74f42ab7f05c9.tar.bz2
Use cbranch patterns when available
From-SVN: r29613
Diffstat (limited to 'gcc/expr.h')
-rw-r--r--gcc/expr.h26
1 files changed, 25 insertions, 1 deletions
diff --git a/gcc/expr.h b/gcc/expr.h
index 53cb9a9..52f743b 100644
--- a/gcc/expr.h
+++ b/gcc/expr.h
@@ -377,6 +377,11 @@ enum optab_index
/* String length */
OTI_strlen,
+ /* Combined compare & jump/store flags/move operations. */
+ OTI_cbranch,
+ OTI_cmov,
+ OTI_cstore,
+
OTI_MAX
};
@@ -427,6 +432,10 @@ extern optab optab_table[OTI_MAX];
#define strlen_optab (optab_table[OTI_strlen])
+#define cbranch_optab (optab_table[OTI_cbranch])
+#define cmov_optab (optab_table[OTI_cmov])
+#define cstore_optab (optab_table[OTI_cstore])
+
/* Tables of patterns for extending one integer mode to another. */
extern enum insn_code extendtab[MAX_MACHINE_MODE][MAX_MACHINE_MODE][2];
@@ -778,9 +787,24 @@ extern void emit_cmp_insn PROTO((rtx, rtx, enum rtx_code, rtx,
extern void emit_cmp_and_jump_insns PROTO((rtx, rtx, enum rtx_code, rtx,
enum machine_mode, int, int, rtx));
+/* The various uses that a comparison can have; used by can_compare_p:
+ jumps, conditional moves, store flag operations. */
+enum can_compare_purpose
+{
+ ccp_jump,
+ ccp_cmov,
+ ccp_store_flag
+};
/* Nonzero if a compare of mode MODE can be done straightforwardly
(without splitting it into pieces). */
-extern int can_compare_p PROTO((enum machine_mode));
+extern int can_compare_p PROTO((enum machine_mode, enum can_compare_purpose));
+
+extern void prepare_cmp_insn PROTO((rtx *, rtx *, enum rtx_code *, rtx,
+ enum machine_mode *, int *, int,
+ enum can_compare_purpose));
+
+extern rtx prepare_operand PROTO((int, rtx, int, enum machine_mode,
+ enum machine_mode, int));
/* Generate code to indirectly jump to a location given in the rtx LOC. */
extern void emit_indirect_jump PROTO((rtx));