SLOW Performance Issues: post here to report

Having trouble with the game? Report issues and get help here. Read this first!

Moderators: Developers, Forum Moderators

Forum rules
Before reporting issues in this section, you must read the following topic:

Re: SLOW Performance Issues: post here to report

Postby Hemerodromus » November 4th, 2013, 12:48 am

I am having the same problem on my macbook pro. The slowdown only occurs when I have the main menu up, and I can open and play a game, if I act before the slowdown basically freezes up the program.

My specs are as follows:
It is a Macbook Pro 13" made in 2010 with an Intel Core 2 Duo, 2.4Ghz and 4GB of RAM. It uses an NVidia GeForce 320M 256MB video card. I am running Wesnoth 1.10.6 on OS X 10.9.
Hemerodromus
 
Posts: 1
Joined: August 27th, 2010, 12:24 am

Re: SLOW Performance Issues: post here to report

Postby Arcus » April 28th, 2014, 12:11 pm

Hi,

i love playing on large maps, now i've compiled Wesnoth 1.11.13 and just began to create a new Map, sized 141x100. The editor version in 1.10.7 was able to handle such a large map, editing anything with a little delay (perhaps 1/10 second). The editor in version 1.11.13 needs 2-3 seconds on my system, to make any changes on the map. The screen freezes completely in this time. It doesn't matter wether i change 1, 13, 112 or X fields on the map. It takes everytime the same delay.

This occurs with every map on this size.

And the problem goes on: I just tested such a large map to see if there are problems by playing these. If a unit moves, the fps breaks. The unit doesn't slide it's way to the new location. The game skips frames like hell and i'm ending up with 1 frame per second.

I've compiled version 1.11.13 on my openSuSe system (version 13.1, linux-kernel 3.12.1)
Few things about my system: Intel(R) Core(TM) i5-4200U, 8GB Ram, NVIDIA Geforce GT 730M
Arcus
 
Posts: 2
Joined: April 25th, 2014, 1:50 pm

Re: SLOW Performance Issues: post here to report

Postby Coffee » April 28th, 2014, 9:53 pm

Arcus wrote:I just tested such a large map to see if there are problems by playing these. If a unit moves, the fps breaks. The unit doesn't slide it's way to the new location. The game skips frames like hell and i'm ending up with 1 frame per second.


For 1.11.13 there has been a change to the way animations are drawn when the CPU/disk is stressed. The skipping animations should actually occur because the alternative is jerky motion. Does this happen with fog of war and shroud turned off? I just tested on a 200x200 user map and it works smooth with fog and shroud off and low fps as you say here with fog on (which is probably due to the new fog clearing as the unit goes mechanism and the massive map).
User avatar
Coffee
Developer
 
Posts: 162
Joined: October 12th, 2010, 8:24 pm

Re: SLOW Performance Issues: post here to report

Postby CIB » April 29th, 2014, 7:26 am

Make sure to compile with -O3 btw, it makes a huge difference for fast fog clearing.
CIB
Code Contributor
 
Posts: 625
Joined: November 24th, 2006, 11:26 pm

Re: SLOW Performance Issues: post here to report

Postby Arcus » April 29th, 2014, 2:36 pm

ok now,

ive recompiled wesnoth, -O3 wasnt flagged for everything, ive changed that. it took long, but it had an effect. the game is a little bit faster.

the fps drops anyway. its not 1 frame per second anymore, but below 10 fps. without fog and shroud, everything works fine...
I also tried with disabled animations and effects, but that had no effect.

i dont want to play without fog and shroud, so i hope until version 1.12.0 this can be speeded up to work fine with large maps, too.

anyway, if someone has any further ideas, i could need them^^
thanks :)
Arcus
 
Posts: 2
Joined: April 25th, 2014, 1:50 pm

Re: SLOW Performance Issues: post here to report

Postby gfgtdf » April 29th, 2014, 4:24 pm

Arcus wrote:ok now,

ive recompiled wesnoth, -O3 wasnt flagged for everything, ive changed that. it took long, but it had an effect. the game is a little bit faster.

the fps drops anyway. its not 1 frame per second anymore, but below 10 fps. without fog and shroud, everything works fine...
I also tried with disabled animations and effects, but that had no effect.

i dont want to play without fog and shroud, so i hope until version 1.12.0 this can be speeded up to work fine with large maps, too.

