glamor-fbo: Tweek the cache bucket calculation.
And also reduce the expire count to 100 which should be good enough on x11perf and cairo-trace testing. Signed-off-by: Zhigang Gong <zhigang.gong@linux.intel.com>
This commit is contained in:
parent
a1de528c56
commit
36ac9b7191
|
@ -6,7 +6,7 @@
|
|||
|
||||
#include "glamor_priv.h"
|
||||
|
||||
#define GLAMOR_CACHE_EXPIRE_MAX 1000
|
||||
#define GLAMOR_CACHE_EXPIRE_MAX 100
|
||||
|
||||
#define GLAMOR_CACHE_DEFAULT 0
|
||||
#define GLAMOR_CACHE_EXACT_SIZE 1
|
||||
|
@ -51,7 +51,7 @@ static inline unsigned long __fls(unsigned long x)
|
|||
|
||||
inline static int cache_wbucket(int size)
|
||||
{
|
||||
int order = __fls(size / 256);
|
||||
int order = __fls(size / 32);
|
||||
if (order >= CACHE_BUCKET_WCOUNT)
|
||||
order = CACHE_BUCKET_WCOUNT - 1;
|
||||
return order;
|
||||
|
@ -59,7 +59,7 @@ inline static int cache_wbucket(int size)
|
|||
|
||||
inline static int cache_hbucket(int size)
|
||||
{
|
||||
int order = __fls(size / 256);
|
||||
int order = __fls(size / 32);
|
||||
if (order >= CACHE_BUCKET_HCOUNT)
|
||||
order = CACHE_BUCKET_HCOUNT - 1;
|
||||
return order;
|
||||
|
|
Loading…
Reference in New Issue
Block a user