[Python-checkins] python/dist/src/Misc NEWS,1.471,1.472
tim_one@users.sourceforge.net
tim_one@users.sourceforge.net
Thu, 15 Aug 2002 20:40:09 -0700
Update of /cvsroot/python/python/dist/src/Misc
In directory usw-pr-cvs1:/tmp/cvs-serv1138
Modified Files:
NEWS
Log Message:
Newly-relaxed limits on random.randrange(). Also added some info about
Karatsuba's better cache behavior with extremely large multiplicands.
Index: NEWS
===================================================================
RCS file: /cvsroot/python/python/dist/src/Misc/NEWS,v
retrieving revision 1.471
retrieving revision 1.472
diff -C2 -d -r1.471 -r1.472
*** NEWS 16 Aug 2002 03:38:10 -0000 1.471
--- NEWS 16 Aug 2002 03:40:07 -0000 1.472
***************
*** 94,102 ****
Karatsuba multiplication has O(N**1.58) runtime (the exponent is
log_base_2(3)) instead of the previous O(N**2). Measured results may
! be better or worse than that, depending on platform quirks. Note that
! this is a simple implementation, and there's no intent here to compete
! with, e.g., GMP. It gives a very nice speedup when it applies, but
! a package devoted to fast large-integer arithmetic should run circles
! around it.
- u'%c' will now raise a ValueError in case the argument is an
--- 94,104 ----
Karatsuba multiplication has O(N**1.58) runtime (the exponent is
log_base_2(3)) instead of the previous O(N**2). Measured results may
! be better or worse than that, depending on platform quirks. Besides
! the O() improvement in raw instruction count, the Karatsuba algorithm
! appears to have much better cache behavior on extremely large integers
! (starting in the ballpark of a million bits). Note that this is a
! simple implementation, and there's no intent here to compete with,
! e.g., GMP. It gives a very nice speedup when it applies, but a package
! devoted to fast large-integer arithmetic should run circles around it.
- u'%c' will now raise a ValueError in case the argument is an
***************
*** 296,299 ****
--- 298,306 ----
Library
+
+ - random.randrange(-sys.maxint-1, sys.maxint) no longer raises
+ OverflowError. That is, it now accepts any combination of 'start'
+ and 'stop' arguments so long as each is in the range of Python's
+ bounded integers.
- New "algorithms" module: heapq, implements a heap queue. Thanks to