[Info-vax] Volatile, was: Re: yet another sys$qiow question

Bob Gezelter gezelter at rlgsc.com
Wed Aug 26 23:22:17 EDT 2015


On Wednesday, August 26, 2015 at 10:10:52 PM UTC-4, David Froble wrote:
> John Reagan wrote:
> > Looking at the code, the updating of the IOSB is done very carefully.  There
> > are EVAX_MB builtins used in the code (it is in Macro32) and they make very
> > sure that the first longword is always filled in last (with an MB between
> > storing into the 2nd longword and storing into the 1st longword).  I also
> > found code that worries about misaligned IOSBs to ensure atomic updating
> > (including letting an alignment fault occur just to get proper
> > synchronization).
> > 
> > Looking in just the [SYS] facility (so that doesn't even count drivers, RMS,
> > RTLs, etc.), I found 389 uses of the MB instruction.  That EVAX_MB builtin is
> > mapped to the 'mf' instruction for Itanium.  There are equivalent
> > instructions for x86 although the stronger memory ordering rules might make
> > some of them unnecessary (but I doubt that the Macro compiler will be able to
> > figure that out without human assistance)
> 
> 
> Ok, a question.  Just curious.
> 
> Do you have any feel for how much time might be saved by monitoring the IOSB 
> status instead of using one of the signaling methods, such as an AST or event flag?

David,

It depends upon what you mean by "monitoring the IOSB". 

Spinning of any sort will be expensive. "Periodically checking" means that there is some other event stream occurring, with its limits on latency.

ASTs are very low overhead.

- Bob Gezelter. http://www.rlgsc.com



More information about the Info-vax mailing list