[Xorp-hackers] PATCH: Logging improvements, fix artificial deal for xorpsh commit.

Ben Greear greearb at candelatech.com
Fri Oct 9 08:10:53 PDT 2009


J.T. Conklin wrote:
> Ben Greear <greearb at candelatech.com> writes:
>   
>> 2) Change some pass-by-value string arguments to const string& in
>> router-mgr.  This will improve performance and a small bit of memory
>> usage.
>>     
>
> Hi Ben,
>
> This, and passing string literals to functions/methods that expected
> string parameters, was identified as being responsible for a huge
> proprortion of the static footprint bloat during the "XORP on a Diet"
> project I did while at the company. Most, if not all, of the problems
> I found and fixed made it back to the public sources.
>
> I used rather rudementary tools (grep, nm, perl scripts, etc.) to
> identify the sources, so I'm not terribly surprised that others still
> exist.
>
> Fortunately, these tend to be uncontroversial and quite easy to fix.
>   
Yeah, it was a trivial fix and almost certainly harmless.  I plan to 
continue fixing
such problems as I find them.  I'll remember to keep an eye out for 
passing string
literals too..haven't been watching for those.

I've found no problems with the removal of delays for xorpsh commit and 
the startup
logic in 3 days of heavy testing, by the way.  It's possible it's 
uncovered a few races
I wouldn't have noticed otherwise...but the bugs were there regardless 
(and I'm fixing
the bugs as I find them.)

Thanks,
Ben

-- 
Ben Greear <greearb at candelatech.com> 
Candela Technologies Inc  http://www.candelatech.com




More information about the Xorp-hackers mailing list