User loginNavigation |
SemanticsCLL: A Concurrent Language Built from Logical Principles
CLL: A Concurrent Language Built from Logical Principles by Deepak Garg, 2005.
In this report, we use both the Curry-Howard isomorphism and proof-search to design a concurrent programming language from logical principles. ... Our underlying logic is a first-order intuitionistic linear logic where all right synchronous connectives are restricted to a monad.Yet another example of using monads to embed effectful computations into a pure FP. Another interesting part is the methodology of derivation of a PL from a logic. By Andris Birkmanis at 2007-06-30 18:06 | Logic/Declarative | Semantics | Type Theory | 2 comments | other blogs | 12355 reads
Application-specific foreign-interface generationApplication-specific foreign-interface generation, John Reppy and Chunyan Song, October 2006.
FFIs are a perennial engineering problem, and it's very nice to see progress being made on automating what's automatable about building interfaces. Their interface specification language is built from two little DSLs. The first one is a language that for specifying how to map low level types to high level types, and the second one is a rewriting-based language for translating API functions, which makes use of the type mapping programs you defined earlier. The whole thing is quite pretty, and seems to read very well. An interesting gimme for you stack-language fans: the DSL that Reppy and Song use to specify type mappings from low-level to high-level types is a combinator-based language that reads a bit like Forth or Postscript. By neelk at 2007-06-20 20:52 | DSL | Functional | Implementation | Logic/Declarative | Semantics | 3 comments | other blogs | 6748 reads
Synthetic ComputabilityAndrej Bauer has made available his tutorial slides on Synthetic Computability, which he gave at the Mathematical Foundations of Programming Semantics #23 conference last month. He motivates the idea of a synthetic theory, with reference to Hyland's construction of Eff (the effective topos), and tackles the ideas lying behind synthetic domain theory, one of the most rarefied areas of PL semantics, as accessibly as I have seen it done. Highly theoretical, highly recommended. Via Bauer's announcement at his Mathematics and Computation weblog. From abstract interpretation to small-step typing
Patrick Cousot is well known for abstract interpretation, which among other
applications offers a general approach to understanding and designing type
systems. It thus surprises me that his work seems to have been discussed only
cursorily on LtU.
Patrick Cousot and Radhia Cousot, Abstract interpretation: A unified lattice model for static analysis of programs by construction or approximation of fixpoints. POPL 1977, 238-252. A program denotes computations in some universe of objects. Abstract interpretation of programs consists in using that denotation to describe computations in another universe of abstract objects, so that the results of abstract execution give some informations on the actual computations. An intuitive example (which we borrow from Sintzoff) is the rule of signs. The text -1515*17 may be undestood to denote computations on the abstract universe {(+), (-), (+-)} where the semantics of arithmetic operators is defined by the rule of signs. The abstract execution -1515*17 ==> -(+)*(+) ==> (-)*(+) ==> (-), proves that -1515+17 is a negative number. Abstract interpretation is concerned by a particlar underlying structure of the usual universe of computations (the sign, in our example). It gives a summay of some facets of the actual executions of a program. In general this summary is simple to obtain but inacurrate (e.g. -1515+17 ==> -(+)+(+) ==> (-)+(+) ==> (+-)). Despite its fundamental incomplete results abstract interpretation allows the programmer or the compiler to answer questions which do not need full knowledge of program executions or which tolerate an imprecise answer (e.g. partial correctness proofs of programs ignoring the termination problems, type checking, program optimizations which are not carried in the absence of certainty about their feasibility, ...).Patrick Cousot, Types as abstract interpretations. POPL 1997, 316-331. Starting from a denotational semantics of the eager untyped lambda-calculus with explicit runtime errors, the standard collecting semantics is defined as specifying the strongest program properties. By a first abstraction, a new sound type collecting semantics is derived in compositional fixpoint form. Then by successive (semi-dual) Galois connection based abstractions, type systems and/or type inference algorithms are designed as abstract semantics or abstract interpreters approximating the type collecting semantics. This leads to a hierarchy of type systems, which is part of the lattice of abstract interpretations of the untyped lambda-calculus. This hierarchy includes two new à la Church/Curry polytype systems. Abstractions of this polytype semantics lead to classical Milner/Mycroft and Damas/Milner polymorphic type schemes, Church/Curry monotypes and Hindley principal typing algorithm. This shows that types are abstract interpretations. I started learning more about abstract interpretation for two reasons. First, abstract interpretation underlies CiaoPP, a program preprocessor mentioned here that uses the same assertion language for static and dynamic checking and optimization. Second, on our way to a logical interpretation of delimited continuations, Oleg and I build a type system using what we call small-step abstract interpretation. Manuel Hermenegildo, Germán Puebla, and Francisco Bueno, Using global analysis, partial specifications, and an extensible assertion language for program validation and debugging. In The logic programming paradigm: A 25-year perspective, ed. Krzysztof R. Apt, Victor W. Marek, Mirek Truszczynski, and David S. Warren, 161-192, 1999. Berlin: Springer-Verlag. We present a framework for the application of abstract interpretation as an aid during program development, rather than in the more traditional application of program optimization. Program validation and detection of errors is first performed statically by comparing (partial) specifications written in terms of assertions against information obtained from static analysis of the program. The results of this process are expressed in the user assertion language. Assertions (or parts of assertions) which cannot be verified statically are translated into run-time tests. The framework allows the use of assertions to be optional. It also allows using very general properties in assertions, beyond the predefined set understandable by the static analyzer and including properties defined by means of user programs. We also report briefly on an implemention of the framework. The resulting tool generates and checks assertions for Prolog, CLP(R), and CHIP/CLP(fd) programs, and integrates compile-time and run-time checking in a uniform way. The tool allows using properties such as types, modes, non-failure, determinancy, and computational cost, and can treat modules separately, performing incremental analysis. In practice, this modularity allows detecting statically bugs in user programs even if they do not contain any assertions.Oleg Kiselyov and Chung-chieh Shan, A substructural type system for delimited continuations. TLCA 2007. We propose type systems that abstractly interpret small-step rather than big-step operational semantics. We treat an expression or evaluation context as a structure in a linear logic with hypothetical reasoning. Evaluation order is not only regulated by familiar focusing rules in the operational semantics, but also expressed by structural rules in the type system, so the types track control flow more closely. Binding and evaluation contexts are related, but the latter are linear. By Chung-chieh Shan at 2007-04-21 22:07 | Semantics | Type Theory | 20 comments | other blogs | 15962 reads
A Logic for Parametric PolymorphismA Logic for Parametric Polymorphism, Gordon Plotkin and MartÃn Abadi.
By neelk at 2007-04-13 22:27 | Category Theory | Lambda Calculus | Semantics | Theory | login or register to post comments | other blogs | 7598 reads
RZ: a tool for bringing constructive and computable mathematics closer to programming practiceRZ: a tool for bringing constructive and computable mathematics closer to programming practice, Chris Stone and Andrej Bauer.
Realizability is a way of formalizing the constructive interpretation of logical formulas (eg, the BHK interpretation). Constructively, a proof of an implication By neelk at 2007-04-10 22:57 | DSL | Lambda Calculus | Semantics | 3 comments | other blogs | 6614 reads
Towards a Mechanized Metatheory of Standard MLTowards a Mechanized Metatheory of Standard ML, Daniel K. Lee, Karl Crary, and Robert Harper.
The way that most programming languages end up working is by defining a smaller core language to which the constructions in the base language are translated. This means that you can prove the type-safety of a programming language by showing that the internal language is type safe, and that every type-correct program in the full language translates to a type-correct expression in the internal language. In this paper, the authors carried out the mechanization of a core language for SML. The next step is mechanizing the correctness of an elaborator from SML to this core language, and then full, no-foolin' SML will have a fully machine-checked correctness proof. By neelk at 2007-04-02 15:59 | Functional | Semantics | Type Theory | 1 comment | other blogs | 8478 reads
A Certified Type-Preserving Compiler from Lambda Calculus to Assembly LanguageA Certified Type-Preserving Compiler from Lambda Calculus to Assembly Language
I found this while attempting to follow up on this post. The approach taken here—dependently-typed ASTs and denotational semantics—and the observation that, carried to its logical conclusion, the result is typed intermediate and assembly languages, proof-carrying code, etc. suggests to me a connection to this work. It also seems to offer a denotational counterpoint to Leroy's coinductive big-step operational semantics, also done in Coq. Fascinating stuff. By Paul Snively at 2007-03-22 15:46 | Functional | Implementation | Lambda Calculus | Meta-Programming | Semantics | Type Theory | 14 comments | other blogs | 35067 reads
Concoqtion: Indexed Types Now!Concoqtion: Indexed Types Now!
The follow-up to Concoqtion: Mixing Indexed Types and Hindley-Milner Type Inference, discussed earlier. Good stuff. Update: There's now a public Concoqtion web site! Josh, does this answer your question? :-) By Paul Snively at 2007-03-12 15:20 | DSL | Functional | Implementation | Semantics | Type Theory | 6 comments | other blogs | 8995 reads
Using Category Theory to Design Implicit Conversions and Generic OperatorsUsing Category Theory to Design Implicit Conversions and Generic Operators, John C. Reynolds, 1980. (Try this if the official link doesn't work.)
This is an old, but still cute, paper. The basic intuition is that a good design principle for a language with implicit conversions is that whatever order of conversions the language takes, you should get the same result. He then formalizes that by giving a category of types and conversions, and demanding that everything commute properly. And these give just the conditions the language designer has to check to make sure that he or she hasn't screwed anything up. Someone could probably get a fun little paper by taking this idea and shooting some dependent types into it. (Maybe somebody already has?) If you've got an abstract type, a coercion function, and a proof that it satisfies Reynolds' conditions, now your compiler can silently insert those coercions for you as needed, but you can still be sure that it won't mess up the meaning of your program. |
Browse archives
Active forum topics |
Recent comments
23 weeks 8 hours ago
23 weeks 12 hours ago
23 weeks 12 hours ago
45 weeks 1 day ago
49 weeks 3 days ago
51 weeks 20 hours ago
51 weeks 20 hours ago
1 year 1 week ago
1 year 6 weeks ago
1 year 6 weeks ago