libunwind-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Libunwind-devel] Get Function Address Patch


From: David Mosberger-Tang
Subject: Re: [Libunwind-devel] Get Function Address Patch
Date: Thu, 23 Aug 2007 10:37:55 -0600

Jose,

Before we make a change, I'd like to understand what's wrong with the
existing code.  Could you please explain?

Thanks,

  --david

On 8/23/07, Jose Flavio Aguilar Paulino <address@hidden> wrote:
> On Wed, 2007-08-22 at 13:07 -0600, David Mosberger-Tang wrote:
> > Jose,
> >
> > I checked in a patch to support the tdep_get_func_addr() hook you
> > need.  I didn't check in the changes to the distance-checking so far.
> > Something seems fishy there.  In your patch, you check "cur_dist < 0",
> > but cur_dist is of type "Elf_W(Addr)", which should be an unsigned
> > type, AFAIK, so the check makes no sense.
>
> Sorry me David, what a wanted to was this:
> ...
> cur_dist = (Elf_W (Addr)) (ip - val);
> if (unlikely (val < ip))
>         continue;
> ...
> just a sanity/optimization check,
> but you are right I can't use the cur_dist value!
> Do you want to send a correct version of the patch?
>
> Thanks for reviewing it!
>
> --
> Jose Flavio Aguilar Paulino
> Toolchain Team
> Software Engineer
> IBM - Ltc Brazil
>
>


-- 
Mosberger Consulting LLC, http://www.mosberger-consulting.com/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]