From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 16227 invoked by alias); 23 Apr 2010 14:33:34 -0000 Received: (qmail 16208 invoked by uid 22791); 23 Apr 2010 14:33:32 -0000 X-SWARE-Spam-Status: No, hits=-1.9 required=5.0 tests=BAYES_00 X-Spam-Check-By: sourceware.org Received: from rock.gnat.com (HELO rock.gnat.com) (205.232.38.15) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 23 Apr 2010 14:33:28 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by filtered-rock.gnat.com (Postfix) with ESMTP id D99912BABE2; Fri, 23 Apr 2010 10:33:26 -0400 (EDT) Received: from rock.gnat.com ([127.0.0.1]) by localhost (rock.gnat.com [127.0.0.1]) (amavisd-new, port 10024) with LMTP id T4Dt-5x+fkp5; Fri, 23 Apr 2010 10:33:26 -0400 (EDT) Received: from joel.gnat.com (localhost.localdomain [127.0.0.1]) by rock.gnat.com (Postfix) with ESMTP id C14BC2BAB9A; Fri, 23 Apr 2010 10:33:26 -0400 (EDT) Received: by joel.gnat.com (Postfix, from userid 1000) id 7CFF1F5895; Fri, 23 Apr 2010 07:33:26 -0700 (PDT) Date: Fri, 23 Apr 2010 14:33:00 -0000 From: Joel Brobecker To: Jerome Guitton Cc: gdb-patches@sourceware.org Subject: Re: [RFA] Alpha/Tru64 maximum debuggable stack frame size Message-ID: <20100423143326.GN19194@adacore.com> References: <1271951672-23382-1-git-send-email-guitton@adacore.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1271951672-23382-1-git-send-email-guitton@adacore.com> User-Agent: Mutt/1.5.20 (2009-06-14) 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: 2010-04/txt/msg00790.txt.bz2 > 2010-04-22 Jerome Guitton > > * alpha-tdep.c (INSN_OPCODE, MEM_RA, MEM_RB, MEM_DISP, BR_RA) > (OPR_FUNCTION, OPR_HAS_IMMEDIATE, OPR_RA, OPR_RC, OPR_LIT): New macros. > (lda_opcode, stq_opcode, bne_opcode, subq_opcode, subq_function): > New constants. > (alpha_heuristic_analyze_probing_loop): New function. > (alpha_heuristic_frame_unwind_cache): In the prologue analysis, detect > and handle cases when a stack probe loop is generated. > * alpha-mdebug-tdep.c (alpha_mdebug_frameless): New function. > (alpha_mdebug_max_frame_size_exceeded): New function. > (alpha_mdebug_after_prologue): Use alpha_mdebug_frameless. > (alpha_mdebug_frame_sniffer, alpha_mdebug_frame_base_sniffer): > Return 0 when the maximum debuggable frame size has been exceeded. OK, with a few little corrections... > +/* Return a non-null result if the function is frameless; zero otherwise. */ ^^^^ Can you use zero instead of null when you mean integer 0. I noticed a few places where this needs to be adjusted... > + return PROC_FRAME_REG (proc_desc) == ALPHA_SP_REGNUM > + && PROC_FRAME_OFFSET (proc_desc) == 0; Can you add parentheses around the condition. It's not strictly necessary, but it's part of the GNU style, because it helps code automatic formatters such as GNU indent. return (PROC_FRAME_REG (proc_desc) == ALPHA_SP_REGNUM && PROC_FRAME_OFFSET (proc_desc) == 0); > + return PROC_FRAME_OFFSET (proc_desc) == 0 > + && !alpha_mdebug_frameless (proc_desc); Same here, please. > +/* Instruction decoding. The notations for registers, immediates and opcodes Missing second space after first period. > + If anything different is found, the function returns without > + changing PC and FRAME_SIZE. Otherwise, PC will point immediately Likewise here. -- Joel