This is the mail archive of the
mailing list for the GDB project.
Re: [02/15] Python interpreter callback functions
- From: Tom Tromey <tromey at redhat dot com>
- To: "Ulrich Weigand" <uweigand at de dot ibm dot com>
- Cc: gdb-patches at sourceware dot org
- Date: Tue, 09 Jun 2009 11:59:07 -0600
- Subject: Re: [02/15] Python interpreter callback functions
- References: <200906091515.n59FFU04027588@d12av02.megacenter.de.ibm.com>
- Reply-to: tromey at redhat dot com
>>>>> "Ulrich" == Ulrich Weigand <firstname.lastname@example.org> writes:
Ulrich> If there's a more elegant way of passing this sort of
Ulrich> environmental information through the Python interpreter, I'd
Ulrich> appreciate any hints from the Python experts ;-)
I think this is ok as a default, but ideally the various Python
methods would take an optional architecture argument. That would mean
having some Python representation of the architecture.
I think any place that acquires the GIL should probably also set the
architecture. I noticed that gdbpy_new_objfile was not touched in
your patch; there may be other places as well. Perhaps all this work
could be done by a single convenience function, to make it harder to
forget in the future.
If we had some notion of the "host architecture", then stuff like
builtin_type_pyint could just use that instead. Those defines really
represent types on the host.