blender/intern/guardedalloc
Lukas Stockner 0f2ae614a1 Use mmap() IO for reading uncompressed .blends
Instead of submitting tons of tiny IO syscalls, we can speed things up
significantly by `mmap`ing the .blend file into virtual memory and directly
accessing it.

In my local testing, this speeds up loading the Dweebs file with all its
linked files from 19sec to 10sec (on Linux).

As far as I can see, this should be supported on Linux, OSX and BSD.
For Windows, a second code path uses `CreateFileMapping` and
`MapViewOfFile` to achieve the same result.

Reviewed By: mont29, brecht

Differential Revision: https://developer.blender.org/D8246
2021-01-14 22:03:29 +01:00
..
cpp Cleanup: don't use deprecated exception specifications 2020-05-14 11:24:50 +02:00
intern Use mmap() IO for reading uncompressed .blends 2021-01-14 22:03:29 +01:00
test/simpletest Cleanup: spelling 2020-07-10 16:04:09 +10:00
tests Guarded allocator: Fix lock-free allocator tests 2020-11-19 16:17:48 +01:00
CMakeLists.txt Use mmap() IO for reading uncompressed .blends 2021-01-14 22:03:29 +01:00
MEM_guardedalloc.h Cleanup: spelling 2020-11-20 11:39:22 +11:00