1. 1
Bitonic Sort
in
Shared SIMD Array Processor
Anukul Chandra Panda, Pankaj K Sa
{pandaa,pankajksa}@nitrkl.ac.in
Banshidhar Majhi
bmajhi@nitrkl.ac.in
Presented By :
Dilruk G.A. (148209B)
Jagoda S.D. (148214K)
2. Index …
Background of Sorting
SIMD Array Processor
Bitonic Sort Algorithm
Conclusion
2
3. Background of Sorting
Sorting of data is needed everywhere
• Data Structures, Joins in databases, Searching Algorithms
Simple algorithms required O(n2)
• Selection Sort, Insertion Sort, Bubble Sort
Even advanced algorithm take O(nLogn)
• Merge Sort, Heap Sort, Cube Sort
Parallel sorting solve the problem
• Bitonic Sort, Parallel Merge Sort
3
4. SIMD Array Processor
Special purpose
processor
• Ex: multi core, GPU
Single Instruction ,
Multiple Data
• One instruction work on multiple
data items simultaneously
4
Single Program Counter
Multiple Processing Elements (PEs)
5. Bitonic Sorting Algorithm
List A: (3, 4, 7, 8) monotonically increasing.
List B: (6, 5, 2, 1) monotonically decreasing.
List AB: (3, 4, 7, 8, 6, 5, 2, 1) Bitonic list.
Bitonic list is two monotonic lists concatenated
together, one increasing and one decreasing.
For n elements n/2 comparators are using.
Repeatedly build Bitonic lists and then sort them.
Just logn stages are required to sort the Bitonic list.
5
7. Time Complexity
In line 2 a shared memory access is needed.
Line 26 need one more operation to write
data back to the array.
Within nested loop 2 memory references are
multiplied
7