Alexey Serbin has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/15313 )

Change subject: KUDU-3063: Set a ratio to reserve some nvm memory
......................................................................


Patch Set 1:

> Memkind calculate the malloc size by memkind_malloc_usable_size,
 > when the usage reach to ~85%-90% of nvm capacity, memkind will
 > allocate fail(suppose fragmentation from memkind/jemalloc).
 > EvictOldestUnlock won't be invoked because usage will never larger
 > then capacity.

Should we instead multiply the results of memkind_malloc_usable_size() by 5/4 
when calculating the charge for an element in ShardedLRUCache::Allocate()?  
This way the logic seems to be more transparent, given that the root cause is 
the fragmentation that is not counted in by memkind_malloc_usable_size() itself.

If doing so, probably it's worth to update the comment/description for  
'nvm_cache_usage_ratio' flag, and making the default value to be 5/4?


--
To view, visit http://gerrit.cloudera.org:8080/15313
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Iceb1931f5addbf76774854ca1613b6a085b577e3
Gerrit-Change-Number: 15313
Gerrit-PatchSet: 1
Gerrit-Owner: ye yuqiang <[email protected]>
Gerrit-Reviewer: Adar Dembo <[email protected]>
Gerrit-Reviewer: Alexey Serbin <[email protected]>
Gerrit-Reviewer: Bankim Bhavsar <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: ye yuqiang <[email protected]>
Gerrit-Comment-Date: Fri, 28 Feb 2020 21:20:22 +0000
Gerrit-HasComments: No

Reply via email to