From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2124 invoked by alias); 27 Nov 2011 14:38:39 -0000 Received: (qmail 2114 invoked by uid 22791); 27 Nov 2011 14:38:38 -0000 X-SWARE-Spam-Status: No, hits=-0.7 required=5.0 tests=AWL,BAYES_40,RCVD_IN_DNSWL_LOW,SPF_SOFTFAIL,TW_BJ,TW_ZJ X-Spam-Check-By: sourceware.org Received: from mail-iy0-f169.google.com (HELO mail-iy0-f169.google.com) (209.85.210.169) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Sun, 27 Nov 2011 14:38:23 +0000 Received: by iaek3 with SMTP id k3so9468529iae.0 for ; Sun, 27 Nov 2011 06:38:23 -0800 (PST) Received: by 10.50.213.6 with SMTP id no6mr49498527igc.51.1322404703208; Sun, 27 Nov 2011 06:38:23 -0800 (PST) Received: from [127.0.0.1] ([203.110.240.205]) by mx.google.com with ESMTPS id p16sm32298274ibk.6.2011.11.27.06.38.19 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 27 Nov 2011 06:38:22 -0800 (PST) Message-ID: <4ED24C58.1090300@playingwithpointers.com> Date: Sun, 27 Nov 2011 14:38:00 -0000 From: Sanjoy Das User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.24) Gecko/20111114 Icedove/3.1.16 MIME-Version: 1.0 To: Jan Kratochvil CC: gdb-patches@sourceware.org, Stan Shebs Subject: Re: Regression for gdb.base/jit.exp and gdb.base/jit-so.exp [Re: JIT Interface Patches Landed] References: <4EC8D2D4.1080402@playingwithpointers.com> <4EC9CE39.40604@earthlink.net> <20111126002251.GA5257@host1.jankratochvil.net> <4ED0E6F9.8090101@playingwithpointers.com> <20111127105332.GA25259@host1.jankratochvil.net> <4ED249CA.705@playingwithpointers.com> <20111127143036.GA32565@host1.jankratochvil.net> In-Reply-To: <20111127143036.GA32565@host1.jankratochvil.net> Content-Type: multipart/mixed; boundary="------------090800060509040501090902" 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: 2011-11/txt/msg00732.txt.bz2 This is a multi-part message in MIME format. --------------090800060509040501090902 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-length: 226 > Could you post to gdb-patches when the checked in version has not been posted > here yet? Attached. I skipped the patch because it is already there at gdb-patches. :) Thanks! -- Sanjoy Das http://playingwithpointers.com --------------090800060509040501090902 Content-Type: text/x-diff; name="patch.diff" Content-Transfer-Encoding: 8bit Content-Disposition: attachment; filename="patch.diff" Content-length: 2757 =================================================================== RCS file: /cvs/src/src/gdb/ChangeLog,v retrieving revision 1.13552 retrieving revision 1.13553 diff -u -r1.13552 -r1.13553 --- src/gdb/ChangeLog 2011/11/25 17:05:36 1.13552 +++ src/gdb/ChangeLog 2011/11/27 14:26:05 1.13553 @@ -1,3 +1,10 @@ +2011-11-27 Sanjoy Das + + Fix regression in jit.exp. + * jit.c (jit_reader_try_read_symtab, jit_bfd_try_read_symtab) + (jit_register_code): Set the jit_objfile_data field to the correct + value. + 2011-11-25  Uros Bizjak  * alpha-tdep.c (br_opcode): New. =================================================================== RCS file: /cvs/src/src/gdb/jit.c,v retrieving revision 1.21 retrieving revision 1.22 diff -u -r1.21 -r1.22 --- src/gdb/jit.c 2011/11/20 09:18:48 1.21 +++ src/gdb/jit.c 2011/11/27 14:26:09 1.22 @@ -710,10 +710,13 @@ xfree (obj); } -/* Try to read CODE_ENTRY using the loaded jit reader (if any). */ +/* Try to read CODE_ENTRY using the loaded jit reader (if any). + ENTRY_ADDR is the address of the object file (in the target's + address space) being read. */ static int -jit_reader_try_read_symtab (struct jit_code_entry *code_entry) +jit_reader_try_read_symtab (struct jit_code_entry *code_entry, + CORE_ADDR entry_addr) { void *gdb_mem; int status; @@ -735,7 +738,7 @@ &priv_data }; - priv_data = code_entry->symfile_addr; + priv_data = entry_addr; if (!loaded_jit_reader) return 0; @@ -765,10 +768,12 @@ return status; } -/* Try to read CODE_ENTRY using BFD. */ +/* Try to read CODE_ENTRY using BFD. ENTRY_ADDR is the address of the + object file (in the target's address space) being read. */ static void jit_bfd_try_read_symtab (struct jit_code_entry *code_entry, + CORE_ADDR entry_addr, struct gdbarch *gdbarch) { bfd *nbfd; @@ -832,7 +837,7 @@ objfile = symbol_file_add_from_bfd (nbfd, 0, sai, OBJF_SHARED, NULL); do_cleanups (old_cleanups); - add_objfile_entry (objfile, code_entry->symfile_addr); + add_objfile_entry (objfile, entry_addr); } /* This function registers code associated with a JIT code entry. It uses the @@ -855,10 +860,10 @@ paddress (gdbarch, code_entry->symfile_addr), pulongest (code_entry->symfile_size)); - success = jit_reader_try_read_symtab (code_entry); + success = jit_reader_try_read_symtab (code_entry, entry_addr); if (!success) - jit_bfd_try_read_symtab (code_entry, gdbarch); + jit_bfd_try_read_symtab (code_entry, entry_addr, gdbarch); } /* This function unregisters JITed code and frees the corresponding --------------090800060509040501090902--