[Bug middle-end/69780] [4.9/5/6 Regression] ICE on __builtin_alloca_with_align with small alignment
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69780 Martin Sebor changed: What|Removed |Added Status|ASSIGNED|RESOLVED Blocks||69759 Resolution|--- |FIXED --- Comment #6 from Martin Sebor --- Fixed in r233640. Referenced Bugs: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69759 [Bug 69759] __builtin_alloca and __builtin_alloca_with_align undocumented
[Bug middle-end/69780] [4.9/5/6 Regression] ICE on __builtin_alloca_with_align with small alignment
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69780 --- Comment #5 from Martin Sebor --- Author: msebor Date: Tue Feb 23 18:09:37 2016 New Revision: 233640 URL: https://gcc.gnu.org/viewcvs?rev=233640=gcc=rev Log: PR middle-end/69780 - [4.9/5/6 Regression] ICE on __builtin_alloca_with_align with small alignment PR c/69759 - __builtin_alloca and __builtin_alloca_with_align undocumented gcc/c-family/ChangeLog: * c-common.c (check_builtin_function_arguments): Validate and reject invalid arguments to __builtin_alloca_with_align. gcc/ChangeLog: * doc/extend.texi (Other Builtins): Document __builtin_alloca and __builtin_alloca_with_align. gcc/testsuite/ChangeLog: * g++.dg/ext/builtin_alloca.C: New test. * gcc.dg/builtins-68.c: New test. Added: trunk/gcc/testsuite/g++.dg/ext/builtin_alloca.C trunk/gcc/testsuite/gcc.dg/builtins-68.c Modified: trunk/gcc/ChangeLog trunk/gcc/c-family/ChangeLog trunk/gcc/c-family/c-common.c trunk/gcc/doc/extend.texi trunk/gcc/testsuite/ChangeLog
[Bug middle-end/69780] [4.9/5/6 Regression] ICE on __builtin_alloca_with_align with small alignment
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69780 --- Comment #4 from Martin Sebor --- Patch posted for review: https://gcc.gnu.org/ml/gcc-patches/2016-02/msg00947.html
[Bug middle-end/69780] [4.9/5/6 Regression] ICE on __builtin_alloca_with_align with small alignment
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69780 Jakub Jelinek changed: What|Removed |Added CC||jakub at gcc dot gnu.org --- Comment #2 from Jakub Jelinek --- Another ICE: void bar (int i) { void *p = __builtin_alloca_with_align (1, i); } I bet __builtin_alloca_with_align has never been meant to be used publicly, and requires that the second argument is integer constant (and is in bits, thus also needs to be a multiple of __CHAR_BITS__). I think the right fix is to require this, e.g. during __builtin_alloca_with_align expansion - and error out if it doesn't satisfy this.
[Bug middle-end/69780] [4.9/5/6 Regression] ICE on __builtin_alloca_with_align with small alignment
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69780 Martin Sebor changed: What|Removed |Added Status|NEW |ASSIGNED Assignee|unassigned at gcc dot gnu.org |msebor at gcc dot gnu.org --- Comment #3 from Martin Sebor --- Pretty much any invalid argument to __builtin_alloca_with_align (either first or second) causes an ICE, probably for the reason you mentioned. Let me try to come up with a patch to reject invalid arguments.
[Bug middle-end/69780] [4.9/5/6 Regression] ICE on __builtin_alloca_with_align with small alignment
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69780 Richard Biener changed: What|Removed |Added Status|UNCONFIRMED |NEW Last reconfirmed||2016-02-12 Known to work||4.6.4 Target Milestone|--- |4.9.4 Summary|ICE on |[4.9/5/6 Regression] ICE on |__builtin_alloca_with_align | |with small alignment|__builtin_alloca_with_align ||with small alignment Ever confirmed|0 |1 Known to fail||4.7.4, 4.8.5, 4.9.2, 5.3.0, ||6.0 --- Comment #1 from Richard Biener --- Confirmed as a regression from 4.6.x