ANN: Dogelog Runtime, Prolog to the Moon (2021)

Chris Angelico rosuav at gmail.com
Wed Sep 15 13:26:39 EDT 2021


On Thu, Sep 16, 2021 at 3:17 AM Mostowski Collapse <janburse at fastmail.fm> wrote:
>
> I really wonder why my Python implementation
> is a factor 40 slower than my JavaScript implementation.
> Structurally its the same code.
>

Very hard to know. Your code is detailed and complicated. Do they
produce identical results? Are you using the same sort of
floating-point data everywhere, or is one integer and the other float?
What's going on with all the globals, the continuations, etc? My
suspicion is that you're trying to write weird, wonky Python code, and
then are surprised that it doesn't perform well.

ChrisA


More information about the Python-list mailing list