From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24261 invoked by alias); 27 Jun 2002 18:08:36 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 24237 invoked from network); 27 Jun 2002 18:08:34 -0000 Received: from unknown (HELO harvester.transas.com) (193.125.200.2) by sources.redhat.com with SMTP; 27 Jun 2002 18:08:34 -0000 Received: from localhost (localhost [127.0.0.1]) by harvester.transas.com (Postfix) with SMTP id 9A8B86B821; Thu, 27 Jun 2002 22:08:32 +0400 (MSD) Received: from clue.transas.com (clue.transas.com [10.0.0.42]) by harvester.transas.com (Postfix) with ESMTP id 604AD6B820; Thu, 27 Jun 2002 22:08:32 +0400 (MSD) Received: by clue.transas.com with Internet Mail Service (5.5.2653.19) id ; Thu, 27 Jun 2002 22:08:32 +0400 Message-ID: <2E74F312D6980D459F3A05492BA40F8DFE33AA@clue.transas.com> From: Andrew Volkov To: Daniel Jacobowitz Cc: gdb-patches@sources.redhat.com, jimb@redhat.com, ezannoni@redhat.com Subject: RE: [RFA/RFC] blockframe.c Fix errorneous addr check Date: Thu, 27 Jun 2002 11:08:00 -0000 MIME-Version: 1.0 Content-Type: text/plain; charset="koi8-r" X-SW-Source: 2002-06/txt/msg00557.txt.bz2 >On Thu, Jun 27, 2002 at 09:13:41PM +0400, Andrew Volkov wrote: >> Hi, >> >> This patch fix wrong detection of belonging addr to startup file: >> if call main is last instuction in crt0, then >> inside_entry_file erroneously return false. >> >> Ok to commit? >> Andrey >> >> P.S. Possible this bug not in this func, but in symbol reader. > >I'm inclined to believe the bug is in the symbol reader. Upper PC >bounds are generally exclusive - first address after the function. > >-- >Daniel Jacobowitz Carnegie Mellon University >MontaVista Software Debian GNU/Linux Developer > Daniel you're right, this bug in coffread.c(complete_symtab) function, rather, in invalid calculating of current_source_end_addr: current_source_end_addr = start_addr + size; but must be: current_source_end_addr = start_addr + size + ; As I understand, since machine address size is not known at time of parsing coff file, then we have big trouble :(. Comments/suggestions? Andrey