Jump to content
Tommi Prami

What "Project analyzers" out there.

Recommended Posts

Sometimes one have questions that answer is not that easy 🙂 Or need quite bit of work.

 

Lately I've had two.

 

  • Where this unit is linking from?
  • Which units in this project has initialization and/or finalization sections?

 

I bet there are tons of these good questions we sometimes would need answers for 🙂 

 

There might be something for these. Plain search for files does not help usually, because all depends what is linked into the specific project.

 

-Tee-

Share this post


Link to post

I used to use Peganza, but I stopped renewing it, since I used it so seldom.

 

My current approach in principle

  • Build project with detailed MAP file enabled
  • Extract the unit list to a separate file
  • Load the unit list in a PowerShell script
  • Define the include paths in the PS script
  • Walk the paths/files and search for the objectives, using PS

Share this post


Link to post

The Uses Report from Pascal Analyzer (Peganza) is pretty close to your needs. Perhaps even the free Pascal Analyzer Lite version will do here.

 

Regarding other analyzers I can speak for Understand, which gives much more information but for a higher cost. About the same is true for Lattix Architect, for which MMX can produce the necessary output.

 

I make use of all three tools quite often.

Share this post


Link to post
3 hours ago, Tommi Prami said:

Which units in this project has initialization and/or finalization sections?

For this purpose, you can use the standard search with the appropriate parameters.
Alternatively, you can use the Grep Search included with the GExperts plugin to take advantage of the finer tuning and search the map file as well

Edited by Dinar

Share this post


Link to post

Pascal Analyzer Lite is helpful; I have not used the full product. It is the only tool I have used which can advise as to uses references which can be demoted from interface to implementation. It does give some false positives, however.

The CnPack Uses Cleaner is also helpful, though like Pascal Analyzer Lite, it will give some false positives. It doesn't take long, however, to build a mental list of the modules you can't remove, despite its advice.

MMX is great for tabulating unit dependency cycles, and although the report it generates is huge, it is easily parsed, and I have built a simple tool to do that and present in a grid the cycle counts per unit, which is helpful.

DUDS is quite fast, and its tree view seems to me to communicate a more useful sense of dependency relations than the Cartesian map in MMX.

 

I have not found any single tool which does all that I could wish. The Pascal Analyzer Lite Uses report is very useful, and for demoting uses references, MMX is far superior to hand editing. 

Pascal Analyzer Lite is slow, and if your project is large, definitely use the 64-bit version, or it will run out of memory. If you are in a VM, give it plenty of RAM. PAL has used about 2.6GB on the large project I have been reworking.

 

The thing I really would like is to find a tool which can help you discover which modules in dependency cycle chains are villains, and which are victims. In a large legacy project, it is very difficult to identify the modules which are most in need of rework.

  • Like 2

Share this post


Link to post
1 hour ago, Bill Meyer said:

its tree view seems to me to communicate a more useful sense of dependency relations than the Cartesian map in MMX.

MMX has two displays for cycles: a treeview and a Dependency Structure Matrix:


image.thumb.png.173b398f98073baf558c38e8edc17840.png

image.png.b0744e4d3fcf8daafb357f37e06a56eb.png

  • Like 1

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×