# make oldconfig new option "Choose SLAB allocator", what isit

## Dirk.R.Gently

Updating to the vanilla-sources I did the standard, "make oldconfig" and had this option:

```
Choose SLAB allocator

> 1. SLAB (SLAB)

  2. SLUB (Unqueued Allocator) (SLUB) (NEW)

choice[1-2?]: 
```

All I could find on slub was

slub-core.patch: 

This is a new slab allocator which was motivated by the complexity of the existing code in mm/slab.c. It attempts to address a variety of concerns with the existing implementation.

Oh it appears I found it:

Note that the SLAB allocator will be replaced with the SLUB allocator once it's proved stable.

It has a much simpler design than SLAB and scales better on SMP's.

Probably not safe to use yet.

----------

## energyman76b

SLUB written by Christoph Lameter is a replacement for SLAB. Ok, that is in the help.

BUT: it is VERY new (only some month old), it is VERY buggy. It is said to be slower and it makes people's boxes not boot on occasion.

So stay away from it. At some point in the future, SLUB may replace SLAB, but until then it is only for testers and people with daily backups

----------

## makenoob

 *energyman76b wrote:*   

> SLUB written by Christoph Lameter is a replacement for SLAB. Ok, that is in the help.
> 
> BUT: it is VERY new (only some month old), it is VERY buggy. It is said to be slower and it makes people's boxes not boot on occasion.
> 
> So stay away from it. At some point in the future, SLUB may replace SLAB, but until then it is only for testers and people with daily backups

 

so, what does it do in the vanilla-kernel? i don't understand, wth developers to do that and why they don't leave the buggy features out and provide patches for people, who want to blow their boxes...

----------

## energyman76b

 *makenoob wrote:*   

>  *energyman76b wrote:*   SLUB written by Christoph Lameter is a replacement for SLAB. Ok, that is in the help.
> 
> BUT: it is VERY new (only some month old), it is VERY buggy. It is said to be slower and it makes people's boxes not boot on occasion.
> 
> So stay away from it. At some point in the future, SLUB may replace SLAB, but until then it is only for testers and people with daily backups 
> ...

 

only stuff in the vanilla kernel gets really tested. And if you turn it off, you don't have any impact from its existance. So where is the problem?

----------

## Dirk.R.Gently

I decided to try a version of the kernel with it, and haven't come across any problems just yet.  Supposedly it's supposed to improve performance, and I do notice that I boot faster.  I'll post if I have any problems.

Oh, the details of SLUB when configuring the kernel is:

```
 SLUB is a slab allocator that minimizes cache line usage                  

  â instead of managing queues of cached objects (SLAB approach).           

  â Per cpu caching is realized using slabs of objects instead                

  â of queues of objects. SLUB can use memory efficiently                  

  â and has enhanced diagnostics. 
```

----------

## wyv3rn

 *makenoob wrote:*   

>  *energyman76b wrote:*   SLUB written by Christoph Lameter is a replacement for SLAB. Ok, that is in the help.
> 
> BUT: it is VERY new (only some month old), it is VERY buggy. It is said to be slower and it makes people's boxes not boot on occasion.
> 
> So stay away from it. At some point in the future, SLUB may replace SLAB, but until then it is only for testers and people with daily backups 
> ...

 

The only "vanilla kernel" with the SLUB allocator merged are experimental 2.6.22-rc series kernels.  2.6.21 and lower don't have it.  You can still choose SLAB over SLUB.  What do you expect if you're using an unstable -rc series kernel?  I'd be a lot more worried about all the other changes to stuff that is not selectable.

----------

## makenoob

if it's in an unstable kernel, it's okay. but the op wrote, that he uses a plain vanilla kernel and not that's an "experimental vanilla series" of the kernel. i was wondering, why the developers put this, as energyman told, _very_ new and _very_ buggy, stuff in a kernel for everyone, but still needs testing...

what is the other, not selectable stuff your talking about?

just my 2 cent...

----------

## musv

Ok, it's an old thread but it's the right topic:

I just tested the new slub allocator for a couble of days and I think it isn't stable yet. 

Experiences with slub:

If you write something (chat, xterm, openoffice), sometimes the system stumbles for a part of a second and it seems like keep pressing the last pressed key. For example, you write a short lettttttttttttttttttttttttttttttttttttttttttter.  :Smile:  Changing back to Slab, the problem disappears. I recognized this problem only while using X apps. If it occures also at the console I don't know. 

So I switched back to Slab. If Slub someday will get more stable, I'll give it a new chance.

----------

## roderick

 *musv wrote:*   

> Ok, it's an old thread but it's the right topic:
> 
> I just tested the new slub allocator for a couble of days and I think it isn't stable yet. 
> 
> Experiences with slub:
> ...

 

I noticed that happened while emerging something.

I typed yes while the emerge was still calculating deps to buffer the answer and then it started repeating the y. I though it was a bug elsewhere....

----------

## Sadako

I've been using it for a few days now, and have yet to encounter that issue...

----------

## cruzki

 *musv wrote:*   

> Ok, it's an old thread but it's the right topic:
> 
> I just tested the new slub allocator for a couble of days and I think it isn't stable yet. 
> 
> Experiences with slub:
> ...

 

I have the same problem a years ago, so I thinks this is a problem with swap (like me) than with SLUB

----------

## musv

Ok, I have to revise my theory. It's not the SLUB allocator. I switched back to SLAB and the problem came back after a while. It must be something else of kernel 2.6.22-r3, because in 2.6.21 I don't get that behaviour. Strange. Does someone have a solution?

----------

