diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index c06baeea5e146cc7d3d015d24c37d1eea61a499a..9b2a831b2e198023f01d2aff7fbe899f239d2c5b 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2005-12-29  Alan Modra  <amodra@bigpond.net.au>
+
+	PR target/25572
+	* config/rs6000/rs6000.c (create_TOC_reference): Set regs_ever_live.
+
 2005-12-28  Nathan Sidwell  <nathan@codesourcery.com>
 
 	* config.gcc (mt-*-*): Add --with-arch support.
diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c
index e23e86b1f956e9ac4598cd553d485a7e9b44dc63..7bec9103c559e60c9fd111f280705d2ebbadb3e1 100644
--- a/gcc/config/rs6000/rs6000.c
+++ b/gcc/config/rs6000/rs6000.c
@@ -13499,6 +13499,8 @@ uses_TOC (void)
 rtx
 create_TOC_reference (rtx symbol)
 {
+  if (no_new_pseudos)
+    regs_ever_live[TOC_REGISTER] = 1;
   return gen_rtx_PLUS (Pmode,
 	   gen_rtx_REG (Pmode, TOC_REGISTER),
 	     gen_rtx_CONST (Pmode,