This is the mail archive of the gdb-patches@sourceware.org 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: [patch] [i386] Put hlt at the ON_STACK breakpoint [Re: GDB 7.4.91 available for testing]


On Mon, 23 Jul 2012 22:07:27 +0200, Philippe Waroquiers wrote:
> Note that the trap instruction should only be written by the
> push_dummy_code function : for Normal breakpoints, only a Z0 packet
> should be done, as Valgrind will not allow to modify the guest
> executable code (it is not mapped writable). 

I do not understand now what is and what is not allowed for valgrind to write.

For the inferior call to work at all you have to create the stack frame for
it, otherwise it cannot work, at least for parameters passed by stack.

So the GDB patch is no longer needed when you have fixed valgrind to put 0xcc
during Z0? Why valgrind cannot write 0xcc into stack memory when it already
has to write there to create the stack frame / parameters passed by stack?

(Yes, I should read valgrind source code instead.)

IIUC the 'hlt' cleanup patch can go only for 7.6 as 7.5 should not regress
with new/fixed valgrind.


Thanks,
Jan


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