🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.functional
Article #395

Re: BOTTOM !== NONTERMINATION

#395
From: David Gudeman
Date: Fri, 27 Jul 1990 17:59
51 lines
3093 bytes
In article  <3943@rex.cs.tulane.edu> fs@rex.cs.tulane.edu (Frank Silbermann) writes:
>
>If you incorporate the effects of the optimizations
>into your denotational semantics, you might as well
>just give an operational semantics instead.
>Denotational semantics is a _functional_ notation
>for _declaratively_ describing a language's constructs.

I don't think you understand what I'm saying.  I suggesting that (1)
the denotational semantics are intended to give a rigorous
mathematical meaning to a program.  (2) it would be nice if the
interpreter for the language was --in some sense-- an implementation
of the semantics.  (3) if you identify all error results together in
the semantics, then the interpreter is _not_ an implementation of the
semantics, because the interpreter (hopefully) produces informative
messages on errors.  So (4) the semantics should specify the
information content of error messages.

This is all fine a good, but there are a lot of optimizations that
make it impossible to give informative error messages because
information is lost during the course of the optimization.  So are we
to be left with an optimizing compiler that no longer implements the
semantics?  Well if you think formal semantics are important for the
developement environment (the interpreter) then presumably you think
it is good for the production code (the compiler).  So, you either
need a different semantics or you need to specify the semantic effect
of an optimization.  In general the _semantic_ effects of optimization
involves no more than making some error results into less-defined
error results.  Some error results may be changed into "undefined".

I'm not suggesting that you somehow specify the optimizations in the
semantics, only that you specify the semantics of optimized programs.

>If the words `declarative' and `functional'
>don't ring a bell for you, I wonder why you are interested
>in functional programming in the first place!

I know what "declarative" and "functional" mean (as well as anyone).
I don't think they are synonyms for "good".  It is not possible to
make a pure declarative language that is adequate for general-purpose
programming.  However, many of the notations and optimizations that
come out of the functional language research are useful in their own
right. I'm not religious about functional programming but I'm
interested in it; so I guess the answer is that I'm not a member of
the church, but I attend services on the off chance that it might be
good for my soul.
-- 
					David Gudeman
Department of Computer Science
The University of Arizona        gudeman@cs.arizona.edu
Tucson, AZ 85721                 noao!arizona!gudeman
Technical Details
Message-ID: <23593@megaron.cs.arizona.edu>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!lll-winken!elroy.jpl.nasa.gov!sdd.hp.com!cs.utexas.edu!asuvax!noao!arizona!gudeman

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!lll-winken!elroy.jpl.nasa.gov!sdd.hp.com!cs.utexas.edu!asuvax!noao!arizona!gudeman
From: gudeman@cs.arizona.edu (David Gudeman)
Newsgroups: comp.lang.functional
Subject: Re: BOTTOM !== NONTERMINATION
Message-ID: <23593@megaron.cs.arizona.edu>
Date: 27 Jul 90 17:59:06 GMT
Organization: U of Arizona CS Dept, Tucson
Lines: 51