Skip to content

Commit

Permalink
2.17b
Browse files Browse the repository at this point in the history
  • Loading branch information
thomas-huet committed Jul 24, 2016
1 parent b40be2f commit 8d579f2
Show file tree
Hide file tree
Showing 9 changed files with 223 additions and 189 deletions.
22 changes: 9 additions & 13 deletions afl-analyze.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,21 +89,17 @@ static volatile u8

/* Classify tuple counts. This is a slow & naive version, but good enough here. */

#define AREP4(_sym) (_sym), (_sym), (_sym), (_sym)
#define AREP8(_sym) AREP4(_sym), AREP4(_sym)
#define AREP16(_sym) AREP8(_sym), AREP8(_sym)
#define AREP32(_sym) AREP16(_sym), AREP16(_sym)
#define AREP64(_sym) AREP32(_sym), AREP32(_sym)
#define AREP128(_sym) AREP64(_sym), AREP64(_sym)

static u8 count_class_lookup[256] = {

/* 0 - 3: 4 */ 0, 1, 2, 4,
/* 4 - 7: +4 */ AREP4(8),
/* 8 - 15: +8 */ AREP8(16),
/* 16 - 31: +16 */ AREP16(32),
/* 32 - 127: +96 */ AREP64(64), AREP32(64),
/* 128+: +128 */ AREP128(128)
[0] = 0,
[1] = 1,
[2] = 2,
[3] = 4,
[4 ... 7] = 8,
[8 ... 15] = 16,
[16 ... 31] = 32,
[32 ... 127] = 64,
[128 ... 255] = 128

};

Expand Down
Loading

0 comments on commit 8d579f2

Please sign in to comment.