Dynamic Binding

Why is Dynamic binding (regarding DLLs) are considered better in comparison with static binding? What are DLLs and how they work?

Questions by Anshu007

Showing Answers 1 - 6 of 6 Answers

sim_sam

  • Feb 12th, 2009
 

While generating the binary executable, a compiler have two options:

1. It can include the helper libraries (third party libraries for example) with the exe file in binary form which increases the size of the final exe but the exe file can run on its own without needing any more libraries to be included by the end user/client.

2. These libraries are included on run time by the end user  as DLLs. Advantage is that the final size of the shipped exe file is small. On run time, these DLLs are dynamically linked to the exe file.

  Was this answer useful?  Yes

ajrobb

  • Sep 22nd, 2010
 

Dynamic binding in MS Windows or shared objects in Unix are libraries compiled with position-independent code that are similar to program files. Their advantages include:

1. Different programs using the same library can share the library text and const memory segments.

2. Programs files can be smaller as they do not have to include all the executable code.

3. Fixes to the dynamic/shared objects don't require changes to the executable program files that use them.

4. They can be dynamically loaded by a running program to plug in extended program function.

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions