comp.lang.ada
 help / color / mirror / Atom feed
* Re: Language Challenge 2000 - Update
       [not found]   ` <87bbro$9281@news.cis.okstate.edu>
@ 2000-02-03  0:00     ` Brian Rogoff
  2000-02-03  0:00       ` David Starner
  0 siblings, 1 reply; 12+ messages in thread
From: Brian Rogoff @ 2000-02-03  0:00 UTC (permalink / raw)


On 3 Feb 2000, David Starner wrote:
> On Thu, 03 Feb 2000 01:14:35 -0600, Bobby D. Bryant <bdbryant@mail.utexas.edu> wrote:
> >bvoh@sdynamix.com wrote:
> >
> >> as a special recognition for demonstrated skills in crafting the fastest
> >> solution with a smallest footprint.
> >
> >You are, IMO, propagating the wrong value system.  Why don't you sponsor a
> >contest that subordinates speed and footprint to the *really* important
> >stuff like fault-freeness and maintainability?
> 
> I get the feeling that they aren't reading these lists, so this isn't 
> going to do anything.
> 
> One interesting language contest, though, is the International Functional 
> Programming Contest. The main values for the last one were correctness,
> and rapid development with a touch of speed. I think Ada would be a poor
> language for it though, as the winners (or just those who were correct)
> all ran nice high level languages. (All the C entries failed to be
> correct, IIRC.)

Unless I misread the results, some C and C++ teams (as well as Perl and
Python teams) were correct, they just weren't in the top six. 

> I didn't want to worry about not having garbage collecting 
> or hetrogenous lists, so I went with Icon.

If you had a library, you could have heterogeneous lists and more in 
Ada. For GC, I suppose you'd have to use AppletMagic. 

Another choice might be to use a language with GC, built in lists, a
powerful module system with signatures, strong static typing (which Icon
lacks), higher order functions, and an implementation with a rich tool set 
for constructing compilers. I wonder if there is such a beast? ;-)

> I would be deeply impressed
> with anyone who got Ada into the victory circle.

I think its tougher to write code quickly in Ada or C++ than in a good FP, 
like OCaml, and these contests favor speed of writing.

I think "fastest running solution with smallest footprint" would favor 
low level languages like Ada or C++. Writing a BDD library or a numerical 
linear algebra library which has to run fast is tougher in an FP, though 
you can always use the LLL as output, like FFTW does.

-- Brian






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

* Re: Language Challenge 2000 - Update
  2000-02-03  0:00     ` Language Challenge 2000 - Update Brian Rogoff
