Archived

This topic is now archived and is closed to further replies.

warpexplorer

how do you get rid of useless dll functions?

Recommended Posts

I have a dll with a big pile of functions in it. This wouldn''t normally be a problem except that I''m only exporting a couple of them and those are only useing about 15 more. Which means that I have a slightly smaller big pile of functions that are not being used and not being exported. If I look in my .map file I find that these functions, even though they are in no way being used, are takeing up a HUGE amoung of space (about 400k). The obvious solution is to remove the unused functions from my code, but I will probably be using alot of them later and dont really want to go though them all looking for the ones I dont need for the moment. Is there any compiler option that removes unused code from the final build? (I''m using MSVC by the way) thanks

Share this post


Link to post
Share on other sites
If they''re not being used or referenced and aren''t being exported, any decent compiler should remove them in release/optimising mode. If your compiler doesn''t, burn it and get a new one.

[ MSVC Fixes | STL | SDL | Game AI | Sockets | C++ Faq Lite | Boost | Asking Questions | Organising code files | My stuff ]

Share this post


Link to post
Share on other sites