1. Welcome to the Starbound support forums. Please check the support FAQs before posting: http://playstarbound.com/support

Bug/Issue [SOLVED] CPU >100% Issue (macOS 10.12 Sierra/ 2009 Macbook)

Discussion in 'Starbound Support' started by Valiance30156, Feb 19, 2017.

  1. Valiance30156

    Valiance30156 Big Damn Hero

    Hello everyone,

    I was wondering if I could get some help on an issue I've been having with running Starbound. Since the Official Release 1.2 update, my computer hasn't been able to run this title at a consistent framerate (jumping between <10 and 60 fps).

    At first, I thought it might be a memory problem, so I checked Activity Monitor, which is used to help diagnose problems and monitor the hardware. Since I have two 4GB sticks of RAM (making 8), this was debunked. It typically went up to the high 800 MB range in memory usage, for reference.

    Then I checked the CPU tab of Activity Monitor. Whenever there was snow or rain, the fps staggered between <10 - 60 in a rhythmic pattern. However, when I warp to the Tier 2 Boss stage (Ceremonial Hunting Grounds), two things happen: the CPU exceeds 100% usage, and the fps drops to 3-5. When I leave the area, the CPU eventually 'calms down' and returns to the staggering range or <10 - 60 fps.

    For the record, when there was very little going on on-screen, the fps would actually be at the normal range.

    There are no GL Errors aside from a "GL_INVALID_VALUE" error which seems to appear while loading the database upon startup. Might anyone be able to help me in this matter? Is it a hardware issue? If so, are there workarounds?

    Specs:

    Processor: 2.26 GHz Intel Core 2 Duo
    Memory: 8 GB 1067 MHz DDR3
    Video Card: NVIDIA GeForce 9400M 256 MB

    -----

    Some other notes:

    -Kemono Race Mod (manually installed via mod folder) & "Xbawks" Character Extender installed (via Steam Workshop)
    -Uploaded log file

    -----

    Edit 2:
    The game will no longer launch- it simply hangs upon loading. I'm performing a re-install as of this post.

    Edit 3:
    Still hangs, but crashes after several minutes of hanging. It should be noted that everything is Vanilla.

    -----

    Edit4:
    The problem after the first reinstall was forgetting to remove the existing directory, which I didn't notice. After the second reinstall (complete reinstall; noticed the removal of some folders), I tried launching outside of Steam, and it worked. The staggering fps is there partly due to software optimization issues.

    The OP scenario still remains- playing past Tier 2 (Tungsten Ore) is impossible for now.
     

    Attached Files:

    Last edited: Feb 19, 2017
  2. Corraidhín

    Corraidhín Supernova

  3. Iris Blanche

    Iris Blanche Pudding Paradox Forum Moderator

    The [Error] OpenGL errors this frame: GL_INVALID_VALUE can be ignored. Nearly everyone is getting this (at least what i've seen in the support forums ^-^)

    You said it crashed. Can you attach a log from the crashes?

    ~ Iris ~
     
  4. Valiance30156

    Valiance30156 Big Damn Hero

    Thanks for taking the time to reply :)

    Well, this is "spooky"- it launches out of Steam now. Note that this is after a Shut Down and Power On the following morning.

    What I distinctly remember is checking the game log file immediately after the first and second hang; both logs hung shortly after beginning to load the "SDL" at the same spot.

    Hold on... I intentionally didn't empty the Trash Bin last night. The log should be attached.

    Let me reiterate that it is a hang- the Apple crash log appeared when it did so after several minutes (refer to OP Edit 2 and 3), to which the details specifically stated a hang.

    -----

    Edit1:
    Mildly unrelated, but the fps is normal during the night time of a planet's day/ night cycle. Once dawn starts, it begins staggering again.

    ------

    Edit2:

    The effect from the OP has now reappeared on the Erchius (?) Mining Facility level with a Vanilla character (Avian) and no mods installed. CPU Usage exceeds 100%, but now also seems to lock up the computer intermittently as well. Leaving the area once again calms down the CPU.

    On a side note, using the /fullbright Admin command tends to stabilize the fps on planets, most of the time (the fullbright command was off on the Erchius Mining Facility).

    ------

    Edit3:

    Used the admin command /reload to reload the game assets while in a subsequent session. In the Erchius Mining Facility, I used /reload and left the level. After re-entering the level shortly afterwards, it ran in a completely stable manner, with no fps staggering whatsoever. When attempting to do this procedure on the homeworld/ starting planet for the character, it seems to somewhat stabilize the fps, but not entirely.

    If this can be reproduced on the Ceremonial Hunting Grounds level, this might just be an optimization quick-fix, but don't quote me on that yet.

    By the way, there's an error with the /togglelayer admin command- it simply states that the command doesn't exist, even though it lists the help information for it.
     

    Attached Files:

    Last edited: Feb 19, 2017
  5. Valiance30156

    Valiance30156 Big Damn Hero

    After shutting down the game and restarting, the fps is staggering in the Erchius Mining Facility. Using /reload did not reproduce the quoted solution, and the area runs at the usual 15-60 fps.

    The starbound.log attached is for the most recent session.

    -----

    Edit:
    Well, looks like this is an optimization-based bug- lighting being rendered in general seems to adversely effect the framerate; even moreso for pulsating or flickering lights.

    In the Erchius Mining Facility, leaving the entrance teleporter to the left stabilizes the fps due to little lighting being rendered. When I come back to the airlock/ entrance, it staggers once more.

    Using /fullbright seems to help in varying degrees, depending on the weather that is active, and the time of day. For the main Tier-based levels to progress, this command seems to have no effect.

    Using /reload worked at first, but didn't in subsequent sessions. Perhaps this is due to how the lighting is rendered upon loading the level initially?

    As for the CPU usage (which was the original reason for posting), /reload seems to help, but again only to some degree. I did not check the Activity Monitor on that session, unfortunately.

    Hopefully this helps the developers in optimizing the code...

    ------

    Edit2:

    I got back to the same point I was at from the OP (Ceremonial Hunting Grounds), and the framerate was much more stable than before. Still staggering around 15-60 fps, but playable. This likely points to the Kemono Race Mod, which I was using at that time.

    Funnily enough, when the shading is removed with the /fullbright command in that level, I still had framerate/ CPU spikes- but only when a monster or enemy NPC was aggressive (attacking) or 'pathfinding' (how to reach the player).
     

    Attached Files:

    Last edited: Feb 20, 2017
  6. Healthire

    Healthire Can't Most Program the Least

    Some graphics cards have shown difficulty dealing with the larger texture atlas sizes enabled in 1.2, especially ones with 256MB or less memory. It might be that your graphics card is running low on memory. Try enabling the "limitTextureAtlasSize" option in starbound.config by setting it to true instead of false. This will limit the graphics memory usage and may improve your performance.

    High CPU usage up toward 100% is expected with an intel core 2 duo, it's lower spec than we recommend for running the game smoothly.
     
  7. Valiance30156

    Valiance30156 Big Damn Hero

    Thanks for taking the time to reply on this matter. I'll change the config file and see if the performance is better.

    -----

    Edit:
    The CPU usage was capped by the option (15-30%), but made the game more unstable in framerate. Despite the fact that my computer is fairly old by this point, is there anything else within the config file that can be changed?

    A log file was attached showing the most recent session, and I changed the 'limitTextureAtlasSize' option back to false.

    -----

    Edit2:
    After digging around about CPU issues with Starbound, it seems to confirm that optimization is the issue with this matter, as same-year Macbook Pros and Macbooks (I think the quad-core CPU was the standard from 2011?) have ran the title with better performance. The video card doesn't seem to be capping out either (a video card memory warning would pop up in some form), but correct me if I'm wrong.

    -----

    Edit3:

    I appear to have found a solution, which was not related to the software. In System Preferences, under the Energy Saver section, I had previously turned off the "Put Hard Disks to sleep when possible" option for running off of the Power Adapter. I sat through an entire day/ night cycle on my character's homeworld with the option on to check how the game would perform.

    At first I thought it was a faulty AC Adapter, but then realized that the option was on for the Battery, which I never tried until now. I would've never known that keeping the Hard Disk Drive running constantly was going to cap the framerate.

    If the issue arises when I run Starbound again through the Power Adapter, then this solution is debunked.

    -----

    Edit4:
    Running with the "Put Hard Disks to sleep when possible" option on for the Power Adapter seems to have confirmed the issue. On the battery, the game will eventually stabilize its fps after roughly 15 minutes or more, but on the Power Adapter it stays to a degree. It should be noted that it was launched outside of Steam, but in this case I'm sure the same result would occur.

    Thinking back, most games have been like this on macOS/ Mac OS X in general- on the battery the fps stabilizes after about an hour, but on the power adapter it doesn't stabilize the fps as well. As an example, Salt & Sanctuary runs stable enough on my computer after about 30-45 minutes of staggering fps on the battery, which also tends to last about two hours with it running anyhow.

    -----

    Edit5:

    The issue has now been resolved, as far as I can tell (haven't been around enemies). With the previous stated option on paired with the 'limitTextureAtlasSize' config file option being set to true, I experienced almost no framerate drops, and the performance is much better.

    Thanks for the help everyone.

    -----

    Edit6:

    Rendering water and aquatic enemies seems to grind the framerate down to 10-15 at times. It's still more stable than it was before.

    Labelling the thread as solved.

    ------

    Edit7:

    While the option certainly stabilizes the framerate, there is still a fair amount of slowdown (smooths out the 'jerkiness' of having the fps jump between 15-60+; being in micro-dungeons or boss levels results in a slow-but-stable 5-10+ fps, or causes an occasional sag to 3 fps, rhythmically). When there are a lot of blocks/ structures on-screen, the fps drops.

    In the future, it would be nice to have the following:

    -the item lighting has an all-static-render/'simple animation' option in the future (i.e. torches don't have flickered lighting)
    -reduce layer detail option
    -the ability to reduce the texture Atlas size even further (making custom Atlas sizes for experienced or low-end PC users), but have a minimum size that can't be overridden
    -forcing the game to split the load between all cores, if possible
     

    Attached Files:

    Last edited: Feb 22, 2017

Share This Page