comp.lang.ada
 help / color / mirror / Atom feed
* Re: Say it isn't so! (Formerly: Ada replacements for DOS I/O)
@ 1994-10-31 12:51 cwarwick
  0 siblings, 0 replies; 6+ messages in thread
From: cwarwick @ 1994-10-31 12:51 UTC (permalink / raw)


On Fri, 28 Oct 1994 11:59:00 PDT, 
Bennett, Chip  <BennettC@J64.STRATCOM.AF.MIL> wrote:

>We use SunAda (aka Verdix) with Motif.  Does this mean that if an
>application is drawing to the screen and number crunching at the same time
>in a separate Ada task, that the "background" task is going to be suspended
>for the same I/O interrupts that the "foreground" task is being suspended?

Well my experiments under SCO and Verdix have shown me that a blocking OS 
call, i.e. READ, will halt both the foreground and background task until it 
has completed... (my data is not yet complete, when I hit the problem on 
DOS I went over and quickly checked on the SCO box)

>Does everyone else consider this acceptable, or am I the only one that is
>appalled?

I don't hold any view. My plan is to switch to Unix processes on the SCO 
and avoid the problem altogether... so much for system independance
 --
 Lorne Elliot in a Conan the Barabarian suit, or
 "Beware the fool, for only the fool may speak the truth"

 Chris Warwick
 cwarwick@fox.nstn.ns.ca
 warwick@anchor.hfx.prior.ca



^ permalink raw reply	[flat|nested] 6+ messages in thread
* Re: Say it isn't so! (Formerly: Ada replacements for DOS I/O)
@ 1994-10-31 14:45 CONDIC
  0 siblings, 0 replies; 6+ messages in thread
From: CONDIC @ 1994-10-31 14:45 UTC (permalink / raw)


From: Marin David Condic, 407.796.8997, M/S 731-93
Subject: Re: Say it isn't so! (Formerly: Ada replacements for DOS I/O)
Original_To:  PROFS%"SMTP@PWAGPDB"
Original_cc:  CONDIC



>"Bennett, Chip (KTR) ~U" <BennettC@J64.STRATCOM.AF.MIL> wrote:
>
>Chris Warwick <cwarwick@FOX.NSTN.NS.CA> wrote:
>
>> We just got burned on a project using Alsys Ada. Seems we had assumed that
>> a multi-tasking Ada program would perform I/O is parallel with other
>> processing. The system service call actucally halts all processing in the
>> program until the system service is complete...
>
>> I don't mean to burn Alsys, since the bug(?) also exists in the Verdix
>> compiler we are using. The difference is the Verdix is for Unix so we just
>> sidestepped the problem by not using Ada tasks...
>
>We use SunAda (aka Verdix) with Motif.  Does this mean that if an
>application is drawing to the screen and number crunching at the same time
>in a separate Ada task, that the "background" task is going to be suspended
>for the same I/O interrupts that the "foreground" task is being suspended?
>
>Does everyone else consider this acceptable, or am I the only one that is
>appalled?

In my experience with DEC Ada for VAX/VMS, the same problem
occurs. If a task performs an I/O operation, the runtime system
does not consider the task blocked and thus has no reason to
start running other tasks.

I believe that we fixed this problem by juggling task priorities
so that I/O tasks were at the bottom of the list, but I don't
recall if the preemptive scheduling was able to interrupt the
pending QIO. The only way to successfully fix this would have
been to dip into very serious system calls within the context of
the task to shoot the QIO in the head in the event that there was
nothing pending. This may have been what we did, but it's been
such a long time now and my two or three remaining brain cells
have a hard time executing a successful "rendezvous"

I don't know as I'd call this a "bug" because Ada never specified
a scheduling algorithm, nor was I/O ever explicitly considered as
some sort of tasking structure which would require the task to be
blocked. (A call to "TEXT_IO.GET (ITEM => X);" was never
specified to behave as the execution of "wait 1.0;" or "accept
THIS_ENTRY;) Hence an implementation could legally consider the
task to be running - not blocked - and do nothing to preempt it.

I share your frustration in that it would be *extremely* handy
for a task to be considered blocked or ready whenever the
underlying operating system would consider a process blocked or
ready. However, I can understand the difficulty of actually
getting this to work. It isn't always easy to design an Ada
runtime kernal and have it match up nicely with an underlying
operating system that wasn't designed to deliberately support
Ada.

Pax,
Marin


Marin David Condic, Senior Computer Engineer    ATT:        407.796.8997
M/S 731-93                                      Technet:    796.8997
Pratt & Whitney, GESP                           Internet:   CONDICMA@PWFL.COM
P.O. Box 109600                                 Internet:   MDCONDIC@AOL.COM
West Palm Beach, FL 33410-9600
===============================================================================
    "I like to dive around in my money like a porpoise and burrow
    through it like a gopher and toss it up and let it hit me on the
    head."

        --  Scrooge McDuck
===============================================================================



^ permalink raw reply	[flat|nested] 6+ messages in thread
* Say it isn't so! (Formerly: Ada replacements for DOS I/O)
@ 1994-10-28 18:59 Bennett, Chip (KTR) ~U
  1994-10-30 15:31 ` Robert Dewar
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Bennett, Chip (KTR) ~U @ 1994-10-28 18:59 UTC (permalink / raw)


Chris Warwick <cwarwick@FOX.NSTN.NS.CA> wrote:

> We just got burned on a project using Alsys Ada. Seems we had assumed that
> a multi-tasking Ada program would perform I/O is parallel with other
> processing. The system service call actucally halts all processing in the
> program until the system service is complete...

> I don't mean to burn Alsys, since the bug(?) also exists in the Verdix
> compiler we are using. The difference is the Verdix is for Unix so we just
> sidestepped the problem by not using Ada tasks...

We use SunAda (aka Verdix) with Motif.  Does this mean that if an
application is drawing to the screen and number crunching at the same time
in a separate Ada task, that the "background" task is going to be suspended
for the same I/O interrupts that the "foreground" task is being suspended?

Does everyone else consider this acceptable, or am I the only one that is
appalled?

*****************************************************************
* Chip Bennett, GDE Systems Inc | BennettC@j64.stratcom.af.mil  *
* USSTRATCOM/J64213             | Voice (402)294-7360           *
* 901 SAC Blvd, Suite 2B24      | FAX   (402)294-7912           *
* Offutt AFB, NE 68113-6600     | Opinions expressed are my own *
*****************************************************************



^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~1994-11-05  3:04 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1994-10-31 12:51 Say it isn't so! (Formerly: Ada replacements for DOS I/O) cwarwick
  -- strict thread matches above, loose matches on Subject: below --
1994-10-31 14:45 CONDIC
1994-10-28 18:59 Bennett, Chip (KTR) ~U
1994-10-30 15:31 ` Robert Dewar
1994-10-31 10:36 ` Rudy Zijlstra
1994-11-05  3:04 ` R. William Beckwith

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox