This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fallout on full bootstrap

On 11.10.14 12:43, Jan-Benedict Glaw wrote:
On Wed, 2014-10-08 17:10:01 -0000, <> wrote:
	* ipa-polymorphic-call.c (extr_type_from_vtbl_store): Do better
	pattern matching of MEM_REF.
	(check_stmt_for_type_change): Update.

This recent commit led to fallout for all targets build with

g++ -c   -g -O2 -DIN_GCC  -DCROSS_DIRECTORY_STRUCTURE  -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute -Woverloaded-virtual -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -Werror -fno-common  -DHAVE_CONFIG_H -I. -I. -I../../../gcc/gcc -I../../../gcc/gcc/. -I../../../gcc/gcc/../include -I../../../gcc/gcc/../libcpp/include -I/opt/cfarm/mpc/include  -I../../../gcc/gcc/../libdecnumber -I../../../gcc/gcc/../libdecnumber/dpd -I../libdecnumber -I../../../gcc/gcc/../libbacktrace    -o ipa-polymorphic-call.o -MT ipa-polymorphic-call.o -MMD -MP -MF ./.deps/ipa-polymorphic-call.TPo ../../../gcc/gcc/ipa-polymorphic-call.c
../../../gcc/gcc/ipa-polymorphic-call.c: In function âtree_node* extr_type_from_vtbl_ptr_store(gimple, type_change_info*, long int*)â:
../../../gcc/gcc/ipa-polymorphic-call.c:2117:1: error: assuming signed overflow does not occur when assuming that (X + c) < X is always false [-Werror=strict-overflow]
cc1plus: all warnings being treated as errors
make[2]: *** [ipa-polymorphic-call.o] Error 1
make[2]: Leaving directory `/home/jbglaw/build-configlist_mk/iq2000-elf/build-gcc/mk/iq2000-elf/gcc'
make[1]: *** [all-gcc] Error 2

(Note that this `g++' is an up-to-date revision, and the line number
mentioned is also wrong.)  It's probably caused by this chunk:

diff --git a/gcc/ipa-polymorphic-call.c b/gcc/ipa-polymorphic-call.c
index 3e4aa04..51c6709 100644
--- a/gcc/ipa-polymorphic-call.c
+++ b/gcc/ipa-polymorphic-call.c
@@ -1218,7 +1226,19 @@ extr_type_from_vtbl_ptr_store (gimple stmt, struct type_change_info *tci,
               print_generic_expr (dump_file, tci->instance, TDF_SLIM);
               fprintf (dump_file, " with offset %i\n", (int)tci->offset);
-         return NULL_TREE;
+         return tci->offset > GET_MODE_BITSIZE (Pmode) ? error_mark_node : NULL_TREE;
+       }
+      if (offset != tci->offset
+         || size != POINTER_SIZE
+         || max_size != POINTER_SIZE)
+       {
+         if (dump_file)
+           fprintf (dump_file, "    wrong offset %i!=%i or size %i\n",
+                    (int)offset, (int)tci->offset, (int)size);
+         return offset + GET_MODE_BITSIZE (Pmode) <= offset		<------------------------
+                || (max_size != -1
+                    && tci->offset + GET_MODE_BITSIZE (Pmode) > offset + max_size)
+                ? error_mark_node : NULL;

This is visible on all builds, see eg. just a few
recent ones:


This is Bug 63496


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]