POV-Ray : Newsgroups : povray.beta-test : RC5 32 bit, not releasing memory on failure to load a large file. Server Time
23 Dec 2024 00:27:22 EST (-0500)
  RC5 32 bit, not releasing memory on failure to load a large file. (Message 1 to 10 of 11)  
Goto Latest 10 Messages Next 1 Messages >>>
From: Stephen
Subject: RC5 32 bit, not releasing memory on failure to load a large file.
Date: 24 Apr 2012 05:56:22
Message: <4f9678c6@news.povray.org>
I tried to load a large (>800 Meg) inc file into the editor and got this 
error:
Failed to open file:
Not enough storage is available to process this command.



OS Win7, 8 Gigs Ram

-- 
Regards
     Stephen


Post a reply to this message

From: Thorsten Froehlich
Subject: Re: RC5 32 bit, not releasing memory on failure to load a large file.
Date: 24 Apr 2012 11:01:27
Message: <4f96c047$1@news.povray.org>
On 24.04.12 11:56, Stephen wrote:
> I tried to load a large (>800 Meg) inc file into the editor and got this error:
> Failed to open file:
> Not enough storage is available to process this command.
>


How did you determine that the memory wasn't released?

> OS Win7, 8 Gigs Ram

32 or 64?

	Thorsten


Post a reply to this message

From: Stephen
Subject: Re: RC5 32 bit, not releasing memory on failure to load a large file.
Date: 24 Apr 2012 11:24:30
Message: <4f96c5ae@news.povray.org>
On 24/04/2012 4:01 PM, Thorsten Froehlich wrote:
> On 24.04.12 11:56, Stephen wrote:
>> I tried to load a large (>800 Meg) inc file into the editor and got
>> this error:
>> Failed to open file:
>> Not enough storage is available to process this command.
>>

>
> How did you determine that the memory wasn't released?

Task manager showed the memory usage going up when I tried to open the 
file then stabilising. When I exited PovRay the memory usage went back 
down to what it was before.

>
>> OS Win7, 8 Gigs Ram
>
> 32 or 64?
>

Win 7 64 bit but running pvengine-sse2 at the time


-- 
Regards
     Stephen


Post a reply to this message

From: Chris Cason
Subject: Re: RC5 32 bit, not releasing memory on failure to load a large file.
Date: 24 Apr 2012 11:32:24
Message: <4f96c788$1@news.povray.org>
On 25/04/2012 01:24, Stephen wrote:
> Task manager showed the memory usage going up when I tried to open the 
> file then stabilising. When I exited PovRay the memory usage went back 
> down to what it was before.

This isn't unusual for windows programs. When POV-Ray requests memory,
in some cases the request goes through the Visual C++ run-time
library, which then requests memory from Windows. If POV-Ray later
releases that memory, there is no guarantee that the RTL will then
hand it back to windows; there is a performance penalty to asking the
OS for memory so it is common for it to be retained in the heap
managed by the RTL.

This shouldn't be a problem as windows manages virtual memory
automatically and will page out RAM that the program has allocated but
isn't actively using (i.e. spare memory in the RTL's heap) if it needs
memory for something else.

That's not to say that the problem you observed isn't a bug; it could
very well be that the editor code didn't release the allocated memory
when it failed to load the file. I'd have to look further.

-- Chris


Post a reply to this message

From: Stephen
Subject: Re: RC5 32 bit, not releasing memory on failure to load a large file.
Date: 24 Apr 2012 14:00:15
Message: <4f96ea2f@news.povray.org>
On 24/04/2012 4:32 PM, Chris Cason wrote:
> On 25/04/2012 01:24, Stephen wrote:
>> Task manager showed the memory usage going up when I tried to open the
>> file then stabilising. When I exited PovRay the memory usage went back
>> down to what it was before.
>
> This isn't unusual for windows programs. When POV-Ray requests memory,
> in some cases the request goes through the Visual C++ run-time
> library, which then requests memory from Windows. If POV-Ray later
> releases that memory, there is no guarantee that the RTL will then
> hand it back to windows; there is a performance penalty to asking the
> OS for memory so it is common for it to be retained in the heap
> managed by the RTL.
>
> This shouldn't be a problem as windows manages virtual memory
> automatically and will page out RAM that the program has allocated but
> isn't actively using (i.e. spare memory in the RTL's heap) if it needs
> memory for something else.
>
> That's not to say that the problem you observed isn't a bug; it could
> very well be that the editor code didn't release the allocated memory
> when it failed to load the file. I'd have to look further.
>

