Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

how to preload a shared object

Posted on 2009-07-15
8
Medium Priority
?
274 Views
Last Modified: 2013-12-15
the requirement is i have .so file  shared.so which linked with b.exe  i have not used any dlopen() to load it is just early run time loading, i heard if we preload this shared.so file

the execution will be improved ? so how to preload a shared.so file.
0
Comment
Question by:tittu
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
8 Comments
 
LVL 53

Expert Comment

by:Infinity08
ID: 24857908
If you add the name of the shared library file to the LD_PRELOAD environment variable, it will be pre-loaded when starting your application, ie. potentially overriding standard C library functions.
However, I'm not sure that's what you meant when you were talking about pre-loading.

Could you clarify what you mean by pre-loading, and where you heard that the "execution will be improved" ?
0
 

Author Comment

by:tittu
ID: 24859055
I think all the Standard applications use pre-loading concept in fact firefox will have its preloader,
gnome nautilus will have its own preloader.
0
 
LVL 53

Expert Comment

by:Infinity08
ID: 24859998
The kind of preloader you're talking about is only useful if you start and stop your application frequently. Is that the case ?
The Firefox Preloader you mentioned, for example, would actually load most of firefox into memory whether you're running it or not, so that when you actually start it, it's faster. Personally, I think it's a bit silly ... If you want to avoid slow startup times, then just don't re-start it once it's started ... You achieve the exact same thing as when using the preloader.

If you want the same thing, then you can just write another application that loads the shared library in memory, and keep it running. When you start your main application, it should use the already loaded shared library, and might thus be slightly faster.
0
Simplifying Server Workload Migrations

This use case outlines the migration challenges that organizations face and how the Acronis AnyData Engine supports physical-to-physical (P2P), physical-to-virtual (P2V), virtual to physical (V2P), and cross-virtual (V2V) migration scenarios to address these challenges.

 

Author Comment

by:tittu
ID: 25366382
not useful comments not expertise
0
 
LVL 53

Expert Comment

by:Infinity08
ID: 25366441
What do you mean by that ?
0
 

Author Comment

by:tittu
ID: 25371597
I need the .so file should be loaded into memory so that the process/exe depends on the .so  start up time will be faster
0
 
LVL 53

Accepted Solution

by:
Infinity08 earned 1000 total points
ID: 25371901
Yes. And that's what I explained in http:#24859998. Which part of it do you want clarification on ?
0
 

Author Closing Comment

by:tittu
ID: 31603643
i cant understand
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

Question has a verified solution.

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

Fine Tune your automatic Updates for Ubuntu / Debian
Google Drive is extremely cheap offsite storage, and it's even possible to get extra storage for free for two years.  You can use the free account 15GB, and if you have an Android device..when you install Google Drive for the first time it will give…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…
Suggested Courses

721 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