1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-04 02:51:31 -08:00
Commit graph

2837 commits

Author SHA1 Message Date
Gareth Rees
61d8887ff8 New platform lia6ll (linux, arm64, clang/llvm). 2021-06-03 21:58:04 +01:00
Gareth Rees
ca146d96d6 New platform xca6ll (macos, arm64, clang/llvm). 2021-06-03 21:58:04 +01:00
Richard Brooksby
951493b588 Merge pull request from ravenbrook/branch/2021-01-09/comma
Ensure that the MPS builds with "clang -Werror -Wcomma -std=c89"

GitHub-reference: https://github.com/Ravenbrook/mps/issues/48
2021-01-20 10:41:41 +00:00
Gareth Rees
5517e27d3a Apply suggestions from code review
Co-authored-by: Richard Brooksby <rb@ravenbrook.com>
2021-01-19 22:05:43 +00:00
Gareth Rees
0007fcbae7 Merge pull request from ravenbrook/branch/2020-09-27/mps-telemetry-control
Remove mps_telemetry_control, deprecated since release 1.111.0

GitHub-reference: https://github.com/Ravenbrook/mps/issues/42
2021-01-17 12:13:18 +00:00
Gareth Rees
452b023a8f Improve maintainability of complex loops.
1. Avoid looping over two expressions in parallel when one makes more
   sense (compilers can do strength reduction optimization: we don't
   need to do it ourselves).

2. Introduce macro ITER_PARALLEL for iterating over two expressions in
   parallel, to clarify the intention and explain the need for the
   cast to void in the implementation.

3. Add macros SAC_LARGE_ITER and SAC_SMALL_ITER to reduce the amount
   of code duplication in sac.c.
2021-01-16 17:06:07 +00:00
Gareth Rees
45376b0353 Ensure that the mps builds with "clang -werror -wcomma -std=c89".
The -Wcomma option appears to be turned on automatically by Xcode
12.3, so it's a good idea for the MPS to build with the option, to
avoid unpleasant surprises when people update their Xcode.

The simplest way to suppress the warning is to cast the left hand side
of the comma operator to void.
2021-01-16 17:06:06 +00:00
Richard Brooksby
0b9dfabcac Merge pull request from ravenbrook/branch/2021-01-10/implicit-conversion
Ensure that the MPS builds with Clang 10.

GitHub-reference: https://github.com/Ravenbrook/mps/issues/52
2021-01-16 16:16:40 +00:00
Gareth Rees
e6ef975298 Document the reason for enabling so many warnings.
Cross-reference the design from the implementation in the compiler
makefile fragments.
2021-01-10 21:26:58 +00:00
Gareth Rees
76bff163f5 Ensure that the mps builds with clang 10.
Clang 10 turns on -Wimplicit-int-float-conversion, and on 64-bit
platforms this issues a warning that implicit conversions to double
from Size and unsigned long "may lose precision".

