[Bug middle-end/86715] ICE passing too large argument on stack

2020-03-27 Thread segher at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86715

Segher Boessenkool  changed:

   What|Removed |Added

 Resolution|--- |WONTFIX
 Status|UNCONFIRMED |RESOLVED

--- Comment #2 from Segher Boessenkool  ---
"struct Matrix" is over 2GB big.  The whole stack is just a few megabytes
typically.  Passing "struct Matrix" on the stack is entirely unreasonable.

The comment right before this sorry() is
  /* We don't allow passing huge (> 2^30 B) arguments
 by value.  It would cause an overflow later on.  */
and this is in generic code.

Closing as WONTFIX.  Sorry.

[Bug middle-end/86715] ICE passing too large argument on stack

2020-03-26 Thread xerofoify at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86715

Nicholas Krause  changed:

   What|Removed |Added

 CC||segher at gcc dot gnu.org,
   ||xerofoify at gmail dot com

--- Comment #1 from Nicholas Krause  ---
Hi,

This does not seem to be happening in the middle end but in RTL expand. I've
tried on x86_64 trunk and now powerpc. Seems to only happen on PowerPC now as
seen here:
test.cpp: In function ‘int main(int, char**)’:
test.cpp:33:23: sorry, unimplemented: passing too large argument on stack
   33 |   result = mulm(m1, m2);
  |   ^
during RTL pass: expand
g++: internal compiler error: Segmentation fault signal terminated program
cc1plus
Please submit a full bug report,
with preprocessed source if appropriate.
See  for instructions.


I'm not aware of stack size limitations on Power so I'm CCed the maintainer to
take a look. Not sure if this occurs on other architectures in expand like ARM
as well. Segher would you please take a look at this for me.