cmake: Add option for "mem: per-CPU allocator cache (ThunderX2 workaround)"
Change-Id: I7156cf433b2081246d1d9b8e4fde489609676ef1
This commit is contained in:
@ -42,7 +42,9 @@ void cpu_local_var_init(void)
|
||||
clv[i].monitor = monitor->cpu + i;
|
||||
clv[i].rusage = rusage.cpu + i;
|
||||
INIT_LIST_HEAD(&clv[i].smp_func_req_list);
|
||||
#ifdef ENABLE_PER_CPU_ALLOC_CACHE
|
||||
clv[i].free_chunks.rb_node = NULL;
|
||||
#endif
|
||||
}
|
||||
|
||||
cpu_local_var_initialized = 1;
|
||||
|
||||
@ -15,6 +15,7 @@
|
||||
|
||||
#include <process.h>
|
||||
#include <syscall.h>
|
||||
#include <config.h>
|
||||
/*
|
||||
* CPU Local Storage (cls)
|
||||
*/
|
||||
@ -103,8 +104,10 @@ struct cpu_local_var {
|
||||
|
||||
/* UTI */
|
||||
void *uti_futex_resp;
|
||||
#ifdef ENABLE_PER_CPU_ALLOC_CACHE
|
||||
/* Per-CPU memory allocator cache */
|
||||
struct rb_root free_chunks;
|
||||
#endif
|
||||
} __attribute__((aligned(64)));
|
||||
|
||||
extern int cpu_local_var_initialized;
|
||||
|
||||
Reference in New Issue
Block a user