SYNC ERRORS CONSTANT - Page 2

SYNC ERRORS CONSTANT

Discuss your problems with the latest release of the engine here. Problems with games, maps or other utilities belong in their respective forums.

Moderator: Moderators

User avatar
overkill
Posts: 500
Joined: 02 Sep 2006, 01:15

Post by overkill »

nicely said
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

Tobi wrote: Could you try the most recent automatic build?

It includes the code which performs the check & gives the warning after every loading step so with that version it should be possible to narrow down the bug a bit.

Just back up your spring.exe and unzip the zipfile with the highest revision number there in your spring directory. Then test it & post infolog here. Don't forget to restore your original spring.exe afterwards.
User avatar
overkill
Posts: 500
Joined: 02 Sep 2006, 01:15

Post by overkill »

I did spring couldnt start because it was missing some dll thing
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

zizu
Posts: 14
Joined: 12 Jun 2006, 01:51

Post by zizu »

I think I found the solution to overkill├â┬ó├óÔÇÜ┬¼├óÔÇ×┬ós problems.

Currently when outside code modifies the floating point control word Spring attempts to reset it by calling ├â┬ó├óÔÇÜ┬¼├àÔÇ£streflop_init<streflop::Simple>();├â┬ó├óÔÇÜ┬¼
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

Warning: this post contains excessively complex content

[quote="zizu"]
I think I found the solution to overkill├â┬ó├óÔÇÜ┬¼├óÔÇ×┬ós problems.

Currently when outside code modifies the floating point control word Spring attempts to reset it by calling ├â┬ó├óÔÇÜ┬¼├àÔÇ£streflop_init<streflop::Simple>();├â┬ó├óÔÇÜ┬¼
User avatar
rattle
Damned Developer
Posts: 8278
Joined: 01 Jun 2006, 13:15

Post by rattle »

Remember to replace the SDL dll as well, the one which ships with spring is newer than the one you need for the automated build.
zizu
Posts: 14
Joined: 12 Jun 2006, 01:51

Post by zizu »

Tobi wrote:You see that rounding control is actually correct, but it's the precision control that's set to double precision (2) instead of single precision (0), resulting in rounding errors which result in desync.
Yes you are right overkill├â┬ó├óÔÇÜ┬¼├óÔÇ×┬ós problems are caused by incorrect precision and not rounding, but other peoples drivers may be tampering with the rounding so I think you should also reset the rounding when recovering to a synced state.
Something like this:

Code: Select all

