From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 10154 invoked by alias); 29 Apr 2004 03:05:44 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 10134 invoked from network); 29 Apr 2004 03:05:43 -0000 Received: from unknown (HELO perpugilliam.csclub.uwaterloo.ca) (129.97.134.31) by sources.redhat.com with SMTP; 29 Apr 2004 03:05:43 -0000 Received: by perpugilliam.csclub.uwaterloo.ca (Postfix, from userid 20006) id 5505EA856A; Wed, 28 Apr 2004 23:05:43 -0400 (EDT) Subject: Re: g++ 3.4.0 cygwin, codegen SSE & alignement issues To: gcc@gcc.gnu.org Date: Thu, 29 Apr 2004 06:46:00 -0000 MIME-Version: 1.0 Message-Id: <20040429030543.5505EA856A@perpugilliam.csclub.uwaterloo.ca> From: rridge@csclub.uwaterloo.ca (Ross Ridge) X-SW-Source: 2004-04/txt/msg01356.txt.bz2 Ross Ridge wrote: > I think a happy middle-way, at least for the i386 port, would be to > implement a special function attribute, say __attribute__((align_stack)), > that only dynamically aligns the stack of functions defined with the > attribute. DJ Delorie wrote: > The existing align-stack code is target independent. Why not create a > target independent attribute? The x86 isn't the only target that has > this problem, just the only one with an OS that makes it so obvious > (although Windows runs on various embedded chips also). Well, the existing target independent forced align-stack code, which only handles main(), is less than ideal on i386 Windows targets. It generates an unnecessary call to __alloca and wastes 16-bytes of stack space. This isn't a problem since it currently only happens in main(), but it would probably better to have the forced, dynamic, stack alignment code done more intelligently in the backend where all the other prologue stack allocation is handled. Ross Ridge -- l/ // Ross Ridge -- The Great HTMU [oo][oo] rridge@csclub.uwaterloo.ca -()-/()/ http://www.csclub.uwaterloo.ca/u/rridge/ db //