@ 2000-02-03  0:00       ` David Starner
  2000-02-03  0:00         ` David Emery
  2000-02-03  0:00         ` Brian Rogoff
  0 siblings, 2 replies; 12+ messages in thread
From: David Starner @ 2000-02-03  0:00 UTC (permalink / raw)


On Thu, 3 Feb 2000 08:22:04 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
>On 3 Feb 2000, David Starner wrote:
>> One interesting language contest, though, is the International Functional 
>> Programming Contest. The main values for the last one were correctness,
>> and rapid development with a touch of speed. I think Ada would be a poor
>> language for it though, as the winners (or just those who were correct)
>> all ran nice high level languages. (All the C entries failed to be
>> correct, IIRC.)
>
>Unless I misread the results, some C and C++ teams (as well as Perl and
>Python teams) were correct, they just weren't in the top six. 

Sorry - two out of the nine C teams were correct. It was the two Perl
teams that got sunk. 

>> I didn't want to worry about not having garbage collecting 
>> or hetrogenous lists, so I went with Icon.
>
>If you had a library, you could have heterogeneous lists and more in 
>Ada. 
You'd have to derive every thing from the same base tagged type, or
have a library with some serious C level pointer evil. Alternately,
I could set up variant records.

>For GC, I suppose you'd have to use AppletMagic. 
Or wrap the Boehm-Weiser GC library.

>Another choice might be to use a language with GC, built in lists, a
>powerful module system with signatures, strong static typing (which Icon
>lacks),

Of course, I would have found strong static typing in my way with those
hetrogenous lists.

>higher order functions, and an implementation with a rich tool set 
>for constructing compilers. I wonder if there is such a beast? ;-)
Hmm? ML, I guess. The compiler part was only applicable to last year,
though. It's a Scheme-style syntax - it's not a big deal to parse.

>> I would be deeply impressed
>> with anyone who got Ada into the victory circle.
>
>I think its tougher to write code quickly in Ada or C++ than in a good FP, 
>like OCaml, and these contests favor speed of writing.
Yep. Ada, for all its good points, is not a language designed for quick
hacking.

-- 
David Starner - dstarner98@aasaa.ofe.org
Only a nerd would worry about wrong parentheses with
square brackets. But that's what mathematicians are.
   -- Dr. Burchard, math professor at OSU




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

* Re: Language Challenge 2000 - Update
  2000-02-03  0:00       ` David Starner
  2000-02-03  0:00         ` David Emery
@ 2000-02-03  0:00         ` Brian Rogoff
  2000-02-03  0:00           ` David Starner
  1 sibling, 1 reply; 12+ messages in thread
From: Brian Rogoff @ 2000-02-03  0:00 UTC (permalink / raw)


On 3 Feb 2000, David Starner wrote:
> On Thu, 3 Feb 2000 08:22:04 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
> >Unless I misread the results, some C and C++ teams (as well as Perl and
> >Python teams) were correct, they just weren't in the top six. 
> 
> Sorry - two out of the nine C teams were correct. It was the two Perl
> teams that got sunk. 
> 
> >> I didn't want to worry about not having garbage collecting 
> >> or hetrogenous lists, so I went with Icon.
> >
> >If you had a library, you could have heterogeneous lists and more in 
> >Ada. 
> You'd have to derive every thing from the same base tagged type, or
> have a library with some serious C level pointer evil. Alternately,
> I could set up variant records.

I was thinking of the tagged type or variant option. Neither Ocaml nor 
Haskell has (untyped) heterogeneous lists, so I can't imagine that this is 
a serious problem. The winning OCaml team didn't even use the class system 
(and Haskell doesn't have OOP facilities) so variants are sufficient here.

> >For GC, I suppose you'd have to use AppletMagic. 
> Or wrap the Boehm-Weiser GC library.

Yuk! How about a real GC for Ada someone? :-)

> >Another choice might be to use a language with GC, built in lists, a
> >powerful module system with signatures, strong static typing (which Icon
> >lacks),
> 
> Of course, I would have found strong static typing in my way with those
> hetrogenous lists.

Explain why. The winning teams had no problem with strong static typing.
Very rarely do I find strong static typing to be a nuisance.

> >higher order functions, and an implementation with a rich tool set 
> >for constructing compilers. I wonder if there is such a beast? ;-)

> Hmm? ML, I guess. The compiler part was only applicable to last year,
> though. It's a Scheme-style syntax - it's not a big deal to parse.

Yes you're right. 

> >> I would be deeply impressed
> >> with anyone who got Ada into the victory circle.
> >
> >I think its tougher to write code quickly in Ada or C++ than in a good FP, 
> >like OCaml, and these contests favor speed of writing.
> Yep. Ada, for all its good points, is not a language designed for quick
> hacking.

I find Ada to be far better for quick hacking than C, but not nearly as
good as Ocaml. GNAT allows me to clean up my mistakes faster in hack mode
than unadorned C, and provides a lot more freedom along dimensions I care
about (genericity, nesting, overloading) while hacking. GNAT error
messages put OCaml error messages to shame; that's still a big problem
with type inference IMO. 

-- Brian





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

* Re: Language Challenge 2000 - Update
  2000-02-03  0:00         ` Brian Rogoff
@ 2000-02-03  0:00           ` David Starner
  2000-02-04  0:00             ` Brian Rogoff
  0 siblings, 1 reply; 12+ messages in thread
From: David Starner @ 2000-02-03  0:00 UTC (permalink / raw)


On Thu, 3 Feb 2000 12:01:44 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
>On 3 Feb 2000, David Starner wrote:
>> >For GC, I suppose you'd have to use AppletMagic. 
>> Or wrap the Boehm-Weiser GC library.
>
>Yuk! How about a real GC for Ada someone? :-)

What's wrong with the Boehm-Weiser library? It's known to work
with GCC/GNAT (the Java frontend depends on it), it interfaces
nicely with other languages, and it works in most modern OS's. 
What would you really gain from a "real" GC for Ada? (And what
do you mean by "real GC" anyway?)

-- 
David Starner - dstarner98@aasaa.ofe.org
Only a nerd would worry about wrong parentheses with
square brackets. But that's what mathematicians are.
   -- Dr. Burchard, math professor at OSU




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

* Re: Language Challenge 2000 - Update
  2000-02-03  0:00       ` David Starner
@ 2000-02-03  0:00         ` David Emery
  2000-02-03  0:00         ` Brian Rogoff
  1 sibling, 0 replies; 12+ messages in thread
From: David Emery @ 2000-02-03  0:00 UTC (permalink / raw)


At an IEEE Ada conference back in the late '80s, they held a programming
contest.  What made this unique was that it had two parts.  The first
part was to implement the given set of requirements.  The second part
consisted of some "maintenance" to apply to the system, i.e. to 
implement a revised set of requirements.  Thus the emphasis in this
contest was on how flexible the software was and how rapidly it could
adjust to new requirements.  

There were 3 teams, if I remember right.  My team had the most 
interesting solution :-), but we couldn't get it to compile.  The
problem was compiler internal errors, rather than issues with our own
code.  (We were simulating OO inheritance using generics, and vendor V's
compiler choked on one particularly complex generic.)  It's too bad, as
our design would have allowed us to make the changes very quickly.

The problem, as I remember, was to produce a system for selling
theatre tickets.  You had to support multiple ticket agencies, so
concurrency was an issue.  THe initial theatre was a "classic box",
but we anticipated alternate theatre shapes, including theatre-in-the-
round.

As I recall, one of the other 2 teams also hit some compiler problems.
The winning team had probably the least elegant design, but they got 
their software to work, which the other teams didn't :-(

Another idea that was discussed, but not adopted, was a contest whereby
the teams swapped designs/software, so in phase 2 you had to modify
someone else's software.  The scoring for that approach was based on
both correctness of the initial design, and also how well another
team could learn your design.  But the "game mechanics" of such a
contest could be touchy.  After all, you spend a lot of effort learning
someone else's software to make it easier for them to win!

         dave




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

* Language Challenge 2000 - Update
@ 2000-02-03  0:00 bvoh
  2000-02-04  0:00 ` Gautier
  0 siblings, 1 reply; 12+ messages in thread
From: bvoh @ 2000-02-03  0:00 UTC (permalink / raw)


		Language Challenge 2000 

**  Important amendment to the "Language Challenge 2000" contest  **


The best entry in each language will be posted on our site to serve as a
barometer for those pondering what language to choose for their
technical computing. It might also double as a place where flame war
enthusiasts can calibrate their rhetoric against the realities of
feasible solutions. The overall winner will receive:

 	Compaq Visual Fortran V6.1 Professional Edition
		Provided courtesy of Compaq

	SDX Modeling and Simulation Software V3.0

as a special recognition for demonstrated skills in crafting the fastest
solution with a smallest footprint.

Questions regarding the contest should be directed to info@sdynamix.com
with Contest 2000 in the "Subject" line. 

-----------------------------------------------
Modeling * Simulation * Analysis
http://www.sdynamix.com
-----------------------------------------------




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

* Re: Language Challenge 2000 - Update
  2000-02-03  0:00           ` David Starner
@ 2000-02-04  0:00             ` Brian Rogoff
  2000-02-04  0:00               ` David Starner
  0 siblings, 1 reply; 12+ messages in thread
From: Brian Rogoff @ 2000-02-04  0:00 UTC (permalink / raw)


On 3 Feb 2000, David Starner wrote:
> On Thu, 3 Feb 2000 12:01:44 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
> >On 3 Feb 2000, David Starner wrote:
> >> >For GC, I suppose you'd have to use AppletMagic. 
> >> Or wrap the Boehm-Weiser GC library.
> >
> >Yuk! How about a real GC for Ada someone? :-)
> 
> What's wrong with the Boehm-Weiser library? 

What is the opposite/dual of a "conservative" garbage collector? 

Answer that question and you can guess what I don't like with this
approach. I'll admit that its probably fine for lots of tasks though.

> It's known to work with GCC/GNAT (the Java frontend depends on it), it
> interfaces nicely with other languages, and it works in most modern
> OS's. 

Whatever makes you happy. To use a line Ada programmers like to throw at 
C folk: "I wouldn't fly in a plane whose software used a conservative 
GC!"

> What would you really gain from a "real" GC for Ada? (And what
> do you mean by "real GC" anyway?)

See the answer to the question above...

-- Brian






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

* Re: Language Challenge 2000 - Update
  2000-02-04  0:00             ` Brian Rogoff
@ 2000-02-04  0:00               ` David Starner
  2000-02-04  0:00                 ` Brian Rogoff
  0 siblings, 1 reply; 12+ messages in thread
From: David Starner @ 2000-02-04  0:00 UTC (permalink / raw)


