You are viewing a plain text version of this content. The canonical link for it is here.
Posted to bcel-user@jakarta.apache.org by Steve Jones <st...@istech.demon.co.uk> on 2003/05/18 14:19:56 UTC

Adding labels to instruction lists

Hi,

I currently use a NOP instruction as a branch target.  I do a final fixup of 
the code by moving the branch targets to the instruction that follows the NOP 
and then remove the NOP. It works but it's messy.

Can anyone suggest a neat way of inserting code labels into an instruction 
list.  A sort of NOP that produces no opcode.

Cheers, Steve.


---------------------------------------------------------------------
To unsubscribe, e-mail: bcel-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: bcel-user-help@jakarta.apache.org


Re: Adding labels to instruction lists

Posted by Chris Nokleberg <ch...@sixlegs.com>.
Steve Jones wrote:
> Can anyone suggest a neat way of inserting code labels into an instruction 
> list.  A sort of NOP that produces no opcode.

Check out MethodGen.removeNOPs

BCEL will do it for you!

Chris



---------------------------------------------------------------------
To unsubscribe, e-mail: bcel-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: bcel-user-help@jakarta.apache.org