From owner-freebsd-current@freebsd.org Mon Nov 20 21:52:32 2017 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 85F7BDF680E for ; Mon, 20 Nov 2017 21:52:32 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-it0-x233.google.com (mail-it0-x233.google.com [IPv6:2607:f8b0:4001:c0b::233]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4AA1A6EEE3 for ; Mon, 20 Nov 2017 21:52:32 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-it0-x233.google.com with SMTP id n134so13562124itg.3 for ; Mon, 20 Nov 2017 13:52:32 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=QGHZuVPm5bqyHdwqebT6l4GqXwToXp1JC5P6pPnNONA=; b=MHsy19+mkhY65nBYGOY88bBS0Um/Jtd3MzxOxPGyzEz0G5/y+o2JBGFYoLFAbiINIY Yg5b4o+RWh+S99o3MKVQJxq+tfdrnIgbQDmeHDFN6J6x9UVCLH1uoMaIkHAh9QpmBkHX TnSJ+4cj/sV9skWucSriBLJRXFADZReFqVyrm167HUkQudUFmwaXmYeB1oWd2ZMEY4Ho jaUeFAuF2H6I6CCi1SCquwym1LXnjv17E69F9JofAve4qZ98HpSphvG3bnVJltvdmV5m BN22dAxjcrEVfDpQRPhXX3ECVp5izKjt8xhstRnzVhQ87mxqq8/96adra/sy20qAFc0s MO5Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=QGHZuVPm5bqyHdwqebT6l4GqXwToXp1JC5P6pPnNONA=; b=ag7IUWUbPimLtmfb1H801mQ0ShPeXVI0r4mc1VsZ4wwO9PwRQG4R6w/PeySG/Wefqw XSC/zuCcSjByOsHVsqcizSVycGex8SBmeqhiusMqNVGPtxjQP01FQ82jJYKxlXF1MA1g /qxJ8B4lAX6pZGgdE+rvNos7YJvs44CVECCMm0L+6G9GOHmhryVyE9KNS4Tm2h+31ivZ o3cgTZdOLUnse1lFH2DoGesfyIffoJ3BT/15E/+1A8depc7TqssfWdMBlRk3T+BG2p2A x6n/uzFlXsw8jBVSXZUAkkJvSq1G0/3K31++ffH76IIMvP2xm6jiS/bqtmzJWyjZh0Cc 8ISw== X-Gm-Message-State: AJaThX6bHK9HDs+2FlDdT3oNS+ZRslPPitC+hAhMuC9YL+E47dyTPsV/ 7gQNTt8FN6BO8FxWXoNgq3NibIMILGNdm/CWPAYa1A== X-Google-Smtp-Source: AGs4zMaAGtTMulncDQpjC9p2RGOW+C7ZF9xUq4L8RprsjAPqqCJ8pBB9ulX2ohAkeTs80XaiYT6TT7hlLERd+tF/1OQ= X-Received: by 10.36.101.207 with SMTP id u198mr20491899itb.50.1511214751538; Mon, 20 Nov 2017 13:52:31 -0800 (PST) MIME-Version: 1.0 Sender: wlosh@bsdimp.com Received: by 10.79.108.204 with HTTP; Mon, 20 Nov 2017 13:52:30 -0800 (PST) X-Originating-IP: [2603:300b:6:5100:c91c:5e34:ef38:d5a] In-Reply-To: References: <1509722947.3890181.1160658160.1B91FF70@webmail.messagingengine.com> From: Warner Losh Date: Mon, 20 Nov 2017 14:52:30 -0700 X-Google-Sender-Auth: fnBQyBEhNIGpGVEJGQ0AeMezsKI Message-ID: Subject: Re: Emacs and LLD To: Ed Maste Cc: Tobias Kortkamp , FreeBSD Current , ashish@freebsd.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.25 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 20 Nov 2017 21:52:32 -0000 On Mon, Nov 20, 2017 at 2:39 PM, Ed Maste wrote: > On 3 November 2017 at 11:29, Tobias Kortkamp wrote: > > > > My src.conf has WITH_LLD_IS_LD=yes and reading > > https://bugs.freebsd.org/214864 leads me to believe that it's somehow > > responsible for the problems I have with Emacs. > > Yes, the emacs build does some rather unusual things and it's perhaps > not surprising that it's one of the ports that's giving grief with > lld. > > The exp-run shows the same error you experienced: > > ./temacs --batch --load loadup bootstrap > Fatal error 'Can't allocate initial thread' at line 337 in file > /poudriere/jails/headamd64PR214864/usr/src/lib/libthr/thread/thr_init.c > (errno = 12) > gmake[2]: *** [Makefile:737: bootstrap-emacs] Abort trap (core dumped) > > I don't yet have any insight into the failure, and hope that someone > with knowledge of the emacs build process and emacs internals can take > a look. > Is temacs still an 'undumped' core dump[*]? Maybe the undumping code isn't playing well with lld's different behavior than ld? Warner [*] For speed, emacs use to compile all its lisp, load it into a memory arena, then take a core dump. The core dump was cleaned up so it could be used as an executable with the now-preloaded lisp code in place. It was a standard thing on 'big iron' that EMACS came from, but always a bit of an 'odd duck' as far as fitting into how Unix works. There used to be knobs to do it differently for things like VMS that simply couldn't easily cope. Maybe one of those needs to be tweaked? It's a tiny bit slower, but with the speed of today's hardware (and most hardware made since ~2000), the optimization likely saves time below the human threshold to detect...