From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7190 invoked by alias); 25 May 2006 14:16:07 -0000 Received: (qmail 7178 invoked by uid 22791); 25 May 2006 14:16:03 -0000 X-Spam-Check-By: sourceware.org Received: from nile.gnat.com (HELO nile.gnat.com) (205.232.38.5) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 25 May 2006 14:15:40 +0000 Received: from localhost (localhost [127.0.0.1]) by filtered-nile.gnat.com (Postfix) with ESMTP id D3FA148CFB5; Thu, 25 May 2006 10:15:38 -0400 (EDT) Received: from nile.gnat.com ([127.0.0.1]) by localhost (nile.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 13994-01-3; Thu, 25 May 2006 10:15:38 -0400 (EDT) Received: from [172.16.1.2] (sdsl-216-220-103-157.dsl.bway.net [216.220.103.157]) by nile.gnat.com (Postfix) with ESMTP id 8463248CFB4; Thu, 25 May 2006 10:15:38 -0400 (EDT) In-Reply-To: <9e4733910605230821wa313c44i3c1dd670a4ee01c@mail.gmail.com> References: <9e4733910605230821wa313c44i3c1dd670a4ee01c@mail.gmail.com> Mime-Version: 1.0 (Apple Message framework v750) Content-Type: text/plain; charset=US-ASCII; format=flowed Message-Id: <92BA74DB-B4E4-495A-A91C-AACB079D8C1D@adacore.com> Cc: gcc@gcc.gnu.org Content-Transfer-Encoding: 7bit From: Geert Bosch Subject: Re: optimizing calling conventions for function returns Date: Thu, 25 May 2006 14:16:00 -0000 To: Jon Smirl X-Mailer: Apple Mail (2.750) 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 X-SW-Source: 2006-05/txt/msg00599.txt.bz2 On May 23, 2006, at 11:21, Jon Smirl wrote: > A new calling convention could push two return addresses for functions > that return their status in EAX. On EAX=0 you take the first return, > EAX != 0 you take the second. This seems the same as passing an extra function pointer argument and calling that instead of doing a regular return. Tail-call optimization should turn the calll into a jump. Why do you think a custom ABI is necessary? -Geert