Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider optional C implementation #17

Open
mulkieran opened this issue Mar 14, 2016 · 1 comment
Open

Consider optional C implementation #17

mulkieran opened this issue Mar 14, 2016 · 1 comment

Comments

@mulkieran
Copy link
Owner

Optional means a user can choose to stick with pure Python version if desired.

@mulkieran
Copy link
Owner Author

Other possibilities are to use some sort of Python to C translation:

  • shedskin doesn't support fractions module
  • pythran objects to classes in modules, requires everything to be functions for more direct analogy to C
  • cython would require actual changes to code base to get most of the benefit or using verbose pure python mode
  • yet another alternative is to use pure C with wrapper when it can be proved that ints and so forth will not overflow. For something as simple as justbases, that's an option. If it can not be proved that ints will not overflow, stick with Python.

The big question is what is the goal, if any. Speedup would be nice and is probably achievable, but nobody is asking for it. The only use is to do display for justbytes, and generally speaking that is fast due to the limits put on the values that get displayed, i.e., if you're only calculating two digits after the decimal point the computation will still terminate pretty quickly.

So, the only goal is to exercise these things, to see if they work and how much speedup they provide.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant