rpms/gcc/devel gcc44-pr39175.patch, NONE, 1.1 .cvsignore, 1.254, 1.255 gcc.spec, 1.18, 1.19 sources, 1.257, 1.258 gcc44-rh479912.patch, 1.1, NONE

Jakub Jelinek jakub at fedoraproject.org
Fri Feb 13 13:28:27 UTC 2009


Author: jakub

Update of /cvs/pkgs/rpms/gcc/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv11849

Modified Files:
	.cvsignore gcc.spec sources 
Added Files:
	gcc44-pr39175.patch 
Removed Files:
	gcc44-rh479912.patch 
Log Message:
4.4.0-0.18

gcc44-pr39175.patch:

--- NEW FILE gcc44-pr39175.patch ---
2009-02-13  Jakub Jelinek  <jakub at redhat.com>

	PR target/39175
	* c-common.c (c_determine_visibility): If visibility changed and
	DECL_RTL has been already set, call make_decl_rtl to update symbol
	flags.

	* decl2.c (determine_visibility): If visibility changed and
	DECL_RTL has been already set, call make_decl_rtl to update symbol
	flags.

	* gcc.dg/visibility-20.c: New test.
	* g++.dg/ext/visibility/visibility-11.C: New test.

--- gcc/c-common.c.jj	2009-02-09 23:07:06.000000000 +0100
+++ gcc/c-common.c	2009-02-13 12:05:41.000000000 +0100
@@ -1,6 +1,7 @@
 /* Subroutines shared by all languages that are variants of C.
    Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000,
-   2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
+   2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009
+   Free Software Foundation, Inc.
 
 This file is part of GCC.
 
@@ -6249,8 +6250,18 @@ c_determine_visibility (tree decl)
      visibility_specified depending on #pragma GCC visibility.  */
   if (!DECL_VISIBILITY_SPECIFIED (decl))
     {
-      DECL_VISIBILITY (decl) = default_visibility;
-      DECL_VISIBILITY_SPECIFIED (decl) = visibility_options.inpragma;
+      if (visibility_options.inpragma
+	  || DECL_VISIBILITY (decl) != default_visibility)
+	{
+	  DECL_VISIBILITY (decl) = default_visibility;
+	  DECL_VISIBILITY_SPECIFIED (decl) = visibility_options.inpragma;
+	  /* If visibility changed and DECL already has DECL_RTL, ensure
+	     symbol flags are updated.  */
+	  if (((TREE_CODE (decl) == VAR_DECL && TREE_STATIC (decl))
+	       || TREE_CODE (decl) == FUNCTION_DECL)
+	      && DECL_RTL_SET_P (decl))
+	    make_decl_rtl (decl);
+	}
     }
   return false;
 }
--- gcc/cp/decl2.c.jj	2009-01-26 15:24:39.000000000 +0100
+++ gcc/cp/decl2.c	2009-02-13 12:10:53.000000000 +0100
@@ -1,6 +1,6 @@
 /* Process declarations and variables for C++ compiler.
    Copyright (C) 1988, 1992, 1993, 1994, 1995, 1996, 1997, 1998,
-   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008
+   1999, 2000, 2001, 2002, 2003, 2004, 2005, 2007, 2008, 2009
    Free Software Foundation, Inc.
    Hacked by Michael Tiemann (tiemann at cygnus.com)
 
@@ -1921,6 +1921,8 @@ determine_visibility (tree decl)
 {
   tree class_type = NULL_TREE;
   bool use_template;
+  bool orig_visibility_specified;
+  enum symbol_visibility orig_visibility;
 
   /* Remember that all decls get VISIBILITY_DEFAULT when built.  */
 
@@ -1933,6 +1935,9 @@ determine_visibility (tree decl)
      maybe_clone_body.  */
   gcc_assert (!DECL_CLONED_FUNCTION_P (decl));
 
+  orig_visibility_specified = DECL_VISIBILITY_SPECIFIED (decl);
+  orig_visibility = DECL_VISIBILITY (decl);
+
   if (TREE_CODE (decl) == TYPE_DECL)
     {
       if (CLASS_TYPE_P (TREE_TYPE (decl)))
@@ -2061,6 +2066,15 @@ determine_visibility (tree decl)
 	  || ! DECL_VISIBILITY_SPECIFIED (decl))
 	constrain_visibility (decl, tvis);
     }