anyway, if someone has any further ideas, i could need them^^
thanks :)

i recently had problems with slow calculation of minimap of large maps (the minimap is recalculated after every step of the move.). If replacing "scale_surface_sharp" with "scale_surface" in https://github.com/wesnoth/wesnoth/blob ... p.cpp#L265 (src/minimap.cpp line 265) helps for you that could be a casue.
Scenario with Robots SP scenario (1.11/1.12), allows you to build your units with components, PYR No preperation turn 1.12 mp-mod that allows you to select your units immideately after the game begins.
gfgtdf
Developer
 
Posts: 771
Joined: February 10th, 2013, 2:25 pm

Re: SLOW Performance Issues: post here to report

Postby Scampada » June 28th, 2014, 12:07 am

What did they do to Wesnoth? I've been playing it for years on old Ubuntu, Mint, Debian etc. Now I've got openSUSE 13.1 KDE and decided to compile Wesnoth 1.11.15. Well, I'm there. But it's lagging lik'n old crap on Windows 98.
The first is, when I select fast (2x speed) animation, they've become... ahem... looks like it's giving one frame out of ten needed.
Then, the second is about the fog. They said enough of this - it's lagging.

So, I do not understand, what wrong is with Wesnoth, why, and what did I get theverydamnnewest version to get all those bugs for? Can I play MP with e.g. 1.10? It was fast and furious...
And there are some oddities in that new interface.

Please, revert those wrong changes making Wesnoth ill and release a patch or something... wanna play my favourite game... thanks in advance

Ah, yes. Packard Bell dot s 1.66 x64, 2 cores, 2Gb RAM, openSUSE 13.1 KDE4, home and / are both ext4, game compiled with cmake... CPU usage 50-75% even while minimized, memory usage about 8-10%... All previous Wesnoths ran great...
Proud to be true neutral.
Slythe Ring to rule them all, Slythe Ring to find them,
Slythe Ring to bring them all and in the darkness bind them

Sincerely yours, a rogue and a scoundrel, and just a nice man.
User avatar
Scampada
 
Posts: 12
Joined: March 15th, 2011, 12:05 am

Re: SLOW Performance Issues: post here to report

Postby Scampada » June 28th, 2014, 9:09 am

Make sure to compile with -O3 btw, it makes a huge difference for fast fog clearing.

Excuse me, what is -O3? What does that flag mean and where should I put it? I googled it and found nothing.
I don't want to recompile AGAIN (the fourth time), but if that may make the game faster... I have nothing else left...
Proud to be true neutral.
Slythe Ring to rule them all, Slythe Ring to find them,
Slythe Ring to bring them all and in the darkness bind them

Sincerely yours, a rogue and a scoundrel, and just a nice man.
User avatar
Scampada
 
Posts: 12
Joined: March 15th, 2011, 12:05 am

Re: SLOW Performance Issues: post here to report

Postby iceiceice » June 28th, 2014, 2:50 pm

-O3 is the level of optimizations used by the compiler. 3 is the highest level. O2 is what we use by default I think.

I don't use CMake, but if you were using scons I think the way you do it is something like scons extra_flags_release="-O3".

You can tell what you have by looking at the compilation log. For instance you can see that I'm using -O2:

Spoiler:


Scampada wrote:I don't want to recompile AGAIN (the fourth time), but if that may make the game faster... I have nothing else left...


Try enabling your build tool to use multiple cores. In scons, that would be done with scons --jobs 2 (you said you have two cores?)
Also I would recommend to use clang instead of gcc, it is about twice as fast for the wesnoth project. You should be able to compile in 20 minutes give or take.
User avatar
iceiceice
Developer
 
Posts: 1055
Joined: August 23rd, 2013, 2:10 am

Re: SLOW Performance Issues: post here to report

Postby shadowm » June 28th, 2014, 9:09 pm

Note that if you were building with cmake + gcc and didn’t specify a value for the CMAKE_BUILD_TYPE option, you will get a build that has no optimizations enabled at all, which is bound to result in very poor performance and large executable sizes. If you want to enable optimizations, set CMAKE_BUILD_TYPE to Release (e.g. cmake -DCMAKE_BUILD_TYPE=Release ..), which will use -O3.

