| delorie.com/archives/browse.cgi | search |
| Mailing-List: | contact cygwin-help AT cygwin DOT com; run by ezmlm |
| List-Subscribe: | <mailto:cygwin-subscribe AT cygwin DOT com> |
| List-Archive: | <http://sourceware.org/ml/cygwin/> |
| List-Post: | <mailto:cygwin AT cygwin DOT com> |
| List-Help: | <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs> |
| Sender: | cygwin-owner AT cygwin DOT com |
| Mail-Followup-To: | cygwin AT cygwin DOT com |
| Delivered-To: | mailing list cygwin AT cygwin DOT com |
| Message-ID: | <42E7DEA5.3040400@familiehaase.de> |
| Date: | Wed, 27 Jul 2005 21:21:09 +0200 |
| From: | "Gerrit P. Haase" <gerrit AT familiehaase DOT de> |
| User-Agent: | Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.8) Gecko/20050511 |
| MIME-Version: | 1.0 |
| To: | Krzysztof Duleba <krzysan AT skrzynka DOT pl> |
| CC: | cygwin AT cygwin DOT com |
| Subject: | Re: perl - segfault on "free unused scalar" |
| References: | <dc7n8k$m72$1 AT sea DOT gmane DOT org> <42E76865 DOT 4000301 AT familiehaase DOT de> <dc82t0$r0a$1 AT sea DOT gmane DOT org> <42E7B413 DOT 8040203 AT familiehaase DOT de> <dc8ebq$36m$1 AT sea DOT gmane DOT org> |
| In-Reply-To: | <dc8ebq$36m$1@sea.gmane.org> |
| X-IsSubscribed: | yes |
Krzysztof Duleba wrote:
> But there's plenty of memory left when perl crashes. I have 1 GB RAM and
> 1 GB swap file.
>
> I've simplified the test case. It seems that Cygwin perl can't handle
> too much memory. For instance:
>
> $ perl -e '$a="a"x(200 * 1024 * 1024); sleep 9'
This requires about 525 MB on my box.
> OK, this could have failed because $a might require 200 MB of continuous
> space. But hashes don't, do they? Then why does the following code fail?
>
> $ perl -e '$a="a"x(1024 * 1024);my %b; $b{$_}=$a for(1..400);sleep 9'
>
> Or that one?
Requires a little more, maybe about 550 MB.
> $ perl -e '$a="a"x(50 * 1024 * 1024);$b=$a;$c=$a;$d=$a;$e=$a;sleep 10'
This requires not that much, nearly 400 MB, but it is still about 16 MB
too much for the default Cygwin settings of 384 MB per program.
> On linux there's no such problem - perl can use all available memory.
Please see the docs about the limits on Cygwin how to increase the
maximum memory usage:
http://cygwin.com/cygwin-ug-net/cygwin-ug-net.html#setup-maxmem
Regards,
Gerrit
--
=^..^=
--
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Problem reports: http://cygwin.com/problems.html
Documentation: http://cygwin.com/docs.html
FAQ: http://cygwin.com/faq/
| webmaster | delorie software privacy |
| Copyright © 2019 by DJ Delorie | Updated Jul 2019 |