D John Anderson wrote:
> While I'm in favor of faster code, and I don't dispute that these
> changes make things faster, I'm curious if they result in any measurable
> or noticeable improvement.

I didn't do exact measurements on all of the changes, but at least one
of the rect.Get() changes improved one test on Linux by about 0.5%.
Also, I only looked at len() calls that showed in the top 100 cumulative
call stacks for the tests, which there weren't that many (i.e. easy fix,
wanted to do also partly to put some examples into the code).

So overall I expect the effect to be 1% or less for any test, but
noticeable at least when looking at profiles.

> I think the if __debug__ can be removed, since asserts only happen when
> __debug__ is True.

Yes, I've done so. Bryan also pointed this out. I mixed assert with
logger.debug() calls which can be expensive.

-- 
  Heikki Toivonen


Attachment: signature.asc
Description: OpenPGP digital signature

_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _

Open Source Applications Foundation "chandler-dev" mailing list
http://lists.osafoundation.org/mailman/listinfo/chandler-dev

Reply via email to