]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
MINOR: pattern: make the pat_lru_seed read_mostly
authorWilly Tarreau <w@1wt.eu>
Sat, 10 Apr 2021 15:42:04 +0000 (17:42 +0200)
committerWilly Tarreau <w@1wt.eu>
Sat, 10 Apr 2021 17:27:41 +0000 (19:27 +0200)
This seed is created once at boot and is used in every LRU hash when
caching results. Let's mark it read_mostly.

src/pattern.c

index e6892f62a108d55457f573cf5b2a1940958a23cf..252bd35d1fee9564ba6d58d39774357eaeae61a4 100644 (file)
@@ -139,7 +139,7 @@ static THREAD_LOCAL struct sample_data static_sample_data;
 struct list pattern_reference = LIST_HEAD_INIT(pattern_reference);
 
 static THREAD_LOCAL struct lru64_head *pat_lru_tree;
-static unsigned long long pat_lru_seed;
+static unsigned long long pat_lru_seed __read_mostly;
 
 /*
  *