Message47134
Logged In: YES
user_id=752496
Commited the previous minor changes. And took another
approach: left _WorkRep but with improvements:
- Optimized the conversion from Decimal's int to _WorkRep's
int (in _WorkRep).
- Changed a comparison in __add__ so there's no more need of
__cmp__, __abs__, and __neg__ in _WorkRep.
- _WorkRep's sign now uses the scheme of Decimal, so I
eliminated a lot of changes from (0,1) to (1,None,-1) and
viceversa.
Now it shows a speedup of 6% in the tests and 4% in the
telco benchmark, but I think that the greater win is in the
readibility of the code (specially with the signs).
I attach the new decimal.py.
. Facundo |
|
Date |
User |
Action |
Args |
2007-08-23 15:40:20 | admin | link | issue1053375 messages |
2007-08-23 15:40:20 | admin | create | |
|