|
From: Naveen K. <g_n...@ya...> - 2005-07-26 13:45:23
|
No problem. There is no hurry. Take your time. For now I have modified vex so that sysenter instructions go through the int $0x91 syscall route. The following are system call paths supported on Solaris 10+ /* used by very old statically linked binaries */ lcall $0x07, $0x0 /* standard solaris syscall method. Now being phased out by the int $0xZZ path */ lcall $0x27, $0x0 /* To be standard on Solaris 11 onwards(in development) */ int $0x91 /* For solaris on intel pentiums that support it*/ sysenter /* For solaris on AMD */ syscall You can get an overview of this from a Sun Engineer's blog. http://blogs.sun.com/roller/page/rab Naveen --- Julian Seward <js...@ac...> wrote: > > I will deal with the int/sysenter stuff in vex for > you, but not until > after Valgrind 3.0 ships -- am v. busy. > > It would be helpful if you could send a summary of > what new int and > sysenter variants you need. > > J > > > On Friday 22 July 2005 18:54, you wrote: > > changes to vex that I had to make to get it > compiled > > on sol 10. > > > > -bash-3.00$ svn diff > > Index: priv/guest-x86/toIR.c > > > =================================================================== > > --- priv/guest-x86/toIR.c (revision 1290) > > +++ priv/guest-x86/toIR.c (working copy) > > @@ -10376,13 +10376,16 @@ > > > > case 0xCD: /* INT imm8 */ > > d32 = getIByte(delta); delta++; > > - if (d32 != 0x80) goto decode_failure; > > + if (d32 != 0x80 && d32 != 0x91) goto > > decode_failure; > > /* It's important that all ArchRegs carry > their > > up-to-date value > > at this point. So we declare an > > end-of-block here, which > > forces any TempRegs caching ArchRegs to > be > > flushed. */ > > > > > jmp_lit(Ijk_Syscall,((Addr32)guest_EIP_bbstart)+delta); > > dres.whatNext = Dis_StopHere; > > + if( d32 == 0x80 ) { > > DIP("int $0x80\n"); > > + } > > + else { DIP("int $0x91\n"); } > > break; > > > > /* ------------------------ Jcond, byte offset > > --------- */ > > Index: Makefile > > > =================================================================== > > --- Makefile (revision 1290) > > +++ Makefile (working copy) > > @@ -99,7 +99,7 @@ > > > > version: > > rm -f priv/main/vex_svnversion.h > > - echo -n "\"" > priv/main/vex_svnversion.h > > + echo "\"\c" > priv/main/vex_svnversion.h > > svnversion -n . >> > priv/main/vex_svnversion.h > > echo "\"" >> priv/main/vex_svnversion.h > > > > int $0x91 is the new syscall gate for sol 10 > > > > echo -n is not supported on all platforms(within > > Makefile). So we have to use the "\c" at the end. > > > > Naveen > > > > --- Julian Seward <js...@ac...> wrote: > > > > vex x86->IR: unhandled instruction bytes: 0xF8 > > > > > > 0x2A > > > > > > > 0x7 0x8B > > > > > > Fixed in vex r1284. The attached test program > > > should now > > > work properly. > > > > > > What is the current state of valgrind-3 on > > > x86-solaris? > > > > > > J > > > > > > > > > #include <stdio.h> > > > > > > int x0, x1, x2, x3, x4; > > > > > > extern void foo ( void ); > > > asm("\n" > > > ".global foo\n" > > > "foo:\n" > > > > > > "\txorl %eax,%eax\n" > > > "\tpushfl\n" > > > "\tpopl x0\n" > > > > > > "\tstc\n" > > > "\tpushfl\n" > > > "\tpopl x1\n" > > > > > > "\tclc\n" > > > "\tpushfl\n" > > > "\tpopl x2\n" > > > > > > "\tcmc\n" > > > "\tpushfl\n" > > > "\tpopl x3\n" > > > > > > "\tcmc\n" > > > "\tpushfl\n" > > > "\tpopl x4\n" > > > > > > "\tret\n" > > > ); > > > > > > > > > int main ( void ) > > > { > > > const int M = 0xFFFF; /* don't want to see the > ID > > > flag, bit 21 */ > > > foo(); > > > printf("0x%x 0x%x 0x%x 0x%x 0x%x\n", x0&M, > x1&M, > > > x2&M, x3&M, x4&M); > > > return 0; > > > } > > > > > ____________________________________________________ > > Start your day with Yahoo! - make it your home > page > > http://www.yahoo.com/r/hs > __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com |