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 vstinner
Recipients serhiy.storchaka, vstinner
Date 2016-12-01.16:32:13
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1480609933.76.0.994700875579.issue28852@psf.upfronthosting.co.za>
In-reply-to
Content
Benchmark:

   ./python -m perf timeit -s 'x=list(range(1000))' 'sorted(x)'

Python 3.6 and 3.7 compared to Python 3.5:

   $ python3 -m perf compare_to 3.5.json.gz 3.6.json.gz 3.7.json.gz
   Median +- std dev: [3.5] 18.4 us +- 0.9 us -> [3.6] 20.5 us +- 0.9 us: 1.11x slower (+11%)
   Median +- std dev: [3.5] 18.4 us +- 0.9 us -> [3.7] 19.8 us +- 1.1 us: 1.08x slower (+8%)

I compiled Python with "./configure && make". The benchmark should be run again using LTO+PGO compilation to get more reliable benchmark results.

It seems like the benchmark is not very stable even with system tune (python3 -m perf system tune, isolcpus and rcu_nocbs in the Linux command line). I ran the benchmark 3 times using --append to concatenate all runs to get enough samples.

Histograms:

$ python3 -m perf hist 3.5.json.gz 3.6.json.gz 3.7.json.gz 
[ 3.5.json ]
15.0 us:  1 #
15.2 us:  0 |
15.5 us:  3 ###
15.7 us:  4 ####
16.0 us:  7 #######
16.2 us:  5 #####
16.5 us: 16 ################
16.7 us:  4 ####
17.0 us:  8 ########
17.2 us: 10 ##########
17.4 us:  7 #######
17.7 us:  5 #####
17.9 us:  5 #####
18.2 us: 23 ########################
18.4 us: 77 ###############################################################################
18.7 us:  5 #####
18.9 us:  0 |
19.2 us:  0 |
19.4 us:  0 |
19.7 us:  0 |
19.9 us:  0 |
20.1 us:  0 |
20.4 us:  0 |
20.6 us:  0 |
20.9 us:  0 |
21.1 us:  0 |

[ 3.6.json ]
15.0 us:  0 |
15.2 us:  0 |
15.5 us:  0 |
15.7 us:  0 |
16.0 us:  0 |
16.2 us:  0 |
16.5 us:  0 |
16.7 us:  0 |
17.0 us:  0 |
17.2 us:  0 |
17.4 us:  2 ###
17.7 us:  2 ###
17.9 us:  3 #####
18.2 us:  4 #######
18.4 us:  3 #####
18.7 us:  7 ############
18.9 us:  5 ########
19.2 us:  8 #############
19.4 us:  6 ##########
19.7 us:  7 ############
19.9 us:  9 ###############
20.1 us: 24 ########################################
20.4 us: 16 ###########################
20.6 us: 47 ###############################################################################
20.9 us: 27 #############################################
21.1 us: 10 #################

[ 3.7.json ]
15.0 us:  0 |
15.2 us:  0 |
15.5 us:  0 |
15.7 us:  0 |
16.0 us:  0 |
16.2 us:  1 ##
16.5 us:  0 |
16.7 us:  2 ###
17.0 us:  4 ######
17.2 us:  6 #########
17.4 us:  4 ######
17.7 us: 11 #################
17.9 us: 10 ################
18.2 us: 14 ######################
18.4 us: 10 ################
18.7 us:  5 ########
18.9 us:  3 #####
19.2 us: 10 ################
19.4 us:  6 #########
19.7 us: 13 #####################
19.9 us: 50 ###############################################################################
20.1 us: 10 ################
20.4 us: 19 ##############################
20.6 us:  2 ###
20.9 us:  0 |
21.1 us:  0 |
History
Date User Action Args
2016-12-01 16:32:13vstinnersetrecipients: + vstinner, serhiy.storchaka
2016-12-01 16:32:13vstinnersetmessageid: <1480609933.76.0.994700875579.issue28852@psf.upfronthosting.co.za>
2016-12-01 16:32:13vstinnerlinkissue28852 messages
2016-12-01 16:32:13vstinnercreate