mirror of
https://github.com/RfidResearchGroup/proxmark3.git
synced 2025-08-14 10:37:23 -07:00
CHG: Extracted @piwi's bucketsort into separate files under /common
This commit is contained in:
parent
e0b30228e9
commit
089d061f2d
7 changed files with 229 additions and 105 deletions
23
common/radixsort.h
Normal file
23
common/radixsort.h
Normal file
|
@ -0,0 +1,23 @@
|
|||
#ifndef RADIXSORT_H__
|
||||
#define RADIXSORT_H__
|
||||
|
||||
#include <string.h>
|
||||
#include <stdint.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
typedef union {
|
||||
struct {
|
||||
uint32_t c8[256];
|
||||
uint32_t c7[256];
|
||||
uint32_t c6[256];
|
||||
uint32_t c5[256];
|
||||
uint32_t c4[256];
|
||||
uint32_t c3[256];
|
||||
uint32_t c2[256];
|
||||
uint32_t c1[256];
|
||||
};
|
||||
uint32_t counts[256 * 8];
|
||||
} rscounts_t;
|
||||
|
||||
uint64_t * radixSort(uint64_t * array, uint32_t size);
|
||||
#endif // RADIXSORT_H__
|
Loading…
Add table
Add a link
Reference in a new issue