This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/44175] [C++0x] decltype sometimes cannot recurse


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=44175

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

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

--- Comment #8 from Jakub Jelinek <jakub at gcc dot gnu.org> 2011-06-08 06:08:54 UTC ---
I wonder if for at least Linux host the driver shouldn't attempt to increase
stack size for its children, say to 32MB if possible:

{
  struct rlimit rl;
  if (getrlimit (RLIMIT_STACK, &rl) == 0)
    {
      if (rl.rlim_cur != RLIM_INFINITY
          && rl.rlim_cur < 32*1024*1024
          && (rl.rlim_max == RLIM_INFINITY
              || rl.rlim_max > rl.rlim_cur))
        {
          if (rl.rlim_max == RLIM_INFINITY || rl.rlim_max >= 32*1024*1024)
            rl.rlim_cur = 32*1024*1024;
          else
            rl.rlim_cur = rl.rlim_max;
          setrlimit (RLIMIT_STACK, &rl);
        }
    }
}

then I guess maximum tinst depth could go back to 1024.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]