From: Ilya Enkovich Date: Wed, 26 Nov 2014 13:53:38 +0000 (+0000) Subject: re PR lto/64075 (ICE: in bp_pack_value, at data-streamer.h:106) X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=3c350d48a595d93c3e6336b79091d7f506a5fb03;p=gcc.git re PR lto/64075 (ICE: in bp_pack_value, at data-streamer.h:106) 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 --- diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 8dd1ab75801..9f2d701439b 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,10 @@ +2014-11-26 Ilya Enkovich + + 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 * doc/invoke.texi (-gdwarf-@{version}): Mention experimental DWARFv5. diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index adf4a384248..03605d1178e 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2014-11-26 Ilya Enkovich + + PR lto/64075 + * gcc.dg/pr64075.c: New. + 2014-11-26 Rainer Orth * 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 index 00000000000..f913a79eed1 --- /dev/null +++ b/gcc/testsuite/gcc.dg/pr64075.c @@ -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; +} diff --git a/gcc/tree-streamer-in.c b/gcc/tree-streamer-in.c index 99448dd33f3..eb205edb700 100644 --- a/gcc/tree-streamer-in.c +++ b/gcc/tree-streamer-in.c @@ -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"); diff --git a/gcc/tree-streamer-out.c b/gcc/tree-streamer-out.c index ad58b849f79..0d87cfff9f4 100644 --- a/gcc/tree-streamer-out.c +++ b/gcc/tree-streamer-out.c @@ -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); }