[llvm-commits] [llvm] r145908 - /llvm/trunk/docs/LangRef.html

Dan Gohman gohman at apple.com
Mon Dec 5 19:31:14 PST 2011


Author: djg
Date: Mon Dec  5 21:31:14 2011
New Revision: 145908

URL: http://llvm.org/viewvc/llvm-project?rev=145908&view=rev
Log:
Line up the comments in a code example.

Modified:
    llvm/trunk/docs/LangRef.html

Modified: llvm/trunk/docs/LangRef.html
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/docs/LangRef.html?rev=145908&r1=145907&r2=145908&view=diff
==============================================================================
--- llvm/trunk/docs/LangRef.html (original)
+++ llvm/trunk/docs/LangRef.html Mon Dec  5 21:31:14 2011
@@ -2582,11 +2582,11 @@
 <pre class="doc_code">
 entry:
   %poison = sub nuw i32 0, 1           ; Results in a poison value.
-  %still_poison = and i32 %poison, 0     ; Whereas (and i32 undef, 0) would return 0.
+  %still_poison = and i32 %poison, 0   ; Whereas (and i32 undef, 0) would return 0.
   %poison_yet_again = getelementptr i32* @h, i32 %still_poison
   store i32 0, i32* %poison_yet_again  ; undefined behavior
 
-  store i32 %poison, i32* @g         ; Poison value conceptually stored to memory.
+  store i32 %poison, i32* @g           ; Poison value conceptually stored to memory.
   %poison2 = load i32* @g              ; Returns a poison value, not just undef.
 
   store volatile i32 %poison, i32* @g  ; External observation; undefined behavior.
@@ -2596,38 +2596,38 @@
   %poison3 = load i16* %narrowaddr     ; Returns a poison value.
   %poison4 = load i64* %wideaddr       ; Returns a poison value.
 
-  %cmp = icmp slt i32 %poison, 0      ; Returns a poison value.
-  br i1 %cmp, label %true, label %end ; Branch to either destination.
+  %cmp = icmp slt i32 %poison, 0       ; Returns a poison value.
+  br i1 %cmp, label %true, label %end  ; Branch to either destination.
 
 true:
-  store volatile i32 0, i32* @g      ; This is control-dependent on %cmp, so
-                                     ; it has undefined behavior.
+  store volatile i32 0, i32* @g        ; This is control-dependent on %cmp, so
+                                       ; it has undefined behavior.
   br label %end
 
 end:
   %p = phi i32 [ 0, %entry ], [ 1, %true ]
-                                     ; Both edges into this PHI are
-                                     ; control-dependent on %cmp, so this
-                                     ; always results in a poison value.
-
-  store volatile i32 0, i32* @g      ; This would depend on the store in %true
-                                     ; if %cmp is true, or the store in %entry
-                                     ; otherwise, so this is undefined behavior.
+                                       ; Both edges into this PHI are
+                                       ; control-dependent on %cmp, so this
+                                       ; always results in a poison value.
+
+  store volatile i32 0, i32* @g        ; This would depend on the store in %true
+                                       ; if %cmp is true, or the store in %entry
+                                       ; otherwise, so this is undefined behavior.
 
   br i1 %cmp, label %second_true, label %second_end
-                                     ; The same branch again, but this time the
-                                     ; true block doesn't have side effects.
+                                       ; The same branch again, but this time the
+                                       ; true block doesn't have side effects.
 
 second_true:
   ; No side effects!
   ret void
 
 second_end:
-  store volatile i32 0, i32* @g      ; This time, the instruction always depends
-                                     ; on the store in %end. Also, it is
-                                     ; control-equivalent to %end, so this is
-                                     ; well-defined (again, ignoring earlier
-                                     ; undefined behavior in this example).
+  store volatile i32 0, i32* @g        ; This time, the instruction always depends
+                                       ; on the store in %end. Also, it is
+                                       ; control-equivalent to %end, so this is
+                                       ; well-defined (again, ignoring earlier
+                                       ; undefined behavior in this example).
 </pre>
 
 </div>





More information about the llvm-commits mailing list