diff mbox series

[wwwdocs] projects/tree-ssa/tree-browser.html - use more regular markup, existing CSS, move to HTML 5

Message ID alpine.LSU.2.21.1809021357120.6216@anthias.pfeifer.com
State New
Headers show
Series [wwwdocs] projects/tree-ssa/tree-browser.html - use more regular markup, existing CSS, move to HTML 5 | expand

Commit Message

Gerald Pfeifer Sept. 2, 2018, noon UTC
This page did a lot of manual formatting (via tables) which was not
consistent with other spots on our site.  This address that by using
CSS instead of manually constructing tables, and adds <p> environments
where suitable, overall making this simpler/shorter, more consistent,
and HTML 5 in the end.

Committed.

Gerald
diff mbox series

Patch

Index: projects/tree-ssa/tree-browser.html
===================================================================
RCS file: /cvs/gcc/wwwdocs/htdocs/projects/tree-ssa/tree-browser.html,v
retrieving revision 1.5
diff -u -r1.5 tree-browser.html
--- projects/tree-ssa/tree-browser.html	1 Sep 2018 23:42:10 -0000	1.5
+++ projects/tree-ssa/tree-browser.html	2 Sep 2018 11:57:14 -0000
@@ -8,41 +8,29 @@ 
   <body>
     <h1>Tree Browser</h1>
     
-    Until recently the only way to debug trees from gdb was to call debug_tree as follows:
+<p>Until recently the only way to debug trees from gdb was to call
+debug_tree as follows:</p>
     
-    <table border="1" width="100%">
-      <tr> 
-	<td>
-	  <pre>
+<pre class="smallexample">
 (gdb) p debug_tree (current_function_decl) 
-	  </pre>
-	</td>
-      </tr>
-    </table>
-
-    An alternative for interactively scan tree structures is to use the Tree Browser.
-    You can access Tree Browser from anywhere during a debugging session as follows:
-
-    <table border="1" width="100%">
-      <tr> 
-	<td>
-	  <pre>
+</pre>
+
+<p>An alternative for interactively scan tree structures is to use the
+Tree Browser.  You can access Tree Browser from anywhere during a debugging
+session as follows:</p>
+
+<pre class="smallexample">
 (gdb) p browse_tree (current_function_decl)
  
 Tree Browser 
 foo 
 Up/prev expressions updated. 
 TB&gt; 
-	  </pre>
-	</td>
-      </tr>
-    </table>
-
-For listing available commands, you could try:
-    <table border="1" width="100%">
-      <tr> 
-	<td>
-	  <pre>
+</pre>
+
+<p>For listing available commands, you could try:</p>
+
+<pre class="smallexample">
 TB&gt; h 
 Possible commands are: 
  
@@ -102,19 +90,15 @@ 
                   pp  -  Pretty print current node. 
                    p  -  Prints the current node. 
 TB&gt;  
-	  </pre>
-	</td>
-      </tr>
-    </table>
-    Note that this list of commands is susceptible to change, since this is a pretty new tool 
-    and is still in development. <br/>
+</pre>
+
+<p>Note that this list of commands is susceptible to change, since this
+is a pretty new tool and is still in development.</p>
     
-    Now let's try some of these commands: we're on the declaration of the current function, 
-    we can have a look at its body.
-    <table border="1" width="100%">
-      <tr> 
-	<td>
-	  <pre>
+<p>Now let's try some of these commands: we're on the declaration of the
+current function, we can have a look at its body.</p>
+
+<pre class="smallexample">
 TB&gt; decl_saved_tree 
 { 
   int T.1; 
@@ -134,18 +118,13 @@ 
     }, return i; 
 } 
 TB&gt;  
-	  </pre>
-	</td>
-      </tr>
-    </table>
-
-    The above output is a pretty-print of the body of the current function.
-    A call to debug_tree would have printed more things about the structure of
-    the Abstract Syntax Trees (AST), as follows:    
-    <table border="1" width="100%">
-      <tr> 
-	<td>
-	  <pre>
+</pre>
+
+<p>The above output is a pretty-print of the body of the current function.
+A call to debug_tree would have printed more things about the structure of
+the Abstract Syntax Trees (AST), as follows:</p>
+
+<pre class="smallexample">
 TB&gt; p 
  &lt;expr_with_file_location 0x401a2aa0 
     type &lt;void_type 0x401a089c void VOID 
@@ -197,22 +176,18 @@ 
     arg 1 &lt;identifier_node 0x401c6480 one.c&gt; 
     one.c:3:0&gt; 
 TB&gt;  
