[Bug bootstrap/87747] [9 regression] Bootstrap failure if using gcc-4.6 as stage1 compiler
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87747 --- Comment #5 from Richard Earnshaw --- Author: rearnsha Date: Tue Oct 30 11:33:24 2018 New Revision: 265620 URL: https://gcc.gnu.org/viewcvs?rev=265620&root=gcc&view=rev Log: Don't allow the pool allocator to be configured to allocate zero-sized objects PR bootstrap/87747 would have been significantly easier to track down if the pool allocator had faulted an attempt to configure it to allocate zero-sized objects. Instead, this slipped through and we later hit memory corruption when the assumed size turned out to be different to the configured size. While, theoretically, there might be a use case for this, it seems unlikely to me that GCC would have such a use. So this patch adds a checking assert that the object size is not zero. * alloc-pool.h (base_pool_allocator ::initialize): Assert that the allocation size is not zero. Modified: trunk/gcc/ChangeLog trunk/gcc/alloc-pool.h
[Bug bootstrap/87747] [9 regression] Bootstrap failure if using gcc-4.6 as stage1 compiler
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87747 Richard Earnshaw changed: What|Removed |Added Status|UNCONFIRMED |RESOLVED Resolution|--- |FIXED --- Comment #4 from Richard Earnshaw --- -
[Bug bootstrap/87747] [9 regression] Bootstrap failure if using gcc-4.6 as stage1 compiler
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87747 --- Comment #3 from iii at gcc dot gnu.org --- Author: iii Date: Thu Oct 25 13:47:10 2018 New Revision: 265488 URL: https://gcc.gnu.org/viewcvs?rev=265488&root=gcc&view=rev Log: Fix rtx_code_size static initialization order fiasco r264556 and r264537 changed the format of EQ_ATTR_ALT RTXs to "ww", which also required adjusting rtx_code_size initializer. In order to simplify things, the list of rtx_codes known to use HOST_WIDE_INTs was replaced by the format string check. However, unlike the old one, this new check cannot be always performed at compile time, in which case a static constructor is generated. This may lead to a static initialization order fiasco with respect to other static constructors in the compiler, in case of PR87747, cselib's pool_allocator. gcc/ChangeLog: 2018-10-25 Ilya Leoshkevich PR bootstrap/87747 * rtl.c (RTX_CODE_HWINT_P_1): New helper macro. (RTX_CODE_HWINT_P): New macro. (rtx_code_size): Use RTX_CODE_HWINT_P (). Modified: trunk/gcc/ChangeLog trunk/gcc/rtl.c
[Bug bootstrap/87747] [9 regression] Bootstrap failure if using gcc-4.6 as stage1 compiler
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87747 --- Comment #2 from Ilya Leoshkevich --- This is a little bit more complicated, because EQ_ATTR_ALT is valid only for GENERATOR_FILEs. The regtest has just finished, so I will post the patch to the mailing list now.
[Bug bootstrap/87747] [9 regression] Bootstrap failure if using gcc-4.6 as stage1 compiler
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87747 Richard Biener changed: What|Removed |Added Priority|P3 |P1 Target Milestone|--- |9.0 --- Comment #1 from Richard Biener --- Expanding the || test is probably the fix.