:: Home :: Get Hosted :: PPM FAQ :: Forum FAQ :: Search :: Memberlist :: Usergroups :: Register :: Profile :: Log in to check your private messages :: Log in ::
Do you want to advertise at Project Perfect Mod. Find out how to do it HERE.

The time now is Sat Dec 16, 2017 10:32 pm
All times are UTC + 0
 Forum index » Featured Tools » Voxel Section Editor III » Bug Reporting
Possible memory leak...
Moderators: stucuk
Post new topic   Reply to topic Page 1 of 1 [15 Posts] View previous topic :: View next topic
Author Message
G-E
General


Joined: 09 Feb 2015

PostPosted: Fri Mar 27, 2015 6:48 am    Post subject:   Possible memory leak... Reply with quote

I was working on the same model the whole time, my Halo helicopter, which is rather big but not that detailed.

I used autonormals a few times, mostly just drawing lines and stuff since was removing the voxel texture side effects of wonky internal coloured dots...

Suddenly I noticed everything I did had a delay, so I popped open tasks, and woooo 3.7GB!


memleak.jpg
 Description:
 Filesize:  106.96 KB
 Viewed:  2129 Time(s)

memleak.jpg



Back to top
View user's profile Send private message
Banshee
Supreme Banshee


Joined: 15 Aug 2002
Location: Brazil

PostPosted: Fri Mar 27, 2015 4:23 pm    Post subject: Reply with quote

Finding memory leaks is a complicated task. It could be anywhere and VXLSE III has currently over 136k lines of code. It's quite big, believe it or not.

A couple of years ago, I've worked hard to reduce the memory leak, specially with the 3D viewer.

If you point out all the procedures that you did to reach 3.7gb, it will be easier for me to find out which parts of the code are leaking memory.

Back to top
View user's profile Send private message Visit poster's website Skype Account
G-E
General


Joined: 09 Feb 2015

PostPosted: Fri Mar 27, 2015 6:13 pm    Post subject: Reply with quote

I didn't use the 3d viewer in that session at all, I didn't copy/paste anything either...

99% of it was drawing lines/dots/fills and the occasional undo.
_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
G-E
General


Joined: 09 Feb 2015

PostPosted: Fri Mar 27, 2015 6:14 pm    Post subject: Reply with quote

I'll keep an eye on it next time I work on a voxel at length.

I must say that impressively it didn't actually crash #Tongue
_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
Banshee
Supreme Banshee


Joined: 15 Aug 2002
Location: Brazil

PostPosted: Fri Mar 27, 2015 11:25 pm    Post subject: Reply with quote

If you don't disable the 3D viewer panel (that is below the two side view panels), you are still using.

But I'll pay a closer attention to the code from the drawing tools and Undo/Redo.

Back to top
View user's profile Send private message Visit poster's website Skype Account
G-E
General


Joined: 09 Feb 2015

PostPosted: Sat Mar 28, 2015 1:48 am    Post subject: Reply with quote

Any idea why most models "center" in the viewer around a rearward side position?

It appears that more than half the voxel I load, if I rotate them in the viewer, they spin from a fixed point at the right-rear... the effect of this is when turning it to the side more of the voxel goes off screen. Also checking left and right sides often requires more fiddling with zoom...

I suspect it's related to the transformation size shrinking the voxel visually without moving the numeric "center" ?
_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
Banshee
Supreme Banshee


Joined: 15 Aug 2002
Location: Brazil

PostPosted: Sat Mar 28, 2015 4:04 am    Post subject: Reply with quote

The memory leak problem lies on the Undo/Redo, as far as I could see. I've fixed it in revision 505.

Regarding the viewer, the model is centered at the (0, 0, 0) position. If your model is bigger than the default frustum (which may happen very often), parts of it will be outside the view. Nothing that a zoom out doesn't solve, I guess.

Back to top
View user's profile Send private message Visit poster's website Skype Account
G-E
General


Joined: 09 Feb 2015

PostPosted: Sat Mar 28, 2015 4:24 am    Post subject: Reply with quote

OK... so I haven't tried 505 but I can report that after editing the model and saving it, opening a new model doesn't reduce the memory usage...

