From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 30744 invoked by alias); 11 Apr 2011 14:06:02 -0000 Received: (qmail 30722 invoked by uid 22791); 11 Apr 2011 14:06:00 -0000 X-SWARE-Spam-Status: No, hits=-2.4 required=5.0 tests=AWL,BAYES_00,RCVD_IN_DNSWL_LOW,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from nef2.ens.fr (HELO nef2.ens.fr) (129.199.96.40) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Mon, 11 Apr 2011 14:05:55 +0000 Received: from mailhost.lps.ens.fr (tournesol.lps.ens.fr [129.199.120.1]) by nef2.ens.fr (8.13.6/1.01.28121999) with ESMTP id p3BE5cF1048252 ; Mon, 11 Apr 2011 16:05:38 +0200 (CEST) X-Envelope-To: gcc-patches@gcc.gnu.org Received: from localhost (localhost [127.0.0.1]) by mailhost.lps.ens.fr (Postfix) with ESMTP id 04B1A3BE17; Mon, 11 Apr 2011 16:05:38 +0200 (CEST) Received: from mailhost.lps.ens.fr ([127.0.0.1]) by localhost (tournesol.lps.ens.fr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LAXCfM+SpWAN; Mon, 11 Apr 2011 16:05:37 +0200 (CEST) Received: by mailhost.lps.ens.fr (Postfix, from userid 8513) id E3A603BE18; Mon, 11 Apr 2011 16:05:37 +0200 (CEST) Date: Mon, 11 Apr 2011 14:06:00 -0000 To: matz@suse.de, ebotcazou@adacore.com Cc: paul.richard.thomas@gmail.com, gcc-patches@gcc.gnu.org, fortran@gcc.gnu.org, dominiq@lps.ens.fr Subject: Re: Implement stack arrays even for unknown sizes References: <20110409100809.BF9CD3BE18@mailhost.lps.ens.fr> <20110410132925.5B1493BE18@mailhost.lps.ens.fr> <201104111529.43906.ebotcazou@adacore.com> In-Reply-To: <201104111529.43906.ebotcazou@adacore.com> User-Agent: Heirloom mailx 12.4pre 6/29/08 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Message-Id: <20110411140537.E3A603BE18@mailhost.lps.ens.fr> From: dominiq@lps.ens.fr (Dominique Dhumieres) Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org X-SW-Source: 2011-04/txt/msg00755.txt.bz2 > What ulimit -s have you used for your capacita tests? On *-apple-darwin* the stacksize is limited to (kbytes, -s) 65532 and it is hard coded. It is my (very limited) understanding that this limit can be bypassed by using something such as -Wl,-stack_size,0xf0000000 (for 1Gbytes in 64 bit mode -in 32 bit mode you need an additional trick). Doing so for capacita does not help. For nf the best I get is [macbook] lin/test% gfc -Ofast -funroll-loops -fstack-arrays nf.f90 -g -save-temps [macbook] lin/test% valgrind --max-stackframe=64118496 a.out ==25739== Memcheck, a memory error detector ==25739== Copyright (C) 2002-2010, and GNU GPL'd, by Julian Seward et al. ==25739== Using Valgrind-3.6.1 and LibVEX; rerun with -h for copyright info ==25739== Command: a.out ==25739== Solve 97 by 105 by 99 FD problem - method=NFCG Band elements are 100.00, 10.00, and 1.00. stiffness= 1000.00 Target RMS residual = 0.1000E-06 Maximum Iterations = 50 Iter Alpha Beta RMS Residual Sum of Residuals 0 0.9958682E-01 100.0000 0 1.00000 0.1412538E-01 -0.2314427E-09 1 0.08835 0.00000 0.9698062E-02 -0.2522486E-09 ... 44 0.07743 0.55715 0.8934363E-07 -0.4388281E-14 Time for setup 0.868 Time per iteration 1.709 Total Time 76.049 ==25739== ==25739== HEAP SUMMARY: ==25739== in use at exit: 656 bytes in 13 blocks ==25739== total heap usage: 409 allocs, 396 frees, 387,298,208 bytes allocated ==25739== ==25739== LEAK SUMMARY: ==25739== definitely lost: 0 bytes in 0 blocks ==25739== indirectly lost: 0 bytes in 0 blocks ==25739== possibly lost: 0 bytes in 0 blocks ==25739== still reachable: 656 bytes in 13 blocks ==25739== suppressed: 0 bytes in 0 blocks ==25739== Rerun with --leak-check=full to see details of leaked memory ==25739== ==25739== For counts of detected and suppressed errors, rerun with: -v ==25739== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 0 from 0) > Compiling with -fstack-check should give the segfault reliably. It does not seems to work for me. Dominique