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

David Froble davef at tsoft-inc.com
Thu Aug 27 19:59:06 EDT 2015


VAXman- @SendSpamHere.ORG wrote:
> In article <00AFC46D.EA88A745 at SendSpamHere.ORG>, VAXman-  @SendSpamHere.ORG writes:
>> In article <mrnbn4$o0c$1 at dont-email.me>, David Froble <davef at tsoft-inc.com> writes:
>>> Bob Gezelter wrote:
>>>> 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
>>> Well, yes Bob, that's how I see things also.  But we would not be discussing 
>>> polling the IOSB status unless someone came up with the (in my opinion very 
>>> poor) idea of doing so.  I'm trying to understand why anyone would come up with 
>>> the idea, unless as JF suggests they came from a MS-DOS background where there 
>>> were no ASTs or any signaling capabilities that I'm aware of.
>> Because, the programmer's language of choice equivalent of:
>>
>> 10$:	BLBC	IOSB,10$
> 
> Sorry, brainfart...
> 
> 10$:	TSTW	IOSB
> 	BEQL	10$
> 
>> is so efficient... NOT!  Why would anybody POLL the IOSB?  I thing that those
>> CPU cycles could be put to far better use.
>>
>>
>>>  As Steve 
>>> suggests, if I/O performance needs tweeking, there is IO_PERFORM.
>> And one STILL needs to check the status in the IOSA.
>>
>> -- 
>> VAXman- A Bored Certified VMS Kernel Mode Hacker    VAXman(at)TMESIS(dot)ORG
>>
>> I speak to machines with the voice of humanity.

No problem Brian, I understood what you were trying to say.

And I'm still asking, why would anyone do such?  Is there any valid reason?



More information about the Info-vax mailing list