Log In
0 votes
Dynamically Linked Libraries imply more page faults than static? Why?
in Operating System 192 views

2 Answers

0 votes
in case of static linking we will load everything at one time and there will be no dependency at run time and all required library are there in Main memory but in case of dynamic linking everytime we need to refer library it will load and run time which creates page fault.So Dynamic linking will have more page faults.
0 votes
Because in dynamically linked libraries, libraries are'nt moved to memory with the program, when a program needs a dll, it search in the memory for already present dll, but if it didn't find the required dll in memory, then page fault happens and it is imported.

With static linked libraries, a copy of library is linked with program at compile time and is therefore imported to memory with the program.

Related questions

1 vote
0 answers
Consider five memory partitions of size $100 \text{ KB }, 500 \text{ KB }, 200 \text{ KB }, 450 \text{ KB and } 600 \text{ KB }$ ... Fit algorithm First Fit algorithm Both next fit and best fit results in same None of the above Answer given by ME: Option $(B)$ My answer: Option $(D)$
asked Dec 26, 2018 in Operating System zeeshanmohnavi 339 views
0 votes
0 answers
consider a 900KB memory is managed using variable partitions but no compaction it currently has 3 processes occupied partition sizes 212KB 114KB and 100KB respectively which of the following smallest request wil be denied a)475 b)285 c)355 d)none of the above
asked Dec 17, 2018 in Operating System suneetha 396 views