-	  </pre>
-	</td>
-      </tr>
-    </table>
-
-    An interesting thing to remark in this dumping is that a node is represented as 
-    a well parenthesized expression.  Each tree node contains several fields that are in 
-    general aligned at the same indentation level.  
-    For example BIND_EXPR has a child called vars (a set of variable definitions), a body, 
-    and a block.  All these fields are accessible from Tree Browser.  <br/>
-
-    Thus if we continue our exploration of the current tree structure, 
-    <table border="1" width="100%">
-      <tr> 
-	<td>
-	  <pre>
+</pre>
+
+<p>An interesting thing to remark in this dumping is that a node is
+represented as a well parenthesized expression.  Each tree node contains
+several fields that are in general aligned at the same indentation level.  
+For example BIND_EXPR has a child called vars (a set of variabl
+definitions), a body, and a block.  All these fields are accessible from
+Tree Browser.</p>
+
+<p>Thus if we continue our exploration of the current tree structure,</p>
+
+<pre class="smallexample">
 TB&gt; arg0 
 { 
   int T.1; 
@@ -241,21 +216,18 @@ 
     T.1 = i * 3, T.2 = i + T.1, toons (T.2) 
   }, return i; 
 TB&gt; 
-	  </pre>
-	</td>
-      </tr>
-    </table>
-    Here I have to write some notes on the current chaining of expressions procedure.  
-    A compound_expr contains two operands: arg0 the child that contains the expression 
-    and arg1 the child that contains the rest of the list of expressions.  In arg0 
-    GCC stores an expr_with_file_location node that contains the expression and an 
-    information about the position of this expression in the original source code. <br/>
-    
-    For accessing the next expression you can use the next command: 
-    <table border="1" width="100%">
-      <tr> 
-	<td>
-	  <pre>
+</pre>
+
+<p>Here I have to write some notes on the current chaining of expressions
+procedure.  A compound_expr contains two operands: arg0 the child that
+contains the expression and arg1 the child that contains the rest of the
+list of expressions.  In arg0 GCC stores an expr_with_file_location node
+that contains the expression and an information about the position of this
+expression in the original source code.</p>
+
+<p>For accessing the next expression you can use the next command:</p>
+
+<pre class="smallexample">
 TB&gt; nx 
 i = i + 1, koo (), if (i != 0) 
   { 
@@ -284,17 +256,12 @@ 
     T.1 = i * 3, T.2 = i + T.1, toons (T.2) 
   }, return i; 
 TB&gt;  
-	  </pre>
-	</td>
-      </tr>
-    </table>
-
-    You can choose to go backwards via the history stack: this pops the last visited
-    node from the stack.
-    <table border="1" width="100%">
-      <tr> 
-	<td>
-	  <pre>
+</pre>
+
+<p>You can choose to go backwards via the history stack: this pops the
+last visited node from the stack.</p>
+
+<pre class="smallexample">
 TB&gt; hpr 
 koo (), if (i != 0) 
   { 
@@ -305,17 +272,12 @@ 
     T.1 = i * 3, T.2 = i + T.1, toons (T.2) 
   }, return i; 
 TB&gt;  
-	  </pre>
-	</td>
-      </tr>
-    </table>
-
-    Or via the previous expression command (this information is not yet included in GCC's trees,
-    Tree Browser stores it in a hash table):
-    <table border="1" width="100%">
-      <tr> 
-	<td>
-	  <pre>
+</pre>
+
+<p>Or via the previous expression command (this information is not
+yet included in GCC's trees, Tree Browser stores it in a hash table):</p>
+
+<pre class="smallexample">
 TB&gt; pr 
 i = i + 1, koo (), if (i != 0) 
   { 
@@ -326,20 +288,17 @@ 
     T.1 = i * 3, T.2 = i + T.1, toons (T.2) 
   }, return i; 
 TB&gt;  
-	  </pre>
-	</td>
-      </tr>
-    </table>
+</pre>
 
     <h1> Extensions </h1>
-  <br/>    
-    Some extensions could be added in the near future, such as including commands
-    that allows you to modify tree structure, apply optimizations locally on a 
-    given node.  
-  <br/>
-    A more interesting but much more long term project is to write 
-    an interactive program editor/optimizer, but for the moment this is only 
-    science fiction... :-)
+
+<p>Some extensions could be added in the near future, such as including
+commands that allows you to modify tree structure, apply optimizations
+locally on a given node.</p>
+
+<p>A more interesting but much more long term project is to write 
+an interactive program editor/optimizer, but for the moment this is only 
+science fiction... :-)</p>
     
   </body>
 </html>