From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: * X-Spam-Status: No, score=1.3 required=5.0 tests=BAYES_00,INVALID_MSGID, MSGID_RANDY autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,a2aeab5a4f8df549 X-Google-Attributes: gid103376,public From: gdemont@my-deja.com Subject: Re: Large arrays in GNAT Date: 2000/07/16 Message-ID: <8kt0mb$a6b$1@nnrp1.deja.com>#1/1 X-Deja-AN: 647057863 References: <3971DC1F.D415BFBE@npolar.no> X-Http-Proxy: 1.0 sitelnet.unine.ch:8080 (Squid/2.1.PATCH2), 1.0 x62.deja.com:80 (Squid/1.1.22) for client 130.125.13.32, 130.125.90.100 Organization: Deja.com - Before you buy. X-Article-Creation-Date: Sun Jul 16 18:59:29 2000 GMT X-MyDeja-Info: XMYDJUIDgdemont Newsgroups: comp.lang.ada X-Http-User-Agent: Mozilla/4.72 (Macintosh; I; PPC) Date: 2000-07-16T00:00:00+00:00 List-Id: > I cannot declare an array of Float larger than 2.5 mill elements > using my Ada95 gnat compiler (gnat-3.12p-12) on my linux box. > A : array (Integer range 1 .. 2_500_000) of Float; A is taken on the stack, so if the "exe" has a limit on that, you have to extend this limit. A more comfortable way is to allocate A in the heap - according to the OS, the only limit is +/- the total user workspace in virtual memory (4 GB on a 32-bit system). type vector is array (Integer range <>) of Float; type vector_a is access vector; A: vector_a:= New vector(1 .. 2_500_000); HTH ______________________________________________________ Gautier -- http://members.xoom.com/gdemont/gsoft.htm Sent via Deja.com http://www.deja.com/ Before you buy.