source:
branches/v4/platforms/caba-ring-ccxcachev4_memcachev4-mips32el/soft/sort/sort.c
Last change on this file was 134, checked in by , 13 years ago | |
---|---|
File size: 446 bytes |
Line | |
---|---|
1 | #include "sort.h" |
2 | #include "system.h" |
3 | #include "stdio.h" |
4 | |
5 | //-------------------------------------*/ |
6 | void sort(unsigned int *base, unsigned int n, sort_t type) |
7 | { |
8 | switch(type) |
9 | { |
10 | case SORT_SHELL: |
11 | sort_shell(base, n); |
12 | break; |
13 | case SORT_SELECTION: |
14 | sort_selection(base, n); |
15 | break; |
16 | case SORT_INSERTION: |
17 | sort_insertion(base, n); |
18 | break; |
19 | case SORT_BUBBLE: |
20 | sort_bubble(base, n); |
21 | break; |
22 | default: |
23 | break; |
24 | } |
25 | } |
Note: See TracBrowser
for help on using the repository browser.