Commit Graph

283090 Commits

Author SHA1 Message Date
thorpej 3dfc7953fe malloc(9) -> kmem(9) 2020-11-21 18:23:36 +00:00
rillig cde2127e43 make(1): rename SuffAddSrc to SrcList_Add
The main character in this function is the list of sources, therefore
make it the subject.
2020-11-21 18:12:55 +00:00
rillig bd80e4d940 make(1): improve parameter name in SuffUpdateTarget 2020-11-21 18:09:13 +00:00
rillig 9bed54020b make(1): document necessary condition in SuffUpdateTarget 2020-11-21 18:06:09 +00:00
thorpej 098dc0bddb malloc(9) -> kmem(9) 2020-11-21 17:59:13 +00:00
thorpej 192b994748 malloc(9) -> kmem(9) 2020-11-21 17:48:26 +00:00
thorpej 2e11474e5b malloc(9) -> kmem(9)
XXX Audit use of KM_NOSLEEP here.
2020-11-21 17:46:08 +00:00
rillig 6652031933 make(1): limit memory usage in tests
There is a suspicious condition in SuffUpdateTarget code that looks wrong
on the first sight.  When removing it though, make allocates huge amounts
of memory.  To stop freezing the whole machine in this situation, limit
the total memory.

The limit of 200000 has been determined experimentally on NetBSD 8.0
x86_64.  With a limit of 100000, make wouldn't even start.  100 MB of
memory is really a lot for such a simple program that according to top(1)
only needs 8 MB.  But 200 MB is still better than 5 GB.

Since the Makefile is used on other platforms as well, via the bmake
distribution, and since every operating system has its own list of ulimit
options, make this configurable.
2020-11-21 17:44:40 +00:00
thorpej b8a5a3568f malloc(9) -> kmem(9) 2020-11-21 17:22:03 +00:00
rillig 65275b772e make(1): in SuffExpandChildren, only expand ${VAr} if needed 2020-11-21 17:18:36 +00:00
thorpej 61a804956d malloc(9) -> kmem(9) 2020-11-21 17:09:34 +00:00
thorpej d206c3458b malloc(9) -> kmem(9) 2020-11-21 15:52:32 +00:00
rillig 0eb2702f38 make(1): add test for dynamic variable with modifiers in global context 2020-11-21 15:48:05 +00:00
thorpej ad1425b7c2 malloc(9) -> kmem(9) 2020-11-21 15:36:36 +00:00
rillig 4fa84349d1 make(1): clean up freeing of environment variables in Var_Parse
The previous code with the extra boolean variable was a brain-twister
since the responsibility of freeing the memory was distributed over 3
different functions.
2020-11-21 15:32:52 +00:00
thorpej d62a896277 malloc(9) -> kmem(9) 2020-11-21 15:30:06 +00:00
rillig bfaeb69ca7 make(1): clean up parameter order in EvalUndefined 2020-11-21 15:28:44 +00:00
thorpej ec7360b952 malloc(9) -> kmem(9) 2020-11-21 15:26:53 +00:00
rillig 4834bcd8db make(1): rename local variable in Var_Subst 2020-11-21 15:02:52 +00:00
rillig ef5f627573 make(1): add test for .include with trailing garbage in the line 2020-11-21 14:59:11 +00:00
rillig 84c5f79d54 make(1): clean up reference counting in SuffList_Insert 2020-11-21 13:20:12 +00:00
rillig 82ab80ea5e make(1): move reference counting for suffixes to SrcNew 2020-11-21 13:16:37 +00:00
rillig f2299498cb make(1): clean up reference counting for suffixes 2020-11-21 13:11:13 +00:00
wiz ed388c6b2e Bump date for previous. 2020-11-21 12:26:41 +00:00
rillig bbdb624c98 make(1): add explanation for test suff-rebuild 2020-11-21 12:01:16 +00:00
rillig 416a199000 make(1): add more debug logging for suffix handling
One notable thing is that there is no debug output when adding a
transformation rule like ".c.o",  which means that these rules don't end
up in the global allTargets variable.

This may or may not be intentional.  It seems not intentional since this
is one of the causes for the suff-rebuild test to behave unexpectedly.
2020-11-21 11:59:22 +00:00
rillig c7d2d627f1 make(1): enable debug logging for test suff-rebuild
As long as it is not clear why this test fails, it's better to have the
debug log available, both for reading it and for getting notified if
any behavior in this area changes.
2020-11-21 11:55:57 +00:00
jmcneill d5776e5520 Add a per-CPU event counter that counts every time an interrupt handler is
preempted by a higher priority interrupt.
2020-11-21 11:43:59 +00:00
kim 3eea9a90f9 boot.cfg.5: Note that userconf can be used multiple times
Additionally:
- Make it easier for the reader to learn which keywords can be used
  multiple times
- Use multiple "userconf" lines in the EXAMPLES section, conveniently
  listing the current DRM drivers that a user might need to disable to
  troubleshoot "blank screen after boot" issues.
2020-11-21 11:41:54 +00:00
mlelstv 47f463a521 Fix previous and tag the right callout... 2020-11-21 11:26:55 +00:00
mlelstv 1352e383d0 Run callout without kernel lock, the softint itself is still protected. 2020-11-21 11:23:22 +00:00
rillig 91b9265a19 make(1): improve comment style in GNode_Free
It was unclear what the ellipsis referred to.  It was meant to refer to
the function call Lst_Free, but that was not necessarily obvious to a
casual reader.
2020-11-21 10:56:17 +00:00
rillig 6d886316ea make(1): fix indentation in Make_HandleUse 2020-11-21 10:51:26 +00:00
rillig ed1ae9b4ee make(1): fix comment for allTargets
Source nodes are also included in this list.  What's not includes is
nodes that are _only_ source nodes.
2020-11-21 10:50:39 +00:00
rillig 2c440fadec make(1): add more debug logging for suffixes
The "Removing suffix" is not covered by the current tests.  It would be
best if that code were unreachable at all, since a reference count of -1
doesn't make sense.
2020-11-21 10:36:01 +00:00
rillig 27b9e4c5e6 make(1): add test for incomplete transformation rule 2020-11-21 10:32:42 +00:00
rillig 8f33a92f2e make(1): add debug logging when adding a suffix to the global list 2020-11-21 09:53:40 +00:00
rillig 99a15640c4 make(1): rename local variable s to suff
The name s was ambiguous.  It could have meant suffix, src, str, and
probably more.
2020-11-21 09:51:00 +00:00
skrll 1f14513bf6 Trailing whitespace 2020-11-21 09:36:26 +00:00
rin f52e729971 roundsleep(): Too many zeros; tv_nsec should be compared with
500 msec, not 5000. Raised by clang for ILP32 archs.
2020-11-21 09:24:02 +00:00
rillig 6adf3573af make(1): make debug logging more precise in Suff_EndTransform 2020-11-21 09:19:46 +00:00
rillig 71013d7845 make(1): flatten Suff_EndTransform
This avoids the duplicate code for testing OP_TRANSFORM.
2020-11-21 09:16:44 +00:00
rillig 6950342b0d make(1): make output of test suff-rebuild more verbose 2020-11-21 08:51:57 +00:00
rillig dadca80717 make(1): rename SuffScanTargets to SuffUpdateTarget
The word "scan" no longer applies to this function since that is done by
SuffUpdateTargets instead.
2020-11-21 08:23:36 +00:00
mlelstv abde51a7a8 Restore missing message for RB_ASKNAME.
Cleanups.
2020-11-21 08:10:27 +00:00
rin d50adbc140 Fix build with clang for earmv7hf; loadroundkey() is used only for __aarch64__. 2020-11-21 08:09:21 +00:00
rillig c6c7de4990 make(1): clean up parameter names for SuffScanTargets
The prefix "gs" came from a time when SuffScanTargets was called via
Lst_ForEach, passing it a struct GNodeSuff.  The "gs" had just been the
abbreviation for "GNode + Suff", which was already non-expressive.  On
top of that, the struct had a third field "r", also with an unclear name,
which was not even mentioned in the name of the struct.

For now, just remove the needless prefix since it has absolutely no
meaning anymore.  Maybe it will become clear what the "r" was supposed to
mean, it could be some kind of "result".
2020-11-21 08:01:20 +00:00
thorpej fd5889cbee malloc(9) -> kmem(9) 2020-11-21 00:27:52 +00:00
rillig 91454f41a4 make(1): make string iterator in ParseDependencyTargetWord const 2020-11-20 20:01:16 +00:00
thorpej cf0030cb28 malloc(9) -> kmem(9) 2020-11-20 18:49:44 +00:00