[lkml]   [2013]   [Sep]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH 5/5] lib: Add error string support to printks
On 09/20/2013 06:45 AM, Joe Perches wrote:
> On Fri, 2013-09-20 at 00:21 -0500, Daniel Santos wrote:
> [nice example about bloat]
>> Yeah, I do agree, I just don't see how to do it without introducing
>> unnecessary bloat.
> I think the code size cost of %pE is pretty trivial
> compared to the log size/runtime cost.

I suppose that would depend upon the conditions. If no printks with
error codes/names/messages are triggered, then the cost on the syslog is
zero. Either way, we're already looking at adding one byte to the format
string for the extra 'E' character and the 3-4 bytes for sign extend
instruction would not exist on arm and most other archs. I guess I'm
usually trying to consider the memory constrained system where you
wouldn't enable this feature but still suffer the sign extend bloat --
then again, I don't know of many embedded x86_64 systems. :)

> I would not want to see it used generically.

Hmm, I had considered this as a new mechanism to emit error codes to the
ring buffer. What sort of guidelines do you think are reasonable for
when to use this proposed extension and when not to? Maybe on printks
for error conditions that are most likely?


 \ /
  Last update: 2013-09-23 22:01    [W:0.097 / U:6.844 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site