How reduce dll size again

My dll have been bigger multiplied up many times than early for some reason. I'm beginning to size up the situation:

  1. A source hasn't changed.
  2. Debug information everywhere turned off.
  3. Dll use package "Pack", but not include in Runtime Packages options.
  4. I've compared new dll with old version dll thought the instrumentality of PE Explore. In new dll I find out many modules with prefix 'ec' implicitly imported unlike old dll.
  5. Package "Pack" using ecControls components
  6. Dll doesn't using explicitly call to ecControls units.

Why ecControls units imported in dll? Have anybody some advice?


If a unit in ecControls is accidentally used, it's initialization section (if it has one) will be called and you can put a breakpoint in there to try and see where it is being called from. You can also put a breakpoint in System.InitUnits (with debug dcus on) to see if any unit in ecControls is being initialized.

I use this technique in Forms.pas when working on a dll to make sure that Forms.pas is not being linked in accidentally.

If your DLL is using a package that's not included in the Runtime Packages list, then its units will be implicitly imported into your DLL instead of linking to the runtime package. That's probably what's causing it right there. Try adding the package to your Runtime Packages list and see if the ecControls issue goes away.

Why you dont just rename the ecControls directory and rebuild (deleting the package first of course)? That will let you see exactly where it is being referenced.

Need Your Help

Generating a new variable every n loops in R

r variables for-loop counter naming-conventions

I have a command that generates a variable every 10 loops in R (index1, index2, index3... and so on). The command I have is functional, but I am thinking of a smarter way to write this command. Her...

Producer and consumer with notifications in C#

c# design-patterns producer-consumer

I have a producer (P) which pushes items into a consumer (C). C may decide not to consume all the items as soon as they arrive; instead it may asynchronously wait until there are n items in the que...