1
0
forked from Alepha/Alepha
Commit Graph

37 Commits

Author SHA1 Message Date
00908187bd Function Composition helpers 2025-09-07 03:45:10 -04:00
3bd236b556 Add fast random facility.
This is a low-memory-overhead and low-cpu-overhead (per generated
bit) random number generator.  The repeat cycle is around 2**88.
Which means around 2**120 bits are available before a cycle.  Which
means that about 2**102 12-bit samples are available before repeats.

This should be more than sufficient for blob rollover purposes.
If 100 million blobs are split per second (absurdly high), then
that's about 2**27 per second.  If run for 30 years, that's
2**30 seconds.  If run across 128 CPUs, that's 2**7 CPUs.  Thus
2**(27+30+7) total samples are required before loop.  This is
2**64 which is WAAAY less than 2**88.  (And this is overly
conservative, as these generators should be one-per-thread...
so we're really much closer to 2**57, not that it matters.)

For this reason, there's no reseed code.  The cycle length of
mt11213b is significantly longer, however, it has a significantly
larger state.  One goal here is to keep the amount of state for
this generator to a single cache line.  As such, if the cycle
length is later shown to be significantly smaller than 2**48
or so, a reseed code path may need to be added.  (This is on
the assumption that the above described intensive run would
run for more than 1 million seconds, or about two weeks.)
2024-09-05 18:44:39 -04:00
d4dfe9f90f Major Enum type enhancements
`UnifiedEnum` -- union construction of enumerates

Access the enumerates as constexpr string array

Negation support for binary `Enum`
2024-08-12 16:50:14 -04:00
322bf65400 Invariant gadget. 2024-08-08 17:19:05 -04:00
308b64fc64 UnifiedEnum -- union construction of enumerates 2024-07-13 16:38:06 -04:00
6a89b18c11 Create C++26(?) emulation of template for
C++26 (I hope) is supposed to have this syntax:

```
template for( const auto &element: aggregate )
{
        ...;
}
```

Thus, I've adjusted this gadget to have a similar name, to enable
simple mechanical code changes.  From Alepha, you'd use it
thus:

```
template_for( aggregate ) <=[&]( const auto &element )
{
        ...;
};
```
2024-07-12 14:35:52 -04:00
6122f3ba80 UA 2024-07-08 17:06:31 -04:00
32e6c36570 Rename the template_for header.
C++26 (I hope) is supposed to have this syntax:

```
template for( const auto &element: aggregate )
{
	...;
}
```

Thus, I've adjusted this gadget to have a similar name, to enable
simple mechanical code changes.  From Alepha, you'd use it
thus:

```
template_for( aggregate ) <=[&]( const auto &element )
{
	...;
};
```
2024-07-05 11:59:26 -04:00
b5fb8c76f2 Create C++26(?) emulation of template for. 2024-07-05 11:54:19 -04:00
fa33154064 Add a template binding gadget for type lists. 2024-06-14 11:28:13 -04:00
94b0a1561b Relocate Blob, Buffer, and DataChain to Memory. 2024-05-20 18:18:04 -04:00
29575e7e30 Some cleanup and tests for Enum and constexpr strings. 2024-04-04 00:53:12 -04:00
66e8acfd5b List delimiting primitive for output streams. 2024-04-03 15:53:43 -04:00
60ed507e8d Capabilities clauses can now be repeated. 2024-01-27 05:12:43 -05:00
001de28231 String distance algorithms. 2023-11-17 01:22:30 -05:00
4426fc2857 Mailbox has been modernized. 2023-11-16 07:32:56 -05:00
b8d6c5aced Modernize thread code. 2023-11-14 16:57:02 -05:00
81a28bbf0d Merge branch 'master' of /Sources/Repositories/Alepha 2023-11-10 23:56:38 -05:00
868723ea57 Pthread might also be needed. 2023-11-10 23:56:28 -05:00
c78237e844 Get Blob and Buffer building and a bit tested 2023-11-10 23:29:20 -05:00
e2c5d28c5b Constness. 2023-11-10 23:25:12 -05:00
0728478f24 Assertion facility. 2023-11-10 23:23:38 -05:00
8f96c9e888 Rehabilitate the Thread type and test. 2023-11-08 04:33:09 -05:00
7097e6ae65 renames 2023-10-29 20:37:52 -04:00
80cf4138ed Start name unification for console. 2023-10-29 11:58:24 -04:00
89dd3cc81c Tuplize args testing.
The code bit-rotted a bit.  Some internals of Alepha
changed, this impl of tuplize args being imported from a
near-dead laptop.
2023-10-25 04:48:09 -04:00
08971abb06 Add IStreamable helper. 2023-10-22 04:43:25 -04:00
5beca91dde Lower the cmake required version 2023-10-21 02:03:37 -04:00
127dd6308f Merge branch 'sean-approved' 2023-10-20 04:50:32 -04:00
909fe49169 Backdate required cmake to 3.22
In this commit, I propose to backdate cmake to version 3.22, as that is
the currently-supported Ubuntu LTS version.
2023-10-20 04:50:23 -04:00
267e6b4b70 Stackable streambuf testing... 2023-10-20 03:17:57 -04:00
f0b514dccd Add tests for string algorithms. 2023-10-15 19:51:37 -04:00
a8433d13e3 More progress on the testing front. 2023-10-12 18:57:40 -04:00
7bafa453da More testing. 2023-10-12 18:36:37 -04:00
dd3f825ecd A lot of the tests are now in cmake.
I've also fixed a few things up so that the tests can be all run, more easily.
2023-10-12 18:29:16 -04:00
57b68ef8a4 A lot of progress towards unifying the build system. 2023-10-12 18:11:51 -04:00
fe5831f643 A simple cmake build system to start. 2023-10-12 14:55:13 -04:00