mirror of
https://github.com/AFLplusplus/AFLplusplus.git
synced 2025-06-12 18:18:07 +00:00
Merge branch 'dev' of https://github.com/AFLplusplus/AFLplusplus into dev
This commit is contained in:
@ -103,19 +103,29 @@ static u32 map_size = MAP_SIZE;
|
|||||||
/* Classify tuple counts. This is a slow & naive version, but good enough here.
|
/* Classify tuple counts. This is a slow & naive version, but good enough here.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#define TIMES4(x) x,x,x,x
|
||||||
|
#define TIMES8(x) TIMES4(x),TIMES4(x)
|
||||||
|
#define TIMES16(x) TIMES8(x),TIMES8(x)
|
||||||
|
#define TIMES32(x) TIMES16(x),TIMES16(x)
|
||||||
|
#define TIMES64(x) TIMES32(x),TIMES32(x)
|
||||||
static u8 count_class_lookup[256] = {
|
static u8 count_class_lookup[256] = {
|
||||||
|
|
||||||
[0] = 0,
|
[0] = 0,
|
||||||
[1] = 1,
|
[1] = 1,
|
||||||
[2] = 2,
|
[2] = 2,
|
||||||
[3] = 4,
|
[3] = 4,
|
||||||
[4 ... 7] = 8,
|
[4] = TIMES4(8),
|
||||||
[8 ... 15] = 16,
|
[8] = TIMES8(16),
|
||||||
[16 ... 31] = 32,
|
[16] = TIMES16(32),
|
||||||
[32 ... 127] = 64,
|
[32] = TIMES32(64),
|
||||||
[128 ... 255] = 128
|
[128] = TIMES64(128)
|
||||||
|
|
||||||
};
|
};
|
||||||
|
#undef TIMES64
|
||||||
|
#undef TIMES32
|
||||||
|
#undef TIMES16
|
||||||
|
#undef TIMES8
|
||||||
|
#undef TIMES4
|
||||||
|
|
||||||
static void classify_counts(u8 *mem) {
|
static void classify_counts(u8 *mem) {
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user