comp.lang.ada
 help / color / mirror / Atom feed
* Re: Integer division: a winner declared
       [not found]     ` <1970@peora.UUCP>
@ 1986-02-19 10:03       ` Matthew P. Wiener
  1986-02-20 17:38         ` Integer division semantics; Ada Stavros Macrakis
  1986-02-21  4:12         ` Integer division: a winner declared Peter Ladkin
       [not found]       ` <127@diablo.ARPA>
  1 sibling, 2 replies; 8+ messages in thread
From: Matthew P. Wiener @ 1986-02-19 10:03 UTC (permalink / raw)


In article <1970@peora.UUCP> jer@peora.UUCP (J. Eric Roskos) writes:
>The problem is, as far as the implementation of machines is concerned, Ada
>is likely to be the driving force for the forseeable future -- any company
>doing an implementation is faced with either complying with Ada, or
>suffering a performance penalty making the Ada compiler adapt the results
>of the division (in software) to suit the Ada definition.  Due to the
>DoD's requirement for Ada, it seems likely that most manufacturers would
>choose the Ada definition for the divide operations in their instruction
>sets.

You may be interested that many of the largest defense companies/contractors
consider Ada to be a complete joke and have no intention of making it available
unless their programmers start screaming and begging for it.  This includes
Los Alamos National Labs, Lawrence Livermore Labs, the National Security Agency,
NASA and Lockheed.  Considering that all the biggies run UNIX on Cray-2s and
are--if they are intelligent--moving towards workstations that will talk with
the Cray-2s quite easily (read UNIX workstations), it looks like that a large
portion of DoD programming will move towards C, not Ada.

Incidentally, LLL and NSA both have their own private languages.

>[Note that the Ada standard was open for public comment through many
>revisions, so if there was a strong opinion about division, it should have
>been (and probably was) voiced then.]

Yes and no.  Several companies were asked to make suggestions and they
laughed at the Ada idea even then.  I for one do not care what the Ada
standard is, and couldn't imagine why I would have wanted to contribute
any strong feelings about language design to a language I couldn't care
about.  Besides, I wouldn't be surprised if they chose the boneheaded
way of doing integer division for idiotic reasons anyway.

>Thus it looks like the "intuitive" Ada definition wins.

Hardy har har.

[And to net.lang.ada readers: sorry for picking on Ada, but I realize many
of you have no choice in the matter anyway.]

ucbvax!brahms!weemba	Matthew P Wiener/UCB Math Dept/Berkeley CA 94720

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

* Integer division semantics; Ada
  1986-02-19 10:03       ` Integer division: a winner declared Matthew P. Wiener
@ 1986-02-20 17:38         ` Stavros Macrakis
  1986-02-21 18:20           ` Contractors and agencies using Ada  Beth Katz
                             ` (2 more replies)
  1986-02-21  4:12         ` Integer division: a winner declared Peter Ladkin
  1 sibling, 3 replies; 8+ messages in thread
From: Stavros Macrakis @ 1986-02-20 17:38 UTC (permalink / raw)


In a discussion of division standards, Matthew P. Wiener
(weemba@brahms.BERKELEY.EDU) brings up some questions about the role
of Ada:
					<11610@ucbvax.BERKELEY.EDU>
> ...many of the largest defense companies/contractors consider Ada to
> be a complete joke and have no intention of making it available
> unless their programmers start screaming and begging for it.

You appear to have a strange model of programming language choice.
Do you have some documentation for your claims?

> This includes [LANL, LLL, NSA, NASA, Lockheed]. ...

Ada is required only for (most) DoD embedded computer systems.  No one
is trying to impose Ada for scientific (LANL, LLL) applications or in
research in general.  NSA -- who knows?  NASA has selected Ada as the
programming language for the Space Station.  Lockheed will be using
Ada in most future embedded systems.

> Considering that all the biggies run UNIX on Cray-2s and are--if
> they are intelligent--moving towards workstations that will talk
> with the Cray-2s quite easily (read UNIX workstations), it looks
> like that a large portion of DoD programming will move towards C,
> not Ada. ...

There is no contradiction between Unix and Ada.  Indeed, Intermetrics
developed and runs their Ada compiler (Byron Ada) under UTS (Amdahl's
Unix for the 370 architecture) -- as well, of course, as under other
hosts and targets (Note: I consult for Intermetrics).  C was used for
some bootstrap RTS modules which would otherwise have been written in
machine language; they are being rewritten in Ada.

> Incidentally, LLL and NSA both have their own private languages.

