Michele Orrù added the comment:

woops, sry. Re-posting the benchmark, with three tests: the first one proposed 
(@abacabadabacaba) with very large sets; another one with smaller sets.

$ ./python.exe -m timeit  -n 100 -s "s= set(range(2000)); l = 
set(range(20000000))"   "s-=l"
100 loops, best of 3: 9.71 usec per loop
[48787 refs]

$ ./python.exe -m timeit  -n 100 -s "s= set(range(1)); l = set(range(20))"   
"s-=l"
100 loops, best of 3: 0.366 usec per loop


$ hg co -C
$ make -j3

----[!PATCHED]--------------------------------------------------
$ ./python.exe -m timeit  -n 100 -s "s= set(range(2000)); l = 
set(range(20000000))"   "s-=l"
100 loops, best of 3: 665 msec per loop
[48787 refs]

$ ./python.exe -m timeit  -n 100 -s "s= set(range(1)); l = set(range(20))"   
"s-=l"
100 loops, best of 3: 0.849 usec per loop
[48787 refs]

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue8425>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to