📄 instructions2.doc143.html
字号:
<html><head><title>VM Spec </title></head><body BGCOLOR=#eeeeff text=#000000 LINK=#0000ff VLINK=#000077 ALINK=#ff0000> <a href="VMSpecTOC.doc.html">Contents</a> | <a href="Instructions2.doc142.html">Prev</a> | <a href="Instructions2.doc144.html">Next</a> | <a href="Mnemonics.doc.html">Index</a><hr><br> <a name="lneg"></a><h2>lneg</h2><a name="lneg.Operation"></a><b>Operation</b><br><a name="69508"></a>Negate <code>long</code><p><Table Border="3"><tr><td><a name="69507"></a> <i>lneg</i><td><a name="87568"></a> </Table><Table><tr><td></Table><p><a name="lneg.Forms"></a><b>Forms</b><br><a name="69509"></a><i>lneg</i><em> </em>= 117 (0x75)<p><a name="lneg.Stack"></a><b>Stack</b><br><a name="69510"></a>..., <i>value.word1</i><em>, </em><i>value.word2</i><em> </em><img src="chars/arrwdbrt.gif"> ..., <i>result.word1</i><em>, </em><i>result.word2</i><p><a name="lneg.Description"></a><b>Description</b><br><a name="69511"></a>The <i>value</i> must be of type <code>long</code>. It is popped from the operand stack. The <code>long</code> <i>result</i> is the arithmetic negation of <i>value</i>, -<i>value</i>. The <i>result</i> is pushed onto the operand stack.<p><a name="69512"></a>For <code>long</code> values, negation is the same as subtraction from zero. Because the Java Virtual Machine uses two's-complement representation for integers and the range of two's-complement values is not symmetric, the negation of the maximum negative <code>long</code> results in that same maximum negative number. Despite the fact that overflow has occurred, no exception is thrown. <p><a name="69513"></a>For all <code>long</code> values <code>x</code>, -<code>x</code> equals <code>(~x)</code> <code>+</code> <code>1</code>.<p><hr><!-- This inserts footnotes--><p><a href="VMSpecTOC.doc.html">Contents</a> | <a href="Instructions2.doc142.html">Prev</a> | <a href="Instructions2.doc144.html">Next</a> | <a href="Mnemonics.doc.html">Index</a><p><font size=-1>Java Virtual Machine Specification (HTML generated by dkramer on February 25, 1997)<br><i><a href="Copyright.doc.html">Copyright © 1996 Sun Microsystems, Inc.</a>All rights reserved</i><br>Please send any comments or corrections to <a href="mailto:doug.kramer@sun.com">doug.kramer@sun.com</a></font></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -