Re: Largest size array in Gnat 2005 for the PC?




"Martin Krischik" <krischik@xxxxxxxxxxxxxxxxxxxxx> wrote in message
news:4726d889$1@xxxxxxxxxxxxxxx
ME schrieb:

What is the largest array (in storage units) that you can declare in Gnat
2005 for the PC?

How much virtual memory does your computer have?

Does pragma Storage_ size affect this and if so where would you place it
in
a procedure?

No, the array index used affect the maximum size. I suggest you read:
so then
Type My_Array is array (1..Long_Long_Integer'last) of record...
is fine?

http://en.wikibooks.org/wiki/Ada_Programming/Types/array

and consider what would happen if "Index_Range" is of type
Long_Long_Integer and if you computer has enough memory to hold such a
beast.

Martin

PS: There is no "GNAT 2005" - There is

1) "GNAT GPL 2005" which is 3 releases old - the current release is GNAT
GPL 2007-2
2) Ada 2005: which is a standard and as such puts no restriction or
arrays size whatsoever.

--
mailto://krischik@xxxxxxxxxxxxxxxxxxxxx
Ada programming at: http://ada.krischik.com


.



Relevant Pages

  • Re: Windows array allocation problem
    ... If the required size exceeds the possible size, the program has internal virtual memory management to solve the problem in pieces, storing intermediate pieces on the disk. ... much is available for an actual allocation. ... since the array dimension and the determination of whether to use the virtual memory manager are presently being determined by the calling program and passed in. ...
    (comp.lang.fortran)
  • Re: Windows array allocation problem
    ... The required array size is dictated by the size of the problem being solved, and it can easily be much greater than 2 GB. ... If the required size exceeds the possible size, the program has internal virtual memory management to solve the problem in pieces, storing intermediate pieces on the disk. ... The decision whether to use the virtual memory manager is currently made in a calling program, which passes along the result of that decision along with the required array size to the subject program. ...
    (comp.lang.fortran)
  • Re: J4 - presentation/discussion on "Future of the COBOL Standard"
    ... there is obviously no problem with allocating the maximum ... array size: all that's actually needed in the compiled program is a pointer ... of some sort to the virtual memory segment that it's stored in. ... compilers that actually allocate space as part of the compiled unit will run ...
    (comp.lang.cobol)
  • Re: Mergesort Vs Quicksort
    ... given as variable-length records packed end-to-end in one array, ... If your dataset is large enough that you can't allocate two full ... oodles of extra virtual memory you can allocate virtually for free, ... also allocating each CONS cell on the heap, ...
    (comp.programming)
  • Re: J4 - presentation/discussion on "Future of the COBOL Standard"
    ... there is obviously no problem with allocating the maximum ... array size: all that's actually needed in the compiled program is a pointer ... of some sort to the virtual memory segment that it's stored in. ... compilers that actually allocate space as part of the compiled unit will run ...
    (comp.lang.cobol)