As for speeding up builds, the -j<N> switch (e.g. -j2, equivalent to the --jobs 2 example from iceiceice above) can be passed to either make or scons (depending on whether you are building with cmake or scons) to build that number of files in parallel, taking advantage of your CPU power at the cost of higher RAM usage.
Author of the unofficial UtBS sequels Invasion from the Unknown and After the Storm.
I also made Wesnoth RCX, a team-color preview tool for artists and content creators.
Elsewhere: shadowmBlogFollow me on Twitter
User avatar
shadowm
Developer
 
Posts: 6041
Joined: November 14th, 2006, 5:54 pm
Location: Chile

Re: SLOW Performance Issues: post here to report

Postby beetlenaut » June 29th, 2014, 3:52 am

shadowm wrote:If you want to enable optimizations, set CMAKE_BUILD_TYPE to Release (e.g. cmake -DCMAKE_BUILD_TYPE=Release ..), which will use -O3.
I had no idea the default was so bad. That dropped my executable size from 49M to 21M, and everything loads two or three times as fast! :shock:
Campaigns: Dead Water
The Founding of Borstep
Secrets of the Ancients
User avatar
beetlenaut
Developer
 
Posts: 1980
Joined: December 8th, 2007, 3:21 am
Location: Oaxaca, Mexico

Re: SLOW Performance Issues: post here to report

Postby bmartin » March 4th, 2015, 2:58 am

Ubuntu 14.04, Wesnoth 1.12.0 from the repository. English version.

I just installed this OS on my computer. It's using all the standard libraries w/ the newest updates from the repositories.

Steps to reproduce:
  1. Start Heir to the Throne.

Instant 200-350% CPU usage (quad core). I tried disabling animations but that didn't help.

This is on a Core i7 CPU (quad core, 2.8 GHz) with 8 GB RAM and an NVIDIA GeForce GT 630M GPU. It tears it up with most games.
bmartin
 
Posts: 2
Joined: March 4th, 2015, 2:49 am

Re: SLOW Performance Issues: post here to report

Postby iceiceice » March 4th, 2015, 3:23 am

Ok just to be clear, exactly how did you install the game? To the best of my knowledge wesnoth 1.12 is not currently in the standard Trusty Tahr repository.

Afaik the ways you can install on Ubuntu are:

User avatar
iceiceice
Developer
 
Posts: 1055
Joined: August 23rd, 2013, 2:10 am

Re: SLOW Performance Issues: post here to report

Postby beetlenaut » March 4th, 2015, 3:33 am

bmartin wrote:Instant 200-350% CPU usage (quad core).
This definitely shouldn't happen, but I had a similar issue recently that went away without anyone actually trying to fix it as far as I know. Maybe your problem is related: What resolution are you using? Try running BfW in a small window (600x400 or so) and see if it still happens.
Campaigns: Dead Water
The Founding of Borstep
Secrets of the Ancients
User avatar
beetlenaut
Developer
 
Posts: 1980
Joined: December 8th, 2007, 3:21 am
Location: Oaxaca, Mexico

Re: SLOW Performance Issues: post here to report

Postby bmartin » March 4th, 2015, 4:28 am

I tried wesnoth --resolution 640x480; it set the res. to 800x480x32. The problem persists.

Code: Select all
blake ~ $ apt-cache search wesnoth-1.12 | grep "1.12 -"
wesnoth-1.12 - fantasy turn-based strategy game - complete suite (branch 1.12)

blake ~ $ cat /etc/issue
Ubuntu 14.04.2 LTS \n \l

blake ~ $ apt-cache policy wesnoth-1.12
wesnoth-1.12:
  Installed: 1:1.12.0-1~ubuntu14.04.1
  Candidate: 1:1.12.0-1~ubuntu14.04.1
  Version table:
 *** 1:1.12.0-1~ubuntu14.04.1 0
        100 http://us.archive.ubuntu.com/ubuntu/ trusty-backports/universe amd64 Packages
        100 /var/lib/dpkg/status


Apparently it's from backports. Backports was enabled by default; I didn't enable it.

I tried 1.10.7; same problem. I'm guessing this is an SDL or pulseaudio thing. What can I do to test those theories?
bmartin
 
Posts: 2
Joined: March 4th, 2015, 2:49 am

PreviousNext

Return to Technical Support

Who is online

Users browsing this forum: No registered users and 2 guests