[gcc/f16] 4.6.1-10

Jakub Jelinek jakub at fedoraproject.org
Mon Oct 3 18:33:09 UTC 2011


commit 37a4ebf94483cebbc56e6760248fd009a965b186
Author: Jakub Jelinek <jakub at redhat.com>
Date:   Mon Oct 3 20:31:55 2011 +0200

    4.6.1-10

 gcc.spec           |    2 ++
 gcc46-godump.patch |   35 +++++++++++++++++++++++++++++++++++
 2 files changed, 37 insertions(+), 0 deletions(-)
---
diff --git a/gcc.spec b/gcc.spec
index 0306aca..0c73628 100644
--- a/gcc.spec
+++ b/gcc.spec
@@ -169,6 +169,7 @@ Patch15: gcc46-libstdc++-docs.patch
 Patch17: gcc46-no-add-needed.patch
 Patch18: gcc46-ppl-0.10.patch
 Patch19: gcc46-pr47858.patch
+Patch20: gcc46-godump.patch
 
 Patch1000: fastjar-0.97-segfault.patch
 Patch1001: fastjar-0.97-len1.patch
@@ -640,6 +641,7 @@ package or when debugging this package.
 %patch18 -p0 -b .ppl-0.10~
 %endif
 %patch19 -p0 -b .pr47858~
+%patch20 -p0 -b .godump~
 
 %if 0%{?_enable_debug_packages}
 cat > split-debuginfo.sh <<\EOF
diff --git a/gcc46-godump.patch b/gcc46-godump.patch
new file mode 100644
index 0000000..9f8dec0
--- /dev/null
+++ b/gcc46-godump.patch
@@ -0,0 +1,35 @@
+2011-10-03  Jakub Jelinek  <jakub at redhat.com>
+	    Ian Lance Taylor  <iant at google.com>
+
+	* godump.c (go_output_typedef): Handle printing also
+	enum values that don't fit into signed HWI.
+
+--- gcc/godump.c.jj	2011-03-15 15:31:35.000000000 +0100
++++ gcc/godump.c	2011-10-03 20:27:50.762422071 +0200
+@@ -844,9 +844,23 @@ go_output_typedef (struct godump_contain
+       for (element = TYPE_VALUES (TREE_TYPE (decl));
+ 	   element != NULL_TREE;
+ 	   element = TREE_CHAIN (element))
+-	fprintf (go_dump_file, "const _%s = " HOST_WIDE_INT_PRINT_DEC "\n",
+-		 IDENTIFIER_POINTER (TREE_PURPOSE (element)),
+-		 tree_low_cst (TREE_VALUE (element), 0));
++	if (host_integerp (TREE_VALUE (element), 0))
++	  fprintf (go_dump_file, "const _%s = " HOST_WIDE_INT_PRINT_DEC "\n",
++		   IDENTIFIER_POINTER (TREE_PURPOSE (element)),
++		   tree_low_cst (TREE_VALUE (element), 0));
++	else if (host_integerp (TREE_VALUE (element), 1))
++	  fprintf (go_dump_file,
++		   "const _%s = " HOST_WIDE_INT_PRINT_UNSIGNED "\n",
++		   IDENTIFIER_POINTER (TREE_PURPOSE (element)),
++		   tree_low_cst (TREE_VALUE (element), 1));
++	else
++	  fprintf (go_dump_file,
++		   "const _%s = " HOST_WIDE_INT_PRINT_DOUBLE_HEX "\n",
++		   IDENTIFIER_POINTER (TREE_PURPOSE (element)),
++		   (unsigned HOST_WIDE_INT)
++		   TREE_INT_CST_HIGH (TREE_VALUE (element)),
++		   TREE_INT_CST_LOW (TREE_VALUE (element)));
++
+       pointer_set_insert (container->decls_seen, TREE_TYPE (decl));
+       if (TYPE_CANONICAL (TREE_TYPE (decl)) != NULL_TREE)
+ 	pointer_set_insert (container->decls_seen,


More information about the scm-commits mailing list