This is one of the raisons d'etre of Ada.  The Air Force, the Navy,
the Army, etc. ALL had their own languages, many of them based on
Algol 58 (yes, 58, not 68).  If the LLL and NSA languages have some
special attributes which makes them particularly suited for their
users, I would imagine they will continue to be used.  If, on the
other hand, they are simply not-invented-here growths, I would imagine
they would fade away as more and more facilities (packages, tool)
become available for Ada.

> ... Besides, I wouldn't be surprised if they chose the boneheaded
> way of doing integer division for idiotic reasons anyway. ...  [And
> to net.lang.ada readers: sorry for picking on Ada, but I realize
> many of you have no choice in the matter anyway.]

Insults and condescension don't help your argument.

	-s

	Macrakis@Harvard.{Harvard.EDU,ARPA,uucp,csnet}
		@Harvunxh.bitnet

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

* Re: Integer division: a winner declared
  1986-02-19 10:03       ` Integer division: a winner declared Matthew P. Wiener
  1986-02-20 17:38         ` Integer division semantics; Ada Stavros Macrakis
@ 1986-02-21  4:12         ` Peter Ladkin
  1986-02-21  4:58           ` Peter Ladkin
  1 sibling, 1 reply; 8+ messages in thread
From: Peter Ladkin @ 1986-02-21  4:12 UTC (permalink / raw)


In article <11923@ucbvax.BERKELEY.EDU>, weemba@brahms.BERKELEY.EDU 
(Matthew P. Wiener) writes:
> You may be interested that many of the largest defense companies/contractors
> consider Ada to be a complete joke and have no intention of making it 
> available
> unless their programmers start screaming and begging for it.  This includes
> Los Alamos National Labs, Lawrence Livermore Labs, 
> the National Security Agency,
> NASA and Lockheed.

Considering ADA to be flawed - not in one of your cases.
Having no intention of making it available, again false in two of
your quoted list.
From first hand knowledge.

There is enormous pressure to write in ADA for DOD work.
DOE? No idea.

Peter Ladkin

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

* Re: Integer division: a winner declared
  1986-02-21  4:12         ` Integer division: a winner declared Peter Ladkin
@ 1986-02-21  4:58           ` Peter Ladkin
  0 siblings, 0 replies; 8+ messages in thread
From: Peter Ladkin @ 1986-02-21  4:58 UTC (permalink / raw)


In article <5030@kestrel.ARPA>, ladkin@kestrel.ARPA (Peter Ladkin) writes:
> Considering ADA to be flawed - not in one of your cases.

I meant - at least one of the organisations quoted doesn't 
consider ADA to be flawed.

> Having no intention of making it available, again false in two of
> your quoted list.
> From first hand knowledge.

To be read similarly. Sorry for the confusion.

Peter Ladkin

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

* Re: Integer division: a winner declared
       [not found]       ` <127@diablo.ARPA>
@ 1986-02-21  8:34         ` Gene Ward Smith
  0 siblings, 0 replies; 8+ messages in thread
From: Gene Ward Smith @ 1986-02-21  8:34 UTC (permalink / raw)


In article <127@diablo.ARPA> avg@diablo.UUCP (Allen VanGelder) writes:

>Ada clearly has it right.  Knuth agrees, but spells "rem" differently.
>Ada examples:
>	   5/ 3   =  1		 5 rem  3 =  2		 5 mod  3 =  2
>	(-5)/ 3   = -1		-5 rem  3 = -2		-5 mod  3 =  1
>	   5/(-3) = -1		 5 rem -3 =  2		 5 mod -3 = -2
>	(-5)/(-3) =  1		-5 rem -3 = -2		-5 mod -3 = -1
>

   It looks like I need to unsay most of the bad things I said about Ada.
