This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Patch, fortran] Runtime memory leak checking.

Paul Richard Thomas wrote:
> OK to go on ice ready for 4.5?  (Is there any appetite to add it to 4.4?)
> Paul

Hi Paul,

my comments:

Here, we should probably change the first line too

    2.  Make sure each time `-lgfortran' or `-lm' is seen, it forms
-       part of the series `-lgfortran -lm'.
+       part of the series `-lgfortran -liberty -lm'.

some indenting problems (find where it is :-)):

+  if (gfc_option.rtcheck & GFC_RTCHECK_MEMLEAKS)
+      gfc_add_modify (&alloc_block, res,

       /* Free the temporary afterwards.  */
-      tmp = gfc_call_free (var);
+  tmp = gfc_call_free (var, true, &gfc_current_locus,
       gfc_add_expr_to_block (&se->post, tmp);

space indenting:

+      /* Succesfully found in the allocation table.  */
+      if (type == ALLOCTYPE_TEMPORARY)
+        usedmem_temp -= (*slot)->size;
+      else
+        usedmem_user -= (*slot)->size;
+      htab_clear_slot (tab, (void *) slot);

Ok for 4.5.
Thank you (and FX).


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]