]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
Document enable_ranger and disable_ranger.
authorMartin Sebor <msebor@redhat.com>
Thu, 19 Aug 2021 18:49:40 +0000 (12:49 -0600)
committerMartin Sebor <msebor@redhat.com>
Thu, 19 Aug 2021 18:49:40 +0000 (12:49 -0600)
gcc:
* gimple-range.cc: Add comments.
* gimple-range.h: Same.

gcc/gimple-range.cc
gcc/gimple-range.h

index 60b7d3a59cd74c0ad121817cb8aef57ff76f5b7a..ef3afeacc901932a7dec7a690cbd862c5f56a589 100644 (file)
@@ -381,6 +381,10 @@ gimple_ranger::dump (FILE *f)
   m_cache.dump (f);
 }
 
+/* Create a new ranger instance and associate it with function FUN.
+   Each call must be paired with a call to disable_ranger to release
+   resources.  */
+
 gimple_ranger *
 enable_ranger (struct function *fun)
 {
@@ -392,6 +396,9 @@ enable_ranger (struct function *fun)
   return r;
 }
 
+/* Destroy and release the ranger instance associated with function FUN
+   and replace it the global ranger.  */
+
 void
 disable_ranger (struct function *fun)
 {
index 41845b14fd6395e1aac5ecb1bb0dbc4e5718a42b..eaebb9c5833793cfb262903d88d20c643a7e08f6 100644 (file)
@@ -62,6 +62,9 @@ protected:
   range_tracer tracer;
 };
 
+/* Create a new ranger instance and associate it with a function.
+   Each call must be paired with a call to disable_ranger to release
+   resources.  */
 extern gimple_ranger *enable_ranger (struct function *);
 extern void disable_ranger (struct function *);