Date: Sun, 28 Sep 1997 18:47:14 +0200 (IST) From: Eli Zaretskii To: Oberhumer Markus cc: dj AT delorie DOT com, djgpp-workers AT delorie DOT com, malcolm AT manawatu DOT gen DOT nz, Charles Sandmann Subject: Re: [malcolm AT manawatu DOT gen DOT nz: Fork source code.] In-Reply-To: <199709261425.RAA26936@is.elta.co.il> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Precedence: bulk On Fri, 26 Sep 1997, Oberhumer Markus wrote: > > * Charles once told me that there are many bugs and subtleties > > in the way different DPMI hosts implement functions 0900h > > and 0901h. This code uses these heavily and seems to rely > > on the fact that no interrupt will arrive when the virtual > > interrupts are disabled. Will this assumtion hold? What, > > if any, are other implications, for the case of this code, > > of whatever problems there are in the different > > implementations of 0900h out there? > > You can easily lock at least Windows 3.1 with some calls to 0900/0901. > > I'm always using the following macros in my programs: > #define disable() __asm__ __volatile__("cli \n"); > #define enable() __asm__ __volatile__("sti ; cld \n"); Charles, what do you think about this? (My message quoted by Thomas refers to an implementation of `fork' that creates multiple threads in the same program by using a user-defined software signal generated on each timer tick. It was submitted to DJ for inclusion in v2.02.)