From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 4349 invoked by alias); 7 Feb 2008 13:55:42 -0000 Received: (qmail 4341 invoked by uid 22791); 7 Feb 2008 13:55:41 -0000 X-Spam-Check-By: sourceware.org Received: from main.gmane.org (HELO ciao.gmane.org) (80.91.229.2) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 07 Feb 2008 13:55:10 +0000 Received: from root by ciao.gmane.org with local (Exim 4.43) id 1JN7DS-0003mK-D6 for gcc-help@gcc.gnu.org; Thu, 07 Feb 2008 13:55:02 +0000 Received: from 85-127-19-147.dynamic.xdsl-line.inode.at ([85.127.19.147]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 07 Feb 2008 13:55:02 +0000 Received: from tim by 85-127-19-147.dynamic.xdsl-line.inode.at with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 07 Feb 2008 13:55:02 +0000 To: gcc-help@gcc.gnu.org From: Tim Blechmann Subject: __sync_compare_and_swap_16 argument alignment Date: Thu, 07 Feb 2008 13:55:00 -0000 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit User-Agent: Pan/0.132 (Waxed in Black) X-IsSubscribed: yes Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org X-SW-Source: 2008-02/txt/msg00055.txt.bz2 hi all, from my experience, the __sync_compare_and_swap_16 functions have the signatures: __sync_compare_and_swap_16 (type *ptr, type oldval, type newval) that doesn't quite map to the CMPXCHG16B instruction, since the ptr argument is required to be 16 byte aligned ... i am not sure, but shouldn't the signature be something like: __sync_compare_and_swap_16 (type __attribute__ ((__aligned__(16))) *ptr, type oldval, type newval) ? (at least for the x86_64 architecture) thanks in advance, tim -- tim@klingt.org http://tim.klingt.org The composer makes plans, music laughs. Morton Feldman