I'm working on a large c++ built library that has grown by a significant amount recently. Due to it's size, it is not obvious what has caused this size increase.
Do you have any suggestions of tools (msvc or gcc) that could help determine where the growth has come from.
edit Things i've tried: Dumpbin the final dll, the obj files, creating a map file and ripping through it.
edit again So objdump along with a python script seems to have done what I want.
Process Explorer has a facility that allows you to search through the currently running processes for a specific file. To perform this search go to Find -> Find Handle or DLL... and then enter the name of the file you are interested in. Save this answer. Show activity on this post.
In Windows, a dynamic-link library (DLL) is a kind of executable file that acts as a shared library of functions and resources. Dynamic linking is an operating system capability. It enables an executable to call functions or use resources stored in a separate file.
To use a DLL by explicit linking, applications must make a function call to explicitly load the DLL at run time. To explicitly link to a DLL, an application must: Call LoadLibraryEx or a similar function to load the DLL and obtain a module handle.
If gcc, objdump. If visual studio, dumpbin.
I'd suggest doing a diff of the output of the tool for the old (small) library, vs. the new (large) library.
keysersoze's answer (compare the output of objdump
or dumpbin
) is correct. Another approach is to tell the linker to produce a map file, and compare the map files for the old and new versions of the DLL.
link.exe
/MAP
ld
-M
(or gcc -Wl,-M
)If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With