Dynamically Linked Libraries

K

Kwan

Hi All,

In a Unix system (I am using Solaris, but not limited to it), who will
dynamically linked libraries been linked to a multithreaded process?

Will it have a different instance for every single thread, or just one
copy and shared amough all threads?

I have some static member variables in the class suggested that every
single threads is having their own instance. Is that true?

Thanks in advance.
 
A

Adam Fineman

Kwan said:
Hi All,

In a Unix system (I am using Solaris, but not limited to it), who will
dynamically linked libraries been linked to a multithreaded process?
The answer to that question is platform-specific, has nothing to do with
the C++ language, and is off-topic in this newsgroup.
Will it have a different instance for every single thread, or just one
copy and shared amough all threads?

I have some static member variables in the class suggested that every
single threads is having their own instance. Is that true?
The C++ language knows nothing of threads.

For the first question, look for a newsgroup with 'unix' in the title.
For the rest, look for a newsgroup with 'thread' in the title.

HTH,

- Adam
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,147
Messages
2,570,833
Members
47,378
Latest member
BlakeLig

Latest Threads

Top