[CMake] Why does cmake adds /STACK:10000000 for msvc linker?
Andrew Maclean
andrew.amaclean at gmail.com
Mon Apr 13 01:20:41 EDT 2009
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 <sahn at pobox.com> 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
> <Ch.Ehrlicher at gmx.de> 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/
___________________________________________
More information about the CMake
mailing list