There should be obviously no residual data saved for things like undo or even underlying pixel data, or is that windows just not flushing unused allocations?
_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
Crimsonum
Seth


Joined: 14 Jul 2005
Location: Fineland

PostPosted: Sat Mar 28, 2015 8:41 am    Post subject: Reply with quote

G-E wrote:
Any idea why most models "center" in the viewer around a rearward side position?

It appears that more than half the voxel I load, if I rotate them in the viewer, they spin from a fixed point at the right-rear... the effect of this is when turning it to the side more of the voxel goes off screen. Also checking left and right sides often requires more fiddling with zoom...


This sounds like a problem with the HVA. Sometimes, if you modify an existing voxel (instead of creating one from scratch) without a proper .hva in the same folder, something like you described happens.
_________________


Back to top
View user's profile Send private message Visit poster's website
G-E
General


Joined: 09 Feb 2015

PostPosted: Sat Mar 28, 2015 10:18 am    Post subject: Reply with quote

It happens to voxels I use in game that are perfectly centered so it's not that.
_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
Graion Dilach
Defense Minister


Joined: 22 Nov 2010
Location: Iszkaszentgyörgy, Hungary

PostPosted: Sat Mar 28, 2015 12:37 pm    Post subject: Reply with quote

I've seen a LOT of voxels with bad bounds fixed with HVA Position.

That's why I always start working with other voxels by deleting the HVA and recalculate bounds via VXLSE.

Hint: the 3D Preview window ignores HVA Position.
_________________



AS Discord server: https://discord.gg/7aM7Hm2

Back to top
View user's profile Send private message Skype Account
Banshee
Supreme Banshee


Joined: 15 Aug 2002
Location: Brazil

PostPosted: Sat Mar 28, 2015 4:19 pm    Post subject: Reply with quote

G-E wrote:
OK... so I haven't tried 505 but I can report that after editing the model and saving it, opening a new model doesn't reduce the memory usage...

There should be obviously no residual data saved for things like undo or even underlying pixel data, or is that windows just not flushing unused allocations?


One of the reasons from this thing you have described is the residual memory related to Undo/Redo. And, as I said, this is fixed in the latest revision. So, please, try the latest version before we continue to investigate if we still have any serious memory leak problem with the program.

Back to top
View user's profile Send private message Visit poster's website Skype Account
G-E
General


Joined: 09 Feb 2015

PostPosted: Sat Mar 28, 2015 7:32 pm    Post subject: Reply with quote

Banshee: I downloaded it after I posted that but I haven't used it yet...

Graion: I'm sure that's true, I also delete the hva whenever I resize the voxel...
_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
G-E
General


Joined: 09 Feb 2015

PostPosted: Mon Mar 30, 2015 4:12 am    Post subject: Reply with quote

505 still has a memory leak, I just crashed editing my halo.vxl...

I did import texture and undo a couple times because I kept forgetting to uncheck the apply top/bottom colours option.

The last thing I did when it ran out of memory was a flood fill, I missed the line and filled the layer, I clicked the correct dot again 3 times because I didn't see anything updating.

"Out of memory."

I checked taskman, 3.76gb...
_________________
http://www.moddb.com/mods/scorched-earth-ra2-mod-with-smart-ai

Back to top
View user's profile Send private message
Banshee
Supreme Banshee


Joined: 15 Aug 2002
Location: Brazil

PostPosted: Thu Sep 24, 2015 5:02 pm    Post subject: Reply with quote

Just an update: revision 519 has fixed many memory leaks with auto normals and a couple of other things based in what was reported in the first post of this topic.

Back to top
View user's profile Send private message Visit poster's website Skype Account
Display posts from previous:   
Post new topic   Reply to topic Page 1 of 1 [15 Posts] View previous topic :: View next topic
 Forum index » Featured Tools » Voxel Section Editor III » Bug Reporting
Jump to:  
Share on TwitterShare on FacebookShare on Google+Share on DiggShare on RedditShare on PInterestShare on Del.icio.usShare on Stumble Upon
Quick Reply
Username:


If you are visually impaired or cannot otherwise play the game below please contact the Administrator for help.


 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © phpBB Group

Wildcard SSL Certificates
[ Time: 0.1313s ][ Queries: 15 (0.0154s) ][ Debug on ]