Subject: Re: bug#68244: hash-table improvements

From: Andy Moreton <[email-masked]>
Date: Sun, 14 Jan 2024 22:08:14 +0000

On Sat 13 Jan 2024, Mattias Engdegård wrote:

> All right, I've pushed the parts that I have little doubt about being a
> definite improvement: a batch of refactoring steps, then the hash-table
> printing reforms, the representation and growth algorithm improvements, and
> finally documentation updates, all now on master.

Something in this patch series causes a build failure on Windows using
the Mingw64 toolchain. I've tried bisecting this, and at each step doing
"git clean -xdf" and then autogen, configure and make for a native build.

The last good commit on master is:
  c3d0cc50faf5 ("Remove rehash-threshold and rehash-size struct members")

Bisect identifies this as the bad commit:
  d3cefd3e9835 ("Leaner hash table dumping and thawing")

I have included the end of the log from the failing build below.

    AndyM

                           -----o0o-----

cp -f temacs.exe bootstrap-emacs.exe
rm -f bootstrap-emacs.pdmp
./temacs --batch  -l loadup --temacs=pbootstrap \
	--bin-dest c:/emacs/30.0.50/mingw64-x86_64-O2-native/bin/ --eln-dest c:/emacs/30.0.50/mingw64-x86_64-O2-native/lib/emacs/30.0.50/
Loading loadup.el (source)...
Dump mode: pbootstrap
Using load-path (c:/emacs/git/emacs/master/lisp c:/emacs/git/emacs/master/lisp/emacs-lisp c:/emacs/git/emacs/master/lisp/progmodes c:/emacs/git/emacs/master/lisp/language c:/emacs/git/emacs/master/lisp/international c:/emacs/git/emacs/master/lisp/textmodes c:/emacs/git/emacs/master/lisp/vc)
Loading emacs-lisp/debug-early (source)...

...[snipped]...

Loading c:/emacs/git/emacs/master/lisp/emacs-lisp/rmc.el (source)...
Finding pointers to doc strings...
Finding pointers to doc strings...done
Dumping under the name bootstrap-emacs.pdmp
Dumping fingerprint: 9f59e49a3ba95f3d7451327de9cf2863b9ddb392220c5f88f384f16245a619c2
Dump complete
Byte counts: header=100 hot=16147196 discardable=207320 cold=11360080
Reloc counts: hot=1123689 discardable=5662
ANCIENT=yes make -C ../lisp compile-first EMACS="../src/bootstrap-emacs.exe"
make[3]: Entering directory '/c/emacs/git/emacs/master/build/mingw64-x86_64-O2-native/lisp'
  ELC      /c/emacs/git/emacs/master/lisp/emacs-lisp/macroexp.elc

C:/emacs/git/emacs/master/src/lisp.h:2564: Emacs fatal error: assertion failed: 0 < size

Backtrace:
00007ff722cebc3e
00007ff722b674b1
00007ff722be90dc
00007ff722c33077
00007ff722c26f8a
00007ff722c271e1
00007ff722c28a62
00007ff722c26dc8
00007ff722c271e1
00007ff722c27515
00007ff722c28e7a
00007ff722c267a1
00007ff722c271e1
00007ff722c297a7
00007ff722c26dc8
00007ff722c271e1
00007ff722c27515
00007ff722c28e7a
00007ff722c267a1
00007ff722c271e1
00007ff722c28a62
00007ff722c26dc8
00007ff722c28358
00007ff722c26dc8
00007ff722c5d820
00007ff722c66167
00007ff722c67cd1
00007ff722c26f36
00007ff722c271e1
00007ff722c26dc8
00007ff722c271e1
00007ff722c28a62
00007ff722c26dc8
00007ff722c271e1
00007ff722c28a62
00007ff722c26dc8
00007ff722c29a80
00007ff722c26dc8
00007ff722c271e1
00007ff722c28a62
00007ff722c26dc8
00007ff722c271e1
00007ff722c26dc8
00007ff722c271e1
00007ff722c27515
00007ff722c2269e
00007ff722c67708
00007ff722c67898
00007ff722c22382
00007ff722c3dde8
00007ff722c26f72
00007ff722c5d820
00007ff722c66167
00007ff722c67cd1
00007ff722c26f36
00007ff722c271e1
00007ff722c26dc8
00007ff722c271e1
00007ff722c28a62
00007ff722c26dc8
00007ff722c271e1
00007ff722c28a62
...
make[3]: *** [Makefile:325: /c/emacs/git/emacs/master/lisp/emacs-lisp/macroexp.elc] Error 3
make[3]: Leaving directory '/c/emacs/git/emacs/master/build/mingw64-x86_64-O2-native/lisp'
make[2]: *** [Makefile:1017: bootstrap-emacs.pdmp] Error 2
make[2]: Leaving directory '/c/emacs/git/emacs/master/build/mingw64-x86_64-O2-native/src'
make[1]: *** [Makefile:554: src] Error 2
make[1]: Leaving directory '/c/emacs/git/emacs/master/build/mingw64-x86_64-O2-native'
make[1]: Entering directory '/c/emacs/git/emacs/master/build/mingw64-x86_64-O2-native'