[pypy-dev] JIT not kicking in for callbacks

Maciej Fijalkowski fijall at gmail.com
Mon Mar 31 20:33:15 CEST 2014


hi "interpret" includes "in the jit". if you're having trouble with
the performance, please let us know how to reproduce it and we'll try
to help you pinpoint down the problem.

On Mon, Mar 31, 2014 at 8:28 PM, Eleytherios Stamatogiannakis
<estama at gmail.com> wrote:
> Hello,
>
> I'm not sure, but i think that the JIT doesn't kick in when the loops are
> "external", where C-code does the loop and calls Python code for each
> iteration, through CFFI callbacks. In our code, we have SQLite, calling
> Python code through callbacks.
>
> Using the loop log:
>
> PYPYLOG=log pypy mterm.py
>
> i see this summary:
>
> interpret                                           91%
> gc-collect-step                                     4%
> gc-minor                                            3%
> jit-optimize                                        0%
> gc-minor-walkroots                                  0%
> jit-tracing                                         0%
> jit-backend                                         0%
> jit-log-compiling-bridge                            0%
> jit-resume                                          0%
> jit-backend-dump                                    0%
> gc-set-nursery-size                                 0%
> jit-log-virtualstate                                0%
> jit-backend-addr                                    0%
> gc-hardware                                         0%
> jit-log-noopt-loop                                  0%
> jit-mem-looptoken-alloc                             0%
> jit-log-opt-bridge                                  0%
> jit-log-rewritten-loop                              0%
> jit-log-rewritten-bridge                            0%
> jit-log-compiling-loop                              0%
> jit-log-opt-loop                                    0%
> jit-log-short-preamble                              0%
> jit-abort                                           0%
> jit-mem-collect                                     0%
> jit-summary                                         0%
> jit-backend-counts                                  0%
>
>
> If i read that correctly, most of the execution time is in the interpreter
> and not in the JITed code. Is there some way where i can "hint" to pypy that
> a callback is essentially the inside of a loop, so PyPy can JIT it?.
>
> I've attached the simple log from which above summary has been produced via:
>
> python logparser.py print-summary log.log -
>
> Regards,
>
> l.
>
>
>
> _______________________________________________
> pypy-dev mailing list
> pypy-dev at python.org
> https://mail.python.org/mailman/listinfo/pypy-dev
>


More information about the pypy-dev mailing list