Sorry about that, Adaphiles, but at first I thought J. Eric Roskos was
saying Ada had two mod-type functions, but later decided he was saying it
had only one (since he said Knuth's was different). I hope foot-in-mouth
disease isn't catching.

>For b > 0, Z_b = {0,1,2,...,b-1} by standard definition.  For b < 0
>I am unaware of any standard definition, but we might as well define
>Z_b = {0,-1,-2,...,b+1}.  Note that b+1 is the multiplicative identity.

   There is a standard remainder defintion for negative b, but it really
doesn't matter; the Knuth/Ada definition is just fine.

>I can't imagine implementing -5/3 = -2.  If you really need this, I

   Just today I needed this. It took an extra (C language) function 
definition. I have *never in my life*, to the best of my recollection,
wanted or needed -5/2 = -1. It's not as important as mod by any means,
so I will just leave you with this thought: it's still wrong, but the 
situation is improving. Maybe the next "language to end all languages"
after Ada will finally get it right.

ucbvax!brahms!gsmith    Gene Ward Smith/UCB Math Dept/Berkeley CA 94720
ucbvax!weyl!gsmith      "Dumb problem. DUMB!!!"

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

* Contractors and agencies using Ada
  1986-02-20 17:38         ` Integer division semantics; Ada Stavros Macrakis
@ 1986-02-21 18:20           `  Beth Katz
  1986-02-21 18:45           ` Integer division semantics; Ada Matthew P. Wiener
  1986-02-21 19:03           ` Matthew P. Wiener
  2 siblings, 0 replies; 8+ messages in thread
From:  Beth Katz @ 1986-02-21 18:20 UTC (permalink / raw)


Matthew P Wiener/UCB Math Dept/Berkeley CA 94720
ucbvax!brahms!weemba    writes:
> You may be interested that many of the largest defense companies/
> contractors consider Ada to be a complete joke and have no intention
> of making it available unless their programmers start screaming and
> begging for it.  This includes Los Alamos National Labs, Lawrence
> Livermore Labs, the National Security Agency, NASA and Lockheed. 
> Considering that all the biggies run UNIX on Cray-2s and are--if
> they are intelligent--moving towards workstations that will talk
> with the Cray-2s quite easily (read UNIX workstations), it looks
> like that a large portion of DoD programming will move towards C,
> not Ada.

To set the record straight (and followup on Macrakis's comments),
NASA has decided to use Ada for Space Station.  At NASA's Goddard
Space Flight Center, one flight dynamics simulator is being developed
by two teams to examine the feasibility of using Ada.  One team
is using Ada while the other is using the more traditional FORTRAN. 
Detailed data (collected as part of the Software Engineering Laboratory)
will be examined from both practical and research perspectives to
help NASA make a decision about using Ada.  Ada is being used as
the only development language on at least one other project at Goddard. 
I'm fairly sure that other NASA sites are also considering using Ada. 
NASA hasn't dismissed it out-of-hand and certainly doesn't consider
it a joke.

As far as UNIX workstations and Ada being mutually exclusive (it
seems to me that Wiener's statement implies that), Verdix has a
compiler running under UNIX on Sun workstations.  NASA Goddard
is using DEC's VMS/Ada on their Vaxen.  Not everybody uses Crays.

No comment from me on the other 'biggies' mentioned above.  I
hesitate to lump everyone together.

			Elizabeth Katz
			Dept. of CS - Univ. of Maryland
Arpanet:  beth@mimsy.umd.edu
CSnet:    beth@umcp-cs
Usenet:   ...!seismo!umcp-cs!beth
*** I'm one of the monitors for the Goddard dual development,  ***
*** and I've been using the Verdix compiler on our Vaxen which ***
*** run UNIX.  All opinions mentioned above are my own.        ***

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

* Re: Integer division semantics; Ada
  1986-02-20 17:38         ` Integer division semantics; Ada Stavros Macrakis
  1986-02-21 18:20           ` Contractors and agencies using Ada  Beth Katz
@ 1986-02-21 18:45           ` Matthew P. Wiener
  1986-02-21 19:03           ` Matthew P. Wiener
  2 siblings, 0 replies; 8+ messages in thread
From: Matthew P. Wiener @ 1986-02-21 18:45 UTC (permalink / raw)


Perhaps the following belongs to e-mail only, but I'm willing to apologize
for the gratuitous Ada-bashing.  I was rather stunned at the attitude that
"Ada does it that way so it must be right" in the posting I had ridiculed.

In article <728@harvard.UUCP> macrakis@harvard.UUCP (Stavros Macrakis) writes:
>In a discussion of division standards, Matthew P. Wiener
>(weemba@brahms.BERKELEY.EDU) brings up some questions about the role
>of Ada:
>					<11610@ucbvax.BERKELEY.EDU>
>> ...many of the largest defense companies/contractors consider Ada to
>> be a complete joke and have no intention of making it available
>> unless their programmers start screaming and begging for it.
>
>You appear to have a strange model of programming language choice.
>Do you have some documentation for your claims?

It comes from talking to numerous people who work at such places over
the years.  Condescension and derision were the usual attitude, and I
was passing it along.  Comments like "Didn't DoD have the same hopes
for COBOL? Hardy Har Har." were typical.

I should emphasize this attitude does not reflect on the language so much
as on the DoD == fubar equation.

>> ... Besides, I wouldn't be surprised if they chose the boneheaded
>> way of doing integer division for idiotic reasons anyway. ...  [And
>> to net.lang.ada readers: sorry for picking on Ada, but I realize
>> many of you have no choice in the matter anyway.]
>
>Insults and condescension don't help your argument.

Then I'll say it politely: the mathematically boneheaded way of doing
integer division does not seem to have much inherently logical reasons
for being adopted, yet it is nearly universal in computer languages.  The
article I was replying to asked why hadn't I or others who care about the
matter given input to the language when we had the chance.  I suspect that
such input was ignored--the discussion on integer division has mostly re-
vealed "idiotic reasons" for supporting the traditional implementation--and
I wouldn't be surprised if they followed the tradition.

But it seems Ada has both 'mod' and 'rem': but the posting I was responding
to ('rem' is the winner in the great integer division debate since Ada does
it that way) seemed to imply that it only had 'rem'.  So I stand corrected.

ucbvax!brahms!weemba	Matthew P Wiener/UCB Math Dept/Berkeley CA 94720

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

* Re: Integer division semantics; Ada
  1986-02-20 17:38         ` Integer division semantics; Ada Stavros Macrakis
  1986-02-21 18:20           ` Contractors and agencies using Ada  Beth Katz
  1986-02-21 18:45           ` Integer division semantics; Ada Matthew P. Wiener
@ 1986-02-21 19:03           ` Matthew P. Wiener
  2 siblings, 0 replies; 8+ messages in thread
From: Matthew P. Wiener @ 1986-02-21 19:03 UTC (permalink / raw)


Perhaps the following belongs to e-mail only, but I'm willing to apologize
for the gratuitous Ada-bashing.  I was rather stunned at the attitude that
"Ada does it that way so it must be right" in the posting I had ridiculed.

In article <728@harvard.UUCP> macrakis@harvard.UUCP (Stavros Macrakis) writes:
>In a discussion of division standards, Matthew P. Wiener
>(weemba@brahms.BERKELEY.EDU) brings up some questions about the role
>of Ada:
>					<11610@ucbvax.BERKELEY.EDU>
>> ...many of the largest defense companies/contractors consider Ada to
>> be a complete joke and have no intention of making it available
>> unless their programmers start screaming and begging for it.
>
>You appear to have a strange model of programming language choice.
>Do you have some documentation for your claims?

It comes from talking to numerous people who work at such places over
the years.  Condescension and derision were the usual attitude, and I
was passing it along.  Comments like "Didn't DoD have the same hopes
for COBOL? Hardy Har Har." were typical.

I should emphasize this attitude does not reflect on the language so much
as on the DoD == fubar equation.

>> ... Besides, I wouldn't be surprised if they chose the boneheaded
>> way of doing integer division for idiotic reasons anyway. ...  [And
>> to net.lang.ada readers: sorry for picking on Ada, but I realize
>> many of you have no choice in the matter anyway.]
>
>Insults and condescension don't help your argument.

Then I'll say it politely: the mathematically boneheaded way of doing
integer division does not seem to have much inherently logical reasons
for being adopted, yet it is nearly universal in computer languages.  The
article I was replying to asked why hadn't I or others who care about the
matter given input to the language when we had the chance.  I suspect that
such input was ignored--the discussion on integer division has mostly re-
vealed "idiotic reasons" for supporting the traditional implementation--and
I wouldn't be surprised if they followed the tradition.

But it seems Ada has both 'mod' and 'rem'.  The posting I was responding
to, by asserting that 'rem' is the winner in the great integer division
debate since Ada does it that way, seemed to imply that it only had 'rem'.
So I stand corrected and the former paragraph is moot.

ucbvax!brahms!weemba	Matthew P Wiener/UCB Math Dept/Berkeley CA 94720

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

end of thread, other threads:[~1986-02-21 19:03 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <11610@ucbvax.BERKELEY.EDU>
     [not found] ` <5100003@ccvaxa>
     [not found]   ` <548@ism780c.UUCP>
     [not found]     ` <1970@peora.UUCP>
1986-02-19 10:03       ` Integer division: a winner declared Matthew P. Wiener
1986-02-20 17:38         ` Integer division semantics; Ada Stavros Macrakis
1986-02-21 18:20           ` Contractors and agencies using Ada  Beth Katz
1986-02-21 18:45           ` Integer division semantics; Ada Matthew P. Wiener
1986-02-21 19:03           ` Matthew P. Wiener
1986-02-21  4:12         ` Integer division: a winner declared Peter Ladkin
1986-02-21  4:58           ` Peter Ladkin
     [not found]       ` <127@diablo.ARPA>
1986-02-21  8:34         ` Gene Ward Smith

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