You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Nobody (including me) has had the time to get it into Phobos.
If you feel like you can included it here aswell.
The two most important todos are:
Figure out a way to template-parameterize radixSortImpl to make it work on aggregate element types when the comparison function can be expressed as an data-member-accessor of the aggregate. For example if ElementType is a struct S { int x, y; } and comparison function "a.x < b.x".
If possible implement a generic sorting algorithm that automatically selects the best suitable in-Place sorting algorithm based on types of the input parameters (range and comparsion/accessor function). This currently means isIntegral, float, double, and as above mentioned aggregates sorted on a member or combination of members whose bijection can fit into 8, 16, 32 or 64 bits.
The text was updated successfully, but these errors were encountered:
I appreciate it but I'd like to keep the code in this repository as my own. Otherwise, since I don't have my own implementation of radix sort, I could provide a link to your code in the README so others can find it. I know the README is huge; I've been meaning to move the module descriptions into separate files which would give your link greater prominence.
Also, sorry for the late response. I haven't given any attention to this repository lately as it's been on the back burner for some time.
I've pushed a draft of a new README and provided a link to your radix sort code. I'll replace the old README once I'm done restructuring this repository.
I have a radix sort implementation at
https://github.com/nordlow/justd/blob/master/intsort.d#L92intsort.d
which beats Phobos own Quicksort by a factor 1.5 to 4 depending on element type (Intergral or FloatingPoint).
Run the unittest and see for yourself.
Not that I've made it work for floating point too using the functions at
https://github.com/nordlow/justd/blob/master/intsort.d#L58
that realizes bijections between
Nobody (including me) has had the time to get it into Phobos.
If you feel like you can included it here aswell.
The two most important todos are:
radixSortImplto make it work on aggregate element types when the comparison function can be expressed as an data-member-accessor of the aggregate. For example if ElementType is astruct S { int x, y; }and comparison function "a.x < b.x".isIntegral,float,double, and as above mentioned aggregates sorted on a member or combination of members whose bijection can fit into 8, 16, 32 or 64 bits.The text was updated successfully, but these errors were encountered: