Re: [Python-Dev] Store startup modules as C structures for 20%+ startup speed improvement?

2018-09-18 Thread Neil Schemenauer
On 2018-09-18, Carl Shapiro wrote: > How might people feel about using the linker to bundle a list of pre-loaded > modules into a single-file executable? The users of Python are pretty diverse so it depends on who you ask. Some would like a giant executable that includes everything they need (so

Re: [Python-Dev] Store startup modules as C structures for 20%+ startup speed improvement?

2018-09-18 Thread Carl Shapiro
On Tue, Sep 18, 2018 at 11:38 AM, Steve Dower wrote: > The primary benefit of the importlib hook approach is that it would not > require rebuilding CPython each time you make a change. Since we need to > consider a wide range of users across a wide range of platforms, having the > ability to

Re: [Python-Dev] SEC: Spectre variant 2: GCC: -mindirect-branch=thunk -mindirect-branch-register

2018-09-18 Thread Franklin? Lee
On Tue, Sep 18, 2018 at 2:40 AM INADA Naoki wrote: > > On Tue, Sep 18, 2018 at 7:08 AM Wes Turner wrote: > > > > To summarize: > > > > - CPython may be vulnerable to speculative execution vulnerabilities, but > > none are known. > > - In general, CPython is currently too slow for speculative

Re: [Python-Dev] Store startup modules as C structures for 20%+ startup speed improvement?

2018-09-18 Thread Fabio Zadrozny
On Tue, Sep 18, 2018 at 2:57 PM, Carl Shapiro wrote: > On Tue, Sep 18, 2018 at 5:55 AM, Fabio Zadrozny wrote: > >> During the import process, Python can already deal with folders and .zip >> files in sys.path... now, instead of having special handling for a new >> concept with a custom command

Re: [Python-Dev] Store startup modules as C structures for 20%+ startup speed improvement?

2018-09-18 Thread Steve Dower
On 18Sep2018 1057, Carl Shapiro wrote: On Tue, Sep 18, 2018 at 5:55 AM, Fabio Zadrozny > wrote: During the import process, Python can already deal with folders and .zip files in sys.path... now, instead of having special handling for a new concept with a

Re: [Python-Dev] Store startup modules as C structures for 20%+ startup speed improvement?

2018-09-18 Thread Carl Shapiro
On Tue, Sep 18, 2018 at 5:55 AM, Fabio Zadrozny wrote: > During the import process, Python can already deal with folders and .zip > files in sys.path... now, instead of having special handling for a new > concept with a custom command line, etc, why not just say that this is a > special file

Re: [Python-Dev] Store startup modules as C structures for 20%+ startup speed improvement?

2018-09-18 Thread Carl Shapiro
On Tue, Sep 18, 2018 at 1:31 AM, Antoine Pitrou wrote: > No idea. In my previous experiments with module import speed, I > concluded that executing module bytecode generally was the dominating > contributor, but that doesn't mean loading bytecode is costless. > My observations might not be so

Re: [Python-Dev] Nearly - all tests PASS for AIX

2018-09-18 Thread Michael
On 17/09/2018 12:50, Michael wrote: > Dear all, > > The last two months I have spent nearly all my free time to cleanup "a > frustration" - from my side - the long list of failing tests for AIX > (there were nearly 20 when I started). == Tests result: SUCCESS == 393 tests OK. 1 test altered the

Re: [Python-Dev] Store startup modules as C structures for 20%+ startup speed improvement?

2018-09-18 Thread Fabio Zadrozny
On Mon, Sep 17, 2018 at 9:23 PM, Carl Shapiro wrote: > On Sun, Sep 16, 2018 at 1:24 PM, Antoine Pitrou > wrote: > >> I think it's of limited interest if it only helps with modules used >> during the startup sequence, not arbitrary stdlib or third-party >> modules. >> > > This should help any

[Python-Dev] Request review of bpo-34125/GH-8416

2018-09-18 Thread Jeroen Demeyer
The gist of bpo-34125 is that the following two statements behave differently with respect to sys.setprofile() profiling: >>> list.append([], None) >>> list.append([], None, **{}) More precisely: the former call is profiled, but the latter is not. The fix at GH-8416 is simply to make this

Re: [Python-Dev] debugging test_importlib.test_bad_traverse - script status is SUCCESS - but FAIL is expected.

2018-09-18 Thread Michael
On 17/09/2018 09:39, Michael wrote: > I read the discussion related to issue32374. That seems to be sure that > other events that could > cause the test to fail (i.e., the program executes successfully) are > caught early, and/or ignored > so that the program fails - and the test succeeds. After

Re: [Python-Dev] Store startup modules as C structures for 20%+ startup speed improvement?

2018-09-18 Thread Antoine Pitrou
On Mon, 17 Sep 2018 17:23:26 -0700 Carl Shapiro wrote: > > > To give an idea, on my machine the baseline Python startup is about 20ms > > (`time python -c pass`), but if I import Numpy it grows to 100ms, and > > with Pandas it's more than 200ms. Saving 4ms on the baseline startup > > would make

Re: [Python-Dev] SEC: Spectre variant 2: GCC: -mindirect-branch=thunk -mindirect-branch-register

2018-09-18 Thread INADA Naoki
On Tue, Sep 18, 2018 at 7:08 AM Wes Turner wrote: > > To summarize: > > - CPython may be vulnerable to speculative execution vulnerabilities, but > none are known. > - In general, CPython is currently too slow for speculative execution > exploitation to be practical. > - Sandboxed, JIT'ed JS