Author serhiy.storchaka
Recipients gvanrossum, levkivskyi, serhiy.storchaka, xgdomingo
Date 2017-12-14.12:22:24
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1513254144.95.0.213398074469.issue32226@psf.upfronthosting.co.za>
In-reply-to
Content
This adds an overhead to every indexing.

$ ./python -m perf timeit --compare-to=./python0 -s 'a = [1]' --duplicate=10000 'a[0]'
python0: ..................... 15.3 ns +- 0.5 ns
python: ..................... 16.1 ns +- 0.3 ns

Mean +- std dev: [python0] 15.3 ns +- 0.5 ns -> [python] 16.1 ns +- 0.3 ns: 1.05x slower (+5%)

$ ./python -m perf timeit --compare-to=./python0 -s 'd = {1: 2}' --duplicate=10000 'd[1]'
python0: ..................... 17.6 ns +- 0.6 ns
python: ..................... 18.4 ns +- 0.5 ns

Mean +- std dev: [python0] 17.6 ns +- 0.6 ns -> [python] 18.4 ns +- 0.5 ns: 1.05x slower (+5%)
History
Date User Action Args
2017-12-14 12:22:25serhiy.storchakasetrecipients: + serhiy.storchaka, gvanrossum, levkivskyi, xgdomingo
2017-12-14 12:22:24serhiy.storchakasetmessageid: <1513254144.95.0.213398074469.issue32226@psf.upfronthosting.co.za>
2017-12-14 12:22:24serhiy.storchakalinkissue32226 messages
2017-12-14 12:22:24serhiy.storchakacreate