equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2001, 2002, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 2001, 2011, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. |
7 * published by the Free Software Foundation. |
128 |
128 |
129 // Unsigned indices, widening |
129 // Unsigned indices, widening |
130 public int getIndex() { return (isWide()) |
130 public int getIndex() { return (isWide()) |
131 ? (_method.getBytecodeShortArg(bci() + 2) & 0xFFFF) |
131 ? (_method.getBytecodeShortArg(bci() + 2) & 0xFFFF) |
132 : (_method.getBytecodeOrBPAt(bci() + 1) & 0xFF); } |
132 : (_method.getBytecodeOrBPAt(bci() + 1) & 0xFF); } |
133 public int getIndexBig() { return _method.getBytecodeShortArg(bci() + 1); } |
133 public int getIndexU1() { return _method.getBytecodeOrBPAt(bci() + 1) & 0xFF; } |
|
134 public int getIndexU2() { return _method.getBytecodeShortArg(bci() + 1) & 0xFFFF; } |
|
135 public int getIndexU4() { return _method.getNativeIntArg(bci() + 1); } |
|
136 public boolean hasIndexU4() { return code() == Bytecodes._invokedynamic; } |
|
137 |
|
138 public int getIndexU1Cpcache() { return _method.getBytecodeOrBPAt(bci() + 1) & 0xFF; } |
|
139 public int getIndexU2Cpcache() { return _method.getNativeShortArg(bci() + 1) & 0xFFFF; } |
134 |
140 |
135 // Fetch at absolute BCI (for manual parsing of certain bytecodes) |
141 // Fetch at absolute BCI (for manual parsing of certain bytecodes) |
136 public int codeAt(int bci) { |
142 public int codeAt(int bci) { |
137 return _method.getBytecodeOrBPAt(bci); |
143 return _method.getBytecodeOrBPAt(bci); |
138 } |
144 } |