RE: memory

new topic     » topic index » view thread      » older message » newer message

face it. euphoria is a memory hog. if you want it to be more efficient, 
try allocating a handle on some memory(euphoria uses 4 bytes per integer 
and 8 bytes per atom).

Kat wrote:
> Hey all,,
> 
> I have a short program that opens a 6.8megabyte file, containing text 
> separated by lots of {0}. The object is to eliminate the {zero}s, and 
> reformat 
> the results to a more text-looking file. What i can't figure is that 
> Taskinfo 
> says Eu is using 86Megabytes in memory to do it! 
> 
> Are these the lines doing it? Is a new instance of data created every 
> time it 
> is mentioned in the line?:
> 
> puts(1,"removing 10 nulls\n")
> place = match({0,0,0,0,0,0,0,0,0,0},data)
> while place do
>  data = data[1..place] & data[place+10..length(data)]
>  place = match({0,0,0,0,0,0,0,0,0,0},data)
> end while
> 
> 
> Kat
> 
>

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu