This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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: dlmopen and core dumps


On Wed, 19 Dec 2012 19:20:34 +0100, Carlos O'Donell wrote:
> On 12/19/2012 01:05 PM, Jan Kratochvil wrote:
> > Python is needlessly expensive.  There does not exist only GDB, there exist
> > other smaller tools examining external programs which can for example run on
> > embedded targets.
> 
> Do you have examples of such tools that I can go look at?

No.  I have for example something for libthread_db but not for r_debug.


> Could you please explain in more detail what you mean by python
> compatibility issues?

I have tried now for example OpenSolaris where it works but I guess on some
QNX or old FreeBSD etc. it may fail to build.  I have not spend the time
trying to find some unusual enough OS to prove the Python package may fail to
build there.


> Note that it was not stated in the original requirements that the
> solution must be usable on every host that GDB and other tools
> support. Such a requirement is pretty broad and doesn't lend itself
> well to an initial implementation.
> 
> Even if that were the case I'm pretty sure I've seen python support
> for all GNU/Linux targets (and other non-Linux ones too) that gdb
> supports. Should we consider embedded systems there is the ability
> to use PyMite and Tiny Python on those systems. We might need to
> limit ourselves to Python 2.5.

DWARF expression evaluator is some 3 screens of C code. Compare that to 11MB
sources and 2MB binary for the Python interpreter.  All just to execute about
2 operations such as an addition and dereference.

Both the ld.so and the few programs introspecing ld.so are generally written
by people who know the DWARF stack language and stack languages in general.
Also the code being executed will be just several opcodes so it is also not
difficult to code it in any unusual stack language like the DWARF one is.


Jan


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