On Fri, 4 Feb 2000 07:53:54 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
>On 3 Feb 2000, David Starner wrote:
>> On Thu, 3 Feb 2000 12:01:44 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
>> >On 3 Feb 2000, David Starner wrote:
>> >> >For GC, I suppose you'd have to use AppletMagic. 
>> >> Or wrap the Boehm-Weiser GC library.
>> >
>> >Yuk! How about a real GC for Ada someone? :-)
>> 
>> What's wrong with the Boehm-Weiser library? 
>
>What is the opposite/dual of a "conservative" garbage collector?
One that collects stuff that's in use? (-: 

>Answer that question and you can guess what I don't like with this
>approach. I'll admit that its probably fine for lots of tasks though.

You aren't going to use a garbage collector with tight memory constraints
anyway. Many large programs have unbounded memory leaks, whereas the BW
garbage collector's uncolleted unused memory will stay bounded over the
run of the program. With systems that run on PC's, reasonably bounded memory 
leaks aren't a problem.

>> It's known to work with GCC/GNAT (the Java frontend depends on it), it
>> interfaces nicely with other languages, and it works in most modern
>> OS's. 
>
>Whatever makes you happy. To use a line Ada programmers like to throw at 
>C folk: "I wouldn't fly in a plane whose software used a conservative 
>GC!"

Why? What is about conservative GC that makes it a danger? Also,
the main point of conservative GC is in an open system (a Unix program
for instance) a real GC makes interfacing with other langugages difficult.
In a closed system (a plane), I would think you'd use a "real" GC just
because there's no reason not to. (Besides extra memory usage, unpredicatable
pauses due to GC, etc.)

Now, OTOH, if you were talking about BW GC and GNAT, I'd agree. 
In theory, GCC can do optimizations that confuse garbage collection.
In practice, Jeffrey Law (one of the big GCC guys) thinks it's a problem,
whereas others disagree (including, apparently, the Java GCC people.)

-- 
David Starner - dstarner98@aasaa.ofe.org
Only a nerd would worry about wrong parentheses with
square brackets. But that's what mathematicians are.
   -- Dr. Burchard, math professor at OSU




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

* Re: Language Challenge 2000 - Update
  2000-02-04  0:00               ` David Starner
@ 2000-02-04  0:00                 ` Brian Rogoff
  2000-02-04  0:00                   ` David Starner
  0 siblings, 1 reply; 12+ messages in thread
From: Brian Rogoff @ 2000-02-04  0:00 UTC (permalink / raw)


On 4 Feb 2000, David Starner wrote:

> On Fri, 4 Feb 2000 07:53:54 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
> >On 3 Feb 2000, David Starner wrote:
> >> On Thu, 3 Feb 2000 12:01:44 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
> >> >On 3 Feb 2000, David Starner wrote:
> >> >> >For GC, I suppose you'd have to use AppletMagic. 
> >> >> Or wrap the Boehm-Weiser GC library.
> >> >
> >> >Yuk! How about a real GC for Ada someone? :-)
> >> 
> >> What's wrong with the Boehm-Weiser library? 
> >
> >What is the opposite/dual of a "conservative" garbage collector?
> One that collects stuff that's in use? (-: 

The opposite/dual of a "conservative" garbage collector is a "precise" or
"accurate" garbage collector. A conservative garbage collector (and really 
garbage collector should be in quotes) is not guaranteed to collect all 
garbage. Does that help a little? 

BTW, yes, I understand why you might want a conservative GC, I just don't
care for that trade off.

-- Brian






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

* Re: Language Challenge 2000 - Update
  2000-02-04  0:00                 ` Brian Rogoff
@ 2000-02-04  0:00                   ` David Starner
  2000-02-07  0:00                     ` Brian Rogoff
  0 siblings, 1 reply; 12+ messages in thread
From: David Starner @ 2000-02-04  0:00 UTC (permalink / raw)


On Fri, 4 Feb 2000 15:35:02 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
>On 4 Feb 2000, David Starner wrote:
>
>> On Fri, 4 Feb 2000 07:53:54 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
>> >What is the opposite/dual of a "conservative" garbage collector?
>> One that collects stuff that's in use? (-: 
>
>The opposite/dual of a "conservative" garbage collector is a "precise" or
>"accurate" garbage collector.

Yes, I knew that. Hence the smiley. Sorry.

>A conservative garbage collector (and really 
>garbage collector should be in quotes) is not guaranteed to collect all 
>garbage. Does that help a little? 

Sure, but a generational GC won't collect all the garbage each time
it does garbage collection, either. And most GC's will overlook a 
technically live pointer that won't get used again.

Anyway, how would you implement a "precise" garbage collector in
pure Ada? The only way I can see working is by manually adding roots,
like GCC (2.96)'s internal GC does. But that's a pain that's also
mistake-prone. I probably don't understand storage pools well enough
for this, though.

-- 
David Starner - dstarner98@aasaa.ofe.org
Only a nerd would worry about wrong parentheses with
square brackets. But that's what mathematicians are.
   -- Dr. Burchard, math professor at OSU




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

* Re: Language Challenge 2000 - Update
  2000-02-03  0:00 bvoh
@ 2000-02-04  0:00 ` Gautier
  0 siblings, 0 replies; 12+ messages in thread
From: Gautier @ 2000-02-04  0:00 UTC (permalink / raw)
  To: bvoh

bvoh@sdynamix.com wrote:

> The overall winner will receive:

>         Compaq Visual Fortran V6.1 Professional Edition
>                 Provided courtesy of Compaq

Very kind from you, but is it worth to write a winning Ada program
to finally receive a Fortran compiler ?!!

-- 
Gautier

_____\\________________\_______\
http://members.xoom.com/gdemont/




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

* Re: Language Challenge 2000 - Update
  2000-02-04  0:00                   ` David Starner
@ 2000-02-07  0:00                     ` Brian Rogoff
  0 siblings, 0 replies; 12+ messages in thread
From: Brian Rogoff @ 2000-02-07  0:00 UTC (permalink / raw)


On 4 Feb 2000, David Starner wrote:
> On Fri, 4 Feb 2000 15:35:02 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
> >On 4 Feb 2000, David Starner wrote:
> >
> >> On Fri, 4 Feb 2000 07:53:54 -0800, Brian Rogoff <bpr@shell5.ba.best.com> wrote:
> >> >What is the opposite/dual of a "conservative" garbage collector?
> >> One that collects stuff that's in use? (-: 
> >
> >The opposite/dual of a "conservative" garbage collector is a "precise" or
> >"accurate" garbage collector.
> 
> Yes, I knew that. Hence the smiley. Sorry.

Actually, I should apologize; I gathered you knew when I read the rest of
your message, but somehow my fingers were too quick on the draw. Sorry I 
sounded snotty.

> >A conservative garbage collector (and really 
> >garbage collector should be in quotes) is not guaranteed to collect all 
> >garbage. Does that help a little? 
> 
> Sure, but a generational GC won't collect all the garbage each time
> it does garbage collection, either. And most GC's will overlook a 
> technically live pointer that won't get used again.

True, but I put that in a different category (missing on a sweep versus
just permanently missing) than conservative GC. Besides, there are lots of 
precise GC variants besides generational GC. 

One thing I'd like in a language would be a more sophisticated interface
to memory pools than what we have in storage pools right now. This has
been discussed before, and probably the cabal behind Ada 0X is considering 
this.

> Anyway, how would you implement a "precise" garbage collector in
> pure Ada? 

You could restrict yourself to a subset of Ada. Do the Ada ==> JVM
compilers allow you to munge addresses using the functionality in the 
System hierarchy? 

> The only way I can see working is by manually adding roots,
> like GCC (2.96)'s internal GC does. But that's a pain that's also
> mistake-prone. I probably don't understand storage pools well enough
> for this, though.

For full blown Ada, a reasonable substitute for GC sometimes is manual
region management, where by "region" I mean something like a mark release 
pool a-la the Rationale. Its not quite as nice as GC but its usually
better than trying to free individual objects.

-- Brian





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

end of thread, other threads:[~2000-02-07  0:00 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <38991E72.293907A4@sdynamix.com>
     [not found] ` <38992ADB.AC8748A8@mail.utexas.edu>
     [not found]   ` <87bbro$9281@news.cis.okstate.edu>
2000-02-03  0:00     ` Language Challenge 2000 - Update Brian Rogoff
2000-02-03  0:00       ` David Starner
2000-02-03  0:00         ` David Emery
2000-02-03  0:00         ` Brian Rogoff
2000-02-03  0:00           ` David Starner
2000-02-04  0:00             ` Brian Rogoff
2000-02-04  0:00               ` David Starner
2000-02-04  0:00                 ` Brian Rogoff
2000-02-04  0:00                   ` David Starner
2000-02-07  0:00                     ` Brian Rogoff
2000-02-03  0:00 bvoh
2000-02-04  0:00 ` Gautier

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