Solved

DLLs and Memory

Posted on 2002-05-22
3
224 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
ID: 7041703
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
ID: 7041794
Thats what I thought, thanks.
0
 
LVL 10

Expert Comment

by:makerp
ID: 7041813
glad to be of help
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
how to connect an iphone application to mysql database 10 189
pgpool-II on Ubuntu 14.04... ARGH! 5 846
Finding a good hash function 4 120
Problem to scan all sheets 3 95
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…
Summary: This tutorial covers some basics of pointer, pointer arithmetic and function pointer. What is a pointer: A pointer is a variable which holds an address. This address might be address of another variable/address of devices/address of fu…
The goal of this video is to provide viewers with basic examples to understand recursion 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.

867 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

20 Experts available now in Live!

Get 1:1 Help Now