This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
Re: [RFA] Assuming malloc exists in callfwmall.exp
On Feb 14, 4:28pm, Elena Zannoni wrote:
> > OTOH, given that GDB's mechanism for performing these tests is to
> > use malloc(), I'm not sure how these are supposed to succeed. (As
> > someone else pointed out, they do succeed on some platforms because
> > malloc() sneaks into the picture through the dynamic loader.)
> >
> > Does anyone know of any host/target combinations which manage to pass
> > these tests without using malloc()?
>
> HPUX should pass. That's why those tests were added in the first
> place, I think.
Do you have any idea how this functionality is implemented?
There are a number of platforms which pass these tests, but only
because malloc() is sneaks in because it's required by the dynamic
linker. If HPUX passes for a similar reason, this is cheating. OTOH,
if the HPUX port uses some other mechanism entirely, it might be a
good idea for us to adapt this mechanism so that other targets can
use it too.
Kevin