diff options
Diffstat (limited to 'test')
12 files changed, 34 insertions, 34 deletions
diff --git a/test/090_tables_readwrite/tables_readwrite_tests.c b/test/090_tables_readwrite/tables_readwrite_tests.c index 01c1172..3306dd6 100644 --- a/test/090_tables_readwrite/tables_readwrite_tests.c +++ b/test/090_tables_readwrite/tables_readwrite_tests.c | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | #include "../test.h" | 1 | #include "../test.h" |
| 2 | 2 | ||
| 3 | bool readtableinfo(uint64_t, const char *, tableinfo_t *); | 3 | bool readtableinfo(uint64_t, const unsigned char *, tableinfo_t *); |
| 4 | bool writetableinfo(const tableinfo_t *, uint64_t, char *); | 4 | bool writetableinfo(const tableinfo_t *, uint64_t, unsigned char *); |
| 5 | 5 | ||
| 6 | uint64_t readn(void) { | 6 | uint64_t readn(void) { |
| 7 | char str[STRLENMAX]; | 7 | char str[STRLENMAX]; |
| @@ -66,7 +66,7 @@ void test_writeinfo(tableinfo_t info) { | |||
| 66 | } | 66 | } |
| 67 | 67 | ||
| 68 | void run(void) { | 68 | void run(void) { |
| 69 | char buf[INFOSIZE]; | 69 | unsigned char buf[INFOSIZE]; |
| 70 | tableinfo_t expected, actual; | 70 | tableinfo_t expected, actual; |
| 71 | 71 | ||
| 72 | expected = test_readinfo(); | 72 | expected = test_readinfo(); |
diff --git a/test/100_gendata_cocsep/gendata_cocsep_tests.c b/test/100_gendata_cocsep/gendata_cocsep_tests.c index 91ebb52..46b9443 100644 --- a/test/100_gendata_cocsep/gendata_cocsep_tests.c +++ b/test/100_gendata_cocsep/gendata_cocsep_tests.c | |||
| @@ -2,11 +2,11 @@ | |||
| 2 | 2 | ||
| 3 | #define BUF_SIZE 2000000 | 3 | #define BUF_SIZE 2000000 |
| 4 | 4 | ||
| 5 | size_t gendata_cocsep(void *, uint64_t *, cube_t *); | 5 | size_t gendata_cocsep(unsigned char *, uint64_t *, cube_t *); |
| 6 | bool readtableinfo(uint64_t, const char *, tableinfo_t *); | 6 | bool readtableinfo(uint64_t, const unsigned char *, tableinfo_t *); |
| 7 | 7 | ||
| 8 | void run(void) { | 8 | void run(void) { |
| 9 | char buf[BUF_SIZE]; | 9 | unsigned char buf[BUF_SIZE]; |
| 10 | uint32_t i; | 10 | uint32_t i; |
| 11 | uint64_t selfsim[COCSEP_CLASSES]; | 11 | uint64_t selfsim[COCSEP_CLASSES]; |
| 12 | cube_t rep[COCSEP_CLASSES]; | 12 | cube_t rep[COCSEP_CLASSES]; |
diff --git a/test/101_cocsep_transform_invariant/cocsep_transform_invariant.c b/test/101_cocsep_transform_invariant/cocsep_transform_invariant.c index 853586a..b5a74b0 100644 --- a/test/101_cocsep_transform_invariant/cocsep_transform_invariant.c +++ b/test/101_cocsep_transform_invariant/cocsep_transform_invariant.c | |||
| @@ -1,12 +1,12 @@ | |||
| 1 | #include "../test.h" | 1 | #include "../test.h" |
| 2 | 2 | ||
| 3 | size_t gendata_cocsep(void *, uint64_t *, cube_t *); | 3 | size_t gendata_cocsep(unsigned char *, uint64_t *, cube_t *); |
| 4 | cube_t transform(cube_t, uint8_t); | 4 | cube_t transform(cube_t, uint8_t); |
| 5 | int64_t coord_cocsep(cube_t); | 5 | int64_t coord_cocsep(cube_t); |
| 6 | 6 | ||
| 7 | void run(void) { | 7 | void run(void) { |
| 8 | uint8_t t; | 8 | uint8_t t; |
| 9 | char buf[2000000]; | 9 | unsigned char buf[2000000]; |
| 10 | uint32_t *cocsepdata; | 10 | uint32_t *cocsepdata; |
| 11 | uint64_t selfsim[COCSEP_CLASSES]; | 11 | uint64_t selfsim[COCSEP_CLASSES]; |
| 12 | int64_t coord, tcoord; | 12 | int64_t coord, tcoord; |
diff --git a/test/102_cocsep_selfsim/cocsep_selfsim_tests.c b/test/102_cocsep_selfsim/cocsep_selfsim_tests.c index dd778aa..0ead3b4 100644 --- a/test/102_cocsep_selfsim/cocsep_selfsim_tests.c +++ b/test/102_cocsep_selfsim/cocsep_selfsim_tests.c | |||
| @@ -7,19 +7,19 @@ | |||
| 7 | */ | 7 | */ |
| 8 | #include "../test.h" | 8 | #include "../test.h" |
| 9 | 9 | ||
| 10 | size_t gendata_cocsep(void *, uint64_t *, cube_t *); | 10 | size_t gendata_cocsep(unsigned char *, uint64_t *, cube_t *); |
| 11 | int64_t coord_cocsep(cube_t); | 11 | int64_t coord_cocsep(cube_t); |
| 12 | 12 | ||
| 13 | void run(void) { | 13 | void run(void) { |
| 14 | char str[STRLENMAX]; | 14 | char str[STRLENMAX]; |
| 15 | char buf[2000000]; | 15 | unsigned char buf[2000000]; |
| 16 | uint32_t *cocsepdata, data; | 16 | uint32_t *cocsepdata, data; |
| 17 | int64_t coord, coclass; | 17 | int64_t coord, coclass; |
| 18 | uint64_t selfsim[COCSEP_CLASSES], sim, t; | 18 | uint64_t selfsim[COCSEP_CLASSES], sim, t; |
| 19 | cube_t cube, rep[COCSEP_CLASSES]; | 19 | cube_t cube, rep[COCSEP_CLASSES]; |
| 20 | 20 | ||
| 21 | gendata_cocsep(buf, selfsim, rep); | 21 | gendata_cocsep(buf, selfsim, rep); |
| 22 | cocsepdata = (uint32_t *)((char *)buf + INFOSIZE); | 22 | cocsepdata = (uint32_t *)(buf + INFOSIZE); |
| 23 | 23 | ||
| 24 | /* All cases in the same test so we do not generate data many times */ | 24 | /* All cases in the same test so we do not generate data many times */ |
| 25 | 25 | ||
diff --git a/test/103_cocsep_selfsim_distribution/cocsep_selfsim_distribution_tests.c b/test/103_cocsep_selfsim_distribution/cocsep_selfsim_distribution_tests.c index a907317..90208eb 100644 --- a/test/103_cocsep_selfsim_distribution/cocsep_selfsim_distribution_tests.c +++ b/test/103_cocsep_selfsim_distribution/cocsep_selfsim_distribution_tests.c | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | #include "../test.h" | 1 | #include "../test.h" |
| 2 | 2 | ||
| 3 | size_t gendata_cocsep(void *, uint64_t *, cube_t *); | 3 | size_t gendata_cocsep(unsigned char *, uint64_t *, cube_t *); |
| 4 | int64_t coord_cocsep(cube_t); | 4 | int64_t coord_cocsep(cube_t); |
| 5 | 5 | ||
| 6 | int bcount(uint64_t x) { | 6 | int bcount(uint64_t x) { |
| @@ -15,7 +15,7 @@ int bcount(uint64_t x) { | |||
| 15 | } | 15 | } |
| 16 | 16 | ||
| 17 | void run(void) { | 17 | void run(void) { |
| 18 | char buf[2000000]; | 18 | unsigned char buf[2000000]; |
| 19 | int size[65], tot, j; | 19 | int size[65], tot, j; |
| 20 | uint64_t i, selfsim[COCSEP_CLASSES], sim; | 20 | uint64_t i, selfsim[COCSEP_CLASSES], sim; |
| 21 | cube_t rep[COCSEP_CLASSES]; | 21 | cube_t rep[COCSEP_CLASSES]; |
diff --git a/test/104_cocsep_ttrep/cocsep_ttrep_tests.c b/test/104_cocsep_ttrep/cocsep_ttrep_tests.c index 0b853c3..87975a4 100644 --- a/test/104_cocsep_ttrep/cocsep_ttrep_tests.c +++ b/test/104_cocsep_ttrep/cocsep_ttrep_tests.c | |||
| @@ -3,11 +3,11 @@ | |||
| 3 | uint8_t inverse_trans(uint8_t); | 3 | uint8_t inverse_trans(uint8_t); |
| 4 | cube_t transform_corners(cube_t, uint8_t); | 4 | cube_t transform_corners(cube_t, uint8_t); |
| 5 | int64_t coord_cocsep(cube_t); | 5 | int64_t coord_cocsep(cube_t); |
| 6 | size_t gendata_cocsep(void *, uint64_t *, cube_t *); | 6 | size_t gendata_cocsep(unsigned char *, uint64_t *, cube_t *); |
| 7 | 7 | ||
| 8 | void run(void) { | 8 | void run(void) { |
| 9 | uint8_t t; | 9 | uint8_t t; |
| 10 | char buf[2000000]; | 10 | unsigned char buf[2000000]; |
| 11 | uint32_t *cocsepdata, tt; | 11 | uint32_t *cocsepdata, tt; |
| 12 | uint64_t i, selfsim[COCSEP_CLASSES]; | 12 | uint64_t i, selfsim[COCSEP_CLASSES]; |
| 13 | int64_t j, k, l; | 13 | int64_t j, k, l; |
diff --git a/test/105_gendata_eoesep/gendata_eoesep_tests.c b/test/105_gendata_eoesep/gendata_eoesep_tests.c index 62c36bc..0c22d7f 100644 --- a/test/105_gendata_eoesep/gendata_eoesep_tests.c +++ b/test/105_gendata_eoesep/gendata_eoesep_tests.c | |||
| @@ -23,10 +23,10 @@ The test does not generate the full table. For reference, these are the values: | |||
| 23 | #define ISIZE 512 | 23 | #define ISIZE 512 |
| 24 | #define FULLSIZE (ISIZE + (CL*1024) + (4*EMAX)) | 24 | #define FULLSIZE (ISIZE + (CL*1024) + (4*EMAX)) |
| 25 | 25 | ||
| 26 | char buf[FULLSIZE]; | 26 | unsigned char buf[FULLSIZE]; |
| 27 | 27 | ||
| 28 | size_t gendata_eoesep(char [static FULLSIZE], uint8_t); | 28 | size_t gendata_eoesep(unsigned char [static FULLSIZE], uint8_t); |
| 29 | bool readtableinfo(uint64_t, const char *, tableinfo_t *); | 29 | bool readtableinfo(uint64_t, const unsigned char *, tableinfo_t *); |
| 30 | 30 | ||
| 31 | void run(void) { | 31 | void run(void) { |
| 32 | uint32_t i; | 32 | uint32_t i; |
diff --git a/test/110_coord_invcoord_h48/coord_invcoord_h48_tests.c b/test/110_coord_invcoord_h48/coord_invcoord_h48_tests.c index 025ff2b..fdc4619 100644 --- a/test/110_coord_invcoord_h48/coord_invcoord_h48_tests.c +++ b/test/110_coord_invcoord_h48/coord_invcoord_h48_tests.c | |||
| @@ -1,6 +1,6 @@ | |||
| 1 | #include "../test.h" | 1 | #include "../test.h" |
| 2 | 2 | ||
| 3 | size_t gendata_cocsep(void *, uint64_t *, cube_t *); | 3 | size_t gendata_cocsep(unsigned char *, uint64_t *, cube_t *); |
| 4 | int64_t coord_h48(cube_t, const uint32_t *, uint8_t); | 4 | int64_t coord_h48(cube_t, const uint32_t *, uint8_t); |
| 5 | cube_t invcoord_h48(int64_t, const cube_t *, uint8_t); | 5 | cube_t invcoord_h48(int64_t, const cube_t *, uint8_t); |
| 6 | cube_t transform(cube_t, uint8_t); | 6 | cube_t transform(cube_t, uint8_t); |
| @@ -10,14 +10,14 @@ void run(void) { | |||
| 10 | int i; | 10 | int i; |
| 11 | bool found; | 11 | bool found; |
| 12 | uint8_t h, t; | 12 | uint8_t h, t; |
| 13 | char buf[2000000]; | 13 | unsigned char buf[2000000]; |
| 14 | uint32_t *cocsepdata; | 14 | uint32_t *cocsepdata; |
| 15 | uint64_t selfsim[COCSEP_CLASSES]; | 15 | uint64_t selfsim[COCSEP_CLASSES]; |
| 16 | int64_t c, cc; | 16 | int64_t c, cc; |
| 17 | cube_t cube, invc, rep[COCSEP_CLASSES]; | 17 | cube_t cube, invc, rep[COCSEP_CLASSES]; |
| 18 | 18 | ||
| 19 | gendata_cocsep(buf, selfsim, rep); | 19 | gendata_cocsep(buf, selfsim, rep); |
| 20 | cocsepdata = (uint32_t *)((char *)buf + INFOSIZE); | 20 | cocsepdata = (uint32_t *)(buf + INFOSIZE); |
| 21 | 21 | ||
| 22 | i = 1; | 22 | i = 1; |
| 23 | h = 11; | 23 | h = 11; |
diff --git a/test/112_gendata_h48short/gendata_h48short_tests.c b/test/112_gendata_h48short/gendata_h48short_tests.c index 2ed42c1..0de9408 100644 --- a/test/112_gendata_h48short/gendata_h48short_tests.c +++ b/test/112_gendata_h48short/gendata_h48short_tests.c | |||
| @@ -5,7 +5,7 @@ | |||
| 5 | void h48map_create(h48map_t [static 1], uint64_t, uint64_t); | 5 | void h48map_create(h48map_t [static 1], uint64_t, uint64_t); |
| 6 | void h48map_destroy(h48map_t [static 1]); | 6 | void h48map_destroy(h48map_t [static 1]); |
| 7 | kvpair_t h48map_nextkvpair(h48map_t [static 1], uint64_t [static 1]); | 7 | kvpair_t h48map_nextkvpair(h48map_t [static 1], uint64_t [static 1]); |
| 8 | size_t gendata_cocsep(void *, uint64_t *, cube_t *); | 8 | size_t gendata_cocsep(unsigned char *, uint64_t *, cube_t *); |
| 9 | uint64_t gendata_h48short(gendata_h48short_arg_t [static 1]); | 9 | uint64_t gendata_h48short(gendata_h48short_arg_t [static 1]); |
| 10 | 10 | ||
| 11 | char str[STRLENMAX]; | 11 | char str[STRLENMAX]; |
| @@ -25,7 +25,7 @@ uint64_t readl(void) { | |||
| 25 | } | 25 | } |
| 26 | 26 | ||
| 27 | void run(void) { | 27 | void run(void) { |
| 28 | char buf[2000000]; | 28 | unsigned char buf[2000000]; |
| 29 | h48map_t map; | 29 | h48map_t map; |
| 30 | uint64_t i, j, capacity, randomizer, selfsim[COCSEP_CLASSES]; | 30 | uint64_t i, j, capacity, randomizer, selfsim[COCSEP_CLASSES]; |
| 31 | kvpair_t kv, b[MAXPOS]; | 31 | kvpair_t kv, b[MAXPOS]; |
diff --git a/test/120_gendata_eo/gendata_eo_tests.c b/test/120_gendata_eo/gendata_eo_tests.c index 46a0606..08c495e 100644 --- a/test/120_gendata_eo/gendata_eo_tests.c +++ b/test/120_gendata_eo/gendata_eo_tests.c | |||
| @@ -15,10 +15,10 @@ Pruning table values (from nissy): | |||
| 15 | #define ISIZE 512 | 15 | #define ISIZE 512 |
| 16 | #define FULLSIZE (ISIZE + 1024) | 16 | #define FULLSIZE (ISIZE + 1024) |
| 17 | 17 | ||
| 18 | char buf[FULLSIZE]; | 18 | unsigned char buf[FULLSIZE]; |
| 19 | 19 | ||
| 20 | size_t gendata_coord_dispatch(const char *, void *); | 20 | size_t gendata_coord_dispatch(const char *, unsigned char *); |
| 21 | bool readtableinfo(uint64_t, const char *, tableinfo_t *); | 21 | bool readtableinfo(uint64_t, const unsigned char *, tableinfo_t *); |
| 22 | 22 | ||
| 23 | void run(void) { | 23 | void run(void) { |
| 24 | uint32_t i; | 24 | uint32_t i; |
diff --git a/test/121_coorddata_dr/coorddata_dr.c b/test/121_coorddata_dr/coorddata_dr.c index 707d605..9432b4c 100644 --- a/test/121_coorddata_dr/coorddata_dr.c +++ b/test/121_coorddata_dr/coorddata_dr.c | |||
| @@ -5,15 +5,15 @@ | |||
| 5 | #define TGROUP UINT64_C(4278190335) | 5 | #define TGROUP UINT64_C(4278190335) |
| 6 | 6 | ||
| 7 | cube_t transform(cube_t, uint8_t); | 7 | cube_t transform(cube_t, uint8_t); |
| 8 | uint64_t coordinate_dr_coord(cube_t, const void *); | 8 | uint64_t coordinate_dr_coord(cube_t, const unsigned char *); |
| 9 | cube_t coordinate_dr_cube(uint64_t, const void *); | 9 | cube_t coordinate_dr_cube(uint64_t, const unsigned char *); |
| 10 | uint64_t coordinate_dr_gendata(void *); | 10 | uint64_t coordinate_dr_gendata(unsigned char *); |
| 11 | 11 | ||
| 12 | void run(void) { | 12 | void run(void) { |
| 13 | bool found; | 13 | bool found; |
| 14 | uint64_t t; | 14 | uint64_t t; |
| 15 | char str[STRLENMAX]; | 15 | char str[STRLENMAX]; |
| 16 | void *data; | 16 | unsigned char *data; |
| 17 | size_t size; | 17 | size_t size; |
| 18 | cube_t cube; | 18 | cube_t cube; |
| 19 | uint64_t coord, coord2; | 19 | uint64_t coord, coord2; |
diff --git a/test/122_coorddata_dreo/coorddata_dreo.c b/test/122_coorddata_dreo/coorddata_dreo.c index 0c75c5e..5c1e796 100644 --- a/test/122_coorddata_dreo/coorddata_dreo.c +++ b/test/122_coorddata_dreo/coorddata_dreo.c | |||
| @@ -5,15 +5,15 @@ | |||
| 5 | #define TGROUP UINT64_C(4278190335) | 5 | #define TGROUP UINT64_C(4278190335) |
| 6 | 6 | ||
| 7 | cube_t transform(cube_t, uint8_t); | 7 | cube_t transform(cube_t, uint8_t); |
| 8 | uint64_t coordinate_dreo_coord(cube_t, const void *); | 8 | uint64_t coordinate_dreo_coord(cube_t, const unsigned char *); |
| 9 | cube_t coordinate_dreo_cube(uint64_t, const void *); | 9 | cube_t coordinate_dreo_cube(uint64_t, const unsigned char *); |
| 10 | uint64_t coordinate_dreo_gendata(void *); | 10 | uint64_t coordinate_dreo_gendata(unsigned char *); |
| 11 | 11 | ||
| 12 | void run(void) { | 12 | void run(void) { |
| 13 | bool found; | 13 | bool found; |
| 14 | uint64_t t; | 14 | uint64_t t; |
| 15 | char str[STRLENMAX]; | 15 | char str[STRLENMAX]; |
| 16 | void *data; | 16 | unsigned char *data; |
| 17 | size_t size; | 17 | size_t size; |
| 18 | cube_t cube; | 18 | cube_t cube; |
| 19 | uint64_t coord, coord2; | 19 | uint64_t coord, coord2; |
