From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21397 invoked by alias); 25 Mar 2008 00:42:54 -0000 Received: (qmail 21285 invoked by uid 48); 25 Mar 2008 00:42:12 -0000 Date: Tue, 25 Mar 2008 00:42:00 -0000 Message-ID: <20080325004212.21284.qmail@sourceware.org> X-Bugzilla-Reason: CC References: Subject: [Bug target/35657] TDmode isn't aligned at 128bit when passing to a function In-Reply-To: Reply-To: gcc-bugzilla@gcc.gnu.org To: gcc-bugs@gcc.gnu.org From: "hjl dot tools at gmail dot com" Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org X-SW-Source: 2008-03/txt/msg01950.txt.bz2 ------- Comment #3 from hjl dot tools at gmail dot com 2008-03-25 00:42 ------- This patch will align DFP to its natural boundary. Index: gcc/config/i386/i386.c =================================================================== --- gcc/config/i386/i386.c (revision 1917) +++ gcc/config/i386/i386.c (working copy) @@ -4609,7 +4609,8 @@ ix86_function_arg_boundary (enum machine align = GET_MODE_ALIGNMENT (mode); if (align < PARM_BOUNDARY) align = PARM_BOUNDARY; - if (!TARGET_64BIT) + /* Decimal floating point is aligned to its natural boundary. */ + if (!TARGET_64BIT && !VALID_DFP_MODE_P (mode)) { /* i386 ABI defines all arguments to be 4 byte aligned. We have to make an exception for SSE modes since these require 128bit -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35657