[Bug middle-end/69780] [4.9/5/6 Regression] ICE on __builtin_alloca_with_align with small alignment

jakub at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Sun Feb 14 20:19:00 GMT 2016


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69780

Jakub Jelinek <jakub at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |jakub at gcc dot gnu.org

--- Comment #2 from Jakub Jelinek <jakub at gcc dot gnu.org> ---
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.


More information about the Gcc-bugs mailing list