I've asked the same question some time ago ( http://www.mail-archive.com/[email protected]/msg14883.html).
We had a problem with big number of threads: the 32-bit address space can fit only ~200 threads with such huge stacks. So if you are writing multithreaded application, it is best to remove this option from flags. On Mon, Apr 13, 2009 at 9:20 AM, Andrew Maclean <[email protected]>wrote: > I think the reason was that when Visual Studio 6 was used to build VTK > it used to run out of stack space necessitating the large value that > needed to be set. > > I am pretty sure that this was the case because I think I was one of > the people who noted this problem in the "old days"! > > Andrew > > > On Mon, Apr 13, 2009 at 2:07 AM, Sahn Lam <[email protected]> wrote: > > Don't know the reason behind this, but this is how we unset it: > > > > # > > # Remove /STACK:10000000 set by CMake. This value for stack size > > # is very high, limiting the number of threads we can spawn. > > # Default value used by Windows is 1MB which is good enough. > > # > > STRING(REGEX REPLACE "/STACK:[0-9]+" "" > > CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS}") > > > > > > On Sun, Apr 12, 2009 at 2:48 AM, Christian Ehrlicher > > <[email protected]> wrote: > >> Hi, > >> > >> I don't understand the reason behind this. We've a very huge memory > >> footprint because of this on kde4/windows - kded4.exe has ~30 Threads > >> which means 300MB of stack! > >> > >> Is there an easy way to change this? > >> > >> > >> Thx, > >> Christian > >> _______________________________________________ > >> Powered by www.kitware.com > >> > >> Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > >> > >> Please keep messages on-topic and check the CMake FAQ at: > http://www.cmake.org/Wiki/CMake_FAQ > >> > >> Follow this link to subscribe/unsubscribe: > >> http://www.cmake.org/mailman/listinfo/cmake > >> > > _______________________________________________ > > Powered by www.kitware.com > > > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > > > Please keep messages on-topic and check the CMake FAQ at: > http://www.cmake.org/Wiki/CMake_FAQ > > > > Follow this link to subscribe/unsubscribe: > > http://www.cmake.org/mailman/listinfo/cmake > > > > > > -- > ___________________________________________ > Andrew J. P. Maclean > Centre for Autonomous Systems > The Rose Street Building J04 > The University of Sydney 2006 NSW > AUSTRALIA > Ph: +61 2 9351 3283 > Fax: +61 2 9351 7474 > URL: http://www.acfr.usyd.edu.au/ > ___________________________________________ > _______________________________________________ > Powered by www.kitware.com > > Visit other Kitware open-source projects at > http://www.kitware.com/opensource/opensource.html > > Please keep messages on-topic and check the CMake FAQ at: > http://www.cmake.org/Wiki/CMake_FAQ > > Follow this link to subscribe/unsubscribe: > http://www.cmake.org/mailman/listinfo/cmake >
_______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
