[issue35448] ConfigParser .read() - handling of nonexistent files

2019-10-22 Thread Adrian Wielgosik
Adrian Wielgosik added the comment: Yeah, I lost steam on this issue, sorry. Go ahead :) -- ___ Python tracker <https://bugs.python.org/issue35448> ___ ___ Pytho

[issue35448] ConfigParser .read() - handling of nonexistent files

2018-12-09 Thread Adrian Wielgosik
New submission from Adrian Wielgosik : Documentation of ConfigParser says: > If a file named in filenames cannot be opened, that file will be ignored. > This is designed so that you can specify an iterable of potential > configuration file locations (for example, the current

[issue24700] array compare is hideously slow

2017-08-06 Thread Adrian Wielgosik
Adrian Wielgosik added the comment: Added a PR with a fast path that triggers when compared arrays store values of the same type. In this fast path, no Python objects are created. For big arrays the runtime reduction can reach 50-100x. It's possible to optimize the comparison loop a bit more

[issue24700] array compare is hideously slow

2017-08-06 Thread Adrian Wielgosik
Changes by Adrian Wielgosik <adrian.wielgo...@gmail.com>: -- pull_requests: +3042 ___ Python tracker <rep...@bugs.python.org> <http://bugs.python

[issue28813] Remove unneeded folded consts after peephole

2016-11-27 Thread Adrian Wielgosik
Adrian Wielgosik added the comment: Attached squashed patch. > But moving constant folding from the peephole optimizer to the AST level > (...) would totally eliminate the need in your patch. I'm aware of that and I'm okay with it. I chose an unfortunate moment for implem

[issue28813] Remove unneeded folded consts after peephole

2016-11-27 Thread Adrian Wielgosik
Changes by Adrian Wielgosik <adrian.wielgo...@gmail.com>: Added file: http://bugs.python.org/file45662/clean_co_consts.patch ___ Python tracker <rep...@bugs.python.org> <http://bugs.python

[issue28813] Remove unneeded folded consts after peephole

2016-11-27 Thread Adrian Wielgosik
Changes by Adrian Wielgosik <adrian.wielgo...@gmail.com>: -- keywords: +patch Added file: http://bugs.python.org/file45661/indices_tweak.patch ___ Python tracker <rep...@bugs.python.org> <http://bugs.python

[issue28813] Remove unneeded folded consts after peephole

2016-11-27 Thread Adrian Wielgosik
New submission from Adrian Wielgosik: The attached patch adds new logic to peephole compiler to remove constants that are no longer needed after the main peephole pass. For example: def f(): var = 'te' + 'xt' num = -12 num = -6 * 2 return (1, (3, 4), 6

[issue28621] Refactor duplicate code calculating digit's bit length

2016-11-05 Thread Adrian Wielgosik
Changes by Adrian Wielgosik <adrian.wielgo...@gmail.com>: -- keywords: +patch Added file: http://bugs.python.org/file45367/bit_length.patch ___ Python tracker <rep...@bugs.python.org> <http://bugs.python

[issue28621] Refactor duplicate code calculating digit's bit length

2016-11-05 Thread Adrian Wielgosik
New submission from Adrian Wielgosik: The attached patch uses an existing function bits_in_digit() in two other functions: - in long_bit_length() - it already had identical logic - in _PyLong_NumBits() - it used a naive, slower way of calculating bit length, so as an added bonus the patch

[issue27097] ceval: Wordcode follow up, explicit unsigned short read

2016-05-24 Thread Adrian Wielgosik
Adrian Wielgosik added the comment: I'm pretty sure this is undefined behavior. Here's how similar code was fixed in Chromium: https://codereview.chromium.org/9117014/patch/1/2 -- nosy: +Adrian Wielgosik ___ Python tracker <rep...@bugs.python.