Message156568
The -10..11 range was determined empirically. As you see from the values, only -10 shows up as significant... In fact, just storing 0 to 5 would capture the bulk of the savings.
Right, I'll do some test with the hardcoded values you mentioned.
Btw, I don't think -0.0 is worth it, that value is a typical arithmetic result and not something you typically get from input data.
Also, while interning in python is certainly possible, perhaps it would make sense to implement such in c. Perhaps in the math module, or perhaps even the 'intern' builtin can be extended for this purpose? It could be documented to intern any immutable object that it sees fit to intern, leaving the details to the implementation. |
|
Date |
User |
Action |
Args |
2012-03-22 15:07:45 | kristjan.jonsson | set | recipients:
+ kristjan.jonsson, mark.dickinson, pitrou, michael.foord, serhiy.storchaka |
2012-03-22 15:07:45 | kristjan.jonsson | set | messageid: <1332428865.34.0.316494979692.issue14381@psf.upfronthosting.co.za> |
2012-03-22 15:07:44 | kristjan.jonsson | link | issue14381 messages |
2012-03-22 15:07:44 | kristjan.jonsson | create | |
|