summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2008-09-06 09:21:39 +0000
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2008-09-06 09:21:39 +0000
commit84166344d5c07a1111be19deff267d02caa8ac89 (patch)
treef67b8496dbdeaecb48df917c3f90754df3021132
parentf5ec18cc5caf6a5925178329366811fd398e928c (diff)
downloadgcc-84166344d5c07a1111be19deff267d02caa8ac89.tar.gz
gcc/
* config/mips/mips.c (mips_function_ok_for_sibcall): Check for DECL being null. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@140056 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/config/mips/mips.c3
2 files changed, 7 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 280b57170a4..f3a30d97222 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2008-09-06 Richard Sandiford <rdsandiford@googlemail.com>
+
+ * config/mips/mips.c (mips_function_ok_for_sibcall): Check for
+ DECL being null.
+
2008-09-06 Richard Sandiford <rdsandiford@goolemail.com>
Peter Fuerst <post@pfrst.de>
diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c
index 9187991c763..799570cc7ae 100644
--- a/gcc/config/mips/mips.c
+++ b/gcc/config/mips/mips.c
@@ -6173,7 +6173,8 @@ mips_function_ok_for_sibcall (tree decl, tree exp ATTRIBUTE_UNUSED)
because there is no direct "jx" instruction equivalent to "jalx" to
switch the ISA mode. We only care about cases where the sibling
and normal calls would both be direct. */
- if (mips_use_mips16_mode_p (decl)
+ if (decl
+ && mips_use_mips16_mode_p (decl)
&& const_call_insn_operand (XEXP (DECL_RTL (decl), 0), VOIDmode))
return false;