Thanks Chris.
Just one other symptom. After the file fails to load and Process 
Explorer records PovRay having 2.8 Gigs of private memory. I tried to 
render another file and got the message:

Possible Parse Error: Insufficient memory to allocate intermediate image 
storage.
Fatal error in parser: Out of memory.
Render failed


-- 
Regards
     Stephen


Post a reply to this message

From: Christian Froeschlin
Subject: Re: RC5 32 bit, not releasing memory on failure to load a large file.
Date: 24 Apr 2012 14:01:41
Message: <4f96ea85$1@news.povray.org>
Stephen wrote:

> I tried to load a large (>800 Meg) inc file into the editor

the possible memory release problem aside, I think most text
editors are not designed to handle such files gracefully. Your
chances will be better with the x64 version but I'd still be
wary about things like syntax highlighting ;)


Post a reply to this message

From: Chris Cason
Subject: Re: RC5 32 bit, not releasing memory on failure to load a large file.
Date: 24 Apr 2012 14:10:23
Message: <4f96ec8f@news.povray.org>
On 25/04/2012 04:00, Stephen wrote:
> Just one other symptom. After the file fails to load and Process 
> Explorer records PovRay having 2.8 Gigs of private memory. I tried to 
> render another file and got the message:
> 
> Possible Parse Error: Insufficient memory to allocate intermediate image 
> storage.
> Fatal error in parser: Out of memory.
> Render failed

That certainly does sound like the memory wasn't released back to the
heap. Thanks for the heads-up, I'll try to duplicate it.

-- Chris


Post a reply to this message

From: Stephen
Subject: Re: RC5 32 bit, not releasing memory on failure to load a large file.
Date: 24 Apr 2012 14:37:42
Message: <4f96f2f6@news.povray.org>
On 24/04/2012 7:10 PM, Chris Cason wrote:
> That certainly does sound like the memory wasn't released back to the
> heap. Thanks for the heads-up, I'll try to duplicate it.

Although the file is 840 MB it compresses to 169 MB so I could always 
split it and send it via Big File Transfer, or the like.

-- 
Regards
     Stephen


Post a reply to this message

From: Chris Cason
Subject: Re: RC5 32 bit, not releasing memory on failure to load a large file.
Date: 24 Apr 2012 14:41:49
Message: <4f96f3ed$1@news.povray.org>
On 25/04/2012 04:37, Stephen wrote:
> On 24/04/2012 7:10 PM, Chris Cason wrote:
>> That certainly does sound like the memory wasn't released back to the
>> heap. Thanks for the heads-up, I'll try to duplicate it.
> 
> Although the file is 840 MB it compresses to 169 MB so I could always 
> split it and send it via Big File Transfer, or the like.

Thanks for the offer, I don't expect that's needed though - I would
suspect the issue isn't related to the content. You could try a
different (but similarly large) file to see if it happens with that too.

-- Chris


Post a reply to this message

From: Stephen
Subject: Re: RC5 32 bit, not releasing memory on failure to load a large file.
Date: 24 Apr 2012 14:44:54
Message: <4f96f4a6@news.povray.org>
On 24/04/2012 7:01 PM, Christian Froeschlin wrote:
> Stephen wrote:
>
>> I tried to load a large (>800 Meg) inc file into the editor
>
> the possible memory release problem aside, I think most text
> editors are not designed to handle such files gracefully. Your
> chances will be better with the x64 version but I'd still be
> wary about things like syntax highlighting ;)

So true. I just wanted the name of a group inside it. I ended up using 
the Hex editor XVI32. Then Pov 64 bit for rendering.
A waste of time, really. An isosurface did the trick.

-- 
Regards
     Stephen


Post a reply to this message

Goto Latest 10 Messages Next 1 Messages >>>

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.