Outofprocess component to load dll multiple times

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,
I have a fortran dll that is developed by somebody else (available
commercially).
This dll uses a COMMON block which is not threadsafe and hence causing quite
a bit of problems.
Iam using a managed c++ class as a wrapper for this native dll. Is there a
way to load the dll multiple times so that I have a new dll instance
everytime I instantiate the managed c++ wrapper class ? An approach like this
would help eliminate the probelms due to the fortran dll not being threadsafe.
I would have loved to - but modifying the dll is not an option.

thank you.
vikrantca
 
You can load that dll into separate application domain. The drawback of this
approach are marshalling issues, which can reduce performance.

Another option - modification of wrapper C++ class. You can make it thread
safe. If you're working only through that wrapper then making it threadsafe
is even better option then loading it in the separate domain.
 
Back
Top