[Info-vax] LLVM, volatile and async VMS I/O and system calls

chris chris-nospam at tridac.net
Thu Sep 23 17:41:07 EDT 2021


On 09/23/21 18:58, Simon Clubley wrote:
> On 2021-09-23, chris<chris-nospam at tridac.net>  wrote:
>>
>> Not really, as no code in a high level language should be written so
>> as to depend on the sequence of instructions generated. If you want
>> that defined more tightly, then you should be using assembler, or
>> have intimate knowledge of compiler translations and output.
>>
>> One of the functions of a high level language is to provide an
>> abstraction layer between applications and the underlying machine.
>> Of course, that doesn't apply to systems or kernel programming but
>> such work requires a much deeper understanding of comp sci algorithmics
>> than simple application programming...
>>
>> Chris
>
> Chris,
>
> Are you familiar with true asynchronous I/O in normal applications
> where the operating system can write directly into your address space
> without the program having to wait around in a system call to actually
> receive that data and while the program is actually busy doing something
> else at the same time?
>
> Simon.
>


But of course. In the case of a dma transfer, the app
allocates a buffer, fills in a parameter block, than calls a system
service to do the transfer, The app then receives a message or signal to
show that the transfer is complete. Fairly standard os practice. May
also register a callback function to tidy up and complete the operation.

It get"s more complicated for say disk io, where several processes may
queue "n" reads or writes, in any order and timeline, but due to seek
times, disk behaviour and more, the returned replies may not be in
the same order as the requests. However, each reply will be directed
to the process that requested it. That's what I mean by async io, but
perhaps there is another definiton ?.

Still doesn't explain why a volatiie keyword might be needed at
application level, though I guess there might be a few edge cases...

Chris



More information about the Info-vax mailing list