Recent

Author Topic: Parallel BucketSort 1.0 is here.  (Read 6054 times)

aminer

  • Hero Member
  • *****
  • Posts: 956
Parallel BucketSort 1.0 is here.
« on: September 07, 2012, 03:18:27 am »

Hello,

Parallel BucketSort 1.0 is here.


Description:

Parallel BuckerSort.

Parallel BucketSort gave me 3x scaling when sorting strings on a quad cores,
it scales better than my parallel quicksort and it can be much faster than
my parallel quicksort.

I have thought about my parallel quicksort , and i have found that parallel
quicksort is
fine but the problem with it is that the partition function is not
parallelizable , so i have
tthought about this and i have decided to write a parallel BucketSort,and
this parallel
bucketsort can give you much better performance than parallel quicksort,
just test it yourself and see, parallel bucketsort can sort just strings at
the moment, and
it can use quicksort or mergesort.

And please look at test.pas a parallel bucketsort on many cores - compile
and execute it...

Language: FPC Pascal v2.2.0+ / Delphi 7+ or Lazarus:

http://www.freepascal.org/

Operating Systems: Win , Linux and Mac (x86).

You can download parallel bucketsort from:

http://pages.videotron.com/aminer/



Thank you,
Amine Moulay Ramdane,


aminer

  • Hero Member
  • *****
  • Posts: 956
Re: Parallel BucketSort 1.0 is here.
« Reply #1 on: September 07, 2012, 03:17:23 pm »


Hello,

Parallel BucketSort was updated to version 1.01, the interface
has changed a little bit.

Also note that bucketsort can have much better performance than
my parallel quicksort when you are  using 100000 strings or more.



You can download parallel bucketsort from:

http://pages.videotron.com/aminer/



Thank you,
Amine Moulay Ramdane,


aminer

  • Hero Member
  • *****
  • Posts: 956
Re: Parallel BucketSort 1.0 is here.
« Reply #2 on: September 07, 2012, 05:45:47 pm »


Hello,

Bucket sort is not a sorting algorithm itself, rather it is a
procedure for
partitioning data to be sorted using some given sorting algorithm—a
”meta-algorithm” so to speak.

Bucket sort will be better, when elements are uniformly distributed
over an interval [a, b]  and buckets have not significantly different
number of elements.

bucketsort sequential computational complexity using quicksort is
= p × (n/p) log(n/p) = n log(n/p)

bucket sort parallel computational complexity using quicksort
= (n/p) log(n/p)

I have updated parallel bucketsort to version 1.01 , i have
changed a little bit the interface.

You can download parallel bucketsort from:

http://pages.videotron.com/aminer/


Thank you,
Amine Moulay Ramdane.


aminer

  • Hero Member
  • *****
  • Posts: 956
Re: Parallel BucketSort 1.0 is here.
« Reply #3 on: September 10, 2012, 08:04:31 pm »

Hello,

I have updated parallel bucketsort to versin 1.02..


Now you can sort in both ascending and descending order,
and i have changed a little bit the interface , now 
if you want to sort in ascending order you have to call
the bucketsort method with ctAscending , and if you
want to sort in descending  order call it with ctDescending
like this

myobj.bucketsort(tab,comp,comp1,ctAscending);
// use ctAscending or CtDescending.



You can download parallel bucketsort from:

http://pages.videotron.com/aminer/




Thank you,
Amine Moulay Ramdane.
















mas steindorff

  • Hero Member
  • *****
  • Posts: 533
Re: Parallel BucketSort 1.0 is here.
« Reply #4 on: September 10, 2012, 08:33:42 pm »
Hi Amine,
does your example code work on strings already loaded in memory or can it work directly on a file?

windows 10 &11, Ubuntu 21+ IDE 3.2.2 general releases

aminer

  • Hero Member
  • *****
  • Posts: 956
Re: Parallel BucketSort 1.0 is here.
« Reply #5 on: September 12, 2012, 05:20:41 am »

mas steindorff wrote:
>Hi Amine,
>does your example code work on strings already loaded in memory >or can it work directly on a file?

Yes it works on strings already loaded in memory.


Thank you,
Amine Moulay Ramdane.


 

TinyPortal © 2005-2018