comp.lang.ada
 help / color / mirror / Atom feed
* Problem with large constant array (Gnat 3.15p)
@ 2004-01-26 11:32 Jano
  2004-01-26 15:02 ` Jano
  0 siblings, 1 reply; 2+ messages in thread
From: Jano @ 2004-01-26 11:32 UTC (permalink / raw)


Hi everybody,

I'm trying to compile a quite large constant array, generated by
another tool (namely, awsres from AWS). The array has this form:

package Example is

   use Ada.Streams;

   Content : aliased constant Stream_Element_Array :=
       (137,  80,  78,  71,  13,  10,  26,  10,   0,   0,   0,  13, 
73,  72,
         68,  82,   0,   0,   0,  14,   0,   0,   0,  14,   8,   3);

end Example;

Only that it has about 4.4 millions of elements. The spec file is
about 25mB in size.

I'm using a computer with 384mB (win NT) so it may be part of the
problem. What happens is that gnat1.exe gets as many as 650 mB of
virtual memory and, after half an hour, it still hasn't finished. I
wonder if a computer with enough memory to not swap could finish in a
reasonable time, or if there is some hidden N^2 ruining the
compilation memory usage/time. I've tried with a plain gnatmake
without switches to not use any extra feature but it behaves the same.

Any experiences on this?

Kind regards,

A. Mosteo.



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Problem with large constant array (Gnat 3.15p)
  2004-01-26 11:32 Problem with large constant array (Gnat 3.15p) Jano
@ 2004-01-26 15:02 ` Jano
  0 siblings, 0 replies; 2+ messages in thread
From: Jano @ 2004-01-26 15:02 UTC (permalink / raw)


Jano dice...
> Hi everybody,
> 
> I'm trying to compile a quite large constant array, generated by
> another tool (namely, awsres from AWS). The array has this form:
> 
> package Example is
> 
>    use Ada.Streams;
> 
>    Content : aliased constant Stream_Element_Array :=
>        (137,  80,  78,  71,  13,  10,  26,  10,   0,   0,   0,  13, 
> 73,  72,
>          68,  82,   0,   0,   0,  14,   0,   0,   0,  14,   8,   3);
> 
> end Example;
> 
> Only that it has about 4.4 millions of elements. The spec file is
> about 25mB in size.
> 
> I'm using a computer with 384mB (win NT) so it may be part of the
> problem. What happens is that gnat1.exe gets as many as 650 mB of
> virtual memory and, after half an hour, it still hasn't finished. I
> wonder if a computer with enough memory to not swap could finish in a
> reasonable time, or if there is some hidden N^2 ruining the
> compilation memory usage/time. I've tried with a plain gnatmake
> without switches to not use any extra feature but it behaves the same.
> 
> Any experiences on this?

Answering to myself: A machine with 1GB/amd2000+ compiles it in about 
30s. It seems the time bottleneck is thus because of memory swapping. I 
cannot say if the >600MB memory usage is reasonable or not but I have 
had reports of another compiler suffering the same problem.



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2004-01-26 15:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-01-26 11:32 Problem with large constant array (Gnat 3.15p) Jano
2004-01-26 15:02 ` Jano

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox