lkml.org 
[lkml]   [2015]   [Jan]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH 0/4] kstrdup optimization
Hi Andi, Andreas,

Thanks for comments.

On 12/30/2014 10:29 PM, Andi Kleen wrote:
>> This symmetry issue probably could be cleanly avoided only
>> by having kfree() itself contain such an identifying check, as you suggest
>> (thereby slowing down kfree() performance).
>
> It actually shouldn't slow it down. kfree already complains if you free
> a non slab page, this could be just in front of the error check.
>
> The bigger concern is that it may hide some programing errors elsewhere
> though. So it's probably better to keep it a separate function.

Shall I interpret it as preliminary ack?

If yes, I can repost it without RFC prefix. Anyway I need to:
- add EXPORT_SYMBOL(kstrdup_const),
- add kerneldocs for both functions.

I can also add patch constifying mnt->mnt_devname in alloc_vfsmnt,
on my test platform it could save 13 additional allocations.

Regards
Andrzej




\
 
 \ /
  Last update: 2015-01-08 12:01    [W:0.082 / U:0.356 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site