summaryrefslogtreecommitdiff
path: root/gcc/dojump.c
diff options
context:
space:
mode:
authorbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2008-09-01 06:35:08 +0000
committerbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2008-09-01 06:35:08 +0000
commita30fe044170c44da9e441535e2167ca8e885b3cb (patch)
tree2ebaaed9567b6d2c562b45ef1d92bcb5cb136795 /gcc/dojump.c
parentddda25955ee583217ccbd7ad5c33c6bb9f304649 (diff)
downloadgcc-a30fe044170c44da9e441535e2167ca8e885b3cb.tar.gz
2008-09-01 Basile Starynkevitch <basile@starynkevitch.net>
MERGED WITH TRUNK rev139820 * gcc/melt/warmelt-first.bysl: added location argument to inform. * gcc/warmelt-first-0.c: regenerated. * gcc/warmelt-macro-0.c: regenerated. * gcc/warmelt-normal-0.c: regenerated. * gcc/warmelt-genobj-0.c: regenerated. * gcc/warmelt-outobj-0.c: regenerated. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@139849 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/dojump.c')
-rw-r--r--gcc/dojump.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/gcc/dojump.c b/gcc/dojump.c
index 46aa4f2ebb8..c22402a948d 100644
--- a/gcc/dojump.c
+++ b/gcc/dojump.c
@@ -34,6 +34,7 @@ along with GCC; see the file COPYING3. If not see
#include "optabs.h"
#include "langhooks.h"
#include "ggc.h"
+#include "basic-block.h"
static bool prefer_and_bit_test (enum machine_mode, int);
static void do_jump_by_parts_greater (tree, int, rtx, rtx);
@@ -510,7 +511,9 @@ do_jump (tree exp, rtx if_false_label, rtx if_true_label)
/* High branch cost, expand as the bitwise AND of the conditions.
Do the same if the RHS has side effects, because we're effectively
turning a TRUTH_AND_EXPR into a TRUTH_ANDIF_EXPR. */
- if (BRANCH_COST >= 4 || TREE_SIDE_EFFECTS (TREE_OPERAND (exp, 1)))
+ if (BRANCH_COST (optimize_insn_for_speed_p (),
+ false) >= 4
+ || TREE_SIDE_EFFECTS (TREE_OPERAND (exp, 1)))
goto normal;
case TRUTH_ANDIF_EXPR:
@@ -531,7 +534,8 @@ do_jump (tree exp, rtx if_false_label, rtx if_true_label)
/* High branch cost, expand as the bitwise OR of the conditions.
Do the same if the RHS has side effects, because we're effectively
turning a TRUTH_OR_EXPR into a TRUTH_ORIF_EXPR. */
- if (BRANCH_COST >= 4 || TREE_SIDE_EFFECTS (TREE_OPERAND (exp, 1)))
+ if (BRANCH_COST (optimize_insn_for_speed_p (), false)>= 4
+ || TREE_SIDE_EFFECTS (TREE_OPERAND (exp, 1)))
goto normal;
case TRUTH_ORIF_EXPR: