[issue40925] Remove redundant macros used for stack manipulation in interpreter

2020-06-09 Thread Mark Shannon
New submission from Mark Shannon : Currently, there are fourteen macros provided for stack manipulation. Along with the fundamental, POP(), PUSH() and PEEK(n) the following eleven are also provided: TOP() SECOND() THIRD() FOURTH() SET_TOP(v) SET_SECOND(v

[issue40925] Remove redundant macros used for stack manipulation in interpreter

2020-06-10 Thread Mark Shannon
Mark Shannon added the comment: I'm proposing that we remove the nine macros above; the eleven listed, except TOP() and SECOND(). They can be replaced by POP(), PUSH() and PEEK() without lost of functionality or performance. -- ___ Python tr

[issue40941] Merge generator.gi_running and frame executing flag into single frame state

2020-06-10 Thread Mark Shannon
New submission from Mark Shannon : Generators have a "gi_running" attribute (coroutines have an equivalent cr_running flag). Internally frame also has an executing flag. We use these, plus the test `f_stacktop pointer == NULL`, to determine what state a generator or frame is in. I

[issue40925] Remove redundant macros used for stack manipulation in interpreter

2020-06-11 Thread Mark Shannon
Mark Shannon added the comment: New changeset 33faf5c4f43e24766cf567bec89ad4c7f1491ff7 by Dong-hee Na in branch 'master': bpo-40925: Remove unused stack macro SET_VALUE (GH-20783) https://github.com/python/cpython/commit/33faf5c4f43e24766cf567bec89ad4

[issue40941] Merge generator.gi_running and frame executing flag into single frame state

2020-06-11 Thread Mark Shannon
Mark Shannon added the comment: This change combines the explicit state in `PyFrameObject.f_excuting` and `PyGenObject.gi_running`, and the implicit state in `PyFrameObject.f_stacktop == NULL` and `PyFrameObject.f_last == -1` into a single enum field in `PyFrameObject`. Since we no longer

[issue40941] Merge generator.gi_running and frame executing flag into single frame state

2020-06-11 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +1 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/20803 ___ Python tracker <https://bugs.python.org/issu

[issue40925] Remove redundant macros used for stack manipulation in interpreter

2020-06-13 Thread Mark Shannon
Mark Shannon added the comment: Dennis, thanks for doing the benchmarking. You seem to have removed rather more macros than I suggested, but it probably won't make much difference to the results. Since this may have a negative effect on performance and doesn't seem to be popular,

[issue40925] Remove redundant macros used for stack manipulation in interpreter

2020-06-13 Thread Mark Shannon
Change by Mark Shannon : -- stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.org/issue40925> ___ ___ Pyth

[issue40941] Merge generator.gi_running and frame executing flag into single frame state

2020-07-09 Thread Mark Shannon
Mark Shannon added the comment: issue29590 is unrelated -- ___ Python tracker <https://bugs.python.org/issue40941> ___ ___ Python-bugs-list mailing list Unsub

[issue29590] Incorrect stack traces when re-entering a generator/coroutine stack via .throw()

2020-07-09 Thread Mark Shannon
Mark Shannon added the comment: New changeset 8b33961e4bc4020d8b2d5b949ad9d5c669300e89 by Chris Jerdonek in branch 'master': bpo-29590: fix stack trace for gen.throw() with yield from (#19896) https://github.com/python/cpython/commit/8b33961e4bc4020d8b2d5b949ad9d5c669300e89 -

[issue41323] Perform "peephole" optimization directly on control-flow graph.

2020-07-17 Thread Mark Shannon
New submission from Mark Shannon : Currently we perform various bytecode improvements as a pass on the code objects after generating the code object. This requires parsing the bytecode to find instructions, recreating the CFG, and rewriting the line number table. If we perform the

[issue41323] Perform "peephole" optimization directly on control-flow graph.

2020-07-17 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +20653 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/21517 ___ Python tracker <https://bugs.python.org/issu

[issue40941] Merge generator.gi_running and frame executing flag into single frame state

2020-07-17 Thread Mark Shannon
Mark Shannon added the comment: New changeset cb9879b948a19c9434316f8ab6aba9c4601a8173 by Mark Shannon in branch 'master': bpo-40941: Unify implicit and explicit state in the frame and generator objects into a single value. (GH-20803) https://github.com/python/cpyt

[issue41323] Perform "peephole" optimization directly on control-flow graph.

2020-07-30 Thread Mark Shannon
Change by Mark Shannon : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue41323] Perform "peephole" optimization directly on control-flow graph.

2020-07-30 Thread Mark Shannon
Mark Shannon added the comment: New changeset 6e8128f02e1d36e38e5866f9dc36e051caa47bc9 by Mark Shannon in branch 'master': bpo-41323: Perform 'peephole' optimizations directly on the CFG. (GH-21517) https://github.com/python/cpython/commit/6e8128f02e1d36e38e58

[issue41463] Avoid duplicating jump information from opcode.py in compile.c

2020-08-03 Thread Mark Shannon
New submission from Mark Shannon : opcode.py declares which jumps are relative and which are absolute. We duplicate that information in compile.c We should generate lookup tables in opcodes.h and to repeating that information in compile.c -- messages: 374735 nosy: Mark.Shannon

[issue41463] Avoid duplicating jump information from opcode.py in compile.c

2020-08-03 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +20858 stage: -> patch review pull_request: https://github.com/python/cpython/pull/21714 ___ Python tracker <https://bugs.python.org/issu

[issue41463] Avoid duplicating jump information from opcode.py in compile.c

2020-08-04 Thread Mark Shannon
Mark Shannon added the comment: New changeset 582aaf19e8b94a70c1f96792197770d604ba0fdf by Mark Shannon in branch 'master': bpo-41463: Generate information about jumps from 'opcode.py' rather than duplicating it in 'compile.c' (GH-21714) https://gi

[issue41531] Python 3.9 regression: Literal dict with > 65535 items are one item shorter

2020-08-13 Thread Mark Shannon
Mark Shannon added the comment: New changeset c51db0ea40ddabaf5f771ea633b37fcf4c90a495 by Pablo Galindo in branch 'master': bpo-41531: Fix compilation of dict literals with more than 0x elements (GH-21850) https://github.com/python/cpython/commit/c51db0ea40ddabaf5f771ea633b37f

[issue41531] Python 3.9 regression: Literal dict with > 65535 items are one item shorter

2020-08-13 Thread Mark Shannon
Mark Shannon added the comment: @hroncok, How did you discover this issue? I'd like to clean up the code for creating dictionary literals and it might be helpful to know where such huge dictionary literals exist. I'm guessing that they are used as lookup tables for things like Uni

[issue41670] ceval traces code differently with USE_COMPUTED_GOTOS

2020-08-31 Thread Mark Shannon
Mark Shannon added the comment: A couple of things to fix here. Firstly, the PREDICTion of POP_BLOCK in FOR_ITER shouldn't be there. POP_BLOCK doesn't normally occur after a loop and hasn't since we removed "pseudo exceptions" from the interpreter a couple of years

[issue41670] ceval traces code differently with USE_COMPUTED_GOTOS

2020-08-31 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +21126 stage: -> patch review pull_request: https://github.com/python/cpython/pull/22026 ___ Python tracker <https://bugs.python.org/issu

[issue41703] Most bytecode changes are absent from Python 3.9 What's new

2020-09-08 Thread Mark Shannon
Change by Mark Shannon : -- assignee: -> Mark.Shannon ___ Python tracker <https://bugs.python.org/issue41703> ___ ___ Python-bugs-list mailing list Unsubscrib

[issue41703] Most bytecode changes are absent from Python 3.9 What's new

2020-09-08 Thread Mark Shannon
Mark Shannon added the comment: https://bugs.python.org/issue39320 has a change note: https://docs.python.org/3.9/whatsnew/changelog.html#python-3-9-0-beta-3 -- ___ Python tracker <https://bugs.python.org/issue41

[issue41703] Most bytecode changes are absent from Python 3.9 What's new

2020-09-08 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +21232 stage: -> patch review pull_request: https://github.com/python/cpython/pull/22151 ___ Python tracker <https://bugs.python.org/issu

[issue41703] Most bytecode changes are absent from Python 3.9 What's new

2020-09-08 Thread Mark Shannon
Mark Shannon added the comment: The change note for 33387 incorrectly referred to 32949 -- stage: patch review -> ___ Python tracker <https://bugs.python.org/issu

[issue41703] Most bytecode changes are absent from Python 3.9 What's new

2020-09-09 Thread Mark Shannon
Mark Shannon added the comment: Thanks for the reminder. Tis' done. -- stage: patch review -> ___ Python tracker <https://bugs.python.org/issue41703> ___

[issue41756] Do not always use exceptions to return result from coroutine

2020-09-17 Thread Mark Shannon
Mark Shannon added the comment: I agree with Serhiy, that `PyGen_` is a bad prefix. Unless a function takes generator objects and *only* generators objects, then it shouldn't have a `PyGen` prefix. The API function is the C equivalent of obj.send(val). The first parameter is an o

[issue41756] Do not always use exceptions to return result from coroutine

2020-09-21 Thread Mark Shannon
Mark Shannon added the comment: Yury, Why was the PR merged with a new API function `PyGen_Send`? I explicitly said that any new API function should *not* start with `PyGen`, nor should any function rely on generators and async "coroutines" sharing the same memory layout. If yo

[issue41810] Consider reintroducing `types.EllipsisType` for the sake of typing

2020-09-21 Thread Mark Shannon
Mark Shannon added the comment: I can't resist the pun on typing. `type(...)` is the least typing :) More seriously, >From a general consistency point of view, if this is to be added, shouldn't `types.NoneType` and `types.NotImplementedType` be added as well? -- nosy:

[issue40941] Merge generator.gi_running and frame executing flag into single frame state

2020-09-23 Thread Mark Shannon
Mark Shannon added the comment: Thanks Victor. Sorry I didn't get round to this sooner -- ___ Python tracker <https://bugs.python.org/issue40941> ___ ___

[issue41845] Promote PyObject_GenericGetDict to the stable API

2020-09-23 Thread Mark Shannon
Mark Shannon added the comment: It wasn't removed in 7d95e4072169911b228c9e42367afb5f17fd3db0, just moved from object.h to dictobject.h It was still part of the API at that point, I think. -- ___ Python tracker <https://bugs.python.org/is

[issue39934] Fatal Python error "XXX block stack overflow" when exception stacks >10

2020-09-24 Thread Mark Shannon
Mark Shannon added the comment: iritkatriel What error do you see and on what version? -- ___ Python tracker <https://bugs.python.org/issue39934> ___ ___ Pytho

[issue39934] Fatal Python error "XXX block stack overflow" when exception stacks >10

2020-09-24 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +21435 stage: -> patch review pull_request: https://github.com/python/cpython/pull/22395 ___ Python tracker <https://bugs.python.org/issu

[issue39934] Fatal Python error "XXX block stack overflow" when exception stacks >10

2020-09-25 Thread Mark Shannon
Mark Shannon added the comment: New changeset 02d126aa09d96d03dcf9c5b51c858ce5ef386601 by Mark Shannon in branch 'master': bpo-39934: Account for control blocks in 'except' in compiler. (GH-22395) https://github.com/python/cpython/commit/02d126aa09d96d03dcf9

[issue41670] ceval traces code differently with USE_COMPUTED_GOTOS

2020-09-29 Thread Mark Shannon
Mark Shannon added the comment: New changeset 17b5be0c0a3f74141014e06a660f1b5ddb002fec by Mark Shannon in branch 'master': bpo-41670: Remove outdated predict macro invocation. (GH-22026) https://github.com/python/cpython/commit/17b5be0c0a3f74141014e06a660f1b

[issue41756] Do not always use exceptions to return result from coroutine

2020-10-10 Thread Mark Shannon
Mark Shannon added the comment: Vladimir, Thanks for adding PyIter_Send(). Don't forget to remove PyGen_Send() :) -- ___ Python tracker <https://bugs.python.org/is

[issue41756] Do not always use exceptions to return result from coroutine

2020-10-11 Thread Mark Shannon
Mark Shannon added the comment: What's the difference between removing it and making it properly private (i.e. static)? It's an irrelevant detail whether the code is inlined or in a helper function. -- ___ Python tracker <https://bu

[issue42033] Seemingly unnecessary complexification of foo(**kw)

2020-10-15 Thread Mark Shannon
Mark Shannon added the comment: Have you observed any slowdown or incorrect behaviour? The 3.8 bytecode looks incorrect to me. The C-API documentation doesn't prohibit callables from mutating the dictionary they receive. Unless a copy is made, then a callee could mutate `var`.

[issue33387] Simplify bytecodes for try-finally, try-except and with blocks.

2020-10-16 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +21689 pull_request: https://github.com/python/cpython/pull/22723 ___ Python tracker <https://bugs.python.org/issue33

[issue33387] Simplify bytecodes for try-finally, try-except and with blocks.

2020-10-16 Thread Mark Shannon
Mark Shannon added the comment: Yes, thanks for pointing that out. -- ___ Python tracker <https://bugs.python.org/issue33387> ___ ___ Python-bugs-list mailin

[issue42057] pytest case which catch exceptions become segfault

2020-10-19 Thread Mark Shannon
Mark Shannon added the comment: The test example has no reference to pytest in it. How are you running it? Can you produce a segmentation fault when run without pytest? -- ___ Python tracker <https://bugs.python.org/issue42

[issue42057] peephole optimizer bug relating to JUMP_IF_NOT_EXC_MATCH

2020-10-22 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +21825 pull_request: https://github.com/python/cpython/pull/22893 ___ Python tracker <https://bugs.python.org/issue42

[issue42126] Optimize BUILD_CONST_KEY_MAP for distinct keys

2020-10-23 Thread Mark Shannon
Mark Shannon added the comment: Is this worthwhile? Statically, BUILD_CONST_KEY_MAP represents 0.14% of all bytecode instructions in the standard library, but only 0.03% of the bytecode instructions in functions. Which suggests that dynamically only 1 in 3000 instructions executed is

[issue41835] Speed up dict vectorcall creation using keywords

2020-10-23 Thread Mark Shannon
Mark Shannon added the comment: Could we get a pyperformance benchmark run on this please? -- nosy: +Mark.Shannon ___ Python tracker <https://bugs.python.org/issue41

[issue42126] Optimize BUILD_CONST_KEY_MAP for distinct keys

2020-10-23 Thread Mark Shannon
Mark Shannon added the comment: It sounds like the root cause is that annotations are repeatedly being computed. We should address the underlying issue, IMO. -- ___ Python tracker <https://bugs.python.org/issue42

[issue42099] Fix reference to ob_type in unionobject.c and ceval

2020-10-27 Thread Mark Shannon
Mark Shannon added the comment: New changeset 0564aafb71a153dd0aca4b9266dfae9336a4f2cb by Neil Schemenauer in branch 'master': bpo-42099: Fix reference to ob_type in unionobject.c and ceval (GH-22829) https://github.com/python/cpython/commit/0564aafb71a153dd0aca4b9266dfae

[issue42099] Fix reference to ob_type in unionobject.c and ceval

2020-10-27 Thread Mark Shannon
Mark Shannon added the comment: Thanks Neil -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue42217] compiler: merge co_code and co_lnotab

2020-10-31 Thread Mark Shannon
Mark Shannon added the comment: PEP 626 has just been accepted. Could you please leave this until I have merged in the implementation of PEP 626 which uses a different line number table format -- nosy: +Mark.Shannon ___ Python tracker <ht

[issue42246] Implement PEP 626

2020-11-02 Thread Mark Shannon
New submission from Mark Shannon : Implementation of PEP 626 requires: 1. Implementation of the new line number table and associated APIs. 2. Removal of BEGIN_DO_NOT_EMIT_BYTECODE and END_DO_NOT_EMIT_BYTECODE from the compiler as they do not understand line numbers and may remove lines from

[issue42246] Implement PEP 626

2020-11-02 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +22030 stage: -> patch review pull_request: https://github.com/python/cpython/pull/23113 ___ Python tracker <https://bugs.python.org/issu

[issue42246] Implement PEP 626

2020-11-03 Thread Mark Shannon
Mark Shannon added the comment: The following code is completely eliminated by the macros. 1. if 0: 2. secret_debugging_code() PEP 626 says that all executed lines of code must generate trace events, so we need to emit an instruction for line 1. Dead code elimination will remove the

[issue42246] Implement PEP 626

2020-11-03 Thread Mark Shannon
Change by Mark Shannon : -- nosy: +nedbat ___ Python tracker <https://bugs.python.org/issue42246> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue42294] [C API] Add new C functions with more regular reference counting like PyTuple_GetItemRef()

2020-11-09 Thread Mark Shannon
Mark Shannon added the comment: I'm not convinced that this is worth the effort. The old functions aren't going away, so these additional functions provide no real safety. You can't stop C programmers trading away correctness for some perceived performance benefit :( If we

[issue42246] Implement PEP 626

2020-11-12 Thread Mark Shannon
Mark Shannon added the comment: New changeset 877df851c3ecdb55306840e247596e7b7805a60a by Mark Shannon in branch 'master': bpo-42246: Partial implementation of PEP 626. (GH-23113) https://github.com/python/cpython/commit/877df851c3ecdb55306840e247596e

[issue42246] Implement PEP 626

2020-11-12 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +22142 stage: -> patch review pull_request: https://github.com/python/cpython/pull/23245 ___ Python tracker <https://bugs.python.org/issu

[issue42246] Implement PEP 626

2020-11-12 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +22148 pull_request: https://github.com/python/cpython/pull/23251 ___ Python tracker <https://bugs.python.org/issue42

[issue42246] Implement PEP 626

2020-11-12 Thread Mark Shannon
Mark Shannon added the comment: New changeset cc75ab791dd5ae2cb9f6e0c3c5f734a6ae1eb2a9 by Mark Shannon in branch 'master': bpo-42246: Eliminate jumps to exit blocks by copying those blocks. (#23251) https://github.com/python/cpython/commit/cc75ab791dd5ae2cb9f6e0c3c5f734

[issue42246] Implement PEP 626

2020-11-13 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +22153 pull_request: https://github.com/python/cpython/pull/23256 ___ Python tracker <https://bugs.python.org/issue42

[issue42246] Implement PEP 626

2020-11-13 Thread Mark Shannon
Mark Shannon added the comment: New changeset fd009e606a48e803e7187983bf9a5682e938fddb by Mark Shannon in branch 'master': bpo-42246: Fix memory leak in compiler (GH-23256) https://github.com/python/cpython/commit/fd009e606a48e803e7187983bf9a56

[issue42349] Compiler front-end produces a broken CFG

2020-11-13 Thread Mark Shannon
New submission from Mark Shannon : The front-end of the bytecode compiler produces a broken CFG. A number of "basic-block"s have terminators before their end. This makes the back-end optimizations unsafe as they rely of a well-formed CFG. The fix is simple. Insert a check that the C

[issue42349] Compiler front-end produces a broken CFG

2020-11-13 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +22163 stage: -> patch review pull_request: https://github.com/python/cpython/pull/23267 ___ Python tracker <https://bugs.python.org/issu

[issue42373] PEP 626 does not specify behavior of tracing for keywords.

2020-11-16 Thread Mark Shannon
New submission from Mark Shannon : PEP 626 doesn't cover which keywords are to be traced if they occur on a line by themselves. Some keywords, like `break`, in Python have behavior associated with them. Others, like `else` are just syntax and don't do anything. Currently, it is

[issue42202] Optimize function annotation

2020-11-17 Thread Mark Shannon
Mark Shannon added the comment: For top level functions (functions created once) this isn't going to make any real difference. There might be a small speedup for function creation, but it isn't going to be measurable. For nested functions with annotations, where many functions a

[issue42349] Compiler front-end produces a broken CFG

2020-11-17 Thread Mark Shannon
Mark Shannon added the comment: New changeset 266b462238bddec0213effad3650f19c56511e9f by Mark Shannon in branch 'master': bpo-42349: Compiler clean up. More yak-shaving for PEP 626. (GH-23267) https://github.com/python/cpython/commit/266b462238bddec0213effad3650f1

[issue39934] Fatal Python error "XXX block stack overflow" when exception stacks >10

2020-11-17 Thread Mark Shannon
Mark Shannon added the comment: New changeset 48a9c0eb2a3304ea64d1b32fdf9db853d5d8c429 by Irit Katriel in branch '3.9': [3.9] bpo-39934: Account for control blocks in 'except' in compiler. (GH-22395) (GH-23303) https://github.com/p

[issue42349] Compiler front-end produces a broken CFG

2020-11-23 Thread Mark Shannon
Change by Mark Shannon : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue42373] PEP 626 does not specify behavior of tracing for keywords.

2020-11-23 Thread Mark Shannon
Mark Shannon added the comment: https://github.com/python/peps/pull/1722/ -- ___ Python tracker <https://bugs.python.org/issue42373> ___ ___ Python-bugs-list m

[issue42246] Implement PEP 626

2020-11-24 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +22384 pull_request: https://github.com/python/cpython/pull/23495 ___ Python tracker <https://bugs.python.org/issue42

[issue13897] Move fields relevant to coroutine/generators out of frame into generator/threadstate

2012-01-28 Thread Mark Shannon
New submission from Mark Shannon : The frame object has a number of fields which belong to the generator object. By creating a CoState struct, these fields can be moved to generator/threadstate where they belong. The interpreter no longer has to swap around exception state whenever generators

[issue13897] Move fields relevant to coroutine/generators out of frame into generator/threadstate

2012-01-29 Thread Mark Shannon
Mark Shannon added the comment: Amaury Forgeot d'Arc wrote: > > - Why is it called CoState? is it related to coroutines? Yes it is related to coroutines, threads and generators *are* (a limited form of) asymmetric coroutines, even if we don't usually think of them tha

[issue13897] Move fields relevant to coroutine/generators out of frame into generator/threadstate

2012-01-29 Thread Mark Shannon
Mark Shannon added the comment: Nick Coghlan wrote: > Nick Coghlan added the comment: > > The division of responsibilities between generator objects and the eval loop > is currently a little messy. The eval loop deals almost entirely with frame > objects and also handles swa

[issue13903] New shared-keys dictionary implementation

2012-01-29 Thread Mark Shannon
New submission from Mark Shannon : The proposed dictionary implementation allows sharing of keys & hashes between dictionaries. This leads to substantial memory savings for object-oriented programs. For non-OO programs the impact is negligible. -- components: Interpreter Core hgr

[issue13903] New shared-keys dictionary implementation

2012-01-29 Thread Mark Shannon
Changes by Mark Shannon : Added file: http://bugs.python.org/file24360/6a21f3b35e20.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bugs-list m

[issue13897] Move fields relevant to coroutine/generators out of frame into generator/threadstate

2012-01-29 Thread Mark Shannon
Mark Shannon added the comment: The important part is not the change of name, but wrapping them in a struct which can be embedded in both PyThreadState and PyGenObject. The state->exc_XXX trio of values are the currently handled exception (sys.exc_info()) and are shadowed by genera

[issue13907] test_pprint relies on set/dictionary repr() ordering

2012-01-29 Thread Mark Shannon
New submission from Mark Shannon : The function test_set_reprs() includes the comment: "Consequently, this test is fragile and implementation-dependent" Changing the dictionary iteration ordering breaks it. -- components: Tests messages: 152272 nosy: Mark.Shannon priori

[issue13703] Hash collision security issue

2012-01-29 Thread Mark Shannon
Mark Shannon added the comment: Barry A. Warsaw wrote: > Barry A. Warsaw added the comment: > > On Jan 28, 2012, at 07:26 PM, Dave Malcolm wrote: > >> This turns out to pass without PYTHONHASHRANDOMIZATION in the >> environment, and fail intermittently with it. &g

[issue13909] Ordering of free variables in dis is dependent on dict ordering.

2012-01-29 Thread Mark Shannon
New submission from Mark Shannon : This only seems to apply to free variables, not local or cell variables. The offending tests are lines 429 & 430 of Lib/test/test_dis.py (tricky, code_info_tricky), (co_tricky_nested_f, code_info_tricky_nested_f), Changing PyDict_MINSIZE

[issue13910] test_packaging is dependent on dict ordering.

2012-01-29 Thread Mark Shannon
New submission from Mark Shannon : Changing PyDict_MINSIZE to 4 causes the following failure: python -m test.test_packaging ... Traceback (most recent call last): File "/home/mark/python/cpython/Lib/runpy.py", line 160, in _run_module_as_main "__main__", fname, load

[issue13911] test_trace depends on dict repr() ordering

2012-01-29 Thread Mark Shannon
New submission from Mark Shannon : Changing PyDict_MINSIZE to 4 causes the following failure python -m test.test_trace ... == ERROR: test_coverage (__main__.TestCoverage

[issue13903] New shared-keys dictionary implementation

2012-01-30 Thread Mark Shannon
Mark Shannon added the comment: Does this really need a PEP? There is no new language feature and no change to any API. It is just saving some memory. The only possible issue is changing dict repr() ordering, but issue 13703 will do that anyway

[issue13903] New shared-keys dictionary implementation

2012-01-31 Thread Mark Shannon
Mark Shannon added the comment: Raymond Hettinger wrote: > Raymond Hettinger added the comment: > > Changing dictionaries is a big deal. You're changing many pieces at once > (not a good idea) including changing tunable parameters that are well-studied > (I spent a mon

[issue13903] New shared-keys dictionary implementation

2012-02-06 Thread Mark Shannon
Changes by Mark Shannon : -- hgrepos: -109 ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13903] New shared-keys dictionary implementation

2012-02-08 Thread Mark Shannon
Changes by Mark Shannon : -- hgrepos: +112 ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13903] New shared-keys dictionary implementation

2012-02-08 Thread Mark Shannon
Changes by Mark Shannon : Added file: http://bugs.python.org/file24453/a9138aba7896.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bugs-list m

[issue13903] New shared-keys dictionary implementation

2012-02-08 Thread Mark Shannon
Changes by Mark Shannon : Removed file: http://bugs.python.org/file24360/6a21f3b35e20.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bug

[issue13903] New shared-keys dictionary implementation

2012-02-08 Thread Mark Shannon
Changes by Mark Shannon : Removed file: http://bugs.python.org/file24453/a9138aba7896.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bug

[issue13903] New shared-keys dictionary implementation

2012-02-08 Thread Mark Shannon
Changes by Mark Shannon : Added file: http://bugs.python.org/file24454/1f703b2607af.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bugs-list m

[issue13903] New shared-keys dictionary implementation

2012-02-08 Thread Mark Shannon
Mark Shannon added the comment: Antoine Pitrou wrote: > Antoine Pitrou added the comment: > > Looking at your latest patch, I worry about "any deletion > +(including pop & popitem) causes a split table to become a combined table". > Why wouldn't you use a

[issue13903] New shared-keys dictionary implementation

2012-02-08 Thread Mark Shannon
Changes by Mark Shannon : Removed file: http://bugs.python.org/file24454/1f703b2607af.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bug

[issue13903] New shared-keys dictionary implementation

2012-02-08 Thread Mark Shannon
Changes by Mark Shannon : Added file: http://bugs.python.org/file24455/bc286099ce9a.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bugs-list m

[issue13903] New shared-keys dictionary implementation

2012-02-08 Thread Mark Shannon
Changes by Mark Shannon : Removed file: http://bugs.python.org/file24455/bc286099ce9a.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bug

[issue13903] New shared-keys dictionary implementation

2012-02-08 Thread Mark Shannon
Changes by Mark Shannon : Added file: http://bugs.python.org/file24456/20702d1acf17.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bugs-list m

[issue13970] frameobject should not have f_yieldfrom attribute

2012-02-08 Thread Mark Shannon
New submission from Mark Shannon : The f_yieldfrom field should not be visible at Python level, it is an internal implementation detail. Patch attached. -- files: remove_f_yieldfrom.patch keywords: patch messages: 152895 nosy: Mark.Shannon priority: normal severity: normal status

[issue13911] test_trace depends on dict repr() ordering

2012-02-08 Thread Mark Shannon
Mark Shannon added the comment: Failure occurs in test_pprint which is covered by issue 13907 -- resolution: -> duplicate status: open -> closed ___ Python tracker <http://bugs.python.org/i

[issue13903] New shared-keys dictionary implementation

2012-02-09 Thread Mark Shannon
Changes by Mark Shannon : Added file: http://bugs.python.org/file24465/e50db1b7ad7b.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bugs-list m

[issue13903] New shared-keys dictionary implementation

2012-02-09 Thread Mark Shannon
Changes by Mark Shannon : Removed file: http://bugs.python.org/file24456/20702d1acf17.diff ___ Python tracker <http://bugs.python.org/issue13903> ___ ___ Python-bug

[issue13897] Move fields relevant to sys.exc_info out of frame into generator/threadstate

2012-02-13 Thread Mark Shannon
Mark Shannon added the comment: This issue was too broad. The new patch is focussed on sys.exc_info. All hints of coroutines have been removed and f_yieldfrom is untouched. New patch reduces code by 65 lines and does not conflict with issue 13607. -- title: Move fields relevant to

[issue13897] Move fields relevant to sys.exc_info out of frame into generator/threadstate

2012-02-13 Thread Mark Shannon
Changes by Mark Shannon : Removed file: http://bugs.python.org/file24350/coro.patch ___ Python tracker <http://bugs.python.org/issue13897> ___ ___ Python-bugs-list mailin

[issue13607] Move generator specific sections out of ceval.

2012-02-13 Thread Mark Shannon
Mark Shannon added the comment: Why do the codes used internally by ceval have to be the same as those made public? Have you considered returning the exit code directly, rather than adding another field to frameobject? yieldfrom can be handled in a similar way to yield by returning the

<    5   6   7   8   9   10   11   12   13   >