re PR lto/64075 (ICE: in bp_pack_value, at data-streamer.h:106)
authorIlya Enkovich <ilya.enkovich@intel.com>
Wed, 26 Nov 2014 13:53:38 +0000 (13:53 +0000)
committerIlya Enkovich <ienkovich@gcc.gnu.org>
Wed, 26 Nov 2014 13:53:38 +0000 (13:53 +0000)
gcc/

PR lto/64075
* tree-streamer-in.c (unpack_ts_function_decl_value_fields): Use
proper size for function_code bitfield.
(pack_ts_function_decl_value_fields): Likewise.

gcc/testsuite/

PR lto/64075
* gcc.dg/pr64075.c: New.

From-SVN: r218083

gcc/ChangeLog
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/pr64075.c [new file with mode: 0644]
gcc/tree-streamer-in.c
gcc/tree-streamer-out.c

index 8dd1ab758019343e700e96abf5458dca2a385f44..9f2d701439b84ea6de259513ee69e5682c585fd9 100644 (file)
@@ -1,3 +1,10 @@
+2014-11-26  Ilya Enkovich  <ilya.enkovich@intel.com>
+
+       PR lto/64075
+       * tree-streamer-in.c (unpack_ts_function_decl_value_fields): Use
+       proper size for function_code bitfield.
+       (pack_ts_function_decl_value_fields): Likewise.
+
 2014-11-21  Mark Wielaard  <mjw@redhat.com>
 
        * doc/invoke.texi (-gdwarf-@{version}): Mention experimental DWARFv5.
index adf4a3842487159090103198a9af6781f2979418..03605d1178e547a1f1d489a352d041475c73aea8 100644 (file)
@@ -1,3 +1,8 @@
+2014-11-26  Ilya Enkovich  <ilya.enkovich@intel.com>
+
+       PR lto/64075
+       * gcc.dg/pr64075.c: New.
+
 2014-11-26  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
 
        * gcc.target/i386/pr63620.c: XFAIL get_pc_thunk scan on
diff --git a/gcc/testsuite/gcc.dg/pr64075.c b/gcc/testsuite/gcc.dg/pr64075.c
new file mode 100644 (file)
index 0000000..f913a79
--- /dev/null
@@ -0,0 +1,9 @@
+/* PR lto/64075 */
+/* { dg-do compile } */
+/* { dg-require-effective-target lto } */
+/* { dg-options "-flto" } */
+
+_Complex float test (float a, float b, float c, float d)
+{
+  return 1.0iF;
+}
index 99448dd33f3f00f86256aa0672b7d1047cc90783..eb205edb700cd05a101c864d3c136cfd1905b3f2 100644 (file)
@@ -333,7 +333,7 @@ unpack_ts_function_decl_value_fields (struct bitpack_d *bp, tree expr)
   if (DECL_BUILT_IN_CLASS (expr) != NOT_BUILT_IN)
     {
       DECL_FUNCTION_CODE (expr) = (enum built_in_function) bp_unpack_value (bp,
-                                                                           11);
+                                                                           12);
       if (DECL_BUILT_IN_CLASS (expr) == BUILT_IN_NORMAL
          && DECL_FUNCTION_CODE (expr) >= END_BUILTINS)
        fatal_error ("machine independent builtin code out of range");
index ad58b849f791dd9cd33d0fb1b8a7ab0eac5d40fc..0d87cfff9f4d4b58d026c0a141adff3372c3f0a7 100644 (file)
@@ -300,7 +300,7 @@ pack_ts_function_decl_value_fields (struct bitpack_d *bp, tree expr)
   bp_pack_value (bp, DECL_PURE_P (expr), 1);
   bp_pack_value (bp, DECL_LOOPING_CONST_OR_PURE_P (expr), 1);
   if (DECL_BUILT_IN_CLASS (expr) != NOT_BUILT_IN)
-    bp_pack_value (bp, DECL_FUNCTION_CODE (expr), 11);
+    bp_pack_value (bp, DECL_FUNCTION_CODE (expr), 12);
 }