Subject: Emacs 28.1 clone build with native compilation crashes on s390x

From: Rob Browning <[email-masked]>
Date: Tue, 13 Sep 2022 20:04:32 -0500

On zelenka.debian.org https://db.debian.org/machines.cgi?host=zelenka
the build crashes with a segfault with current Debian sid (unstable).  I
can produce the crash like this:

  git clone --single-branch --branch emacs-28 .../emacs.git
  cd emacs
  ./autogen.sh
  ./configure --prefix=/home/rlb/opt/emacs-tmp --with-native-compilation
  make check

The debian package produced a similar failure earlier:

  https://buildd.debian.org/status/fetch.php?pkg=emacs&arch=s390x&ver=1%3A28.1%2B1-3&stamp=1662863442&raw=0

Here's the final bit of the clone build's log, and I'm happy to help
test on the machine if that'd be useful:

  Loading /home/rlb/emacs/lisp/electric.el (source)...
  Loading /home/rlb/emacs/lisp/paren.el (source)...
  Loading /home/rlb/emacs/lisp/emacs-lisp/shorthands.el (source)...
  Loading /home/rlb/emacs/lisp/emacs-lisp/eldoc.el (source)...
  Loading /home/rlb/emacs/lisp/cus-start.el (source)...
  Loading /home/rlb/emacs/lisp/tooltip.el (source)...
  Loading /home/rlb/emacs/lisp/international/iso-transl.el (source)...
  Finding pointers to doc strings...
  Finding pointers to doc strings...done
  Dumping under the name bootstrap-emacs.pdmp
  Dumping fingerprint: b4b1b9ac4d82ce4537c0e1eb6527b2b7f5831cb6de31c7f9b2fd2a1a0c4531c4
  Dump complete
  Byte counts: header=100 hot=14915588 discardable=175392 cold=10410424
  Reloc counts: hot=1048047 discardable=5080
  make -C ../lisp compile-first EMACS="../src/bootstrap-emacs"
  make[2]: Entering directory '/home/rlb/emacs/lisp'
    ELC+ELN  emacs-lisp/macroexp.elc
    ELC+ELN  emacs-lisp/cconv.elc
    ELC+ELN  emacs-lisp/byte-opt.elc
    ELC+ELN  emacs-lisp/bytecomp.elc
    ELC+ELN  emacs-lisp/comp.elc
    ELC+ELN  emacs-lisp/comp-cstr.elc
    ELC+ELN  emacs-lisp/cl-macs.elc
    ELC+ELN  emacs-lisp/rx.elc
    ELC+ELN  emacs-lisp/cl-seq.elc
  Fatal error 11: Segmentation fault
  Backtrace:
  ../src/bootstrap-emacs(+0x15deb6)[0x2aa0a7ddeb6]
  ../src/bootstrap-emacs(+0x4efc4)[0x2aa0a6cefc4]
  ../src/bootstrap-emacs(+0x4f1fe)[0x2aa0a6cf1fe]
  ../src/bootstrap-emacs(+0x15c240)[0x2aa0a7dc240]
  ../src/bootstrap-emacs(+0x15c2d2)[0x2aa0a7dc2d2]
  ../src/bootstrap-emacs(+0x6a47d8)[0x2aa0ad247d8]
  ../src/bootstrap-emacs(+0x1a7de0)[0x2aa0a827de0]
  ../src/bootstrap-emacs(+0x1a8ee6)[0x2aa0a828ee6]
  ../src/bootstrap-emacs(+0x1a8ee6)[0x2aa0a828ee6]
  ../src/bootstrap-emacs(+0x1a8ee6)[0x2aa0a828ee6]
  ../src/bootstrap-emacs(+0x1a8ee6)[0x2aa0a828ee6]
  ../src/bootstrap-emacs(+0x1a7c3e)[0x2aa0a827c3e]
  ../src/bootstrap-emacs(+0x1a9094)[0x2aa0a829094]
  ../src/bootstrap-emacs(eval_sub+0x410)[0x2aa0a84cc28]
  ../src/bootstrap-emacs(+0x1cdc2e)[0x2aa0a84dc2e]
  ../src/bootstrap-emacs(+0x1cdf10)[0x2aa0a84df10]
  ../src/bootstrap-emacs(eval_sub+0x1b8)[0x2aa0a84c9d0]
  ../src/bootstrap-emacs(+0x1cdeb8)[0x2aa0a84deb8]
  ../src/bootstrap-emacs(eval_sub+0x1b8)[0x2aa0a84c9d0]
  ../src/bootstrap-emacs(eval_sub+0x2c4)[0x2aa0a84cadc]
  ../src/bootstrap-emacs(+0x1cd26a)[0x2aa0a84d26a]
  ../src/bootstrap-emacs(eval_sub+0x532)[0x2aa0a84cd4a]
  ../src/bootstrap-emacs(eval_sub+0x4ba)[0x2aa0a84ccd2]
  ../src/bootstrap-emacs(eval_sub+0x532)[0x2aa0a84cd4a]
  ../src/bootstrap-emacs(+0x1ce488)[0x2aa0a84e488]
  ../src/bootstrap-emacs(eval_sub+0x532)[0x2aa0a84cd4a]
  ../src/bootstrap-emacs(+0x1cd8cc)[0x2aa0a84d8cc]
  ../src/bootstrap-emacs(eval_sub+0x532)[0x2aa0a84cd4a]
  ../src/bootstrap-emacs(+0x1cdc2e)[0x2aa0a84dc2e]
  ../src/bootstrap-emacs(+0x1cdf10)[0x2aa0a84df10]
  ../src/bootstrap-emacs(eval_sub+0x1b8)[0x2aa0a84c9d0]
  ../src/bootstrap-emacs(eval_sub+0x2c4)[0x2aa0a84cadc]
  ../src/bootstrap-emacs(+0x1cdc2e)[0x2aa0a84dc2e]
  ../src/bootstrap-emacs(Ffuncall+0x1f2)[0x2aa0a84a202]
  ../src/bootstrap-emacs(+0x1cc6a4)[0x2aa0a84c6a4]
  ../src/bootstrap-emacs(+0x1ce26c)[0x2aa0a84e26c]
  ../src/bootstrap-emacs(eval_sub+0x638)[0x2aa0a84ce50]
  ../src/bootstrap-emacs(+0x1ce7ec)[0x2aa0a84e7ec]
  ../src/bootstrap-emacs(eval_sub+0x532)[0x2aa0a84cd4a]
  ../src/bootstrap-emacs(+0x1cdc2e)[0x2aa0a84dc2e]
  ../src/bootstrap-emacs(+0x1cdf10)[0x2aa0a84df10]
  ...
  make[2]: *** [Makefile:316: emacs-lisp/cl-seq.elc] Segmentation fault
  make[2]: Leaving directory '/home/rlb/emacs/lisp'
  make[1]: *** [Makefile:870: bootstrap-emacs.pdmp] Error 2
  make[1]: Leaving directory '/home/rlb/emacs/src'
  make: *** [Makefile:449: src] Error 2

Thanks
-- 
Rob Browning
rlb @defaultvalue.org and @debian.org
GPG as of 2011-07-10 E6A9 DA3C C9FD 1FF8 C676 D2C4 C0F0 39E9 ED1B 597A
GPG as of 2002-11-03 14DD 432F AE39 534D B592 F9A0 25C8 D377 8C7E 73A4