Message330844
Thanks for the speedy and helpful response.
Keeping complexity down is fair. The wasted if-checks on subsequent iterations are certainly a negative trade-off. I saw that binarysort() is only called in one place, but I understand wanting to keep it generic.
I think that slow comparison functions, especially when repeatedly sorting short lists, are the main use case.
I don't know if that's common in performance-critical code. I've heard of using human choices for comparisons, when fewer decisions could provide a notable speedup. The patched code seems a bit slower in some situations, but is faster in others.
Do you think it's worth posting to python-ideas to see what people's use cases are? |
|
Date |
User |
Action |
Args |
2018-12-01 08:01:14 | dwyde | set | recipients:
+ dwyde, tim.peters |
2018-12-01 08:01:14 | dwyde | set | messageid: <1543651274.21.0.788709270274.issue35369@psf.upfronthosting.co.za> |
2018-12-01 08:01:14 | dwyde | link | issue35369 messages |
2018-12-01 08:01:13 | dwyde | create | |
|