Memory & CPU usage

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
JeebusSez
Prole
Posts: 4
Joined: Mon Jan 26, 2009 8:37 am

Memory & CPU usage

Post by JeebusSez »

Hello!

I've been looking at Löve for a bit (love the umlat, I work at IKEA where umlats are abound) and I decided to download it to give it a try for development. However, loading the demos or even the no-game results in high CPU usage and high memory utilization.

I saw the CPU spike was a natural behavior for Löve; I can roll with CPU hogging.

However I have no idea why the huge memory spike; Task Manager says it spikes in the 300 000 K+ ranges. Running exhaustive demos such as lovalanche or WRATH (the zombie game using the Ënvy framework) slows the whole thing to a crawl. Although the simpler demos like hamsterball don't produce any significant slowdown, the memory usage is still radical.

My system specs at 2.8ghz Pentium 4 (I think I'm the last one with a single-core who tries to do memory and processor intensive things) and 1.5gb of RAM, so it's not a horrible system by any standard. Is this normal or have I done something horribly horribly wrong? I don't want to pick up a development for an engine that eats up resources like an army of angry cookiemonsters before I've even done anything :brows:

[edit] Also, sometimes when loading a game the program decides after a bit it's not worth it and simply displays the header and a thin sliver of a box.
User avatar
rude
Administrator
Posts: 1052
Joined: Mon Feb 04, 2008 3:58 pm
Location: Oslo, Norway

Re: Memory & CPU usage

Post by rude »

Come again? 300000K? Peak memory usage of lovalanche on my computer: <14000K (SDL needs 10000K just to display the OpenGL frame).

EDIT: Yes, LÖVE takes all the CPU it can get. If you don't want that to happen, use love.timer.sleep().
JeebusSez
Prole
Posts: 4
Joined: Mon Jan 26, 2009 8:37 am

Re: Memory & CPU usage

Post by JeebusSez »

This was just as Militia Defense froze.
Attachments
love_freeze.png
love_freeze.png (63.28 KiB) Viewed 7520 times
User avatar
Kaze
Party member
Posts: 189
Joined: Sat Jul 19, 2008 4:39 pm
Location: Dublin, Ireland

Re: Memory & CPU usage

Post by Kaze »

:shock:
Did you build LOVE yourself?
JeebusSez
Prole
Posts: 4
Joined: Mon Jan 26, 2009 8:37 am

Re: Memory & CPU usage

Post by JeebusSez »

Negative, I downloaded the windows installer. Should I?
User avatar
Kaze
Party member
Posts: 189
Joined: Sat Jul 19, 2008 4:39 pm
Location: Dublin, Ireland

Re: Memory & CPU usage

Post by Kaze »

JeebusSez wrote:Negative, I downloaded the windows installer. Should I?
:roll:
Highest I can get LOVE to use is 14.8mb of memory.
User avatar
osgeld
Party member
Posts: 303
Joined: Sun Nov 23, 2008 10:13 pm

Re: Memory & CPU usage

Post by osgeld »

one of my projects is sucking down about 36 mb, but its all accounted for

far as cpu usage, unless theres a call to sleep every x ms in the update function, yea it will use 100%, putting one there will drop it to < 20%
JeebusSez
Prole
Posts: 4
Joined: Mon Jan 26, 2009 8:37 am

Re: Memory & CPU usage

Post by JeebusSez »

I've installed Löve on my laptop and I don't get nearly as bad memory usage as I do on my desktop (~10,000K). The only thing I can think of is that there's something wrong with the way that my desktop is handling pagefile or something is messing up memory allocation; I will have to fiddle with it and come back to you results later (right now my desk is covered in ants).

Minor victory! :ultrahappy:
Post Reply

Who is online

Users browsing this forum: No registered users and 160 guests