From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12519 invoked by alias); 16 May 2012 01:37:14 -0000 Received: (qmail 12509 invoked by uid 22791); 16 May 2012 01:37:14 -0000 X-SWARE-Spam-Status: No, hits=-4.3 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_HOSTKARMA_W,RCVD_IN_HOSTKARMA_WL X-Spam-Check-By: sourceware.org Received: from relay1.mentorg.com (HELO relay1.mentorg.com) (192.94.38.131) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 16 May 2012 01:37:00 +0000 Received: from svr-orw-exc-10.mgc.mentorg.com ([147.34.98.58]) by relay1.mentorg.com with esmtp id 1SUTAh-0003iO-0L from Yao_Qi@mentor.com ; Tue, 15 May 2012 18:36:59 -0700 Received: from SVR-ORW-FEM-04.mgc.mentorg.com ([147.34.97.41]) by SVR-ORW-EXC-10.mgc.mentorg.com with Microsoft SMTPSVC(6.0.3790.4675); Tue, 15 May 2012 18:36:43 -0700 Received: from [127.0.0.1] (147.34.91.1) by svr-orw-fem-04.mgc.mentorg.com (147.34.97.41) with Microsoft SMTP Server id 14.1.289.1; Tue, 15 May 2012 18:36:57 -0700 Message-ID: <4FB304B3.4080806@codesourcery.com> Date: Wed, 16 May 2012 01:37:00 -0000 From: Yao Qi User-Agent: Mozilla/5.0 (X11; Linux i686; rv:12.0) Gecko/20120430 Thunderbird/12.0.1 MIME-Version: 1.0 To: Joel Brobecker CC: , Subject: Re: [PATCH 1/4] New gdb arch hook: return_with_first_hidden_param_p References: <20120503011435.GA3294@adacore.com> <4FA22D7B.1040707@codesourcery.com> <20120504175830.GQ15555@adacore.com> <4FA743EC.1080903@codesourcery.com> <20120507201345.GX15555@adacore.com> <4FAA2D25.4060700@codesourcery.com> <20120510212054.GA5886@adacore.com> <4FACEB4B.1060603@codesourcery.com> <20120514171453.GL10253@adacore.com> <4FB1FCD2.5070302@codesourcery.com> <20120515150132.GR10253@adacore.com> In-Reply-To: <20120515150132.GR10253@adacore.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8bit X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-05/txt/msg00591.txt.bz2 On 05/15/2012 11:01 PM, Joel Brobecker wrote: >> > No, the extra hidden parameter's type is the reference of the function's >> > return type. My point is if we only examine debug info, we don't know >> > whether hidden parameter is passed, because the debug info is the same >> > regardless of hidden parameter is passed or not. > I may be too naive, or maybe I am not understanding what you are saying, > but I find it horrifying that the compiler would generate a parameter > DIE for a function if that parameter is not actually passed when calling > that function. Did I misunderstand? The compiler doesn't generate the DIE for the hidden parameter (it is not 'this', it is used to store the address of return value). The situation horrifying you doesn't exist. My original words are "My point is if we only examine debug info, we don't know whether hidden parameter is passed, because the debug info is the same". The "same" means compiler doesn't generate DIE for the hidden parameter, so it is the same on the targets having hidden parameter passed and the targets not having hidden parameter passed. -- Yao (齐尧)