Mercurial > pub > dyncall > dyncall
annotate test/call_suite_aggrs/config.lua @ 492:29d09d10ecd9
- added unsigned types to call_suite_aggrs
author | Tassilo Philipp |
---|---|
date | Mon, 21 Mar 2022 10:04:10 +0100 |
parents | 0c68b3f91367 |
children | d45c582b5457 |
rev | line source |
---|---|
432
167faab0c0be
first usable version of test suite for aggregates, handling only non-nested struct params, at the moment;
Tassilo Philipp
parents:
diff
changeset
|
1 -- user config for rand-sig.lua: |
167faab0c0be
first usable version of test suite for aggregates, handling only non-nested struct params, at the moment;
Tassilo Philipp
parents:
diff
changeset
|
2 minargs = 0 |
434
3d2c5d156d78
- test/suite_aggrs: support for nested structs, now
Tassilo Philipp
parents:
432
diff
changeset
|
3 maxargs = 16 |
463
bd8f5da2c74b
suite_aggr: added configurable limits to number of struct fields (also simplified allowing (or not) empty ones)
Tassilo Philipp
parents:
462
diff
changeset
|
4 minaggrfields= 0 -- 0 allows for empty structs/unions |
bd8f5da2c74b
suite_aggr: added configurable limits to number of struct fields (also simplified allowing (or not) empty ones)
Tassilo Philipp
parents:
462
diff
changeset
|
5 maxaggrfields= 12 |
482
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
6 maxarraylen = 16 -- see 1) |
462 | 7 arraydice = 40 -- how often to turn a member into an array (1 out of arraydice-times) |
432
167faab0c0be
first usable version of test suite for aggregates, handling only non-nested struct params, at the moment;
Tassilo Philipp
parents:
diff
changeset
|
8 maxaggrdepth = 3 -- max nesting depth of aggregates, 1 = no nesting |
453
c497b87552f6
- reducing number of default pregenerated cases for suite_aggrs, as some compilers run out of memory otherwise
Tassilo Philipp
parents:
446
diff
changeset
|
9 ncases = 400 |
492 | 10 types = "csijlCSIJLpfd{}<>" -- {...} for structs, <...> for unions |
434
3d2c5d156d78
- test/suite_aggrs: support for nested structs, now
Tassilo Philipp
parents:
432
diff
changeset
|
11 seed = 2112 |
432
167faab0c0be
first usable version of test suite for aggregates, handling only non-nested struct params, at the moment;
Tassilo Philipp
parents:
diff
changeset
|
12 |
167faab0c0be
first usable version of test suite for aggregates, handling only non-nested struct params, at the moment;
Tassilo Philipp
parents:
diff
changeset
|
13 -- specify types more than once to increase relative occurance, e.g.: |
167faab0c0be
first usable version of test suite for aggregates, handling only non-nested struct params, at the moment;
Tassilo Philipp
parents:
diff
changeset
|
14 |
461 | 15 -- this favors non-aggregate args, especially ints (and also increases avg num of aggregate fields): |
432
167faab0c0be
first usable version of test suite for aggregates, handling only non-nested struct params, at the moment;
Tassilo Philipp
parents:
diff
changeset
|
16 --types = "ccssiiiiijjllpfd{}" |
167faab0c0be
first usable version of test suite for aggregates, handling only non-nested struct params, at the moment;
Tassilo Philipp
parents:
diff
changeset
|
17 |
461 | 18 -- this heavily favors nested structs, while not having any union: |
432
167faab0c0be
first usable version of test suite for aggregates, handling only non-nested struct params, at the moment;
Tassilo Philipp
parents:
diff
changeset
|
19 --types = "csijlpfd{{{{{{}" |
167faab0c0be
first usable version of test suite for aggregates, handling only non-nested struct params, at the moment;
Tassilo Philipp
parents:
diff
changeset
|
20 |
461 | 21 -- this heavily favors flat and short/empty aggregates: |
22 --types = "csijlpfd{}}}}}}<>>>>>" | |
482
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
23 |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
24 |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
25 -- 1) note some callconvs pass structs via regs, so using big numbers here will |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
26 -- reduce those cases; however special alignment rules are specified in some |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
27 -- ABIs for bigger arrays, which is also worth testing |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
28 |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
29 |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
30 -- user config for mk-cases.lua |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
31 |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
32 -- if true, aggregates are copied via = operator, otherwise field by field |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
33 aggrcpsimple = true |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
34 |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
35 -- if true, aggregate params are modified in called function, to test whether |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
36 -- they are passed "by value" (important for verifying by-value semantics for |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
37 -- callconvs where hidden pointers are used instead of real copies; aggregate |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
38 -- passing implementations must use of temporary copies in those cases) |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
39 aggrmutabletest = true |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
40 |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
41 -- force aggregate packing, 0=off, pos values set fixed packing, neg values |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
42 -- set a random power-of-2 packing per aggregate, within [1,abs(aggrpacking)] |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
43 aggrpacking = 0 |
0f3b6898078d
suite_aggrs (still ahead of checked in version of dyncall, sorry):
Tassilo Philipp
parents:
463
diff
changeset
|
44 |