OpenVZ Forum


Home » Mailing lists » Devel » [PATCH v5 00/18] slab accounting for memcg
Re: [PATCH v5 15/18] Aggregate memcg cache values in slabinfo [message #48543 is a reply to message #48532] Fri, 19 October 2012 19:50 Go to previous messageGo to previous message
Christoph Lameter is currently offline  Christoph Lameter
Messages: 123
Registered: September 2006
Senior Member
On Fri, 19 Oct 2012, Glauber Costa wrote:

> +
> +/*
> + * We use suffixes to the name in memcg because we can't have caches
> + * created in the system with the same name. But when we print them
> + * locally, better refer to them with the base name
> + */
> +static inline const char *cache_name(struct kmem_cache *s)
> +{
> + if (!is_root_cache(s))
> + return s->memcg_params->root_cache->name;
> + return s->name;
> +}

Could we avoid this uglyness? You can ID a slab cache by combining a memcg
pointer and a slabname.
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: [PATCH v3] SUNRPC: set desired file system root before connecting local transports
Next Topic: [PATCH v5] slab: Ignore internal flags in cache creation
Goto Forum:
  


Current Time: Fri Nov 15 02:08:46 GMT 2024

Total time taken to generate the page: 0.03156 seconds