The International Simutrans Forum

 

Author Topic: Strange error during autosave: ERROR: karte_t::sync_step(): delta_t too large  (Read 2506 times)

0 Members and 1 Guest are viewing this topic.

Offline T0m4S

  • *
  • Posts: 67
  • Languages: ES, EN, FR, IT, DE
Hi,

I got this error when the game did an autosave. It just froze simutrans for several seconds and when it reacted again i got very slow fps for several seconds unitl it became back to normal. I'm using simutrans latest svn snapshot: 7352 plus pak128 latest svn version too. This happened on linux. I've never seen it, so I don't know what it is. If you want the full log or anything else just say it ;)

Code: [Select]
Message: hausbauer_t::fill_menu():    maximum 108
Message: toolbar_t::update():    update toolbar EDITTOOLS
Message: toolbar_t::update():    update toolbar LISTTOOLS
Message: karte_t::speichern():    saving game to 'save/autosave05.sve'
Message: karte_t::speichern(loadsave_t *file):    start
Message: karte_t::speichern(loadsave_t *file):    saved cities ok
Message: depot_t::vehikel_laden():    saving 0 vehicles
Message: depot_t::vehikel_laden():    saving 0 vehicles
Message: depot_t::vehikel_laden():    saving 0 vehicles
Message: depot_t::vehikel_laden():    saving 0 vehicles
Message: depot_t::vehikel_laden():    saving 0 vehicles
ERROR: karte_t::sync_step():    delta_t too large: 12690
For help with this error or to file a bug report please see the Simutrans forum:
http://forum.simutrans.com
ERROR: karte_t::sync_step():    delta_t too large: 12616
For help with this error or to file a bug report please see the Simutrans forum:
http://forum.simutrans.com
Message: karte_t::speichern(loadsave_t *file):    saved tiles
Message: karte_t::speichern(loadsave_t *file):    saved fabs
Message: karte_t::speichern(loadsave_t *file):    saved stops
Message: karte_t::speichern(loadsave_t *file):    saved 166 convois
Message: karte_t::speichern(loadsave_t *file):    saved players
Message: karte_t::speichern(loadsave_t *file):    saved messages
Message: karte_t::speichern(loadsave_t *file):    motd filename
ERROR: karte_t::sync_step():    delta_t too large: 18878
For help with this error or to file a bug report please see the Simutrans forum:
http://forum.simutrans.com
Message: interaction_t::interactive_event():    Keyboard event with code 276 '?'
Message: interaction_t::interactive_event():    Keyboard event with code 0 '?'
Message: interaction_t::interactive_event():    Keyboard event with code 276 '?'
Message: interaction_t::interactive_event():    Keyboard event with code 0 '?'
Message: interaction_t::interactive_event(event_t &ev):    calling a tool
Message: wkz_abfrage():    checking map square 51,73,-1
Message: wkz_abfrage():    index 1
Message: depot_frame_t::depot_frame_t():    get_max_convoi_length()=4
Message: depot_frame_t::build_vehicle_lists():    finally 13 passenger vehicle, 11  engines, 1 good wagons
Message: gui_scrolled_list_t::show_selection():    sel=8, offset=0, size.h=97

Offline DrSuperGood

  • Dev Team
  • Devotee
  • *
  • Posts: 2616
  • Languages: EN
I really do not like how simutrans dynamically changes delta_t increment. I noticed this when fast-forwarding to test my JIT2 that the delta time tick increases in fast forward mode. Due to rounding errors this will produce non-deterministic results and as such if it occurs at all during a multiplayer session it will out of sync people.

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5454
  • Languages: EN, NO
If delta time doesn't increase, it will be impossible to do fast forward at all unless the computer is very fast or the map small. And I think delta time is kept under much more control in multiplayer games. I seem to recall that players that can't keep up are kicked out.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9433
  • Languages: De,EN,JP
Fast forward is not possible in multi-player games. The purpose of fast forward is to get as fast as possible on a given computer (well developed maps never reach 50x increase which is the default of most pak sets).

Offline TurfIt

  • Dev Team, Coder/patcher
  • Devotee
  • *
  • Posts: 1323
The log snippet seems to show sync_step() being called during the save process. If so, that's a rather serious error likely to result in savegame corruption...

Offline Ters

  • Coder/patcher
  • Devotee
  • *
  • Posts: 5454
  • Languages: EN, NO
The log snippet seems to show sync_step() being called during the save process. If so, that's a rather serious error likely to result in savegame corruption...

It might just be that stdout and stderr isn't synchronized, if Simutrans uses the latter for the errors and the former for normal logging. I've seen errors pop up on screen before regular logging that preceed them in non-Simutrans related situations before. This would however be an extreme case, with three errors before stdout is fully flushed.

If on the other hand the game steps while saving, I guess that only happens with autosaving and/or threading enabled. I don't have either enabled, and have been unable to reproduce.

Offline prissi

  • Developer
  • Administrator
  • *
  • Posts: 9433
  • Languages: De,EN,JP
Autosaving with sync_step() is possible, but only at certain positions. For instance the factories do nothing during sync_step(). Hence calling it during saving factories is fine. This is done to have the game a little more responsive during autosave.