3261N/A * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. 0N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 0N/A * This code is free software; you can redistribute it and/or modify it 0N/A * under the terms of the GNU General Public License version 2 only, as 2362N/A * published by the Free Software Foundation. Oracle designates this 0N/A * particular file as subject to the "Classpath" exception as provided 2362N/A * by Oracle in the LICENSE file that accompanied this code. 0N/A * This code is distributed in the hope that it will be useful, but WITHOUT 0N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 0N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 0N/A * version 2 for more details (a copy is included in the LICENSE file that 0N/A * accompanied this code). 0N/A * You should have received a copy of the GNU General Public License version 0N/A * 2 along with this work; if not, write to the Free Software Foundation, 0N/A * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 2362N/A * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 2362N/A * or visit www.oracle.com if you need additional information or have any 0N/A * See JVMS, chapter 6. 0N/A * <p><b>This is NOT part of any supported API. 0N/A * If you write code that depends on this, you do so at your own risk. 0N/A * This code and its internal interfaces are subject to change or 0N/A * deletion without notice.</b> 0N/A * @see Code_attribute#getInstructions 1999N/A /** The kind of an instruction, as determined by the position, size and 0N/A * types of its operands. */ 0N/A /** Opcode is not followed by any operands. */ 0N/A /** Opcode is followed by a byte indicating a type. */ 0N/A /** Opcode is followed by a 2-byte branch offset. */ 0N/A /** Opcode is followed by a 4-byte branch offset. */ 0N/A /** Opcode is followed by a signed byte value. */ 0N/A /** Opcode is followed by a 1-byte index into the constant pool. */ 1999N/A /** Opcode is followed by a 2-byte index into the constant pool. */ 0N/A /** Opcode is followed by a 2-byte index into the constant pool, 0N/A * an unsigned byte value. */ 0N/A /** Opcode is followed by a 2-byte index into the constant pool., 0N/A * an unsigned byte value, and a zero byte. */ 0N/A /** Opcode is followed by variable number of operands, depending 0N/A * on the instruction.*/ 0N/A /** Opcode is followed by a 1-byte reference to a local variable. */ 0N/A /** Opcode is followed by a 1-byte reference to a local variable, 0N/A * and a signed byte value. */ 0N/A /** Opcode is followed by a signed short value. */ 0N/A /** Wide opcode is not followed by any operands. */ 0N/A /** Wide opcode is followed by a 2-byte index into the constant pool. */ 0N/A /** Wide opcode is followed by a 2-byte index into the constant pool, 0N/A * and a signed short value. */ 0N/A /** Opcode was not recognized. */ 0N/A /** The length, in bytes, of this kind of instruction, or -1 is the 0N/A * length depends on the specific instruction. */ 0N/A /** A utility visitor to help decode the operands of an instruction. 0N/A * @see Instruction#accept */ 0N/A /** See {@link Kind#NO_OPERANDS}, {@link Kind#WIDE_NO_OPERANDS}. */ 0N/A /** See {@link Kind#ATYPE}. */ 0N/A /** See {@link Kind#BRANCH}, {@link Kind#BRANCH_W}. */ 0N/A /** See {@link Kind#CPREF}, {@link Kind#CPREF_W}, {@link Kind#WIDE_CPREF_W}. */ 0N/A /** See {@link Kind#CPREF_W_UBYTE}, {@link Kind#CPREF_W_UBYTE_ZERO}, {@link Kind#WIDE_CPREF_W_SHORT}. */ 0N/A /** See {@link Kind#LOCAL}. */ 0N/A /** See {@link Kind#LOCAL_UBYTE}. */ 0N/A /** See {@link Kind#DYNAMIC}. */ 0N/A /** See {@link Kind#DYNAMIC}. */ 0N/A /** See {@link Kind#BYTE}, {@link Kind#SHORT}. */ 0N/A /** Instruction is unrecognized. */ 0N/A /** The kind of primitive array type to create. 0N/A * See JVMS chapter 6, newarray. */ 1999N/A /** An instruction is defined by its position in a bytecode array. */ 0N/A /** Get the position of the instruction within the bytecode array. */ 2146N/A /** Get a byte value, relative to the start of this instruction. */ 2146N/A /** Get an unsigned byte value, relative to the start of this instruction. */ 1999N/A /** Get a 2-byte value, relative to the start of this instruction. */ 0N/A /** Get a unsigned 2-byte value, relative to the start of this instruction. */ 0N/A /** Get a 4-byte value, relative to the start of this instruction. */ 1999N/A /** Get the Opcode for this instruction, or null if the instruction is 0N/A /** Get the mnemonic for this instruction, or a default string if the 0N/A * instruction is unrecognized. */ 0N/A /** Get the length, in bytes, of this instruction, including the opcode 0N/A * and all its operands. */ 0N/A /** Get the {@link Kind} of this instruction. */ 1999N/A /** Invoke a method on the visitor according to the kind of this 1999N/A * instruction, passing in the decoded operands for the instruction. */ for (
int i =
0; i <
npairs; i++) {
private static int align(
int n) {