From owner-freebsd-arch@FreeBSD.ORG Tue Sep 18 20:17:07 2012 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DE6EC1065673; Tue, 18 Sep 2012 20:17:07 +0000 (UTC) (envelope-from phk@phk.freebsd.dk) Received: from phk.freebsd.dk (phk.freebsd.dk [130.225.244.222]) by mx1.freebsd.org (Postfix) with ESMTP id 979418FC08; Tue, 18 Sep 2012 20:17:07 +0000 (UTC) Received: from critter.freebsd.dk (unknown [192.168.61.3]) by phk.freebsd.dk (Postfix) with ESMTP id 90E403B7A4; Tue, 18 Sep 2012 20:17:06 +0000 (UTC) Received: from critter.freebsd.dk (localhost [127.0.0.1]) by critter.freebsd.dk (8.14.5/8.14.5) with ESMTP id q8IKH6f1023197; Tue, 18 Sep 2012 20:17:06 GMT (envelope-from phk@phk.freebsd.dk) To: Jeff Roberson From: "Poul-Henning Kamp" In-Reply-To: Your message of "Tue, 18 Sep 2012 09:00:38 -1000." Content-Type: text/plain; charset=ISO-8859-1 Date: Tue, 18 Sep 2012 20:17:06 +0000 Message-ID: <23196.1347999426@critter.freebsd.dk> Cc: Konstantin Belousov , attilio@freebsd.org, freebsd-arch@freebsd.org, arch@freebsd.org Subject: Re: Aliasing issue with TAILQ on ppc64 ? X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 18 Sep 2012 20:17:08 -0000 In message , Jeff Roberson writes: >If you compile at low optimization levels I assume it goes away? I don't have access to the machine at this time, and in general I'm not particular focused on PPC64, since this is a general problem on any architecture, as I understand the C-language rules. >Can you place asm volatile ("" ::: "memory"); between the two tailq macros >with the same optimization level? I tried earlier to put a printf("FOO") there, and that fixed it, which I why I diagnosed it as an aliasing issue in the first place. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence.