tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: malloc, thread and alignment

On Fri, Mar 27, 2015 at 04:46:51PM +0000, Emmanuel Dreyfus wrote:
 > > Someone^TM should document the kernel CACHE_LINE_SIZE, coherency_unit,
 > > COHERENCY_UNIT, and figure out what it is worthwhile to expose MI to
 > > userland.  
 > Shouldn't malloc take care of that stuff, and enforce a minimal allocation
 > size based on hardware requirement? e.g.: you request one byte, malloc
 > allocates a chunk of 32 bytes. 

It does, for hard alignment requirements. Allocating only whole cache
lines doesn't seem remotely desirable.

David A. Holland

Home | Main Index | Thread Index | Old Index