+
+  /* If visibility changed and DECL already has DECL_RTL, ensure
+     symbol flags are updated.  */
+  if ((DECL_VISIBILITY (decl) != orig_visibility
+       || DECL_VISIBILITY_SPECIFIED (decl) != orig_visibility_specified)
+      && ((TREE_CODE (decl) == VAR_DECL && TREE_STATIC (decl))
+	  || TREE_CODE (decl) == FUNCTION_DECL)
+      && DECL_RTL_SET_P (decl))
+    make_decl_rtl (decl);
 }
 
 /* By default, static data members and function members receive
--- gcc/testsuite/gcc.dg/visibility-20.c.jj	2009-02-13 12:24:42.000000000 +0100
+++ gcc/testsuite/gcc.dg/visibility-20.c	2009-02-13 12:27:00.000000000 +0100
@@ -0,0 +1,18 @@
+/* PR target/39175 */
+/* { dg-do compile } */
+/* { dg-require-visibility "" } */
+/* { dg-options "-O2 -fvisibility=hidden -fpic" { target fpic } } */
+
+__attribute__((noinline)) int
+foo (int x)
+{
+  return x;
+}
+
+int foo (int x);
+
+int
+bar (int x)
+{
+  return foo (x);
+}
--- gcc/testsuite/g++.dg/ext/visibility/visibility-11.C.jj	2009-02-13 12:25:19.000000000 +0100
+++ gcc/testsuite/g++.dg/ext/visibility/visibility-11.C	2009-02-13 12:27:09.000000000 +0100
@@ -0,0 +1,18 @@
+// PR target/39175
+// { dg-do compile }
+// { dg-require-visibility "" }
+// { dg-options "-O2 -fvisibility=hidden -fpic" { target fpic } }
+
+__attribute__((noinline)) int
+foo (int x)
+{
+  return x;
+}
+
+int foo (int x);
+
+int
+bar (int x)
+{
+  return foo (x);
+}


Index: .cvsignore
===================================================================
RCS file: /cvs/pkgs/rpms/gcc/devel/.cvsignore,v
retrieving revision 1.254
retrieving revision 1.255
diff -u -r1.254 -r1.255
--- .cvsignore	11 Feb 2009 14:39:24 -0000	1.254
+++ .cvsignore	13 Feb 2009 13:27:56 -0000	1.255
@@ -1,3 +1,3 @@
 fastjar-0.97.tar.gz
-gcc-4.4.0-20090211.tar.bz2
+gcc-4.4.0-20090213.tar.bz2
 cloog-ppl-0.15.tar.gz


Index: gcc.spec
===================================================================
RCS file: /cvs/pkgs/rpms/gcc/devel/gcc.spec,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -r1.18 -r1.19
--- gcc.spec	11 Feb 2009 14:39:24 -0000	1.18
+++ gcc.spec	13 Feb 2009 13:27:56 -0000	1.19
@@ -1,9 +1,9 @@
-%define DATE 20090211
-%define SVNREV 144103
+%define DATE 20090213
+%define SVNREV 144154
 %define gcc_version 4.4.0
 # Note, gcc_release must be integer, if you want to add suffixes to
 # %{release}, append them after %{gcc_release} on Release: line.
-%define gcc_release 0.17
+%define gcc_release 0.18
 %define _unpackaged_files_terminate_build 0
 %define multilib_64_archs sparc64 ppc64 s390x x86_64
 %define include_gappletviewer 1
@@ -140,7 +140,7 @@
 Patch20: gcc44-libtool-no-rpath.patch
 Patch21: gcc44-cloog-dl.patch
 Patch22: gcc44-raw-string.patch
-Patch23: gcc44-rh479912.patch
+Patch23: gcc44-pr39175.patch
 
 Patch1000: fastjar-0.97-segfault.patch
 
@@ -427,7 +427,7 @@
 %patch21 -p0 -b .cloog-dl~
 %endif
 %patch22 -p0 -b .raw-string~
-%patch23 -p0 -b .rh479912~
+%patch23 -p0 -b .pr39175~
 
 # This testcase doesn't compile.
 rm libjava/testsuite/libjava.lang/PR35020*
@@ -1762,6 +1762,12 @@
 %doc rpm.doc/changelogs/libmudflap/ChangeLog*
 
 %changelog
+* Fri Feb 13 2009 Jakub Jelinek <jakub at redhat.com> 4.4.0-0.18
+- update from trunk
+  - PRs c++/30111, c++/38950, c++/39153, c/35444, middle-end/39154,
+	target/38824, target/39152
+- fix ICE on ppc32 with -fpic -fvisibility=hidden (#485232, PR target/39175)
+
 * Wed Feb 11 2009 Jakub Jelinek <jakub at redhat.com> 4.4.0-0.17
 - update from trunk
   - fix ICE on xen (PR target/39139)


Index: sources
===================================================================
RCS file: /cvs/pkgs/rpms/gcc/devel/sources,v
retrieving revision 1.257
retrieving revision 1.258
diff -u -r1.257 -r1.258
--- sources	11 Feb 2009 14:39:24 -0000	1.257
+++ sources	13 Feb 2009 13:27:56 -0000	1.258
@@ -1,3 +1,3 @@
 2659f09c2e43ef8b7d4406321753f1b2  fastjar-0.97.tar.gz
-563b17cabc73a7f8c7a9e3c1c89356e3  gcc-4.4.0-20090211.tar.bz2
+0acb344a0e9609873db234f701b7095b  gcc-4.4.0-20090213.tar.bz2
 716b7a0823f96c9d02c1703a9c47d387  cloog-ppl-0.15.tar.gz


--- gcc44-rh479912.patch DELETED ---




More information about the fedora-extras-commits mailing list