⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 quick2.doc.html

📁 Jvm 规范说明。The Java Virtual Machine was designed to support the Java programming language. Some concep
💻 HTML
📖 第 1 页 / 共 5 页
字号:
<tr><td><a name="6680"></a>
 <i>ldc2_w_quick</i>
<td><a name="130"></a>
 

<tr><td><a name="6682"></a>
 <i>indexbyte1</i>
<td><a name="137"></a>
 

<tr><td><a name="6684"></a>
 <i>indexbyte2</i>
<td><a name="144"></a>
 

</Table><br><br><p>
<a name="ldc2_w_quick.Forms"></a>
<b>Forms</h3></b>
<a name="12465"></a>
<i>ldc2_w_quick</i> = 205 (0xcd)<p>
<a name="ldc2_w_quick.Stack"></a>
<b>Stack</h3></b>
<a name="6686"></a>
... <img src="chars/arrwdbrt.gif"> ...,<em> </em><i>item.word1</i>, <i>item.word2</i><p>
<a name="ldc2_w_quick.Description"></a>
<b>Description</h3></b>
<a name="6687"></a>
The unsigned <i>indexbyte1</i> and <i>indexbyte2</i> are assembled into an unsigned 16-bit index into the constant pool of the current class <a href="Overview.doc.html#17257">(&#167;3.6)</a>, where the value of the index is (<i>indexbyte1</i> << 8) | <i>indexbyte2</i>. The index must be a valid index into the constant pool of the current class. The (64-bit) constant pool <i>constant</i> at the index must have already been resolved and must be two words wide.<p>
<a name="ldc2_w_quick.Notes"></a>
<b>Notes</h3></b>
<a name="4187"></a>
The opcode of this instruction was originally <i>ldc2_w</i>. The operands of the original <i>ldc2_w</i> instruction are not modified.<p>
<a name="4260"></a>
Only a wide index version of this instruction exists; there is no <i>ldc2_quick</i> instruction that pushes a two-word constant with a single-byte index.<p>
<a name="4184"></a>
<p>
<a name="9076"></a>
<p>

<a name="multianewarray_quick"></a>
<hr><h2>multianewarray_quick</h2>
<a name="multianewarray_quick.Operation"></a>
<b>Operation</h3></b>
<a name="852"></a>
Create new multidimensional array<p><Table Border="1">
<tr><td><a name="845"></a>
 <i>multianewarray_quick</i>
<td><a name="579"></a>
 

<tr><td><a name="847"></a>
 <i>indexbyte1</i>
<td><a name="586"></a>
 

<tr><td><a name="849"></a>
 <i>indexbyte2</i>
<td><a name="593"></a>
 

<tr><td><a name="851"></a>
 <i>dimensions</i>
<td><a name="600"></a>
 

</Table><br><br><p>
<a name="multianewarray_quick.Forms"></a>
<b>Forms</h3></b>
<a name="12466"></a>
<i>multianewarray_quick</i> = 223 (0xdf)<p>
<a name="multianewarray_quick.Stack"></a>
<b>Stack</h3></b>
<a name="853"></a>
..., <i>count1</i>,<em> </em>[<i>count2</i>, ...]<em> </em><img src="chars/arrwdbrt.gif"> ..., <i>arrayref</i><p>
<a name="multianewarray_quick.Description"></a>
<b>Description</h3></b>
<a name="854"></a>
The <i>dimensions</i> is an unsigned byte which must be greater than or equal to 1. It represents the number of dimensions of the array to be created. The operand stack must contain <i>dimensions</i> words, which must be of type <code>int</code> and nonnegative, each representing the number of components in a dimension of the array to be created. The <i>count1</i> is the desired length in the first dimension, <i>count2</i> in the second, etc.<p>
<a name="8049"></a>
All of the <i>count</i> values are popped off the operand stack. The unsigned <i>indexbyte1</i> and <i>indexbyte2</i> are used to construct an index into the constant pool of the current class <a href="Overview.doc.html#17257">(&#167;3.6)</a>, where the value of the index is (<i>indexbyte1</i> << 8) | <i>indexbyte2</i>. The resulting entry must have already been resolved to an array class type of dimensionality greater than or equal to <i>dimensions</i>.<p>
<a name="8024"></a>
A new multidimensional array of the array type is allocated from the garbage-collected heap. The components of the first dimension of the array are initialized to subarrays of the type of second dimension, and so on. The components of the array in the final dimension are initialized to the default initial value for its type (<a href="Concepts.doc.html#15858">&#167;2.5.1</a>). A <code>reference</code> <i>arrayref</i> to the new array is pushed onto the operand stack. <p>

<b>Runtime Exception</h3></b>
<a name="1624"></a>
If any of the <i>dimensions</i> values on the operand stack is less than zero, <i>multianewarray_quick</i> throws a <code>NegativeArraySize</code><code>-Exception</code>.<p>
<a name="multianewarray_quick.Notes"></a>
<b>Notes</h3></b>
<a name="4903"></a>
The opcode of this instruction was originally <i>multianewarray</i>. The operands of the <i>multianewarray</i> instruction are not modified.<p>
<a name="4901"></a>
<p>

<a name="new_quick"></a>
<hr><h2>new_quick</h2>
<a name="new_quick.Operation"></a>
<b>Operation</h3></b>
<a name="7945"></a>
Create new object<p><Table Border="1">
<tr><td><a name="7940"></a>
 <i>new_quick</i>
<td><a name="371"></a>
 

<tr><td><a name="7942"></a>
 <i>indexbyte1</i>
<td><a name="378"></a>
 

<tr><td><a name="7944"></a>
 <i>indexbyte2</i>
<td><a name="385"></a>
 

</Table><br><br><p>
<a name="new_quick.Forms"></a>
<b>Forms</h3></b>
<a name="12467"></a>
<i>new_quick</i> = 221 (0xdd)<p>
<a name="new_quick.Stack"></a>
<b>Stack</h3></b>
<a name="7946"></a>
... <img src="chars/arrwdbrt.gif">  ..., <i>objectref</i><p>
<a name="new_quick.Description"></a>
<b>Description</h3></b>
<a name="7947"></a>
The unsigned <i>indexbyte1</i> and <i>indexbyte2</i> are used to construct an index into the constant pool of the current class <a href="Overview.doc.html#17257">(&#167;3.6)</a>, where the value of the index is (<i>indexbyte1</i> << 8) | <i>indexbyte2</i>. The item at that index must have already been resolved to a class type. A new instance of that class is created, and the instance variables of the new object are initialized to their default initial values (<a href="Concepts.doc.html#15858">&#167;2.5.1</a>). The <i>objectref</i>, a <code>reference</code> to <em>the instance, </em>is pushed onto the operand stack.<p>
<a name="new_quick.Notes"></a>
<b>Notes</h3></b>
<a name="7953"></a>
The opcode of this instruction was originally <i>new</i>. The operands of the original <i>new</i> instruction are not modified.<p>

<a name="putfield_quick"></a>
<hr><h2>putfield_quick</h2>
<a name="putfield_quick.Operation"></a>
<b>Operation</h3></b>
<a name="6789"></a>
Set field in object<p><Table Border="1">
<tr><td><a name="6784"></a>
 <i>putfield_quick</i>
<td><a name="248"></a>
 

<tr><td><a name="6786"></a>
 <i>offset</i>
<td><a name="255"></a>
 

<tr><td><a name="6788"></a>
 <i>unused</i>
<td><a name="262"></a>
 

</Table><br><br><p>
<a name="putfield_quick.Forms"></a>
<b>Forms</h3></b>
<a name="12468"></a>
<i>putfield_quick</i> = 207 (0xcf)<p>
<a name="putfield_quick.Stack"></a>
<b>Stack</h3></b>
<a name="1367"></a>
..., <i>objectref</i>, <i>value</i> <img src="chars/arrwdbrt.gif">  ...<p>
<a name="putfield_quick.Description"></a>
<b>Description</h3></b>
<a name="4914"></a>
The <i>objectref</i>, which m<em>ust be of type </em><code>reference</code>, and <i>value</i>, which m<em>ust be a value of a type appropriate for the specified field, are popped from the </em>operand stack<em>. </em>The <i>value</i> is written at <i>offset</i> into the class instance referenced by <i>objectref</i>.<p>
<a name="putfield_quick.Runtime"></a>
<b>Runtime Exception</h3></b>
<a name="4915"></a>
If <i>objectref</i> is <code>null</code>, the <i>putfield_quick</i> instruction throws a <code>NullPointerException</code>.<p>
<a name="putfield_quick.Notes"></a>
<b>Notes</h3></b>
<a name="17325"></a>
The opcode of this instruction was originally <i>putfield</i>, operating on a field determined dynamically to have an offset into the class instance data of 255 words or less and to have a width of one word. <p>
<a name="17425"></a>
When the constant pool entry referenced by a <i>putfield</i> instruction is resolved, the offset for the field it references is generated. That offset replaces the first operand byte of the original <i>putfield</i> instruction. The second operand byte of the <i>putfield</i> is unused in <i>putfield_quick</i>.<p>

<a name="putfield_quick_w"></a>
<hr><h2>putfield_quick_w</h2>
<a name="putfield_quick_w.Operation"></a>
<b>Operation</h3></b>
<a name="6698"></a>
Set field in object<p><Table Border="1">
<tr><td><a name="6693"></a>
 <i>putfield_quick_w</i>
<td><a name="612"></a>
 

<tr><td><a name="6695"></a>
 <i>indexbyte1</i>
<td><a name="619"></a>
 

<tr><td><a name="6697"></a>
 <i>indexbyte2</i>
<td><a name="626"></a>
 

</Table><br><br> (wide index)<p>
<a name="putfield_quick_w.Forms"></a>
<b>Forms</h3></b>
<a name="12469"></a>
<i>putfield_quick_w</i> = 228 (0xe4)<p>
<a name="putfield_quick_w.Stack"></a>
<b>Stack</h3></b>
<a name="6699"></a>
..., <i>objectref</i>, <i>value</i> <img src="chars/arrwdbrt.gif">  ...<p>
<a name="17271"></a>
OR<p>
<a name="putfield_quick_w.Stack"></a>
<b>Stack</h3></b>
<a name="17274"></a>
..., <i>objectref</i>, <i>value.word1</i>, <i>value.word2</i> <img src="chars/arrwdbrt.gif"> ...<p>
<a name="putfield_quick_w.Description"></a>
<b>Description</h3></b>
<a name="6707"></a>
The <i>objectref</i>, which m<em>ust be of type </em><code>reference</code>, and <i>value</i>, which m<em>ust be a value of a type appropriate for the specified field, are popped from the </em>operand stack<em>. The unsigned </em><i>indexbyte1</i> and <i>indexbyte2</i> are used to construct an index into the constant pool of the current class <a href="Overview.doc.html#17257">(&#167;3.6)</a>, where the index is (<i>indexbyte1</i> << 8) | <i>indexbyte2</i>. The constant pool item at the index must be a <code>CONSTANT_Fieldref</code> <a href="ClassFile.doc.html#4723">(&#167;4.4.2)</a> which must already have been resolved and must not be a class (<code>static</code>) field. The <i>value</i> is written at <i>offset</i> into the class instance referenced by <i>objectref</i>.<p>
<a name="putfield_quick_w.Runtime"></a>
<b>Runtime Exception</h3></b>
<a name="6701"></a>
If <i>objectref</i> is <code>null</code>, the <i>putfield_quick_w</i> instruction throws a <code>NullPointerException</code>.<p>
<a name="putfield_quick_w.Notes"></a>
<b>Notes</h3></b>
<a name="6724"></a>
The opcode of this instruction was originally <i>putfield</i>, operating on a field determined dynamically to have an offset into the class instance data of more than 255 words.<p>

<a name="putfield_quick_w"></a>
<a name="17418"></a>
The operands of the <i>putfield</i> instruction are not modified. Because the <i>putfield_quick_w</i> instruction operates on both one- and two-word wide fields, it needs to know both the field offset and the type of that field. Because the original <i>putfield</i> instruction needed a 16-bit index, the field offset may be 16 bits wide. As there is insufficient space in the instruction to store both a 16-bit offset and a field type, <i>putfield_quick_w</i> retains its original operands and uses them to index into the constant pool, where the 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -