[issue26110] Speedup method calls 1.2x

2021-05-16 Thread Ken Jin
Change by Ken Jin : -- pull_requests: +24793 pull_request: https://github.com/python/cpython/pull/26159 ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2021-05-10 Thread Ken Jin
Change by Ken Jin : -- nosy: +kj nosy_count: 21.0 -> 22.0 pull_requests: +24665 pull_request: https://github.com/python/cpython/pull/26014 ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2019-06-12 Thread Jeroen Demeyer
Jeroen Demeyer added the comment: Note that this idea has been generalized by PEP 590: any type can support this optimization by setting the Py_TPFLAGS_METHOD_DESCRIPTOR flag. -- nosy: +jdemeyer ___ Python tracker

[issue26110] Speedup method calls 1.2x

2017-08-09 Thread Jesús Cea Avión
Changes by Jesús Cea Avión : -- nosy: +jcea ___ Python tracker ___ ___ Python-bugs-list mailing

[issue26110] Speedup method calls 1.2x

2017-03-31 Thread Donald Stufft
Changes by Donald Stufft : -- pull_requests: +1065 ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2017-01-16 Thread INADA Naoki
Changes by INADA Naoki : -- status: open -> closed ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2017-01-16 Thread Roundup Robot
Roundup Robot added the comment: New changeset a6241b2073c6 by INADA Naoki in branch 'default': Issue #26110: Add document for LOAD_METHOD and CALL_METHOD opcode. https://hg.python.org/cpython/rev/a6241b2073c6 -- ___ Python tracker

[issue26110] Speedup method calls 1.2x

2017-01-15 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file46294/call-method-doc5.patch ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2017-01-15 Thread INADA Naoki
INADA Naoki added the comment: Yury, could you review this? -- ___ Python tracker ___ ___ Python-bugs-list

[issue26110] Speedup method calls 1.2x

2017-01-13 Thread STINNER Victor
STINNER Victor added the comment: I just created the issue #29263: "Implement LOAD_METHOD/CALL_METHOD for C functions". -- ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-12-19 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file45963/call-method-doc4.patch ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-12-14 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file45896/callmethod-doc3.patch ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-12-14 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file45891/callmethod-doc2.patch ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-12-14 Thread INADA Naoki
Changes by INADA Naoki : Removed file: http://bugs.python.org/file45890/callmethod-doc2.patch ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-12-14 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file45890/callmethod-doc2.patch ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-12-14 Thread STINNER Victor
STINNER Victor added the comment: INADA Naoki: "My current idea is adding new `tp_fastcall` slot which has same signature to _PyFunction_FastCallDict or _PyCFunction_FastCallDict." FYI I'm working on a solution to avoid tuple and dict to pass parameters to tp_new, tp_init and tp_call. I have

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread INADA Naoki
INADA Naoki added the comment: This patch modify stack layout slightly and adds document in Doc/library/dis.rst -- Added file: http://bugs.python.org/file45889/callmethod-doc.patch ___ Python tracker

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread INADA Naoki
INADA Naoki added the comment: PGO benchmark result https://gist.github.com/methane/64ab60c38324423ef27af70cc6db1dfd -- Added file: http://bugs.python.org/file45887/default.json.gz ___ Python tracker

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file45888/patched.json.gz ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread INADA Naoki
INADA Naoki added the comment: I haven't noticed the patch is committed already. Changing stack layout slightly is for easy to document, not for performance. Please don't close this issue until adding document in Doc/library/dis.rst -- ___ Python

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread INADA Naoki
INADA Naoki added the comment: I'm working on changing stack layout slightly current patch: callable | NULL | arg1 | ...argN next patch will: NULL | callable | arg1 | ...argN After benchmark with PGO build, I'll post it. -- ___ Python tracker

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread Yury Selivanov
Yury Selivanov added the comment: > Inada-san, when I tested the patch last time, I think there was a regression > somewhere, related to the descriptor protocol. Have you fixed that one? Seems to be either fixed, or maybe those bugs were related to my opcode cache patch. Anyways, I decided

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread Roundup Robot
Roundup Robot added the comment: New changeset 64afd5cab40a by Yury Selivanov in branch 'default': Issue #26110: Add LOAD_METHOD/CALL_METHOD opcodes. https://hg.python.org/cpython/rev/64afd5cab40a -- nosy: +python-dev ___ Python tracker

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread Yury Selivanov
Yury Selivanov added the comment: Inada-san, when I tested the patch last time, I think there was a regression somewhere, related to the descriptor protocol. Have you fixed that one? -- ___ Python tracker

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread Guido van Rossum
Changes by Guido van Rossum : -- nosy: -gvanrossum ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > But I think it should be separated issue. Agreed if that so hard. -- ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-12-13 Thread INADA Naoki
INADA Naoki added the comment: > And would be nice to extend the optimization to C functions. I tried it but skipping creating PyCFunction seems impossible for now. My current idea is adding new `tp_fastcall` slot which has same signature to _PyFunction_FastCallDict or

[issue26110] Speedup method calls 1.2x

2016-12-12 Thread INADA Naoki
INADA Naoki added the comment: > Technically the patch LGTM. But we should find the cause of the regression in > some benchmarks. The benchmark is on Sandy Bridge (Core i5 2400) and I didn't use PGO build. perf_event reported branch-miss rate increase at cpickle's save function. I'll rerun

[issue26110] Speedup method calls 1.2x

2016-12-12 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Technically the patch LGTM. But we should find the cause of the regression in some benchmarks. And would be nice to extend the optimization to C functions. In any case this optimization is worth mentioning in What's New. --

[issue26110] Speedup method calls 1.2x

2016-12-12 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file45866/call_method_5.patch ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-12-07 Thread Yury Selivanov
Yury Selivanov added the comment: Please don't merge this without my review. -- ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2016-12-07 Thread INADA Naoki
INADA Naoki added the comment: $ ./python-default -m perf compare_to default.json callmethod4.json -G Slower (7): - pickle_dict: 66.0 us +- 4.6 us -> 77.0 us +- 5.9 us: 1.17x slower - json_loads: 63.7 us +- 0.7 us -> 68.4 us +- 1.4 us: 1.07x slower - unpack_sequence: 120 ns +- 2 ns -> 125 ns +-

[issue26110] Speedup method calls 1.2x

2016-12-07 Thread INADA Naoki
Changes by INADA Naoki : Added file: http://bugs.python.org/file45788/callmethod4.json.gz ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-12-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Added comments on Rietveld. Please document new bytecodes in the dis module documentation and What's New. -- ___ Python tracker

[issue26110] Speedup method calls 1.2x

2016-12-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Please increase the magic number by 10. We need to reserve few numbers for the case of bytecode bug fixes in 3.6. -- nosy: +serhiy.storchaka ___ Python tracker

[issue26110] Speedup method calls 1.2x

2016-12-07 Thread INADA Naoki
Changes by INADA Naoki : -- versions: +Python 3.7 -Python 3.6 Added file: http://bugs.python.org/file45786/call_method_4.patch ___ Python tracker

[issue26110] Speedup method calls 1.2x

2016-09-13 Thread Ryan May
Changes by Ryan May : -- nosy: +Ryan May ___ Python tracker ___ ___ Python-bugs-list

[issue26110] Speedup method calls 1.2x

2016-07-01 Thread INADA Naoki
INADA Naoki added the comment: Oops, previous patch doesn't update magic number in PC/launcher.c Should I update it? Or don't touch it to avoid additional conflicts? -- Added file: http://bugs.python.org/file43601/call_method_3.patch ___ Python

[issue26110] Speedup method calls 1.2x

2016-07-01 Thread INADA Naoki
INADA Naoki added the comment: Updated, based on 102241:908b801f8a62 -- nosy: +naoki Added file: http://bugs.python.org/file43599/call_method_2.patch ___ Python tracker

