From owner-freebsd-stable@FreeBSD.ORG Mon Oct 14 20:42:33 2013 Return-Path: Delivered-To: stable@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTP id 70F2D8AC; Mon, 14 Oct 2013 20:42:33 +0000 (UTC) (envelope-from mi+thun@aldan.algebra.com) Received: from mail1.bemta12.messagelabs.com (mail1.bemta12.messagelabs.com [216.82.251.3]) by mx1.freebsd.org (Postfix) with ESMTP id 28BF62651; Mon, 14 Oct 2013 20:42:32 +0000 (UTC) Received: from [216.82.249.35:57186] by server-3.bemta-12.messagelabs.com id 28/36-06818-2375C525; Mon, 14 Oct 2013 20:42:26 +0000 X-Env-Sender: mi+thun@aldan.algebra.com X-Msg-Ref: server-2.tower-138.messagelabs.com!1381783345!2405520!1 X-Originating-IP: [209.251.202.129] X-StarScan-Received: X-StarScan-Version: 6.9.12; banners=-,-,- X-VirusChecked: Checked Received: (qmail 13494 invoked from network); 14 Oct 2013 20:42:25 -0000 Received: from unknown (HELO PSYEXCHPMTA1.TIMEINC.COM) (209.251.202.129) by server-2.tower-138.messagelabs.com with SMTP; 14 Oct 2013 20:42:25 -0000 Received: by PSYEXCHPMTA1.TIMEINC.COM id hbhbj219f0g6; Mon, 14 Oct 2013 16:42:25 -0400 (envelope-from ) Message-ID: <525C5731.7020809@aldan.algebra.com> Date: Mon, 14 Oct 2013 16:42:25 -0400 From: "Mikhail T." Organization: Virtual Estates, Inc. User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; uk; rv:1.9.2.14) Gecko/20110221 Lightning/1.0b2 Thunderbird/3.1.8 MIME-Version: 1.0 To: Dimitry Andric Subject: Re: runtime linker on 9.x/i386: clang vs. gcc References: <525C1A5C.2030605@aldan.algebra.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Content-Filtered-By: Mailman/MimeDel 2.1.14 Cc: stable@FreeBSD.org X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 14 Oct 2013 20:42:33 -0000 10/14/13 4:31 PM, Dimitry Andric ???????(??): > There is a problem when clang does tail-call optimization on i386 with > PIC in effect, and it emits GOT relocations for the tail-called > functions, instead of PLT relocations. In some scenarios, such as with > the way X.org does lazy dynamic linking, this can cause problems. See > alsohttp://llvm.org/PR15086 (which I unfortunately did not get much > response on). Ouch... That seems like a show-stopper for clang-adoption... At least, on i386. > For now, a workaround is to recompile the affected .so files with > -fno-optimize-sibling-calls (if you are optimizing). Maybe, our clang (both src/ and ports/) should be compiled with that being in effect by default on i386? -mi