This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author facundobatista
Recipients
Date 2004-10-27.01:44:50
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
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
History
Date User Action Args
2007-08-23 15:40:20adminlinkissue1053375 messages
2007-08-23 15:40:20admincreate