This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Proposal for printf functionality enchancement


On Wed, 19 Oct 2005, Daniel Jacobowitz whispered secretively:
> On Wed, Oct 19, 2005 at 02:12:31PM -0400, James Antill wrote:
>>  Or maybe you mean that if you do "int x = bar2(); int y = bar2();"
>> you can optimize the second call (I could see this if you used
>> sprintf() with a local char[]). But that seems far fetched, and again
>> would be solved via. GCC understanding the mini-language properly.
> 
> It means that loads of foo can be hoisted across the call to printf. 

... and also that some loads can possibly be eliminated.

> Research suggests that this is less farfetched of a benefit than you
> think it is.

It's a definite benefit on platforms where register pressure is
significant, like x86.

-- 
`"Gun-wielding recluse gunned down by local police" isn't the epitaph
 I want. I am hoping for "Witnesses reported the sound up to two hundred
 kilometers away" or "Last body part finally located".' --- James Nicoll


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]