From owner-freebsd-hackers@FreeBSD.ORG Thu Oct 2 15:10:41 2014 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 90DB0866 for ; Thu, 2 Oct 2014 15:10:41 +0000 (UTC) Received: from mail-ig0-x22b.google.com (mail-ig0-x22b.google.com [IPv6:2607:f8b0:4001:c05::22b]) (using TLSv1 with cipher ECDHE-RSA-RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 5F5B1B5 for ; Thu, 2 Oct 2014 15:10:41 +0000 (UTC) Received: by mail-ig0-f171.google.com with SMTP id h15so2175934igd.4 for ; Thu, 02 Oct 2014 08:10:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:content-type; bh=rQuiAGSD8ZoajlbtoQHJCQ69z3n47Z6lxvuNveFxn+Q=; b=YE1IMbTlSaKi4iSEfh6DNEipkNW+dAlCjAcbfL/RmcuSSYTx5jmfIws8Eby3Dmd2/0 dKFuIoiTYm4yBCQYv2fxCFUawo1eTEmMVzp2I8ASIz6e6MOLtgP8/lpKKE3IV/Pt3Vii hOpwIBKsn64yAvNEXb6AA5guRaMhwxmlg1sataB2j0MLk4vnzZBmePP6NWgP11HSUA3H Y+W3NW6aVlL01M6eHoBbxlZJZFEHa9KAoTiI0jjfxSinNPnvOR4SLsA71GwhCccYRlvo gFDcs+REAvQUfy3a/Wd9lJLSXFy+uR/Po9d0lUvaqbwyBkGSSNKvpmgqWpTxrNaz7OQ3 5zfA== X-Received: by 10.42.233.75 with SMTP id jx11mr5990979icb.22.1412262640695; Thu, 02 Oct 2014 08:10:40 -0700 (PDT) MIME-Version: 1.0 Sender: carpeddiem@gmail.com Received: by 10.107.44.196 with HTTP; Thu, 2 Oct 2014 08:10:20 -0700 (PDT) In-Reply-To: <20141002075537.GU26076@kib.kiev.ua> References: <20141001031553.GA14360@gta.com> <20141001134044.GA57022@gta.com> <542C8C75.30007@FreeBSD.org> <20141002075537.GU26076@kib.kiev.ua> From: Ed Maste Date: Thu, 2 Oct 2014 11:10:20 -0400 X-Google-Sender-Auth: sW-PFH2ZYQAdAilBzlLv48p6vxY Message-ID: Subject: Re: Kernel/Compiler bug To: Konstantin Belousov , "freebsd-hackers@freebsd.org" Content-Type: text/plain; charset=UTF-8 X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 02 Oct 2014 15:10:41 -0000 On 2 October 2014 03:55, Konstantin Belousov wrote: > > The cost of the increased size for kernel stack is significant, even > on architectures with ample KVA. This must not be done just because > some non-default kernel settings cause stack overflow. If somebody > feels himself qualified enough to tune compiler options, it must > understand the consequences and do other required adjustments, > including kernel stack size tuning. I wonder if we should have a comment in kern.pre.mk, even if it's just an explicit notice that changing -O can have adverse effects. For better or worse it's a fairly common desire to try changing the kernel's -O. Of course, kern.pre.mk is not intended to accommodate user-facing changes. I suspect it's reasonably common for developers to grep '-O2' in sys/conf and discover where it's getting set though.