1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-26 23:31:55 -08:00
Commit graph

100 commits

Author SHA1 Message Date
Richard Brooksby
d1dd0c9105 Updating conerr/4 to know the correct number of pools, now that the reservoir is gone.
Copied from Perforce
 Change: 190010
 ServerID: perforce.ravenbrook.com
2016-03-13 21:49:23 +00:00
Gareth Rees
56778dd360 Avoid unused variable warnings.
Copied from Perforce
 Change: 189978
 ServerID: perforce.ravenbrook.com
2016-03-13 14:58:09 +00:00
Gareth Rees
dfa7354873 Avoid warnings when compiling argerr/{146,147,148}.c with gcc.
Test cases conerr/{53,54}.c rely on junk in uninitialized local variables, so ensure that there is some.
Test case function/72.c relies on an object moving, but it might be pinned by an ambiguous reference from the stack, so don't register the stack as a root.

Copied from Perforce
 Change: 189964
 ServerID: perforce.ravenbrook.com
2016-03-13 14:16:39 +00:00
Gareth Rees
e976a17eb8 Regular testing of mmqa: "make test-make-build" at top level now runs mmqa, hence so does "make test" on linux and freebsd. the whole test suite, including testci, testmmqa, testansi, and testpollnone, takes 26 minutes on my laptop.
MMQA "run" and "runset" commands now exit with non-zero status if any of the tests failed, so that test failures can be identifed by the calling program (for example, make).
Add missing license to files that state "See end of file for license."

Copied from Perforce
 Change: 189957
 ServerID: perforce.ravenbrook.com
2016-03-13 12:57:02 +00:00
Gareth Rees
89a83ac39e A few more mmqa speedups.
Copied from Perforce
 Change: 189948
 ServerID: perforce.ravenbrook.com
2016-03-13 11:42:53 +00:00
Gareth Rees
c2e71054c9 Speed up more mmqa test cases. on my laptop, the whole mmqa test suite (or at least the passing subset) now takes 5 minutes in the hot variety and 11 minutes in the cool variety.
Copied from Perforce
 Change: 189947
 ServerID: perforce.ravenbrook.com
2016-03-13 11:42:32 +00:00
Gareth Rees
d8c8e00f3e Speed up mmqa test cases by reducing iterations. additionally:
* Take test options as parameters=.
* Rename BLAH to VERBOSE.
* Clearer reporting of slotHigh, arenaHigh, firstFit options to MVFF.
* Report times in seconds (not centiseconds).
* Reduce the commit limit exponentially and stop when too small.
* Ramp entering/leaving probabilities are scaled by iterations.

Copied from Perforce
 Change: 189899
 ServerID: perforce.ravenbrook.com
2016-03-12 18:27:38 +00:00
Gareth Rees
9ffa6f2740 Add instructions for testing the hot variety.
Copied from Perforce
 Change: 189720
 ServerID: perforce.ravenbrook.com
2016-03-07 19:58:52 +00:00
Gareth Rees
d1973da5f3 Avoid unusued variable warnings from clang 3.4.1.
Copied from Perforce
 Change: 189717
 ServerID: perforce.ravenbrook.com
2016-03-07 18:47:27 +00:00
Gareth Rees
8afda3c709 Move blatting to a function so that its local variables don't remain on the stack and pin down objects.
Copied from Perforce
 Change: 189714
 ServerID: perforce.ravenbrook.com
2016-03-07 17:31:55 +00:00
Gareth Rees
df50cf79ce Some mmqa tests only work in the cool variety. segregate these into the "coolonly" testset.
Copied from Perforce
 Change: 189711
 ServerID: perforce.ravenbrook.com
2016-03-07 17:18:21 +00:00
Gareth Rees
9a7475e4e8 Change 189541 renamed the reg_scan_p parameter to mps_root_create_reg; update test cases accordingly.
Copied from Perforce
 Change: 189673
 ServerID: perforce.ravenbrook.com
2016-03-06 14:07:45 +00:00
Richard Brooksby
080d135eec Catch up merge from master sources.
Copied from Perforce
 Change: 189088
 ServerID: perforce.ravenbrook.com
2016-02-03 16:56:04 +00:00
Richard Brooksby
d4e54ba17e Backing out the introduction of mps_arena_configure. see <https://info.ravenbrook.com/mail/2016/01/15/11-56-45/0>.
Copied from Perforce
 Change: 189081
 ServerID: perforce.ravenbrook.com
2016-02-03 15:52:05 +00:00
Richard Brooksby
5dccd2e006 Catch-up merge from masters.
Copied from Perforce
 Change: 188928
 ServerID: perforce.ravenbrook.com
2016-01-20 11:04:09 +00:00
Gareth Rees
537af4b0dc Rename mps_key_arena_commit_limit and mps_key_arena_spare_commit_limit as mps_key_commit_limit and mps_key_spare_commit_limit respectively, as suggested by nb in review.
Copied from Perforce
 Change: 188286
 ServerID: perforce.ravenbrook.com
2015-09-08 16:21:27 +01:00
Gareth Rees
c2d2eacdb2 Catch-up merge from master sources to branch/2015-08-06/config.
Copied from Perforce
 Change: 188146
 ServerID: perforce.ravenbrook.com
2015-08-14 16:35:07 +01:00
Gareth Rees
365acce878 Merge branch/2015-08-10/arena-create into the master sources.
Copied from Perforce
 Change: 188144
 ServerID: perforce.ravenbrook.com
2015-08-14 10:57:06 +01:00
Gareth Rees
510c074051 Make -b ensures that mps.o gets rebuilt.
Copied from Perforce
 Change: 188132
 ServerID: perforce.ravenbrook.com
2015-08-11 12:01:53 +01:00
Gareth Rees
e84a0670d7 Test case function/228.c is passing.
Copied from Perforce
 Change: 188123
 ServerID: perforce.ravenbrook.com
2015-08-11 08:35:53 +01:00
Gareth Rees
7dee7f10ea New test case 231: create/configure arena with too-small commit limit.
Copied from Perforce
 Change: 188118
 ServerID: perforce.ravenbrook.com
2015-08-10 20:29:21 +01:00
Gareth Rees
8d2ed22908 Apply commit limit (and spare commit limit) during arena creation, to avoid exceeding the limit and then discovering that we've done so.
Add test case for arena hitting commit limit during creation.

Copied from Perforce
 Change: 188106
 ServerID: perforce.ravenbrook.com
2015-08-10 15:27:26 +01:00
Gareth Rees
511ec1c025 Catch-up merge from branch/2015-08-10/arena-create to branch/2015-08-06/config.
Copied from Perforce
 Change: 188104
 ServerID: perforce.ravenbrook.com
2015-08-10 12:49:36 +01:00
Gareth Rees
afb5ff33c1 Correct the test for too-small client arena sizes.
Add automated test case for client arenas with small sizes.

Copied from Perforce
 Change: 188099
 ServerID: perforce.ravenbrook.com
2015-08-10 11:41:58 +01:00
Gareth Rees
703c1ee5f5 New function mps_arena_configure provides keyword argument interface to changing the properties of an arena.
New keyword arguments MPS_KEY_ARENA_COMMIT_LIMIT and MPS_KEY_SPARE_ARENA_COMMIT_LIMIT can be passed to mps_arena_create_k or mps_arena_configure.
Deprecate mps_arena_commit_limit_set and mps_arena_spare_commit_limit_set.

Copied from Perforce
 Change: 188085
 ServerID: perforce.ravenbrook.com
2015-08-06 17:02:51 +01:00
Gareth Rees
1f95ffbe53 Tweak order of operations so that stack temporary doesn't keep many objects alive.
Copied from Perforce
 Change: 187953
 ServerID: perforce.ravenbrook.com
2015-06-16 10:44:09 +01:00
Gareth Rees
5960e2fd77 Testsets/conerr now passes.
Copied from Perforce
 Change: 187950
 ServerID: perforce.ravenbrook.com
2015-06-15 22:59:14 +01:00
Gareth Rees
e512989019 Argerr testset now passes.
Copied from Perforce
 Change: 187948
 ServerID: perforce.ravenbrook.com
2015-06-15 22:21:52 +01:00
Gareth Rees
24c0e9500f Arguments to the varargs function mps_pool_create must be cast, otherwise the default c promotion rules will result in a constant value lke 64 being protomoted to int (4 bytes) but decoded (wrongly) as size_t (8 bytes).
Copied from Perforce
 Change: 187943
 ServerID: perforce.ravenbrook.com
2015-06-15 19:34:45 +01:00
Gareth Rees
25d29beacb 100 pools are not enough to exceed the commit limit; try 1000 instead.
Copied from Perforce
 Change: 187941
 ServerID: perforce.ravenbrook.com
2015-06-15 18:26:36 +01:00
Gareth Rees
baae574206 Use chomp instead of chop for lines read in from file handles: the last line read from a file does not necessarily have a newline.
Copied from Perforce
 Change: 187937
 ServerID: perforce.ravenbrook.com
2015-06-15 17:20:04 +01:00
Gareth Rees
c96e19b7c8 Change file type to ktext so that qa reports the correct test name.
Copied from Perforce
 Change: 187936
 ServerID: perforce.ravenbrook.com
2015-06-15 17:05:39 +01:00
Gareth Rees
a7c1993c43 Minor documentation improvements.
Copied from Perforce
 Change: 187407
 ServerID: perforce.ravenbrook.com
2014-10-26 12:44:58 +00:00
Gareth Rees
9926492d9a Add a section to the guide explaining how to implement malloc and free.
Copied from Perforce
 Change: 187399
 ServerID: perforce.ravenbrook.com
