seq_cutoff: Initialize each stream with different LBA
Initializing each stream with unique LBA ensures there are no initial rbtree collisions, and thus helps to avoid clustering of all the streams into one big linked list instead of forming performance friendly proper tree structure. Signed-off-by: Robert Baldyga <robert.baldyga@intel.com>
This commit is contained in:
parent
b8735f6517
commit
9bcafb5bfb
@ -73,7 +73,7 @@ void ocf_core_seq_cutoff_init(ocf_core_t core)
|
|||||||
|
|
||||||
for (i = 0; i < OCF_SEQ_CUTOFF_MAX_STREAMS; i++) {
|
for (i = 0; i < OCF_SEQ_CUTOFF_MAX_STREAMS; i++) {
|
||||||
stream = &core->seq_cutoff.streams[i];
|
stream = &core->seq_cutoff.streams[i];
|
||||||
stream->last = 0;
|
stream->last = 4096 * i;
|
||||||
stream->bytes = 0;
|
stream->bytes = 0;
|
||||||
stream->rw = 0;
|
stream->rw = 0;
|
||||||
ocf_rb_tree_insert(&core->seq_cutoff.tree, &stream->node);
|
ocf_rb_tree_insert(&core->seq_cutoff.tree, &stream->node);
|
||||||
|
Loading…
Reference in New Issue
Block a user