all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Wolfgang Jenkner <wjenkner@inode.at>
To: Joseph Mingrone <jrm@ftfl.ca>
Cc: ashish@FreeBSD.org, 22065@debbugs.gnu.org,
	Paul Eggert <eggert@cs.ucla.edu>
Subject: bug#22065: core dumped during compilation (emacs-25 branch on FreeBSD 9)
Date: Sun, 14 Feb 2016 17:12:46 +0100	[thread overview]
Message-ID: <85si0vjkos.fsf@iznogoud.viz> (raw)
In-Reply-To: <867fkz16lw.fsf@phe.ftfl.ca>

On Mon, Nov 30 2015, Joseph Mingrone wrote:

> There is a compilation issue on FreeBSD 9 (which has about another
> year of life) for the emacs-25 branch.  The error/warnings suggest the
> problems may be related to bug 18410.  It compiles fine on FreeBSD 10.
> Attached is a build log.

The pkg-fallout list indicates that that the build has been broken since
13 Nov 2014, although at that time it failed while temacs was loading up
stuff, with a different error message.

http://docs.freebsd.org/cgi/mid.cgi?201411130859.sAD8xATU001375

According to

https://svnweb.freebsd.org/ports/head/editors/emacs-devel/Makefile?view=log

this seems to correlate to a ports update to emacs bzr version 118251
from the previous 117676 (on Aug 10 2014).

There's a prominent change concerning the stack in this time frame, viz.

  commit c7dfea947eba1980fe3a23ad13f04dd40c6c0d68
  Author: Dmitry Antipov
  Date:   Tue Sep 9 07:44:06 2014 +0400

  Add macros to allocate temporary Lisp objects with alloca.

So, on FreeBSD 10, in a jail containing a basic FreeBSD 9 amd64 userland
I bisected between the above commit, which is still good, and some later
bad commit.

As USE_STACK_LISP_OBJECTS wasn't turned on by default before 2014-09-24,
I configured with

$ ./configure --without-all --without-x CPPFLAGS=-DUSE_STACK_LISP_OBJECTS=1

In the last few steps I had to delete the INLINE specifier in the
definition of local_vector_init() in src/alloc.c because it conflicted
with a declaration in src/lisp.h.

The first bad commit turns out to be

  commit edb0288b83b45d295df52ce7644e897613358971
  Author: Dmitry Antipov <dmantipov@yandex.ru>
  Date:   Mon Sep 15 18:53:23 2014 +0400

  If USE_LOCAL_ALLOCATORS, allocate some Lisp objects on stack.

Unfortunately, --enable-checking or --enable-check-lisp-object-type
also somehow makes the bootstrapping failure disappear.

On a current emacs master, after adding
CPPFLAGS=-DUSE_STACK_LISP_OBJECTS=0 to the configure command line
bootstrapping emacs works (in the above jail).

Alternatively (though not very practically), adding CFLAGS="-g -O0"
works (but CFLAGS="-g -O" doesn't).

Alternatively, bootstrapping even with the oldest gcc available from
ports (4.6.4) works.

So, perhaps, the FreeBSD 9 default base cc (a patched gcc 4.2.1) has
some stack-related optimization bug, even on amd64?





  parent reply	other threads:[~2016-02-14 16:12 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-30 22:10 bug#22065: core dumped during compilation (emacs-25 branch on FreeBSD 9) Joseph Mingrone
2015-12-26 21:22 ` Lars Ingebrigtsen
2016-02-13  1:08 ` Paul Eggert
2016-02-14 16:12 ` Wolfgang Jenkner [this message]
2016-02-14 19:47   ` Paul Eggert
2016-02-15  4:05     ` Joseph Mingrone
2016-02-15  5:56       ` Ashish SHUKLA
2016-02-15  8:17       ` Paul Eggert
2016-02-15 13:08         ` Wolfgang Jenkner
2016-02-15 18:51           ` Joseph Mingrone
2016-02-15 18:51         ` Joseph Mingrone
2016-02-17  3:38           ` Joseph Mingrone
2016-02-17  7:56             ` Paul Eggert
2016-02-17 13:23               ` Wolfgang Jenkner
2016-02-17 15:35                 ` Joseph Mingrone
2016-02-17 17:49             ` Wolfgang Jenkner
2016-02-17 22:45               ` Joseph Mingrone
2016-02-18 13:39                 ` Wolfgang Jenkner
2016-03-20  2:40 ` Paul Eggert
     [not found] ` <handler.22065.D22065.145844160912708.notifdone@debbugs.gnu.org>
2016-03-20  2:52   ` bug#22065: closed (Re: bug#22065: core dumped during compilation (emacs-25 branch on FreeBSD 9)) Joseph Mingrone

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=85si0vjkos.fsf@iznogoud.viz \
    --to=wjenkner@inode.at \
    --cc=22065@debbugs.gnu.org \
    --cc=ashish@FreeBSD.org \
    --cc=eggert@cs.ucla.edu \
    --cc=jrm@ftfl.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.