donh@microsoft.UUCP (Don HACHERL) (02/09/90)
In article <274.25C5867A@weyr.FIDONET.ORG> Kenneth.Neal@p0.f69.n110.z1.FIDONET.ORG (Kenneth Neal) writes: > > AF> That's what MS MASM 5.1 for OS/2 wants. > > The compiler does not use IOPL. CodeView, wants IOPL=YES. There is >code in OS/2, for a Debugger to use. I wonder why CodeView, doesn't use >it. (Instead of resorting to IOPL.) CodeView *does* use DosPTrace; IOPL does not let you poke around in other processes' private memory the way a debugger needs to. The reason CV requires IOPL is to avoid avoid deadlocks accessing the screen. The VIO subsystem serializes screen accesses with a semaphore. If you break into your app while it's holding the VIO semaphore, no other app that uses VIO will be able to write to the screen. If CV used VIO this would leave your system completely hung, so it pokes at the video memory directly (which requires IOPL) instead. No sinister plot to avoid using published interfaces, just an annoying hack to avoid deadlock. Don -- Don Hacherl "Sorry, no pithy quotes today" donh%microsof@uunet.uu.net or {uunet|uw-beaver}!microsoft!donh Disclaimer: Little of what I say should be taken seriously, and none should be taken as the opinion of my employer.