2014-10-25 22:31:07 +01:00
Gareth Rees
eced8cbdad Mmqa test function/227.c now passes.
Update test README to mention which function to breakpoint.

Copied from Perforce
 Change: 187397
 ServerID: perforce.ravenbrook.com
2014-10-25 20:03:44 +01:00
Gareth Rees
d4b8907389 Assert if you try to create a pool using a format from another arena, a pool using a chain from another arena, or a root using a thread from another arena.
Copied from Perforce
 Change: 187268
 ServerID: perforce.ravenbrook.com
2014-10-14 22:21:43 +01:00
Gareth Rees
7db46bbb3f Check alignment of address given to poolfree.
Copied from Perforce
 Change: 187265
 ServerID: perforce.ravenbrook.com
2014-10-14 16:54:10 +01:00
Gareth Rees
c89ce2ba0b Get the mmqa conerr tests working:
* Make sure all the test build and run.
* Add output specifications to the passing tests.
* New testset/conerr runs them all.

Copied from Perforce
 Change: 187248
 ServerID: perforce.ravenbrook.com
2014-10-13 21:34:12 +01:00
Gareth Rees
4a13898542 Move <stdlib.h> from testlib.c to testlib.h, for the benefit of test cases that need to use malloc.
Copied from Perforce
 Change: 187247
 ServerID: perforce.ravenbrook.com
2014-10-13 21:33:42 +01:00
Gareth Rees
6367f5c299 Get the mmqa argerr tests working:
* Make sure all the test build and run.
* Add output specifications to the passing tests.
* New testset/argerr runs them all.

Copied from Perforce
 Change: 187245
 ServerID: perforce.ravenbrook.com
2014-10-13 18:35:11 +01:00
Gareth Rees
47110d4316 Mmqa test harness improvements:
* Don't compile for profiling (not needed at the moment)
* Compile with -Wno-unused -Wno-missing-prototypes on OS X (so that argerr/146.c and similar test cases will build).
* Output conclusion for the first failing result (in alphabetical order), rather than whatever comes out of the hash table first.
* Don't gather symbols from block comments, otherwise we can't specify results like "assertcond = mps_pool_o != NULL" as MMQA will think that mps_pool_o is a missing symbol.

Copied from Perforce
 Change: 187244
 ServerID: perforce.ravenbrook.com
2014-10-13 18:33:37 +01:00
Gareth Rees
42633ca624 Turn off the spare memory on the mvff pool so that it returns freed memory to the arena immediately.
Free the initial allocations so that the result determination is accurate.

Copied from Perforce
 Change: 187206
 ServerID: perforce.ravenbrook.com
2014-10-11 00:57:28 +01:00
Gareth Rees
34c8efce22 Specifying assertcond rather than assertline is likely to be more robust against code changes.
Copied from Perforce
 Change: 187203
 ServerID: perforce.ravenbrook.com
2014-10-10 22:55:48 +01:00
Gareth Rees
18a618cfe1 Need to take spare committed memory into account when checking that memory usage hasn't gone up after a collection.
Copied from Perforce
 Change: 187202
 ServerID: perforce.ravenbrook.com
2014-10-10 22:43:07 +01:00
Gareth Rees
f49ea829b9 In function/45.c, read from ambig[i] to prevent the compiler from optimizing away the array and so allowing p[i] to die.
In function/12.c, add a garbage collection to check that the allocation point protocol is being followed. Ensure there's an ambiguous reference to reserved objects before committin them.

Copied from Perforce
 Change: 187200
 ServerID: perforce.ravenbrook.com
2014-10-10 22:14:22 +01:00
Gareth Rees
28ceede8dc Job003495 is fixed, so mmqa test function/171.c now passes.
Reduce workload in function/171.c by a factor of 10 so that it completes in a reasonable amount of time.

Copied from Perforce
 Change: 187194
 ServerID: perforce.ravenbrook.com
2014-10-10 17:35:59 +01:00
Gareth Rees
92fceb127f Job003739 is fixed, so mmqa test function/51.c passes.
Copied from Perforce
 Change: 187192
 ServerID: perforce.ravenbrook.com
2014-10-10 17:21:36 +01:00
Gareth Rees
faf6789c71 Cast arguments to the correct type to avoid them being decoded incorrectly by the varargs interface.
Copied from Perforce
 Change: 187190
 ServerID: perforce.ravenbrook.com
2014-10-10 17:14:09 +01:00
Gareth Rees
712b443baf Make mmqa test suite compile and run on linux (specifically lii6ll).
Avoid compiler warnings about unused variables and bad casts.

Copied from Perforce
 Change: 187188
 ServerID: perforce.ravenbrook.com
2014-10-10 16:58:01 +01:00
Gareth Rees
f24a66c722 It's better to run from test directory -- otherwise testsets will have to be rewritten.
Copied from Perforce
 Change: 187187
 ServerID: perforce.ravenbrook.com
2014-10-10 16:56:34 +01:00