改进Hierarchy的多线程扫描性能: Hierarchy使用rwlock来保证更新线程和扫描线程间的线程安全, 测试发现在不发生读写锁冲突的情况下, 读写锁的固有开销会导致并发扫描速度降低。

reference:
https://stackoverflow.com/questions/11866486/how-many-simultaneous-readers-can-a-pthread-rwlock-have
This commit is contained in:
zhengchao
2021-07-19 02:15:18 +08:00
parent ebd07cc5a7
commit 1e2e3a1798
5 changed files with 385 additions and 301 deletions

View File

@@ -57,7 +57,7 @@ extern "C"
}
#endif
int MAAT_FRAME_VERSION_3_3_1_20210715=1;
int MAAT_FRAME_VERSION_3_4_1_20210719=1;
int is_valid_table_name(const char* str)
{