aboutsummaryrefslogtreecommitdiff
path: root/src/checker.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2022-08-11 13:32:45 +0100
committergingerBill <bill@gingerbill.org>2022-08-11 13:32:45 +0100
commita054c2934eb0caa027a1663cca839cb422621558 (patch)
treef742e44cf522e3e4338c5a4b555f0865878b3953 /src/checker.cpp
parent38102f14c19f83ef1e0c13a824448bab4e80877e (diff)
Cache #load data and hashes
Diffstat (limited to 'src/checker.cpp')
-rw-r--r--src/checker.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/checker.cpp b/src/checker.cpp
index c75fc86af..d01dc5323 100644
--- a/src/checker.cpp
+++ b/src/checker.cpp
@@ -1170,6 +1170,8 @@ void init_checker_info(CheckerInfo *i) {
mutex_init(&i->objc_types_mutex);
map_init(&i->objc_msgSend_types, a);
+ mutex_init(&i->load_file_mutex);
+ string_map_init(&i->load_file_cache, a);
}
void destroy_checker_info(CheckerInfo *i) {
@@ -1205,6 +1207,8 @@ void destroy_checker_info(CheckerInfo *i) {
mutex_destroy(&i->objc_types_mutex);
map_destroy(&i->objc_msgSend_types);
+ mutex_init(&i->load_file_mutex);
+ string_map_destroy(&i->load_file_cache);
}
CheckerContext make_checker_context(Checker *c) {