This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFA] Dwarf2 fix


Michal Ludvig <mludvig@suse.cz> writes:

> Hi all,
> this simple patch mysteriously solves problems that we have had on
> x86-64 with stack unwinding. Can I commit? I believe so :-)

What about committing to the 5.2 branch?  Is a 5.2.1 planned?


>
> 2002-05-13  Michal Ludvig  <mludvig@suse.cz>
>          * dwarf2cfi.c (context_cpy): Copy registers correctly.
>          (update_context): Use __func__ in notes.
>
> Index: dwarf2cfi.c
> ===================================================================
> RCS file: /cvs/src/src/gdb/dwarf2cfi.c,v
> retrieving revision 1.4
> diff -c -3 -p -r1.4 dwarf2cfi.c
> *** dwarf2cfi.c 7 May 2002 11:22:54 -0000       1.4
> --- dwarf2cfi.c 13 May 2002 16:24:00 -0000
> *************** static void
> *** 318,325 ****
> --- 318,329 ----
>    context_cpy (struct context *dst, struct context *src)
>    {
>      int regs_size = sizeof (struct context_reg) * NUM_REGS;
> +   struct context_reg *dreg;
>
> +   dreg = dst->reg;
>      *dst = *src;
> +   dst->reg = dreg;
> +

Can you add a comment here, why this is needed?

>      memcpy (dst->reg, src->reg, regs_size);

>    }
>[...]

Thanks,
Andreas
-- 
 Andreas Jaeger
  SuSE Labs aj@suse.de
   private aj@arthur.inka.de
    http://www.suse.de/~aj


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]