diff mbox series

[3/4] doc: add header for optimization related documentation

Message ID 20201114102356.61234-4-luc.vanoostenryck@gmail.com (mailing list archive)
State Mainlined, archived
Headers show
Series doc: one patch and three improvements | expand

Commit Message

Luc Van Oostenryck Nov. 14, 2020, 10:23 a.m. UTC
Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
---
 Documentation/api.rst | 1 +
 optimize.c            | 8 ++++++--
 2 files changed, 7 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/Documentation/api.rst b/Documentation/api.rst
index 09ed0c4d7f9b..0cc830165e70 100644
--- a/Documentation/api.rst
+++ b/Documentation/api.rst
@@ -25,4 +25,5 @@  Typing
 Optimization
 ~~~~~~~~~~~~
 
+.. c:autodoc:: optimize.c
 .. c:autodoc:: simplify.c
diff --git a/optimize.c b/optimize.c
index bfab74c01b62..fd4ecb990fe9 100644
--- a/optimize.c
+++ b/optimize.c
@@ -1,10 +1,12 @@ 
 // SPDX-License-Identifier: MIT
 //
-// optimize.c - main optimization loop
-//
 // Copyright (C) 2004 Linus Torvalds
 // Copyright (C) 2004 Christopher Li
 
+///
+// Optimization main loop
+// ----------------------
+
 #include <assert.h>
 #include "optimize.h"
 #include "flowgraph.h"
@@ -45,6 +47,8 @@  static void clean_up_insns(struct entrypoint *ep)
 	} END_FOR_EACH_PTR(bb);
 }
 
+///
+// optimization main loop
 void optimize(struct entrypoint *ep)
 {
 	if (fdump_ir & PASS_LINEARIZE)