[m-dev.] Refactoring mdbcomp/feedback.m

Paul Bone pbone at csse.unimelb.edu.au
Wed Aug 4 21:44:16 AEST 2010


Hi Guys.

Just a FYI, let me know if there are any issues with this proposed refactoring.

I've removed all the auto-parallelism specific code from mdbcomp/feedback.m
(module mdbcomp.feedback) and created a new file called
mdbcomp/feedback.automatic_parallelism.m (the module is
mdbcomp.feedback.automatic_parallelism).

Any future uses of the feedback framework should add a new module called
mdbcomp.feedback.<new name>.  Note that only structures and a small amount of
code shared between the mdprof_feedback tool and the profiler is actually
included here.  The analysis code for generating feedback information is stored
in deep_profiler/mdprof_fb.<module>

Splitting the feedback.m file up like this gives the following amount of code
in the two files (in LoC).

  549 feedback.m
  334 feedback.automatic_parallelism.m

After compiling to C in the asm_fast.gc grade the sizes of these modules become
(in lines of C code):

  3656 mdbcomp.feedback.c
  3225 mdbcomp.feedback.automatic_parallelism.c

The sizes of the object files on an amd64 host are:

   text    data     bss     dec     hex filename
  15691       0      12   15703    3d57 mdbcomp.feedback.o
  13246       0      12   13258    33ca mdbcomp.feedback.automatic_parallelism.o

Of course it's more important that the feedback.m file was split in a way that
makes sense from a modularity perspective.  The sizes of the modules are only
provided so that anyone reading this can get an idea of how large the code in
each file is.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 490 bytes
Desc: Digital signature
URL: <http://lists.mercurylang.org/archives/developers/attachments/20100804/7615d48f/attachment.sig>


More information about the developers mailing list