From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17784 invoked by alias); 8 May 2003 23:32:21 -0000 Mailing-List: contact insight-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: insight-owner@sources.redhat.com Received: (qmail 17772 invoked from network); 8 May 2003 23:32:21 -0000 Received: from unknown (HELO localhost.redhat.com) (207.219.125.105) by sources.redhat.com with SMTP; 8 May 2003 23:32:21 -0000 Received: from redhat.com (localhost [127.0.0.1]) by localhost.redhat.com (Postfix) with ESMTP id 99E002B2F for ; Thu, 8 May 2003 19:32:18 -0400 (EDT) Message-ID: <3EBAE902.2050403@redhat.com> Date: Thu, 08 May 2003 23:32:00 -0000 From: Andrew Cagney User-Agent: Mozilla/5.0 (X11; U; NetBSD macppc; en-US; rv:1.0.2) Gecko/20030223 X-Accept-Language: en-us, en MIME-Version: 1.0 To: insight@sources.redhat.com Subject: [commit] Update insight for MAX_REGISTER_SIZE Content-Type: multipart/mixed; boundary="------------060308050601080502010401" X-SW-Source: 2003-q2/txt/msg00073.txt.bz2 This is a multi-part message in MIME format. --------------060308050601080502010401 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Content-length: 79 FYI, this should fix the build problem with *REGISTER*SIZE. committed, Andrew --------------060308050601080502010401 Content-Type: text/plain; name="diffs" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="diffs" Content-length: 2167 2003-05-08 Andrew Cagney * generic/gdbtk-register.c (get_register): Replace MAX_REGISTER_VIRTUAL_SIZE and MAX_REGISTER_RAW_SIZE with MAX_REGISTER_SIZE. (register_changed_p, setup_architecture_data): Ditto. Index: generic/gdbtk-register.c =================================================================== RCS file: /cvs/src/src/gdb/gdbtk/generic/gdbtk-register.c,v retrieving revision 1.17 diff -u -r1.17 gdbtk-register.c --- generic/gdbtk-register.c 25 Mar 2003 01:03:42 -0000 1.17 +++ generic/gdbtk-register.c 8 May 2003 23:11:50 -0000 @@ -265,8 +265,8 @@ CORE_ADDR addr; enum lval_type lval; struct type *reg_vtype; - char *raw_buffer = alloca (MAX_REGISTER_RAW_SIZE); - char *virtual_buffer = alloca (MAX_REGISTER_VIRTUAL_SIZE); + char raw_buffer[MAX_REGISTER_SIZE]; + char virtual_buffer[MAX_REGISTER_SIZE]; int optim, format; struct cleanup *old_chain = NULL; struct ui_file *stb; @@ -439,19 +439,19 @@ static void register_changed_p (int regnum, void *argp) { - char *raw_buffer = alloca (MAX_REGISTER_RAW_SIZE); + char raw_buffer[MAX_REGISTER_SIZE]; if (deprecated_selected_frame == NULL || !frame_register_read (deprecated_selected_frame, regnum, raw_buffer)) return; - if (memcmp (&old_regs[regnum * MAX_REGISTER_RAW_SIZE], raw_buffer, + if (memcmp (&old_regs[regnum * MAX_REGISTER_SIZE], raw_buffer, REGISTER_RAW_SIZE (regnum)) == 0) return; /* Found a changed register. Save new value and return its number. */ - memcpy (&old_regs[regnum * MAX_REGISTER_RAW_SIZE], raw_buffer, + memcpy (&old_regs[regnum * MAX_REGISTER_SIZE], raw_buffer, REGISTER_RAW_SIZE (regnum)); Tcl_ListObjAppendElement (NULL, result_ptr->obj_ptr, Tcl_NewIntObj (regnum)); @@ -464,7 +464,7 @@ xfree (regformat); xfree (regtype); - old_regs = xcalloc (1, (NUM_REGS + NUM_PSEUDO_REGS) * MAX_REGISTER_RAW_SIZE + 1); + old_regs = xcalloc (1, (NUM_REGS + NUM_PSEUDO_REGS) * MAX_REGISTER_SIZE + 1); regformat = (int *)xcalloc ((NUM_REGS + NUM_PSEUDO_REGS) , sizeof(int)); regtype = (struct type **)xcalloc ((NUM_REGS + NUM_PSEUDO_REGS), sizeof(struct type **)); } --------------060308050601080502010401--