On 07/03/13 19:51, Jeff Epler wrote: > On Thu, Mar 07, 2013 at 05:49:55PM +0100, Petr Salinger wrote: >>>> Valgrind does appear to be aware of sysarch, implementing >>>> sysarch(AMD64_SET_FSBASE) in >>>> coregrind/m_syswrap/syswrap-amd64-freebsd.c. >>> >>> Aha. eglibc is testing that the syscall succeeds, which is indicated by >>> setting RAX to 0. >> >> The standard kernel in a success case sets RAX to zero >> and clears carry flag. In error case the carry flag is set >> and RAX contains error number. >>t >> It probably should be >> >> SET_STATUS_Success2((0L, tst->arch.vex.guest_RDX ); > > As you suggest, this change also works (replacement of my earlier change, not > cumulative with it): > > - SET_STATUS_Success2((ULong)*p, tst->arch.vex.guest_RDX ); > + SET_STATUS_Success2(0, tst->arch.vex.guest_RDX ); > > Jeff > Wow! You are a genius :) I confirm that it works perfectly with any of the changes proposed. Thanks! I'm not sure if this means that we can finally have valgrind packaged for Debian/kFreeBSD. The diffstat between "official" valgrind and this freebsd port is pretty big. Could something like a new "valgrind-bsd" package based on this valgrind-freebsd port be allowed on the archives? Regards!
Attachment:
signature.asc
Description: OpenPGP digital signature