[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: implementation dependent bytecodes
Soot doesn't output bytecode. Soot outputs Jasmin, which is an
assembly-like representation of bytecode. So, you would have to modify
Jasmin, not Soot, to output any non-standard bytecodes. Depending on
how complicated your insertion code is, if you wanted to insert things
at the Jimple or Baf level instead of in Jasmin (which is essentially
bytecode, only human-readable), you would have to add the corresponding
instructions to those IRs, and any code manipulating those IRs (ie. for
Jimple, that's most of Soot).
I agree with Etienne: attributes are way easier, and they won't break
your code on other VMs. But again, if your instructions do something
that will break the code if it's not done, then attributes won't help
make your code work on other VMs.
So, it all depends on what your instructions are supposed to do.
Ondrej
On Sun, Mar 16, 2003 at 10:22:04AM -0500, Chris Pickett wrote:
> Hi,
>
> I want to use Soot to insert impdep1 (254) and impdep2 (255) bytecodes
> into a class file for use by SableVM.
>
> How can I do this?
>
> Cheers,
> Chris
>