Jump to content
The Dark Mod Forums

[Resolved in TDM 2.10] When Will Loading Times Be Too Long?


Mik James

Recommended Posts

I took a quick look at the long loading times in TDM with Valgrind and it looks like the inflate_fast function (for unzipping) takes up a large portion of the loading time according to Valgrind:

 

snapshot1tiubm.png

 

I had a quick glimpse at the function here: https://github.com/revelator/The-Darkmod-Experimental/blob/7d86b82fce9eb587952c4963b928fd7974ecfa78/src/framework/Unzip.cpp#L3475

and it looks like it's very old and optimized for old hardware. I've never looked at the deflate/inflate algorithm before but maybe there are faster ways to do this on modern hardware.

 

Unfortunately the reality of it seems to be different.

I tested this by loading up the largest mission we have: Crucible of Omens, in TDM and timing how long it takes to go from "Start Mission" to "Click to Start" appearing.

I then unpacked the ZIP file into the BCD directory to remove unzipping as a bottleneck in the loading process, and the times were the same, give or take a second or 2.

Here is what the directory looks like:

 

PK4:

post-529-0-81053000-1454288136_thumb.png

 

Unzipped:

post-529-0-98526200-1454288139_thumb.png

            Run 1        Run 2        Run 3        Run 4
PK4:        53.32 sec    53.32 sec    52.31 sec    53.10 sec
Unzipped:    52.12 sec    51.55 sec    51.33 sec    51.76 sec

  • Like 1

I always assumed I'd taste like boot leather.

 

Link to comment
Share on other sites

 

 

Unfortunately the reality of it seems to be different.

I tested this by loading up the largest mission we have: Crucible of Omens, in TDM and timing how long it takes to go from "Start Mission" to "Click to Start" appearing.

I then unpacked the ZIP file into the BCD directory to remove unzipping as a bottleneck in the loading process, and the times were the same, give or take a second or 2.

 

Thanks for the test but what about all the pk4 files coming with TDM itself?

 

If you look at the Doom 3 BFG code you'll see that the Unzip.cpp changed a bit since Doom 3 and that inflate_fast() was removed: https://github.com/id-Software/DOOM-3-BFG/blob/master/neo/framework/Unzip.cpp

I don't know how BFG's loading times compare to Doom 3 though.

  • Like 1
Link to comment
Share on other sites

BFG uses binary assets. It's not quite comparable to what we have. That said, you may have a point about packed mod assets loading too. Though the SVN where

we do development has unpacked assets and mission loading isn't substantially faster there.

  • Like 1

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to comment
Share on other sites

 

Thanks for the test but what about all the pk4 files coming with TDM itself?

 

If you look at the Doom 3 BFG code you'll see that the Unzip.cpp changed a bit since Doom 3 and that inflate_fast() was removed: https://github.com/id-Software/DOOM-3-BFG/blob/master/neo/framework/Unzip.cpp

I don't know how BFG's loading times compare to Doom 3 though.

 

That test I did was with all the files unzipped, I'm using the SVN version which does not have pk4's.

I always assumed I'd taste like boot leather.

 

Link to comment
Share on other sites

  • nbohr1more changed the title to [Resolved in TDM 2.10] When Will Loading Times Be Too Long?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recent Status Updates

    • taaaki

      All services hosted on the server were sluggish. I've rebooted and it appears to be better. Let me know if there are still issues.
      · 4 replies
    • datiswous

      Forum is kind of slow lately..
      · 4 replies
    • taffernicus

      How fun is it to play as an undead in thief trilogy / dark mod ? The haunting(T2) and To the end with nothing(T2). Those FMs are exemplary according to me
       
      *tangential, Garrett vs countless apparitions
      https://ibb.co/hM0JrSh
       
      · 7 replies
    • JackFarmer

      Who is actually working on new missions right now? That I, the greatest mapper of all times (and I say this in all modesty, it is innate in me) am working on something epochal is clear to everyone by now. But who else is working on new missions? Please let me, your God, know, because it's so depressingly quiet here and I don't like to post pictures all the time, because even for me it gets a bit too boastful (although justified) with time.
      · 18 replies
×
×
  • Create New...