View previous topic :: View next topic |
Author |
Message |
koopdi Tux's lil' helper
Joined: 07 Feb 2011 Posts: 100
|
Posted: Wed Apr 03, 2013 7:57 pm Post subject: Ramdrive for fast level loading. |
|
|
Hey, I've been playing with the concept of copying maps to ram so that they load faster. It sucks to be left waiting for the next wave respawn in a team game.
I added this line to my fstab.
none /mnt/ramdrive ramfs defaults 0 0
Is there some way to verify that this is actually storing data in ram, and if so, is there a way to test read speeds on this data?
Thanks for your input.
That verification done, what's the best way to load maps and resources into ram on startup? I'm thinking, have a script copy the files over, then rename the original resources and create a symlink to them in ram for transparent operation.
What then to do on shutdown? Remove the symlinks and give the files their original names again?
All this accomplished, what's a good way to acurately time level loads, to see how much of an effect this has? |
|
Back to top |
|
|
Ant P. Watchman
Joined: 18 Apr 2009 Posts: 6920
|
Posted: Thu Apr 04, 2013 3:53 pm Post subject: |
|
|
Linux already uses RAM for disk cache. Using a standard readahead tool like e4rat would work better. |
|
Back to top |
|
|
koopdi Tux's lil' helper
Joined: 07 Feb 2011 Posts: 100
|
Posted: Thu Apr 04, 2013 7:38 pm Post subject: |
|
|
Without googling e4rat or readahead tool, I think I understand what you're saying.
Use the OS's built in ability to cash things to RAM and explicitly call this on large files that you may need loaded at a moments notice...right, that sounds way more elegant - thanks. |
|
Back to top |
|
|
|