Am Mo., 2. Sept. 2024 um 13:58 Uhr schrieb Bruno Haible :
> I did:
> > vma-prot: Add tests.
> > * tests/test-vma-prot.c: New file.
> > * modules/vma-prot-tests: New file.
>
> Oops, I forgot some parentheses. (I will never understand why the '&' and
> '|'
> operators, which are mo
Am Do., 29. Aug. 2024 um 11:36 Uhr schrieb Bruno Haible :
> Hi Marc,
>
> > +#ifndef MINI_GMP_LIMB_TYPE
> > +/* Verify that the gmp.h header file was generated for the same
> > + machine word size as we are using. */
> > +static_assert (GMP_NUMB_BITS == sizeof (mp_limb_t) * CHAR_BIT);
> > +#endi
Am Do., 29. Aug. 2024 um 11:31 Uhr schrieb Bruno Haible :
> Hi Marc,
>
> this looks good, except for two small things:
>
> 1) In the ChangeLog entry
>
> > + * lib/mini-mpq.c: New upstream source file.
> > + * lib/mini-mpq.h: New upstream source file.
>
> I would like to see more precision
Am Do., 29. Aug. 2024 um 10:27 Uhr schrieb Bruno Haible :
> Marc Nieper-Wißkirchen wrote:
> > Shouldn't get the new module libgmp-mpz an entry in MODULES.html.sh?
>
> Yes, feel free to add it. I tend to update this file only occasionally.
>
I followed your suggestio
Am Mi., 28. Aug. 2024 um 14:21 Uhr schrieb Bruno Haible :
[...]
> Let me start with the renamings of what is already in gnulib. Then,
> your additions are welcome (as two patches, please: one for the
> new code in module libgmp, and one for the new tests).
>
>
> 2024-08-28 Bruno Haible
>
>
PS Here is a suggestion for a new `mpq' module. What do you think?
Am Mi., 28. Aug. 2024 um 08:41 Uhr schrieb Marc Nieper-Wißkirchen <
marc.nieper+...@gmail.com>:
> Hi,
>
> This is a request to integrate the missing parts of the mini-gmp library
> into Gnulib. To be mor
Hi,
This is a request to integrate the missing parts of the mini-gmp library
into Gnulib. To be more specific, mini-mpq is currently missing in Gnulib;
see [1].
Thanks,
Marc
--
[1] https://gmplib.org/repo/gmp/file/tip/mini-gmp
Am Do., 22. Aug. 2024 um 07:27 Uhr schrieb Paul Eggert :
> On 2024-08-21 06:36, Bruno Haible wrote:
> > In summary, this paragraph makes no sense for structs.
>
> Hmm, well, the paragraph makes sense to me. I suppose somebody could
> fire off a question to the C committee about the intent of the p
Hi Bruno,
Am Mo., 26. Aug. 2024 um 12:37 Uhr schrieb Bruno Haible :
> Hi Marc,
>
> > Gnulib
> > offers strtod replacements, but these refer to conversion routines of the
> > host systems and may lack the accuracy described in Clinger's well-known
> > paper [1] IIUC.
> >
> > Wouldn't it make sense
Gnulib contains modules like dtoastr that accurately convert floating point
numbers to strings. For the opposite direction of conversion, Gnulib
offers strtod replacements, but these refer to conversion routines of the
host systems and may lack the accuracy described in Clinger's well-known
paper
Am Sa., 17. Aug. 2024 um 15:00 Uhr schrieb Bruno Haible :
> Marc Nieper-Wißkirchen wrote:
> > > This is fixed now.
> > >
> >
> > What about the shell-based gnulib tool? Or should I consider that one
> > deprecated?
>
> Yes. The shell-based impl
Hi!
Bruno Haible schrieb am Sa., 17. Aug. 2024, 11:14:
> Hi Simon,
>
> > Ouch. Shouldn't we rename 'valgrind-tests' instead?
> > ...
> > Whatever problem appears if we rename
> > 'valgrind-tests' to, say, 'valgrindtests' we could fix.
>
> 'valgrindtests' would be a hack.
>
> 'valgrind-support-f
Am Fr., 16. Aug. 2024 um 20:51 Uhr schrieb Collin Funk <
collin.fu...@gmail.com>:
> Hi Marc,
>
> Marc Nieper-Wißkirchen writes:
>
> > ./gitsub.sh upgrade
> >
> > fails when submodules are present where the master branch is not called
> > "master&
ts in liboath/ and libpskc/ of oath-toolkit.
>
Thank you for the patch. I can confirm that the problem has been fixed
when using GNULIB_TOOL_IMPL=py and is still present when using
GNULIB_TOOL_IMPL=sh.
Best wishes,
Marc
> 2024-08-16 Bruno Haible
>
> gnulib-t
Hi!
Running
./gitsub.sh upgrade
fails when submodules are present where the master branch is not called
"master" but something else, e.g. "main", which becomes increasingly common.
The branch name "origin/master" is currently hardcoded in gitsub.sh.
Thanks,
Marc
Hi!
Although I don't use gnulib with '--with-tests', it does create a tests/
directory during bootstrap and fills it with a few files. I attached my
gnulib-cache.m4.
Do you think I can prevent gnulib from creating the directory? Did I
include some module that makes it create the directory, or d
Hi,
If I may chime into the discussion, let me remark that local
parameterization of the memory allocator is often useful (while the linker
approach means a global replacement). For example, part of the
program/library may work with an arena allocator (see, e.g. [1] for a
general discussion) and
Do you have detailed test results/logs?
Thanks,
Marc
Am Di., 19. Dez. 2023 um 23:13 Uhr schrieb Bruno Haible :
> My (preliminary) test results:
>
> The test passes on x86_64, m68k, alpha, s390, s390x, riscv64, loongarch64.
>
> It fails on some platforms with i386, mips, sparc, arm, arm64
>
> It
Am So., 17. Dez. 2023 um 09:50 Uhr schrieb Paul Eggert :
> On 2023-12-16 04:42, Marc Nieper-Wißkirchen wrote:
> > the problem is if further down in the compiler pipeline, the
> > P <= P expression produces some intermediate code that becomes equal to
> > code the opt
Am Fr., 15. Dez. 2023 um 02:00 Uhr schrieb Paul Eggert :
> On 12/3/23 05:15, Andreas F. Borchert wrote:
> > You will have
> > then to possibly live with annoying warnings and odd behaviours.
>
> The C standard says that when P is a null pointer, P==P must be true
> whereas P<=P has undefined behav
Am So., 3. Dez. 2023 um 10:05 Uhr schrieb Paul Eggert :
> On 2023-12-02 01:04, Bruno Haible wrote:
> > On the contrary, I will try to find and eliminate such alarms.
>
> Please don't complicate and/or slow down shared Gnulib code just to
> pacify this particular false alarm from Clang. The obstack
Am Fr., 1. Dez. 2023 um 21:01 Uhr schrieb Paul Eggert :
> On 2023-12-01 10:40, Bruno Haible wrote:
>
> > Indeed, this sentence appears to forbid ((char *) NULL) + something.
>
> Yes. However, Gnulib code can still use ((char *) NULL) + something)
> because the Gnulib portability guidelines allow i
Am Fr., 1. Dez. 2023 um 19:42 Uhr schrieb Bruno Haible :
> Marc Nieper-Wißkirchen wrote:
> > By 6.5.6 "Additive Operators":
> >
> > (2) "... one operator shall be a pointer to a complete object type..."
> >
> > NULL, which is a null pointer con
By 6.5.6 "Additive Operators":
(2) "... one operator shall be a pointer to a complete object type..."
NULL, which is a null pointer constant, is not necessarily a pointer to a
complete object type.
(9) "... If the pointer operand and the result do not point to elements of
the same array object o
I forgot to actually make use of the patched part in the test case; here is
the full patch. Please excuse the mess.
Am Mo., 27. Nov. 2023 um 18:36 Uhr schrieb Marc Nieper-Wißkirchen <
marc.nieper+...@gmail.com>:
> Am Mo., 27. Nov. 2023 um 17:27 Uhr schrieb Marc Nieper-W
Am Mo., 27. Nov. 2023 um 17:27 Uhr schrieb Marc Nieper-Wißkirchen <
marc.nieper+...@gmail.com>:
[...]
> For the moment, I expect
>> - a SIGSEGV on powerpc*-aix, powerpc64-linux, ia64, hppa, and hppa64
>> due to the structure of function pointers, see
>>
>
Marc Nieper-Wißkirchen
+
+ stack: Fix documentation in header file.
+ * lib/stack.h: Correct documentation on `stack_current_base'.
+
2023-11-27 Marc Nieper-Wißkirchen
jit/cache-tests: Fix include guard.
diff --git a/lib/stack.h b/lib/stack.h
index dbd6812bc8..91b1944
+1,8 @@
+2023-11-27 Marc Nieper-Wißkirchen
+
+ jit/cache-tests: Fix include guard.
+ * tests/jit/test-cache.c (main): Extend range of include guard.
+
2023-11-25 Marc Nieper-Wißkirchen
jit/cache-tests: New module.
diff --git a/tests/jit/test-cache.c b/tests/jit/test
Am Sa., 25. Nov. 2023 um 21:19 Uhr schrieb Bruno Haible :
> Hello Marc,
>
> > Here is my attempt at a simple unit test for your new cache module.
> >
> > I have tested it on an x86 box (where the instruction cache is always in
> > sync) and on an Armv8 Raspberry, both running GNU/Linux. Commentin
---
ChangeLog | 9 +
m4/valgrind-helper.m4 | 3 +-
modules/jit/cache-tests | 20 +++
tests/jit/test-cache.c | 77 +
4 files changed, 108 insertions(+), 1 deletion(-)
create mode 100644 modules/jit/cache-tests
create mode 100644 tests/jit/test-cache.c
diff --git
Hi Bruno,
Thanks for making your module available. I have acquired a Raspberry Pi
with an ARMv8, so as soon as my time permits, I should be able to do some
testing.
Marc
Am Mo., 13. Nov. 2023 um 00:10 Uhr schrieb Bruno Haible :
> Marc Nieper-Wißkirchen wrote:
> > I only have access
Hello Bruno,
Am Mo., 6. Nov. 2023 um 19:33 Uhr schrieb Bruno Haible :
[...]
I can provide such a thing easily. In fact, I have it already sitting
> around on my disk since 2021 :-)
>
This is great!
> > GNU
> > lightning currently calls libgcc's `__clear_cache' directly ([1]), but
> this
> > w
The idea is to offer the builtin procedure
__builtin__clear_cache (void *begin, void *end),
which is provided at least by gcc and clang, in a portable manner. From
the documentation of gcc's version:
"This function is used to flush the processor’s instruction cache for the
region of memory betw
Happy new year, Bruno!
Yes, sorry, wrong list! :)
Marc
Am Mo., 2. Jan. 2023 um 15:42 Uhr schrieb Bruno Haible :
>
> Hi Marc,
>
> > For purposes of dynamically calling code, I need the following layout
> > of the assembled code:
> >
> > 0x00: 16-byte header
> > 0x10: entry point #1
> > 0x20: entr
For purposes of dynamically calling code, I need the following layout
of the assembled code:
0x00: 16-byte header
0x10: entry point #1
0x20: entry point #2
I want to use the new align/skip instructions for this. My code
generator currently looks like this:
align (16)
header:
ski
rtions(+)
diff --git a/ChangeLog b/ChangeLog
index ccf4acd03..0d04cb70e 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2022-08-12 Marc Nieper-Wißkirchen
+
+ hamt: fix technically undefined behavior
+ Bug reported by Bruno Haible in
+ <https://lists.gnu.org/r/bug-gnuli
Hi Bruno,
thanks for exhibiting this. The complaint by the UB sanitizer is
correct. Although the code won't use the 64-bit value shifted by 65,
it is technically UB. When I wrote the code, I erroneously assumed
that it would not be UB, but that the result of the shift would be
implementation-depen
Bruno, Paul,
thank you for your responses. So for a universal solution, one would
have to teach first the i18n toolchain how to interpret general PRIxxx
macros.
Am Mi., 13. Apr. 2022 um 09:05 Uhr schrieb Paul Eggert :
>
> On 4/12/22 02:12, Marc Nieper-Wißkirchen wrote:
> > I am wond
I am wondering how to print (using printf) values of type idx_t
reliably without assuming that idx_t == ptrdiff_t and without
conversion to uintptr_t.
Would it make sense to add PRIxxx and SCNxxx macros (as those found in
inttypes.h) to idx.h?
Thanks,
Marc
Am Sa., 8. Jan. 2022 um 11:51 Uhr schrieb Bruno Haible :
>
> Marc Nieper-Wißkirchen wrote:
> > I submitted a patch. An email will follow.
>
> Ah, you already pushed it. Good!
My workflow is not optimized yet. Pushing and sending out the email
with the patch has to happen in two steps.
* lib/c-stack.h: Add extern "C" block.
---
ChangeLog | 5 +
lib/c-stack.h | 8
2 files changed, 13 insertions(+)
diff --git a/ChangeLog b/ChangeLog
index ad525f531..64d70fd41 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2022-01-08 Marc Nieper-Wißkirchen
+
* lib/version-etc.h: Add extern "C" block.
---
ChangeLog | 5 +
lib/version-etc.h | 9 +
2 files changed, 14 insertions(+)
diff --git a/ChangeLog b/ChangeLog
index 60ca624f1..ad525f531 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2022-01-08 Marc Nieper-
Am Fr., 7. Jan. 2022 um 21:54 Uhr schrieb Bruno Haible :
>
> Marc Nieper-Wißkirchen wrote:
> > I just noticed that doesn't include extern "C" guards
> > so that inclusion in a C++ source file becomes easier (see 4.2 in the
> > Gnulib manual).
>
>
I just noticed that doesn't include extern "C" guards
so that inclusion in a C++ source file becomes easier (see 4.2 in the
Gnulib manual).
I don't know what the general policy is, but including
in a C++ makes sense to me and could be made easier.
Marc
PS I haven't systematically checked other
Am Mi., 5. Jan. 2022 um 21:59 Uhr schrieb Bruno Haible :
>
> Hello Marc,
>
[...]
> > If I understand your classification correctly, I meant something more
> > like (E) than (D), I think. As an interface, I would propose would be
> > something along the following lines:
> >
> > decoder_t d = decod
Thank you, Paul. My local tests also show that it behaves better now.
Am Mi., 5. Jan. 2022 um 20:54 Uhr schrieb Paul Eggert :
>
> On 1/5/22 10:00, Bruno Haible wrote:
> > Another possible fix would be to change
> >size_t size;
> > to
> >idx_t size;
> > in the struct.
>
> Yes, that fits bet
Commit 3dc36216f168f4e752b648b19d85eab32a037827 by Paul Eggert
introduced a regression in the stack module.
If "stack.h" is included by client code that is supposed to be
compiled with "-Wsign-compare", the compiler will complain about the
comparison on line 121.
There wasn't a problem before com
Dear Bruno,
thank you for responding so quickly and for this addition!
Marc
Am Sa., 1. Jan. 2022 um 19:55 Uhr schrieb Bruno Haible :
>
> Marc Nieper-Wißkirchen wrote on 2021-12-30:
> > The striconveh module and related modules offer an error handler
> > argument. The current p
Hi Bruno,
thanks for your insights, valuable as always.
Am Sa., 1. Jan. 2022 um 13:57 Uhr schrieb Bruno Haible :
>
> Hi Marc,
>
> > The demand to read a file (in local encoding) and to decode it
> > incrementally seems a typical one.
>
> There are four ways to satisfy this demand.
>
> (A) Using a
The demand to read a file (in local encoding) and to decode it
incrementally seems a typical one.
With Gnulib, this can be done using the mbfile module to read in the
multibytes byte-by-byte and then using the striconveh module to decode
the multibytes in, say, UTF-8 or UTF-32.
This, however, doe
The striconveh module and related modules offer an error handler
argument. The current possible values are:
iconveh_error
iconveh_question_mark
iconveh_escape_sequence
The second option replaces any unconvertible character with a question mark "?".
I would like to request to add a fourth option,
Thanks for the tips!
It's working perfectly now.
Marc
Am Do., 16. Dez. 2021 um 18:08 Uhr schrieb Bruno Haible :
> Marc Nieper-Wißkirchen wrote:
> > Am I supposed to set ${gl_source_base_prefix} somewhere?
>
> No. gnulib-tool defines gl_source_base_prefix as appropriate
based on bootstrap and I have set source_base (and
tests_base) in bootstrap.conf.
Thanks,
Marc
Am Mi., 15. Dez. 2021 um 22:43 Uhr schrieb Bruno Haible :
> Marc Nieper-Wißkirchen wrote:
> > I'm using build-aux/prefix-gnulib-mk to rewrite the Gnulib Makefile
> > fragment so tha
Hi,
I'm using build-aux/prefix-gnulib-mk to rewrite the Gnulib Makefile
fragment so that it can be included by a Makefile in a top-level directory.
What I haven't managed to get working, though, is renaming the Gnulib lib/
directory at the same time (by setting $source_base in bootstrap.conf). Th
Hi Bruno,
thanks for replying so quickly!
My intention is neither to feed the signaling NaN into floating-point
operations nor to cause it an exception to be raised. What I really want
to do is to model a type whose value is either a floating-point number
(including infinities and the NaNs retur
Hi,
I have been searching through the list of modules but haven't been able to
find it: Does Gnulib offer a way to store a signaling NaN in a memory
location (if supported by the platform) and some way to check a memory
location whether it contains a signaling NaN?
The forthcoming C2x standard w
When compiling my code with "-Winline", I suddenly get a warning from
calling gl_list_add_last: "Call is unlikely and code size would grow."
Is there a way to suppress this warning using Gnulib or can the inline
functions of gl_xlist.h be implemented in a way so that this warning cannot
show up?
, ...).
Am Fr., 30. Apr. 2021 um 11:43 Uhr schrieb Simon Josefsson <
si...@josefsson.org>:
> Marc Nieper-Wißkirchen writes:
>
> > Moreover, use cases for a baked-in timeout are not restricted to tests.
> For
> > example, I may want to restrict the build time of certain c
Dear Bruno, dear Simon,
thank you for your replies.
I understand that valgrind-tests and the proposed "timeout-tests" solution
are not completely equivalent. Nevertheless, I still think that some
timeout functionality provided by Gnulib would be useful.
Bruno's solution
**
#if HAVE_DECL_ALARM
Gnulib contains a module named valgrind that allows the easy use of
Valgrind for tests whenever it is supported by the build system.
I would suggest to add a similar module named timeout that sets the
variable TIMEOUT with suitable defaults whenever the GNU coreutils timeout
program (or an equival
Hi!
In Guile's digest I noticed a comment about replacing libltdl (see below)
with the standard `dlopen' interface and providing a shim for systems not
supporting it directly.
Do Guile's observations apply in general? Would it make sense for the
Gnulib project to provide such a shimmed version of
behavior to the
other but that, in principle, a developer can decide to switch to in-tree
builds by touching such a file locally.
Am Fr., 9. Apr. 2021 um 13:16 Uhr schrieb Marc Nieper-Wißkirchen <
marc.nieper+...@gmail.com>:
> I have been experimenting a bit with building in a dedicated
_open-osf.h
lib/iconv_open-solaris.h
lib/iconv_open-zos.h
Thanks,
Marc
Am Sa., 3. Apr. 2021 um 12:22 Uhr schrieb Bruno Haible :
> Marc Nieper-Wißkirchen wrote:
> > Would it do much harm if ".gitignore" included all built files even for
> > developers that work in a
xalloc is now called with a size_t argument. If the argument type is
silently changed to an idx_t, existing code which calls the new xalloc
still with a size_t argument will trigger a compiler warning under GCC's
-Wsign-conversion.
Fixing existing code isn't easy because the sizeof operator return
Hi Bruno,
thanks for replying so quickly.
Let's assume I have a procedure
void *foo_create (size_t n)
{
void *foo = malloc (a + n * b);
if (foo == NULL) ...;
...
return foo;
}
I want 'foo_create' to handle possible overflows. To me, it seems that
should use the xsize module for this and
What is the relationship between these two modules? Both try to minimize
subtle bugs due to overflow.
However, both approaches cannot be easily combined as xsize expects
unsigned integers while idx is a signed one.
What is the suggested use of these modules for new code?
Thanks,
Marc
Am Di., 6. Apr. 2021 um 23:04 Uhr schrieb Bruno Haible :
> > > But when designing a general utility, for all kinds of programs to use,
> > > it is inappropriate to say "storing null elements is not useful".
> >
> > I'm afraid we'll have to disagree here.
>
> In some of my uses of the gl_list modul
list_iterator_t iter,
gl_list_node_t *node_ptr)
{
void *e;
return gl_list_iterator_next (iter, &e, node_ptr) ? e : NULL;
}
to the global API (modulo a better name for the procedure).
Am Di., 6. Apr. 2021 um 21:20 Uhr schrieb Paul Eggert :
> On 4/6/21 12:13 PM, M
Am Di., 6. Apr. 2021 um 21:05 Uhr schrieb Paul Eggert :
> On 4/5/21 11:48 PM, Marc Nieper-Wißkirchen wrote:
> > SIZE_MAX < (uintmax_t) nbytes
>
> Eeuuw! That's a cure worse than the disease. Among other things, there
> is no guarantee that PTRDIFF_MAX <= UINTMAX_MAX
Hi Paul,
thanks!
By the way, the snippet you gave is not portable C code, as it assumes
> that 'void *' and 'struct foo *' have the same machine representation.
> This is not necessarily true on (admittedly now-rare) machines that have
> different flavors of pointers. I suspect the main problem h
Hi,
I have been wondering whether it makes sense to add a small utility trying
to make typecasts in C as type-safe as possible.
The problem is that typecasts are sometimes unavoidable. For an example,
let's take a look at the following snippet using Gnulib's xlist module:
struct foo
{
int bar
Hi Paul,
Am Di., 6. Apr. 2021 um 05:19 Uhr schrieb Paul Eggert :
> On 4/3/21 11:17 PM, Marc Nieper-Wißkirchen wrote:
> > Does the comparison make any sense, by the way?
>
> Yes, although it's needed only on unusual (and these days perhaps
> theoretical?) platforms where
From: Marc Nieper-Wißkirchen
Reported by Bruno Haible in
<https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00047.html>
after a Coverity run.
* lib/hamt.c (bucket_do_while, hamt_iterator): Add missing
derefencing operator and silence a bogus warning on uninitialized
variables.
*
Hi Bruno,
Am Mo., 5. Apr. 2021 um 15:02 Uhr schrieb Bruno Haible :
> Hi Marc,
>
> > * tests/test-hamt.c: New file.
>
> Can you please have a quick look whether these Coverity findings (from our
> weekly Coverity run) are relevant?
>
Coverity seems to be a good tool. I haven't yet tested GCC's ne
Hi Bruno,
Am Mo., 5. Apr. 2021 um 04:45 Uhr schrieb Bruno Haible :
> [Adding back bug-gnulib in CC.]
>
Thanks!
> > Is there a fundamental reason why a list walking algorithm that both
> > inserts and removes items is not possible with an arbitrary Gnulib list
> > container? Obviously, the curr
From: Marc Nieper-Wißkirchen
Suggested by Bruno Haible in
<https://lists.gnu.org/archive/html/bug-gnulib/2021-04/msg00026.html>.
* doc/containers.texi: Add a subsection to section 15.11 Container
data types.
* lib/hamt.h: Improve documentation on how Hamt_entry is supposed
to b
warning and to make
it explicit.
Am So., 4. Apr. 2021 um 08:24 Uhr schrieb Jeffrey Walton :
> On Sun, Apr 4, 2021 at 2:17 AM Marc Nieper-Wißkirchen
> wrote:
> >
> > GCC prints the following warning when compiling the new code:
> >
> > lib/xmalloc.c: In fun
GCC prints the following warning when compiling the new code:
lib/xmalloc.c: In function 'xpalloc':
lib/xmalloc.c:132:64: warning: comparison of integer expressions of
different signedness: 'long unsigned int' and 'idx_t' {aka 'long int'}
[-Wsign-compare]
132 | = ((INT_MULTIPLY_WRAPV (n, ite
Hi Bruno,
thank you very much for all the helpful feedback. I have incorporated your
suggestions, and you can find an updated diff below.
Thanks,
Marc
diff --git a/doc/containers.texi b/doc/containers.texi
index 15c915b93..9bc1ae43d 100644
--- a/doc/containers.texi
+++ b/doc/containers.texi
@@
Hi Bruno,
what do you think of the attempt attached below?
Thanks,
Marc
diff --git a/doc/containers.texi b/doc/containers.texi
index 15c915b93..35caf200c 100644
--- a/doc/containers.texi
+++ b/doc/containers.texi
@@ -35,6 +35,9 @@ log
Gnulib provides several generic container data types. They
Hi Bruno,
thank you very much!
Am Sa., 3. Apr. 2021 um 18:28 Uhr schrieb Bruno Haible :
> Marc Nieper-Wißkirchen wrote:
> > For example, given a list of fruits, insert "pear" after each "apple" and
> > "peach" before each "apple".
Am Sa., 3. Apr. 2021 um 12:14 Uhr schrieb Bruno Haible :
> Marc Nieper-Wißkirchen wrote:
> > > > > I don't understand. You want to use a list_node_t while adding
> nodes to
> > > > > the list? This is invalid, since the comments in gl_list.h say:
>
Hi Bruno,
Am Sa., 3. Apr. 2021 um 12:05 Uhr schrieb Bruno Haible :
> Hi Marc,
>
> > If Gnulib is going to be extended to support the second option as well
>
> That's what I'm suggesting, because the second way to manage files appears
> to be the majority one.
>
> > I am not yet sure how. The prob
Am Sa., 3. Apr. 2021 um 11:49 Uhr schrieb Bruno Haible :
> Marc Nieper-Wißkirchen wrote:
> > > I don't understand. You want to use a list_node_t while adding nodes to
> > > the list? This is invalid, since the comments in gl_list.h say:
> > >
> > &g
From: Marc Nieper-Wißkirchen
This module provides (persistent) hash array mapped tries.
* MODULES.html.sh: Add hamt.
* lib/hamt.c: New file.
* lib/hamt.h: New file.
* modules/hamt: New file.
* modules/hamt-tests: New file.
* tests/test-hamt.c: New file.
---
ChangeLog | 11
!= new_hamt" the element has been
inserted and has now to eventually free "new_hamt" besides "old_hamt".
After I have rebased my code to HEAD, I will commit the new module to
Gnulib.
Thank you for your patience.
Marc
Am So., 18. Okt. 2020 um 20:11 Uhr schrieb Marc Niepe
Hi,
Am Sa., 3. Apr. 2021 um 00:49 Uhr schrieb Bruno Haible :
> This is useful if the list has to be traversed while nodes are added
> > because an iterator cannot be used here.
>
> I don't understand. You want to use a list_node_t while adding nodes to
> the list? This is invalid, since the comme
Hi Bruno,
thank you very much for your prompt reply.
Am Sa., 3. Apr. 2021 um 01:00 Uhr schrieb Bruno Haible :
As far as I know, there are two practices regarding .gitignore management:
>
> * Some developers want a very clean source directory at all times.
> They always to VPATH builds. The
A number of autogenerated header files are not added to ".gitignore" in
"$source_base".
For example, in a current project of mine,
$ git status
shows
lib/alloca.h
lib/fcntl.h
lib/inttypes.h
lib/langinfo.h
lib/limits.h
lib/locale.h
lib/signal.h
lib/stdio.h
lib/stdlib.h
lib/string.h
lib/sys/
lib/
Hi!
At the moment, there does not seem to be an easy way to retrieve the node
of the first or the last element in a list.
This is useful if the list has to be traversed while nodes are added
because an iterator cannot be used here.
What is currently possible is to use get_first/set_first (and
ge
Okay, if you find the latter protocol better anyway, I will switch to
this protocol, and hamts will be stack-allocated (just two words) and
passed by value.
Thanks,
Marc
Am So., 18. Okt. 2020 um 19:58 Uhr schrieb Bruno Haible :
>
> Marc Nieper-Wißkirchen wrote:
> > The existing pr
Am So., 18. Okt. 2020 um 16:39 Uhr schrieb Bruno Haible :
>
> Hi Marc,
>
> > At the moment, the header file exposes an opaque struct Hamt and
> > communication with the code happens through (stack-allocated) pointers
> > to a Hamt. In the implementation, however, each Hamt just consists of
> > two
One final issue (I hope):
At the moment, the header file exposes an opaque struct Hamt and
communication with the code happens through (stack-allocated) pointers
to a Hamt. In the implementation, however, each Hamt just consists of
two pointers (a pointer to a function table and a pointer to the
r
compilers.
* Implement purely non-pure hamts to replace ordinary hash tables.
* Add _nx versions of the procedures that won't call xalloc_die.
Many thanks to Bruno for his support, guidance and his great suggestions.
Marc
Am So., 11. Okt. 2020 um 19:32 Uhr schrieb Marc Nieper-Wißkirchen
:
>
Am So., 11. Okt. 2020 um 10:20 Uhr schrieb Marc Nieper-Wißkirchen
:
>
> Am So., 11. Okt. 2020 um 03:28 Uhr schrieb Bruno Haible :
[...]
> > * hamt_lookup: If the caller is allowed to modify the payload stored in the
> > returned entry, this function should return a
Am So., 11. Okt. 2020 um 16:14 Uhr schrieb Bruno Haible :
>
> Hi Marc,
>
> > I have attached an improved version of the HAMT module to this email.
>
> How about terminology: "delete" vs. "remove"?
> In this sense, 'hamt_delete' is triggering the wrong associations.
> How about renaming 'hamt_remov
Am So., 11. Okt. 2020 um 12:29 Uhr schrieb Bruno Haible :
> The recursion across hamt_do_while / entry_do_while / subtrie_do_while /
> bucket_do_while builds up a stack whose essential contents is a set of
> indices, each at most 5 bits large, with a total of SIZE_WIDTH bits.
> In other words, the
Am So., 11. Okt. 2020 um 14:04 Uhr schrieb Bruno Haible :
>
> Marc Nieper-Wißkirchen wrote:
> > > > /* Return an independent copy of ITER that is initially in the same
> > > >state. */
> > > > extern Hamt_iterator *hamt_iterator_copy (Hamt_iterator *
Am So., 11. Okt. 2020 um 14:14 Uhr schrieb Bruno Haible :
[...]
> > > > /* Return an independent copy of ITER that is initially in the same
> > > >state. */
> > > > extern Hamt_iterator *hamt_iterator_copy (Hamt_iterator *iter);
> > >
> > > Then a copy function is not needed, because the use
Am So., 11. Okt. 2020 um 13:56 Uhr schrieb Bruno Haible :
>
> Marc Nieper-Wißkirchen wrote:
> > I am not so convinced of whether it makes sense to create a
> > gl_set/gl_map frontend for this hamt implementation.
>
> Wikipedia [1] lists some advantages of HAMTs even
1 - 100 of 192 matches
Mail list logo