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

Add sort support from @thomasmulvaney #361

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Add sort support from @thomasmulvaney #361

wants to merge 1 commit into from

Conversation

halgari
Copy link
Member

@halgari halgari commented Aug 20, 2015

Re-adds @thomasmulvaney's merge-sort. It's not a bad algorithm, although the JIT will probably throw a fit with it. We should improve it in the future to a) use mutable arrays during sorting and b) investigate how to get the JIT to be happier. Perhaps we should re-write it in RPython to get C-like speeds and call into Pixie for the comparisons. At any rate, we need some sort of sort at this point. So let's work with this.

@thomasmulvaney
Copy link
Member

I agree its not ideal. We could probably copy rpythons listsort code and make it so a comparison function can be passed.

@thomasmulvaney
Copy link
Member

@halgari I've just implemented a better version using pixies mutable arrays and get performance on par with Clojure when run in JIT mode. It just needs some tidying up.

@heyLu heyLu mentioned this pull request Nov 7, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants