|
From: <sv...@va...> - 2014-09-06 19:30:02
|
Author: mjw
Date: Sat Sep 6 19:29:51 2014
New Revision: 14484
Log:
readstabs.c: Don't include a.out.h, just define the stabs symbol nlist entry.
readstabs.c tries to include a.out.h to get the stabs symbol list entry
definition. STABS isn't specifically tied to the a.out format though.
The symbol entry structure just happens to be defined in the a.out.h
header. The header isn't really standard though. It might be provided
by glibc or the kernel in different locations. And not all arches support
the a.out format so the header might not even exist. Just define the
needed nlist struct entry directly in readstabs.c for VGO_linux. All
arches in glibc and the kernel use the same one anyway.
Modified:
trunk/coregrind/m_debuginfo/readstabs.c
Modified: trunk/coregrind/m_debuginfo/readstabs.c
==============================================================================
--- trunk/coregrind/m_debuginfo/readstabs.c (original)
+++ trunk/coregrind/m_debuginfo/readstabs.c Sat Sep 6 19:29:51 2014
@@ -55,7 +55,18 @@
/* --- !!! --- EXTERNAL HEADERS start --- !!! --- */
#if defined(VGO_linux)
-# include <a.out.h> /* stabs defns */
+/* stabs symbol list entry definition. */
+struct nlist {
+ union {
+ char *n_name;
+ struct nlist *n_next;
+ long n_strx;
+ } n_un;
+ unsigned char n_type;
+ char n_other;
+ short n_desc;
+ unsigned long n_value;
+};
#elif defined(VGO_darwin)
# include <mach-o/nlist.h>
# define n_other n_sect
|
|
From: Philippe W. <phi...@sk...> - 2014-09-07 11:13:36
|
The stabs reader is disabled since 3.9.0 (as it was not converted
to use the new image/di-server).
We however still compile the (I think) broken code.
Maybe we should just remove it ?
Philippe
On Sat, 2014-09-06 at 19:29 +0000, sv...@va... wrote:
> Author: mjw
> Date: Sat Sep 6 19:29:51 2014
> New Revision: 14484
>
> Log:
> readstabs.c: Don't include a.out.h, just define the stabs symbol nlist entry.
>
> readstabs.c tries to include a.out.h to get the stabs symbol list entry
> definition. STABS isn't specifically tied to the a.out format though.
> The symbol entry structure just happens to be defined in the a.out.h
> header. The header isn't really standard though. It might be provided
> by glibc or the kernel in different locations. And not all arches support
> the a.out format so the header might not even exist. Just define the
> needed nlist struct entry directly in readstabs.c for VGO_linux. All
> arches in glibc and the kernel use the same one anyway.
>
> Modified:
> trunk/coregrind/m_debuginfo/readstabs.c
>
> Modified: trunk/coregrind/m_debuginfo/readstabs.c
> ==============================================================================
> --- trunk/coregrind/m_debuginfo/readstabs.c (original)
> +++ trunk/coregrind/m_debuginfo/readstabs.c Sat Sep 6 19:29:51 2014
> @@ -55,7 +55,18 @@
>
> /* --- !!! --- EXTERNAL HEADERS start --- !!! --- */
> #if defined(VGO_linux)
> -# include <a.out.h> /* stabs defns */
> +/* stabs symbol list entry definition. */
> +struct nlist {
> + union {
> + char *n_name;
> + struct nlist *n_next;
> + long n_strx;
> + } n_un;
> + unsigned char n_type;
> + char n_other;
> + short n_desc;
> + unsigned long n_value;
> +};
> #elif defined(VGO_darwin)
> # include <mach-o/nlist.h>
> # define n_other n_sect
>
>
> ------------------------------------------------------------------------------
> Slashdot TV.
> Video for Nerds. Stuff that matters.
> http://tv.slashdot.org/
> _______________________________________________
> Valgrind-developers mailing list
> Val...@li...
> https://lists.sourceforge.net/lists/listinfo/valgrind-developers
|
|
From: Mark W. <mj...@re...> - 2014-09-07 12:25:52
|
On Sun, Sep 07, 2014 at 01:13:28PM +0200, Philippe Waroquiers wrote: > The stabs reader is disabled since 3.9.0 (as it was not converted > to use the new image/di-server). > We however still compile the (I think) broken code. > Maybe we should just remove it ? Haha. I was a little suspecious I couldn't find any tests for the code. So checked and double checked this was the right definition to use for the stabs symbol nlist entry struct. Now I know the real reason why everything seemed to go fine :) So yeah, lets just remove the code before others accidentially spend any more time on it. Cheers, Mark |
|
From: Philippe W. <phi...@sk...> - 2014-09-07 12:33:01
|
On Sun, 2014-09-07 at 14:25 +0200, Mark Wielaard wrote: > On Sun, Sep 07, 2014 at 01:13:28PM +0200, Philippe Waroquiers wrote: > > The stabs reader is disabled since 3.9.0 (as it was not converted > > to use the new image/di-server). > > We however still compile the (I think) broken code. > > Maybe we should just remove it ? > > Haha. I was a little suspecious I couldn't find any tests for the > code. So checked and double checked this was the right definition > to use for the stabs symbol nlist entry struct. Now I know the real > reason why everything seemed to go fine :) > > So yeah, lets just remove the code before others accidentially > spend any more time on it. Julian also thinks the code can be removed, but better done after the release, to avoid any kind of build/whatever problems. Philippe |
|
From: Mark W. <mj...@re...> - 2014-09-18 12:27:06
|
On Sun, 2014-09-07 at 14:32 +0200, Philippe Waroquiers wrote: > On Sun, 2014-09-07 at 14:25 +0200, Mark Wielaard wrote: > > On Sun, Sep 07, 2014 at 01:13:28PM +0200, Philippe Waroquiers wrote: > > > The stabs reader is disabled since 3.9.0 (as it was not converted > > > to use the new image/di-server). > > > We however still compile the (I think) broken code. > > > Maybe we should just remove it ? > > > > Haha. I was a little suspecious I couldn't find any tests for the > > code. So checked and double checked this was the right definition > > to use for the stabs symbol nlist entry struct. Now I know the real > > reason why everything seemed to go fine :) > > > > So yeah, lets just remove the code before others accidentially > > spend any more time on it. > Julian also thinks the code can be removed, but better done after > the release, to avoid any kind of build/whatever problems. There was indeed a non-trivial amount of code that tried to do something STABS (and then actually didn't do anything). Since we are after the release now finally tried to clean this up and removed the dead code. See valgrind svn r14550. Please yell and scream if I accidentally broke something. Cheers, Mark |