summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2007-09-11 10:18:35 +0000
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2007-09-11 10:18:35 +0000
commit2bb2e78eeec7fe745ac7fa1ee92eff5bc38e2916 (patch)
tree7597f6eb43b213f7263a7e3405791ddc23ea04f2
parentb94b01e121d98363484b6493365062421de371d8 (diff)
downloadgcc-2bb2e78eeec7fe745ac7fa1ee92eff5bc38e2916.tar.gz
gcc/
* config/mips/mips.c (mips_set_mips16_mode): Use separate anchor settings for MIPS16. (mips_use_anchors_for_symbol_p): Use default_use_anchors_for_symbol_p. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@128366 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog6
-rw-r--r--gcc/config/mips/mips.c13
2 files changed, 18 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 470e25478db..1c9a5d01144 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,5 +1,11 @@
2007-09-11 Richard Sandiford <richard@codesourcery.com>
+ * config/mips/mips.c (mips_set_mips16_mode): Use separate anchor
+ settings for MIPS16.
+ (mips_use_anchors_for_symbol_p): Use default_use_anchors_for_symbol_p.
+
+2007-09-11 Richard Sandiford <richard@codesourcery.com>
+
* config/mips/mips.c (mips_symbol_insns_1): Allow LEAs of
SYMBOL_FORCE_TO_MEM constants.
(mips_rtx_costs): Give a cost of 1 to force_to_mem_operands.
diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c
index 0e69827296d..289f46e18bc 100644
--- a/gcc/config/mips/mips.c
+++ b/gcc/config/mips/mips.c
@@ -5655,6 +5655,14 @@ mips_set_mips16_mode (int mips16_p)
/* Silently disable DSP extensions. */
target_flags &= ~MASK_DSP;
target_flags &= ~MASK_DSPR2;
+
+ /* Experiments suggest we get the best overall results from using
+ the range of an unextended lw or sw. Code that makes heavy use
+ of byte or short accesses can do better with ranges of 0...31
+ and 0...63 respectively, but most code is sensitive to the range
+ of lw and sw instead. */
+ targetm.min_anchor_offset = 0;
+ targetm.max_anchor_offset = 127;
}
else
{
@@ -5676,6 +5684,9 @@ mips_set_mips16_mode (int mips16_p)
if (align_functions == 0)
align_functions = 8;
}
+
+ targetm.min_anchor_offset = TARGET_MIN_ANCHOR_OFFSET;
+ targetm.max_anchor_offset = TARGET_MAX_ANCHOR_OFFSET;
}
/* (Re)initialize mips target internals for new ISA. */
@@ -8920,7 +8931,7 @@ mips_use_anchors_for_symbol_p (const_rtx symbol)
return false;
default:
- return true;
+ return default_use_anchors_for_symbol_p (symbol);
}
}