First of all, thank you for tackling this issue! I think the speed 
regression is mild enough that it is not too pressing an issue. 

On Tuesday, January 17, 2012 2:44:58 AM UTC-8, Simon King wrote:
>
>  * Should I modify my weak version of 
> `sage.structure.coerce_dict.TripleDict` so that strong references are 
> used in the first place, but so that the oldest references are 
> "weakened" when the dictionary grows bigger than a certain threshold? 
> That is likely to fix the example above and other types of examples as 
> well, but may create an overhead. 


As far as implementation goes, you just have to put every newly-generated 
entry also in a fixed-size ring buffer. I don't think that this would incur 
measurable overhead.




-- 
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel+unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org

Reply via email to