Bug 55958

Summary: Saving is way too slow.
Product: [Applications] boson Reporter: Rivo Laks <rivolaks>
Component: generalAssignee: The Boson Team <boson-bugs>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Compiled Sources   
OS: Linux   
Latest Commit: Version Fixed In:

Description Rivo Laks 2003-03-14 16:27:39 UTC
Version:            (using KDE 3.1.1)
Installed from:    compiled sources
Compiler:          gcc version 3.2.1
OS:          Linux (i686) release 2.4.18

It takes about 150 seconds with ~1000 units.
I know we're using XML and it's much slower than binary format, but so big saving times are IMHO unacceptable. Maybe we should save the XML ourselves, e.g. just save it to stream with QStrings and do all formating ourselves. I think it's possible and it would be probably much faster. Loading is ok, loading the same game only takes few seconds.

Rivo
Comment 1 Andreas Beckermann 2003-03-17 05:14:52 UTC
Well, it was quite obvious that there was some kind of typo around. It took my quite some 
time to figure out *where* that typo was, but finally I found and fixed it :) 
Saving a game on experimental5 with 10 players takes 8.9 seconds on my system now. Still 
too slow for me, but we can live with it for now. We optimize that later, when it is working 
correctly (read: well tested). 
 
btw: XML *never* slows down like *that*. That would be pretty funny, if a HTML site 
(which is comparable to xml) with about 700kb (xml file size of player data) would take 
150 seconds to load or save (without being rendered)... 
 
And no, doing this stuff on our own would be a lot slower than using a well tested library. 
We would save a few function calls (not even micro seconds), but would add a few more 
bugs (*that* is where usually most time is spent). 
 
Comment 2 Rivo Laks 2003-03-17 15:39:39 UTC
Subject: Re:  Saving is way too slow.