1 /** 2 * Some instructions are perniticky enough that its simpler 3 * to write them separately instead of smushing them with 4 * all the rest. the iinc instruction is one of them. 5 * @author $Author: fqian $ 6 * @version $Revision: 1.1 $ 7 */ 8 9 package jas; 10 11 import java.io.*; 12 13 14 public class IincInsn extends Insn implements RuntimeConstants 15 { 16 /** 17 * @param vindex Index of variable to be incremented. 18 * @param increment value to be added to the variable. 19 * 20 * A wide prefix is automatically added if either the 21 * vindex exceeds 256, or the increment value lies 22 * outside the range [-128, 127] 23 * 24 * The VM spec is unclear on how the wide instruction is implemented, 25 * but the implementation makes <em>both</em> the constant and the 26 * variable index 16 bit values for the wide version of this instruction. 27 */ 28 public IincInsn(int vindex, int increment) 29 { 30 opc = opc_iinc; 31 operand = new IincOperand(vindex, increment); 32 } 33 } 34