Title: | DECmcc user notes file. Does not replace IPMT. |
Notice: | Use IPMT for problems. Newsletter location in note 6187 |
Moderator: | TAEC::BEROUD |
Created: | Mon Aug 21 1989 |
Last Modified: | Wed Jun 04 1997 |
Last Successful Update: | Fri Jun 06 1997 |
Number of topics: | 6497 |
Total number of notes: | 27359 |
I'm writting an application on the top of nDBm package, and because the MIR is also built on the top of nDBm, I thinck that my application could interfere with the MIR. In others word, I protect the nDBm routines from thread re-entrance using a CMA mutex ( jacket package), and from concurrent process write access using the ULTRIX flock system call ( and I thinck that the MIR do the same thing ). Then we share the same nDBm routines with two different mutexes, AIE.. ( bad in french ..). Is there a way to avoid this conflict ? Following are suggestions: 1 - : I use the MIR mutex to mutex-lock my routines before calling to nDBm routines. 2 - : I link my program with an nDBm protected routines (the same routines as used to build the MIR routines) note: I used nDBm and the MIR ( in the same process) in my application.
T.R | Title | User | Personal Name | Date | Lines |
---|---|---|---|---|---|
1600.1 | TOOK::SWIST | Jim Swist LKG2-2/T2 DTN 226-7102 | Fri Oct 04 1991 11:46 | 8 | |
Aucun probleme. All non-reentrant operating system routines are protected with the SAME mutex, which is the one hidden behind mcc_mutex_lock_global (cma_mutex_lock_global). That's why the global mutex was invented. Do not use a private mutex to protect OS routines because it won't work, as your note correctly deduces. Bonne chance. | |||||
1600.2 | TOOK::SWIST | Jim Swist LKG2-2/T2 DTN 226-7102 | Fri Oct 04 1991 11:58 | 4 | |
And as an aside, aren't you (we) glad they invented ndbm? With the old dbm routines, you couldn't open more than one DBM file at a time PER PROCESS. Yuck. | |||||
1600.3 | reply 1600.2 | RIVAGE::BACCAR | Mon Oct 07 1991 10:38 | 2 | |
the global mutex of course ... thanck you for your help . |