Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Coconut compiler constant overhead 170 times the overhead of the python interpreter #764

@koraa

Description

@koraa

Thank you for writing coconut. I really like the language, but being productive is hard since the compiler is so slow.

$ time python -c "def x(a): return a"
________________________________________________________
Executed in   61.30 millis    fish           external
   usr time   94.30 millis   45.31 millis   48.99 millis
   sys time   24.50 millis   14.71 millis    9.78 millis
$ time coconut -c "def x(a): return a"
________________________________________________________
Executed in   10.45 secs    fish           external
   usr time   10.22 secs    0.00 millis   10.22 secs
   sys time    0.11 secs    1.58 millis    0.11 secs
$ python -c "$(echo "import time; P = time.perf_counter; a = P(); def f(a): return a; print(P() - a)" | sed 's@; *@\n@g')"
2.8030008252244443e-06
$ coconut -c "$(echo "import time; P = time.perf_counter; a = P(); def f(a): return a; print(P() - a)" | sed 's@; *@\n@g')"
2.4760011001490057e-06

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions