Re: GDB testsuite: »Memory at address 0 is possibly executable«

2014-09-13 Thread Samuel Thibault
Richard Braun, le Sat 13 Sep 2014 10:13:48 +0200, a écrit : > (with the interesting addition that, if MAP_FIXED isn't set, > but the hint is non-zero, the returned mapping must not start at > address 0). Well, it's not easy to implement this, since vm_map is generic, and could be used for other ki

Re: GDB testsuite: »Memory at address 0 is possibly executable«

2014-09-13 Thread Richard Braun
On Sat, Sep 13, 2014 at 01:39:05AM +0200, Samuel Thibault wrote: > So it seems we need what is not actually documented, i.e. a vm_map > with anywhere=1, but which takes into account the suggested address. > I'm fine with officially supporting that, we just need to fix the > documentation, and fix a

Re: GDB testsuite: »Memory at address 0 is possibly executable«

2014-09-13 Thread Samuel Thibault
Samuel Thibault, le Sat 13 Sep 2014 09:54:56 +0200, a écrit : > I've dug a bit more, glibc's _hurd_startup reserves page 0, so no vm_map > or vm_allocate call should be allocating at address 0. But with the > change, address 0 is already taken by the first mapped binary, ld.so. I > guess exec needs

Re: GDB testsuite: »Memory at address 0 is possibly executable«

2014-09-13 Thread Samuel Thibault
Justus Winter, le Sat 13 Sep 2014 02:40:17 +0200, a écrit : > Quoting Samuel Thibault (2014-09-13 01:39:05) > > So it seems we need what is not actually documented, i.e. a vm_map > > with anywhere=1, but which takes into account the suggested address. > > I'm fine with officially supporting that, w

Re: GDB testsuite: »Memory at address 0 is possibly executable«

2014-09-12 Thread Justus Winter
Quoting Samuel Thibault (2014-09-13 01:39:05) > So it seems we need what is not actually documented, i.e. a vm_map > with anywhere=1, but which takes into account the suggested address. > I'm fine with officially supporting that, we just need to fix the > documentation, I'm sorry, I'm lost. What

Re: GDB testsuite: »Memory at address 0 is possibly executable«

2014-09-12 Thread Samuel Thibault
(Just to be clear: I don't think the fix proposed by Justus initially is correct: it was essentially making applications with random addresses actually get to have their map done starting from address 0, but we really ought to rather fix their randomness directly) Samuel

Re: GDB testsuite: »Memory at address 0 is possibly executable«

2014-09-12 Thread Samuel Thibault
Mmm. So it seems we need what is not actually documented, i.e. a vm_map with anywhere=1, but which takes into account the suggested address. I'm fine with officially supporting that, we just need to fix the documentation, and fix all places which weren't aware of this behavior (there are very few)

Re: GDB testsuite: »Memory at address 0 is possibly executable«

2014-09-12 Thread Justus Winter
Hi :) Quoting Thomas Schwinge (2014-09-11 16:23:04) > $ ldd /bin/true > libc.so.0.3 => /lib/i386-gnu/libc.so.0.3 (0x0103a000) > /lib/ld.so => /lib/ld.so.1 (0x) > libmachuser.so.1 => /lib/i386-gnu/libmachuser.so.1 (0x011fa000) > libhurduse

GDB testsuite: »Memory at address 0 is possibly executable«

2014-09-11 Thread Thomas Schwinge
Hi! I've noticed that you guys have recently done some changes in GNU Mach's vm_map or thereabouts, and -- I presume -- that is affecting the GDB testsuite in that tests that used to PASS are now no longer considered for execution, because »Memory at address 0 is possibly executable«: # If we