lkml.org 
[lkml]   [2012]   [Sep]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH -mm v2] coredump: extend core dump note section to contain file names of mapped files
Date
The code needs to be macroized a bit so that compat_binfmt_elf.c will
produce a version that encodes 32-bit values correctly so as to be
compatible with the output of a native 32-bit kernel.

It's doubtful that rolling your own single loop actually performs better
than just calling strlen and memcpy.

Since you're just counting to estimate the size of a temporary buffer,
you could skip the initial loop and just estimate based on mm->map_count.
Then collect the count in the main loop and write the first word of the
buffer last.


Thanks,
Roland


\
 
 \ /
  Last update: 2012-09-18 19:41    [W:0.067 / U:0.912 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site