"Fossies" - the Fresh Open Source Software Archive
Member "redis-7.0.5/utils/lru/README" (21 Sep 2022, 771 Bytes) of package /linux/misc/redis-7.0.5.tar.gz:
As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard
) with prefixed line numbers.
Alternatively you can here view
the uninterpreted source code file.
1 The test-lru.rb program can be used in order to check the behavior of the
2 Redis approximated LRU algorithm against the theoretical output of true
3 LRU algorithm.
5 In order to use the program you need to recompile Redis setting the define
6 REDIS_LRU_CLOCK_RESOLUTION to 1, by editing the file server.h.
7 This allows to execute the program in a fast way since the 1 ms resolution
8 is enough for all the objects to have a different enough time stamp during
9 the test.
11 The program is executed like this:
13 ruby test-lru.rb /tmp/lru.html
15 You can optionally specify a number of times to run, so that the program
16 will output averages of different runs, by adding an additional argument.
17 For instance in order to run the test 10 times use:
19 ruby test-lru.rb /tmp/lru.html 10