1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-02-21 07:09:42 +00:00
openmw/apps/openmw_test_suite
elsid 3affe9913f
Limit the number of simultaneously open not actively used content files
Use LRU cache for ESMReaders. When cache capacity is reached close least
recently used ESMReader. Remember the file name if a reader was open. Once the
reader requested again open the file if there is stored name for it. Put
released ESMReader to the back of the free items list. Close ESMReader's from
the front of the free items list.

Cached item can be used only by one client at the same time. If the same item is
requested twice exception is thrown. This should never happen in practice. If
this happens need to fix the client logic.

It's allowed to go over the capacity limit when requesting different readers.
Ideally this should never happen but there will be system error anyway
signalizing about too many open files. Need to fix client logic in this case.

All places that were using a vector of ESMReaders now using the cache. Cache is
local for each use case and there is no need for a thread safety.
2022-06-03 01:29:03 +02:00
..
detournavigator Increase precision error for navigator tests 2022-05-23 17:18:00 +02:00
esm Use ifstream for ESMReader 2022-04-15 02:58:57 +02:00
esm3 Limit the number of simultaneously open not actively used content files 2022-06-03 01:29:03 +02:00
esm4 Rename components/esm4/acti.hpp -> components/esm4/loadacti.hpp 2022-04-23 00:40:45 +02:00
esmloader Limit the number of simultaneously open not actively used content files 2022-06-03 01:29:03 +02:00
files Put tests output files to a separate dir 2022-05-30 01:34:23 +02:00
fx Put tests output files to a separate dir 2022-05-30 01:34:23 +02:00
lua Put tests output files to a separate dir 2022-05-30 01:34:23 +02:00
misc Put tests output files to a separate dir 2022-05-30 01:34:23 +02:00
mwdialogue Fix keyword search when the keyword is preceded by a non whitespace non alpha character 2021-10-07 13:26:40 +00:00
mwscript Address feedback 2022-05-22 09:29:03 +02:00
mwworld Put tests output files to a separate dir 2022-05-30 01:34:23 +02:00
nifloader Handle NCC flag in Nif files. Objects with this flag will collide only with camera. 2022-04-17 20:03:00 +02:00
openmw Support compilation with c++20 2022-02-24 00:49:40 +01:00
serialization Exchange binary messages between navmeshtool and launcher 2022-03-30 19:24:54 +02:00
settings Put tests output files to a separate dir 2022-05-30 01:34:23 +02:00
shader Put tests output files to a separate dir 2022-05-30 01:34:23 +02:00
sqlite3 Remove redundant include 2022-02-18 22:31:40 +01:00
toutf8 Fix buffer resizing by StatelessUtf8Encoder 2022-02-15 23:02:32 +01:00
CMakeLists.txt Limit the number of simultaneously open not actively used content files 2022-06-03 01:29:03 +02:00
openmw_test_suite.cpp Fix tests on windows 2021-10-21 19:48:31 +02:00
testing_util.hpp Put tests output files to a separate dir 2022-05-30 01:34:23 +02:00