[issue26110] Speedup method calls 1.2x

2016-05-15 Thread Jakub Stasiak
Changes by Jakub Stasiak : -- nosy: +jstasiak ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2016-05-03 Thread Josh Rosenberg
Changes by Josh Rosenberg : -- nosy: +josh.r ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2016-05-02 Thread Guido van Rossum
Guido van Rossum added the comment: This patch doesn't apply cleanly any more. Is it easy to update? -- ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-02-08 Thread Leonardo Santagada
Changes by Leonardo Santagada : -- nosy: +santagada ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2016-02-04 Thread Maciej Szulik
Changes by Maciej Szulik : -- nosy: +maciej.szulik ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2016-02-02 Thread Florin Papa
Changes by Florin Papa : -- nosy: +florin.papa ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2016-02-02 Thread Emanuel Barry
Changes by Emanuel Barry : -- nosy: +ebarry ___ Python tracker ___ ___ Python-bugs-list

[issue26110] Speedup method calls 1.2x

2016-02-01 Thread Yury Selivanov
Yury Selivanov added the comment: For those interested in reviewing this patch at some point: please wait until I upload a new version. The current patch is somewhat outdated. -- ___ Python tracker

[issue26110] Speedup method calls 1.2x

2016-02-01 Thread Alecsandru Patrascu
Changes by Alecsandru Patrascu : -- nosy: +alecsandru.patrascu ___ Python tracker ___

[issue26110] Speedup method calls 1.2x

2016-02-01 Thread Eric Fahlgren
Changes by Eric Fahlgren : -- nosy: +eric.fahlgren ___ Python tracker ___ ___

[issue26110] Speedup method calls 1.2x

2016-02-01 Thread Alecsandru Patrascu
Alecsandru Patrascu added the comment: Yury, thank you for the heads up! Here at Intel, in the Dynamic Scripting Languages Optimization Team, we can help the community with reviewing and measuring this patch in our quiet and stable environment, the same one that we use to provide public

[issue26110] Speedup method calls 1.2x

2016-01-14 Thread Yury Selivanov
Yury Selivanov added the comment: > If you prefer to limit the number of opcodes, you can pass a flag in > arguments. For example, use 2 bytes for 2 arguments instead of only 1? I tried two approaches: 1. Push one more leading NULL to the stack in LOAD_METHOD (which makes it push 3 vals).

[issue26110] Speedup method calls 1.2x

2016-01-14 Thread STINNER Victor
STINNER Victor added the comment: > For keyword and var-arg calls we have three more opcodes -- > CALL_FUNCTION_VAR, CALL_FUNCTION_KW, and CALL_FUNCTION_VAR_KW. I suspect > that making them work with LOAD_METHOD would slow them down too, which will > probably require us to add three (!) more

[issue26110] Speedup method calls 1.2x

2016-01-14 Thread Yury Selivanov
New submission from Yury Selivanov: This issue supersedes issue #6033. I decided to open a new one, since the patch is about Python 3.6 (not 2.7) and is written from scratch. The idea is to add new opcodes to avoid instantiation of BoundMethods. The patch only affects method calls of Python

[issue26110] Speedup method calls 1.2x

2016-01-14 Thread Guido van Rossum
Guido van Rossum added the comment: I like this idea! I like the limitations to positional-only calls. I do think that it would be nice if we could speed up C calls too -- today, s.startswith('abc') is slower than s[:3] == 'abc' precisely because of the lookup. But I'm all for doing this one

[issue26110] Speedup method calls 1.2x

2016-01-14 Thread Brett Cannon
Changes by Brett Cannon : -- nosy: +twouters ___ Python tracker ___ ___ Python-bugs-list

[issue26110] Speedup method calls 1.2x

2016-01-14 Thread Brett Cannon
Changes by Brett Cannon : -- nosy: +dino.viehland ___ Python tracker ___ ___