On GCC-3.4.5 for mingw with Dwarf2-EH
Configured with: ../gcc-3.4.5/configure --with-gcc --with-gnu-ld --with-gnu-as
--host=mingw32 --target=mingw32 --prefix=/mingw --enable-threads --disable-nls
--enable-languages=c,c++,objc,f77 --disable-win32-registry --disable-shared
--disable-sjlj-exceptions --enable-libstdcxx-debug
Thread model: win32
gcc version 3.4.5 (mingw special)
The following testcase shows the stack grows every time an exception get
handled
until the program runs out of stack and crashs.
----------------------------------------
#include <stdio.h>
int main()
{
while(1)
{
try {
int n = 8*1024;
int p[n];
fprintf(stderr, "p=%p\n", p);
throw 1;
}catch(...) {
}
}
}
--
Summary: (mingw) Dwarf2-EH causes stack leak with VLA
Product: gcc
Version: 3.4.5
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: darkxun at paran dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33075