[lkml]   [2018]   [Jan]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Subject[PATCH 0/2] mm/zswap: add minor const/conditional optimizations
Make a couple minor short-circuiting order and const changes
- Since the pointed-to objects are never modified through
these pointers, const-qualify type and compressor
- Test boolean before calling `strcmp()` to take
advantage of short-circuiting.

Joey Pabalinas (2):
mm/zswap: make type and compressor const
mm/zswap: move `zswap_has_pool` to front of `if ()`

mm/zswap.c | 12 +++++++-----
1 file changed, 7 insertions(+), 5 deletions(-)


 \ /
  Last update: 2018-01-02 11:04    [W:0.041 / U:0.820 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site