← Back to team overview

kernel-packages team mailing list archive

[Bug 1456952] Re: support the slub_debug boot option on specific object size

 

** Description changed:

+ [Impact]
+ 
+ slub_debug cannot work for specific kmem_cache size.
+ 
+ e. g. slub_debug=PU,kmalloc-1024
+ 
+ The slub_debug is used to enable the debugging of use-after-free, poison
+ overwritten, double free. And it also increases the up time of the server
+ when the above mentioned errors happen instead of crashing immediately.
+ 
+ However, currently, there exists bug that the slub_debug cannot be applied
+ for the specific object size. This is not helpful to enable the whole
+ system slub_debug because the performance loss will be up to 20%~30%
+ according to the customer's measurement. The patch here to limit the
+ slub_debug only on the specific object size to alleviate the performance
+ loss.
+ 
+ [Fix]
+ 
  The slub_debug=PU,kmalloc-xx cannot work because in the
  create_kmalloc_caches() the s->name is created after the
  create_kmalloc_cache() is called.  The name is NULL in the
  create_kmalloc_cache() so the kmem_cache_flags() would not set the
  slub_debug flags to the s->flags.  The fix here set up a kmalloc_names
  string array for the initialization purpose and delete the dynamic name
  creation of kmalloc_caches.
+ 
+ [Test case]

** Changed in: linux (Ubuntu)
     Assignee: (unassigned) => Gavin Guo (mimi0213kimo)

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1456952

Title:
  support the slub_debug boot option on specific object size

Status in linux package in Ubuntu:
  Incomplete

Bug description:
  [Impact]

  slub_debug cannot work for specific kmem_cache size.

  e. g. slub_debug=PU,kmalloc-1024

  The slub_debug is used to enable the debugging of use-after-free, poison
  overwritten, double free. And it also increases the up time of the server
  when the above mentioned errors happen instead of crashing immediately.

  However, currently, there exists bug that the slub_debug cannot be applied
  for the specific object size. This is not helpful to enable the whole
  system slub_debug because the performance loss will be up to 20%~30%
  according to the customer's measurement. The patch here to limit the
  slub_debug only on the specific object size to alleviate the performance
  loss.

  [Fix]

  The slub_debug=PU,kmalloc-xx cannot work because in the
  create_kmalloc_caches() the s->name is created after the
  create_kmalloc_cache() is called.  The name is NULL in the
  create_kmalloc_cache() so the kmem_cache_flags() would not set the
  slub_debug flags to the s->flags.  The fix here set up a kmalloc_names
  string array for the initialization purpose and delete the dynamic name
  creation of kmalloc_caches.

  [Test case]

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1456952/+subscriptions


References