Solved

DLLs and Memory

Posted on 2002-05-22
3
212 Views
Last Modified: 2010-04-15
I am curious as to how DLLs work in memory most specifically whether the whole DLL is loaded into memory when a single function is called (or class instantiated).

I am mostly interested in terms of COM objects.

Basically can someone tell me what the performance/memory differences are in calling a class in a DLL that contains many other classes as opposed to calling a dll that has a single class?

0
Comment
Question by:JustinB
  • 2
3 Comments
 
LVL 10

Accepted Solution

by:
makerp earned 50 total points
Comment Utility
yes, when you use a dll even if only one function is used then the whole dll is loaded. if this is the case for you you may be better linking staticaly to the dll (only possible if you have a .lib that is a static equavilent)

dlls should only be used if more than one program can use what they have otherwise it aint worth it. obviosly the more classes in a dll the bigger the dll, the more memory it will use and the longer it will take to load
0
 
LVL 1

Author Comment

by:JustinB
Comment Utility
Thats what I thought, thanks.
0
 
LVL 10

Expert Comment

by:makerp
Comment Utility
glad to be of help
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Preface I don't like visual development tools that are supposed to write a program for me. Even if it is Xcode and I can use Interface Builder. Yes, it is a perfect tool and has helped me a lot, mainly, in the beginning, when my programs were small…
Windows programmers of the C/C++ variety, how many of you realise that since Window 9x Microsoft has been lying to you about what constitutes Unicode (http://en.wikipedia.org/wiki/Unicode)? They will have you believe that Unicode requires you to use…
Video by: Grant
The goal of this video is to provide viewers with basic examples to understand and use nested-loops in the C programming language.
The goal of this video is to provide viewers with basic examples to understand and use conditional statements in the C programming language.

763 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

6 Experts available now in Live!

Get 1:1 Help Now