[LLVMdev] Error in the example of sext instruction in reference manual

Bin Tzeng bintzeng at gmail.com
Thu Jun 20 16:39:40 PDT 2013


Hi all,

There might be a simple error in the LLVM reference manual. The example for
sext instruction:

%X = sext i8 -1 to i16     ; yields i16    :65535

%X should yield i16: -1, as opposed to 65535.
Here is the simple patch (also attached):

Index: docs/LangRef.rst
===================================================================
--- docs/LangRef.rst    (revision 184496)
+++ docs/LangRef.rst    (working copy)
@@ -5236,7 +5236,7 @@

 .. code-block:: llvm

-      %X = sext i8  -1 to i16              ; yields i16   :65535
+      %X = sext i8  -1 to i16              ; yields i16:-1
       %Y = sext i1 true to i32             ; yields i32:-1
       %Z = sext <2 x i16> <i16 8, i16 7> to <2 x i32> ; yields <i32 8, i32
7>


Thanks!
Bin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20130620/860e05dd/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: sextExample.diff
Type: application/octet-stream
Size: 482 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20130620/860e05dd/attachment.obj>


More information about the llvm-dev mailing list