This commit adds casts to (double) for all such conversions. The loss
of precision is either impossible in practice (because a double can
represent all integers up to 2**53, which is about 9 petabytes, well
beyond the addressing capabilities for current CPUs), or else
acceptable, because we are accumulating an approximate quantity like
"collection work" or "fill size" (that has to cope with loss of
precision due in any case), or computing a threshold like the spare
commit limit where it is acceptable for it to be somewhat approximate.
2021-01-10 10:42:05 +00:00
Gareth Rees
1f07197a31 Remove mps_telemetry_control, deprecated since release 1.111.0. 2020-09-29 11:15:45 +01:00
Gareth Rees
1e77b9d762 Remove mps_fix, deprecated since release 1.111.0
Also remove undocumented and deprecated MPS_FIX macro, and rename
TRACE_FIX to TRACE_FIX12 to maintain parallelism.
2020-09-27 14:16:39 +01:00
Gareth Rees
7c286cba8f Remove mps_alloc_v, deprecated since release 1.112.0. 2020-09-26 15:08:31 +01:00
Gareth Rees
ac0b724847 Remove reservoir functions, deprecated since release 1.115.0 2020-09-24 11:36:46 +01:00
Gareth Rees
93438da02d Remove mps_arena_expose, deprecated since release 1.111.0
Also remove mps_arena_unsafe_expose_remember_protection and
mps_arena_unsafe_expose_restore_protection.
2020-09-24 09:35:47 +01:00
Gareth Rees
302c8d0b19 Remove mps_tramp, deprecated since release 1.111.0. 2020-09-24 09:30:33 +01:00
Gareth Rees
5acb13ba24 Save and restore errno in signal handlers.
Ensure there are assertions on the results of all the libc functions
in protsgix.c and pthrdext.c.
2020-09-02 19:59:23 +01:00
Bruce Mitchener
c825216539 Fix typos. 2020-09-01 16:33:45 +01:00
Gareth Rees
5d966c76fd Spell out "analysis" in full. 2020-09-01 13:54:31 +01:00
Gareth Rees
5559f36540 Fix indentation of second clause of license. 2020-08-30 10:13:06 +01:00
Gareth Rees
5165d75267 Use https: instead of http: when linking to the ravenbrook web site. 2020-08-30 10:13:03 +01:00
Gareth Rees
e7d4356705 Merge branch 'branch/2020-08-24/eintr' 2020-08-30 09:24:08 +01:00
Gareth Rees
ae265371c1 Set sa_restart flag when calling sigaction().
This ensures that if a mutator thread is blocked in a system call when
the MPS handles a signal, the system call will not fail with EINTR but
instead will be restarted.

Add a test case for the thread suspend and resume signals.
2020-08-30 09:23:35 +01:00
Gareth Rees
7c650f8051 Merge branch 'branch/2020-08-23/macos-build' 2020-08-30 09:08:38 +01:00
Gareth Rees
86525a2b0a Traceid is a typedef for unsigned so we mustn't negate it.
This was not caught by testing because we don't support multiple
traces and so tr->id is always zero.
2020-08-29 18:56:46 +01:00
Gareth Rees
d8aed56eaa Fix build on macos 10.15 with clang 11.0.
We no longer need the -Wno-extended-offsetof or -Wno-invalid-offsetof
compiler options, since the nonstandard uses of offsetof() were
fixed (see job003619), so they can just be removed.
2020-08-23 16:17:36 +01:00
Peter Jackson
1d00afac81 Publish licence updates in code directory.
Publish minor changes to readme and configure files in main directory.
Main directory and code directory licence texts are now fully updated.

Copied from Perforce
 Change: 196994
2020-06-11 17:05:40 +01:00
Gareth Rees
b3052e79c6 Avoid warning from gcc 5.4.0.
Copied from Perforce
 Change: 196419
2019-10-10 15:18:03 +01:00
Gareth Rees
d161061c79 The makefile rule for building a generic target no longer depends on the content of extra_targets, since this is designed to be configurable.
Copied from Perforce
 Change: 196414
2019-10-10 14:37:38 +01:00
Gareth Rees
db58f314d1 Avoid an "extended" (non-standards-conforming) call to offsetof.
Copied from Perforce
 Change: 196195
2019-06-05 16:31:13 +01:00
Gareth Rees
2ed4e993f7 Remove -wno-extended-offsetof flag, no longer needed and not compatible with all the versions of clang that we need to support.
Copied from Perforce
 Change: 196189
2019-06-05 14:33:43 +01:00
Gareth Rees
1442df6958 Revert change 196178, submitted on wrong branch.
Copied from Perforce
 Change: 196185
2019-06-05 10:36:50 +01:00
Gareth Rees
88f046fff1 Call mps_arena_create_k, not mps_arena_create.
Copied from Perforce
 Change: 196181
2019-06-04 15:40:38 +01:00
Gareth Rees
b46461edb5 Restore assembly code (removed in change 194595) for spilling callee-save registers on fr and li platforms.
Copied from Perforce
 Change: 196178
2019-06-04 14:09:05 +01:00
Gareth Rees
93b1364fd2 Change the type of writeff to avoid compiler warnings from gcc 8.
Copied from Perforce
 Change: 196063
2019-03-14 15:17:47 +00:00
Gareth Rees
5f42b4b2b1 Simulate just one allocation failure each time.
Copied from Perforce
 Change: 195983
2019-02-07 11:57:16 +00:00
Gareth Rees
d1418dec5e Add a flag to fotest.c so that oomalloc knows when to return error codes, avoiding confusion between the test's pool and the mps's own pool.
Copied from Perforce
 Change: 195974
2019-02-07 10:21:32 +00:00
Gareth Rees
fd8eba1528 Update urls (mostly http -> https).
Copied from Perforce
 Change: 195858
2018-12-10 13:07:41 +00:00
Gareth Rees
0b324c158b Use tags with dots; regularize design references from code.
Copied from Perforce
 Change: 195761
2018-11-29 17:12:29 +00:00
Gareth Rees
cc9d3b9f7b Change http to https for links to {info,www}.ravenbrook.com.
Copied from Perforce
 Change: 195719
2018-11-22 12:34:46 +00:00
Richard Brooksby
920b7d1200 Improving clarity with some hyphens.
Copied from Perforce
 Change: 195688
2018-11-19 21:12:15 +00:00
Richard Brooksby
9e8f076716 Fixing copy-paste error in comment.
Copied from Perforce
 Change: 195683
2018-11-19 20:56:45 +00:00
Alistair Turnbull
eeb8b6aa9c To guarantee at least one failure while maintaining test coverage, use oomalloc on the
first loop iteration and with 50% probability thereafter.

Copied from Perforce
 Change: 195278
2018-10-17 17:12:14 +01:00
Alistair Turnbull
9e03b1db34 Implement review suggestions:
- https://info.ravenbrook.com/mail/2018/10/09/07-29-18/0/
 - https://info.ravenbrook.com/mail/2018/10/09/12-04-39/0/

Fix the code for shuffling an array.

Ensure that oomAlloc is always used at least once.

TODO: Find a principled way of computing `testSetSIZE`.

Copied from Perforce
 Change: 195272
2018-10-16 18:03:45 +01:00
Gareth Rees
fa3abac8df Improve handling of telemetry events on the critical path:
1. Being on the critical path is a property of the code location where the event is emitted, not of the event type, so indicate this using EVENT_CRITICAL macros rather than a field in the event table.
2. Compile out events on the critical path in hot varieties.
3. Remove TraceFixWhite event (redundant with TraceFixSeg).
4. No need for special handling of PoolFree event -- this are already skipped in hot varieties by dispatching directly to the pool class via PoolFreeMacro.

Copied from Perforce
 Change: 195261
2018-10-15 14:22:16 +01:00
Gareth Rees
6edddcbabb Fix mpseventsql, broken by change 195250.
Copied from Perforce
 Change: 195258
2018-10-15 11:55:51 +01:00
Gareth Rees
ae8f45704e Convenience target for building mpseventsql.
Copied from Perforce
 Change: 195251
2018-10-14 14:59:15 +01:00
Gareth Rees
af935e8479 Update mpseventsql to handle event parameter documentation.
Copied from Perforce
 Change: 195250
2018-10-14 14:59:01 +01:00
Gareth Rees
60bf7320e2 Document the event parameters.
Split event ArenaAccess into ArenaAccessBegin and ArenaAccessEnd to avoid the need for the count field.
New events SegReclaim and SegScan.
Delete some redundant events: AMCFinish (PoolFinish), AMCFix, AMCFixForward, AMCFixInPlace (TraceFix), AMCGenCreate (GenInit), AMCGenDestroy (GenFinish), AMCInit (PoolInitAMC), AMCReclaim (SegReclaim), AMCScanBegin, AMCScanEnd (SegScan), ArenaWriteFaults (ArenaAccessBegin), PoolInitMV, TraceScanSeg (SegScan).
Add result code field to events ArenaAllocFail, CommitLimitSet, SegAllocFail.
Remove arena field from events PoolInitAMS, PoolInitMFS, PoolInitMVFF (already appeared in generic PoolInit event).

Copied from Perforce
 Change: 195247
2018-10-14 14:04:40 +01:00
Gareth Rees
c0266874cf Merge branch/2018-06-20/monitor into the master sources.
Copied from Perforce
 Change: 195235
2018-10-13 12:22:24 +01:00