From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from simark.ca by simark.ca with LMTP id ITJ7DFBQemg5fRcAWB0awg (envelope-from ) for ; Fri, 18 Jul 2025 09:46:56 -0400 Authentication-Results: simark.ca; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=BgTURBCK; dkim-atps=neutral Received: by simark.ca (Postfix, from userid 112) id 1FD361E11C; Fri, 18 Jul 2025 09:46:56 -0400 (EDT) X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-25) on simark.ca X-Spam-Level: X-Spam-Status: No, score=-6.8 required=5.0 tests=ARC_SIGNED,ARC_VALID,BAYES_00, DKIMWL_WL_HIGH,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED,RCVD_IN_SBL_CSS,RCVD_IN_VALIDITY_CERTIFIED, RCVD_IN_VALIDITY_RPBL,RCVD_IN_VALIDITY_SAFE autolearn=ham autolearn_force=no version=4.0.1 Received: from server2.sourceware.org (server2.sourceware.org [8.43.85.97]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by simark.ca (Postfix) with ESMTPS id B96EC1E089 for ; Fri, 18 Jul 2025 09:46:55 -0400 (EDT) Received: from server2.sourceware.org (localhost [IPv6:::1]) by sourceware.org (Postfix) with ESMTP id 6DF043860007 for ; Fri, 18 Jul 2025 13:46:55 +0000 (GMT) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by sourceware.org (Postfix) with ESMTP id 71E65385274A for ; Fri, 18 Jul 2025 13:46:36 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 71E65385274A Authentication-Results: sourceware.org; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=redhat.com ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 71E65385274A Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=170.10.133.124 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1752846396; cv=none; b=jkT5akDoPhJ0uUnhKWDEIe5gmg7nySKxC5yjJzAAm6D2GCpShVjizDTYkoE8JdF1yeYqQcdlF2tusJ5plufvgpaqB6cn14Oz4NY4qrxE6a34BSprxa3SifsZZnH8Kysou30Tm1B61ppAk5V7cABrGlucCApv7zhWD1d6WCinuAo= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1752846396; c=relaxed/simple; bh=AgHm0JhboocrD0B5/REaL/2+gII5Dx7sPtvoGZCCFRQ=; h=DKIM-Signature:Message-ID:Date:MIME-Version:Subject:To:From; b=UeKj4iUiCQ+jmHDxsOLmCFmMW11jW/q/XnK0unPX0+fQI8RrGF1uc8wc2TmPdVCSk9vN1vbyBE3Sxck4/1ojFwKmw8udyviudcGeyprdecLTUIUszokaabRQebyaKI+mMqlwnojZvCpYP+S1RO4QHM6eeWsGk0m6r2ZSuZMsuUs= ARC-Authentication-Results: i=1; server2.sourceware.org DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 71E65385274A Authentication-Results: sourceware.org; dkim=pass (1024-bit key, unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=BgTURBCK DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1752846396; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=sSPxlwoFO/+jXEyXvLwSCgEd9Ue5s5udTKBd8SK7BJc=; b=BgTURBCKRTdkS3Kif7LWHTxTe0MOzli/fE7Jyncd6sGIQFNisH8/UasaZP4avZ19B8J99A nH6kiAIfi6LDwTTCGqsTfV5hoxeK6SGU2Z5JJEHMguMpHJlQk/MN6a/c5hfieof+P/Qfwf gvb7nl4AKt4csotyOZA1hPd62LjPliQ= Received: from mail-qk1-f197.google.com (mail-qk1-f197.google.com [209.85.222.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-280-MW7L0lBcMz2tS-r1TDUxOg-1; Fri, 18 Jul 2025 09:46:34 -0400 X-MC-Unique: MW7L0lBcMz2tS-r1TDUxOg-1 X-Mimecast-MFC-AGG-ID: MW7L0lBcMz2tS-r1TDUxOg_1752846394 Received: by mail-qk1-f197.google.com with SMTP id af79cd13be357-7d413a10b4cso287881485a.1 for ; Fri, 18 Jul 2025 06:46:34 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1752846394; x=1753451194; h=content-transfer-encoding:in-reply-to:from:content-language :references:to:subject:user-agent:mime-version:date:message-id :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=sSPxlwoFO/+jXEyXvLwSCgEd9Ue5s5udTKBd8SK7BJc=; b=diSGgR0eAL7l4oR1Pgj48csnHyG1mCpXLF6+8zY80HOR+wEaSHE/ZMExJ6mgF+RRdO lGjJcUniRPVprZELlpQyOp880hc0hqjMtTDGR9Q69bxLDvKLJb7NgiSpanVmacmIIqXs 8ddtezmn6tzj4nt3aDJ4byq3OXOGw2aq9VSpl4Gl4SavYLMfYrTWEHvCVFXIPLovEAoB zlHatkilNutx+C4UFYg5qh1c0xVwzidggxDwCPba5pxPqXyy5DypU1gLnU/vz5qqRS6V PVqccWwzpN8gghuHW56xD9xr4+BXF0I9/0P8elcGCoutinScsbmyG8T1YbN/ftl43t7z Gsjw== X-Forwarded-Encrypted: i=1; AJvYcCVXQl5Y0fZywv9yyRqOzroLBAt19C3nzOnIPve/FFc0Kwf4+Q51MFYOrl7aTdLY5RKYuFQ5EWsTubcWTg==@sourceware.org X-Gm-Message-State: AOJu0Ywys2qoV11YoK42v3KvV/g4Ji11h6rU8hrK2FfA1iDfUOjosR1k aOJqyiDazJhp8kFfEApX1IKCs1puCDyHHj7zc0stCZlL18Gty8HS69e//Cjjahv7J8qZ3ofbBwi P+viQo4iCOqpE7YKhLpo3y434O/LUs3mfyQDQMFq23dRuSXRBQtx3+IFd4hpaRxM= X-Gm-Gg: ASbGncuMqUJpBhHDkcnTOTX1iPpQp/0cxfmMyi/SQGtfSpZOwiLS8hLbIDdHWpMScSP q46xnZZQhotuJMyct92qKwBbUgsM89Ez1v1WpQ1yGOEJb0hh+Low25BCg3gOb1IbEt9xyXVreox AesWIu5QOjnzgpYgZfeOcjrQ+lWMHea5VJAJybWBC9iYG/uHkWEddDOMJ6KLg8jAABZp1ZqJQ2C UwielaYhv5dLOnqB7xseAdQWrU1Q3dSTFQB6WR8O+Y/nJzc93K+/Q2WsCHjUBFCDb1TMj5SngYX h3xHbrgKHrW1b3tYym2UyPuOmUY0qq1kmXV78zDFL7l7K5yzA4Y= X-Received: by 2002:a05:620a:2714:b0:7e3:2aea:8d33 with SMTP id af79cd13be357-7e342a6009fmr1419068785a.6.1752846394248; Fri, 18 Jul 2025 06:46:34 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEDCBe54fcGGk9PLCyaCqsHRVz3x2iaTCB5BZIUEh76gcsv0wn609mFpmUWxohyR2tmrHQQWw== X-Received: by 2002:a05:620a:2714:b0:7e3:2aea:8d33 with SMTP id af79cd13be357-7e342a6009fmr1419066185a.6.1752846393872; Fri, 18 Jul 2025 06:46:33 -0700 (PDT) Received: from ?IPV6:2804:14d:8084:9a69::1000? ([2804:14d:8084:9a69::1000]) by smtp.gmail.com with ESMTPSA id af79cd13be357-7e356b46a89sm86662885a.37.2025.07.18.06.46.31 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 18 Jul 2025 06:46:33 -0700 (PDT) Message-ID: Date: Fri, 18 Jul 2025 10:46:30 -0300 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH 2/3] gdb, amd64: return after amd64_analyze_frame_setup if current_pc reached To: Pawel Kupczak , gdb-patches@sourceware.org References: <20250701104759.52595-1-pawel.kupczak@intel.com> <20250701104759.52595-3-pawel.kupczak@intel.com> From: Guinevere Larsen In-Reply-To: <20250701104759.52595-3-pawel.kupczak@intel.com> X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: NegfrWMuCawRLVZ5y7XI7o3fn9xmR9Z1WO2J9u6JveQ_1752846394 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-BeenThere: gdb-patches@sourceware.org X-Mailman-Version: 2.1.30 Precedence: list List-Id: Gdb-patches mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: gdb-patches-bounces~public-inbox=simark.ca@sourceware.org On 7/1/25 7:47 AM, Pawel Kupczak wrote: > Make sure the function bails out early if CURRENT_PC is reached, to > avoid the call to amd64_analyze_register_saves. This patch is simple enough that I personally don't think it needs to be separate, it could be sent with the previous one. If you (or someone else who ends up reviewing this series) would prefer it to be separate, though, feel free to add my tag Reviewed-By: Guinevere Larsen -- Cheers, Guinevere Larsen She/Her/Hers > --- > gdb/amd64-tdep.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/gdb/amd64-tdep.c b/gdb/amd64-tdep.c > index 863b29a8c27..e4eb076a55a 100755 > --- a/gdb/amd64-tdep.c > +++ b/gdb/amd64-tdep.c > @@ -2645,6 +2645,9 @@ amd64_analyze_prologue (gdbarch *gdbarch, CORE_ADDR pc, CORE_ADDR current_pc, > return current_pc; > > pc = amd64_analyze_frame_setup (gdbarch, pc, current_pc, cache); > + if (current_pc <= pc) > + return current_pc; > + > return amd64_analyze_register_saves (pc, current_pc, cache); > } >