static inline void reset_fpu_control_registers(){
	unsigned short fpcw = 0;
	STREFLOP_FSTCW(fpcw);
	fpcw &= 0xE0C0;//Save reserved bits.
	fpcw |= 0x003F;
	STREFLOP_FLDCW(fpcw);
}
Tobi wrote: This is probably done by some (driver) DLL loaded in some loading step which references external systems (and it's done at least twice, once before CPregame and once before actual game starts, because of the 2 warnings overkill got).
Drivers changing the FPU control word is only a problem if you don├â┬ó├óÔÇÜ┬¼├óÔÇ×┬ót reset it before executing synced code. Windows (I have no idea how other systems are handling it, but it should be easy to test) maintains the FPU control word on a per thread basis so the best solution to the problem is to move subsystems (like sound) who often depends on outside rogue drivers to a separate thread, or move the synced gamestate to a separate thread then it will be isolated from outside interference with evil drivers.
Tobi wrote:which is why it could help if overkill actually tried the automatic builds
I will make a special exe that will make it easy to track down the offending driver.
User avatar
overkill
Posts: 500
Joined: 02 Sep 2006, 01:15

Post by overkill »

this is odd i didnt post because with the dev version i dont get sync errors but monster lag
User avatar
tooleh
Posts: 57
Joined: 14 Jul 2005, 00:47

Post by tooleh »

overkill wrote:i have an intel(R) express chipset
Oh god...
User avatar
LathanStanley
Posts: 1429
Joined: 20 Jun 2005, 05:16

Post by LathanStanley »

I have a hard time believing a "re-sync" is gonna truely fix the problem...

when a game is out of sync (traditionally) its from TOO much data transfer between clients... thus, the only way to keep it synchronized is to lower the data transfer rate.

When the re-sync happens, If it ever gets finished, it will sync the game sure, but after uploading a mirrored image of the host game to all clients correct? this process probably taking between 1-5 mins... maybe longer..

if the data flow on the network still desynchs games rapidly however, wouldn't that just mean you blew 5 mins to sync and play another 30 seconds, only to have to sync again???

I really don't think a resync is the solution. I believe the dev's need to look into a better parser on the game speed controller, and slow the gamespeed automatically to allow for the weakest computer to reduce network tcp/ip overflow issues that cause desynchs.

This allready happens to a weak extent as when you can see with the .info option on, the players on the bottom right have their net CPU usage shown and packet latency. There probably is an issue with it trying TOO hard to make the game run as fast as possible. If they made it where instead of "if CPU usage is over 95% slow game" to something like "if CPU usage is over 80% slow game" instead, it may sole the problem alltogether. but I'm not very knownlegeable of the actual code, and meh, I dunno how to do it myself.

(not to mention I believe Spring uses UDP, not TCP...)

but oh well... maybe this can spark an idea.
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

Seems you interpret "keeping sync" as keeping in sync regarding clock ticks , ie. regarding game speed etc.

This however isn't the issue, the issue is that the gamestate sometimes starts to differ at different clients. So the simulation is out of synchronization: there was one simulation, but the game desynced (branched off) into two simulations. One set of clients plays a different game then another set of clients.

By fixing the gamestate to be identical on all clients (resync) this can be solved (e.g. by moving a unit a small bit on some clients).

The slowing down works already quite fine I think, it's only when someone really has not enough processor power that he starts to lag severely and drops in the end. In most situations the game slows down to a crawl just fine ;-)
User avatar
LathanStanley
Posts: 1429
Joined: 20 Jun 2005, 05:16

Post by LathanStanley »

You are probably right, I can't argue with you on this, I don't have much of any knowledge on the subject...

it was just my .02$ and my idea on where to consider looking if the resync isn't a working solution...
User avatar
overkill
Posts: 500
Joined: 02 Sep 2006, 01:15

Post by overkill »

well i have enough processing power i think. ill just have to occupy myself till i get a nvidia card or does anybody have any recomendations?
User avatar
overkill
Posts: 500
Joined: 02 Sep 2006, 01:15

Post by overkill »

I messed with my graphix card settings andf now i dont get any sync Errors HURRAY
Tobi
Spring Developer
Posts: 4598
Joined: 01 Jun 2005, 11:36

Post by Tobi »

Any idea what setting you modified? (Can you reproduce it, ie. turn setting on-> sync errors, turn setting off-> no sync errors?)

That would be helpful to include in FAQ etc.
User avatar
overkill
Posts: 500
Joined: 02 Sep 2006, 01:15

Post by overkill »

i tryed to reproduce it but i couldnt, sorry. but if i it happens again Ill keep track of what i change.

E: spelling/grammer
User avatar
rcdraco
Posts: 781
Joined: 22 Nov 2006, 02:50

yup

Post by rcdraco »

ok my tips, I have the same error sometimes when I host, I desync, and everyone else does for about 2 minutes in the beginning, then it syncs up and bam we go, lower your settings[KEY], if you are the host, or if your PC can't "Warm-Up" fast enough, you desync into Oblivion, is it the same map, or is it on every map, certain amounts of players, are you on linux, are they on linux? Anything can set it off, for staters though, turn off all shaders, lower water, max sounds, maybe your PC has spyware, that is what my problem was. Seriously, the developers are doing all they can to make this game enjoyable for everyone, except [SSFL]SuperNoob, who only finds pleasure in making everyone else miserable.
Post Reply

Return to “Help & Bugs”