scholarly journals Mechanizing the metatheory of rewire

2019 ◽  
Author(s):  
◽  
Thomas N. Reynolds

The [lambda]-calculus provides a simple, well-established framework for research in functional programming languages that readily lends itself to the use offormal methods--that is, the use of mathematically sound techniques and supporting tools--to describe and verify properties of programming languages, as well. This is no coincidence. After all, the [lambda]-calculus formalizes the concept of effective computability, for all computable functions are definable in the untyped [lambda]-calculus, making it expressively equivalent torecursive functions. In software, the expressiveness of functional languages is considereda strength. Functional approaches to language design, however, needn't be limited to soft-ware. In hardware, the expressiveness of functional languages becomes a major obstacle to successful hardware synthesis, for the reason that such languages are usually capable of expressing general recursion. The presence of general recursion makes it possible to generate expressions that run forever, never producing a well-defined value. In this dissertation, we study two novel variants of the simply typed [lambda]-calculus, representing fragments of functional hardware description languages. The first variant extends the type system, using natural numbers representing time. This addition, though simple, is non-trivial. We prove that this calculus possesses bounded variants of type-safety and strong normalization. That is to say, we show that all well-typed expressions evaluate to values within a bound determined by the natural number index of their corresponding types. The second variant is a computational [lambda]-calculus that formalizes the core fragment of the hardware description language known as ReWire. We prove that the language has type-safety and is strongly normalizing -- the proof of strong normalizationis the first mechanized proof of its kind. We define an equational theory with respect to this language. This allows us to prove that the language has desirable security properties by construction. This work supports a full-edged, formal methodology for producing high assurance hardware.

2004 ◽  
Vol 14 (5) ◽  
pp. 519-546 ◽  
Author(s):  
MÁRIO FLORIDO ◽  
LUÍS DAMAS

In this paper we present a notion of expansion of a term in the lambda-calculus which transforms terms into linear terms. This transformation replaces each occurrence of a variable in the original term by a fresh variable taking into account non-trivial implications in the structure of the term caused by these simple replacements. We prove that the class of terms which can be expanded is the same of terms typable in an Intersection Type System, i.e. the strongly normalizable terms. We then show that expansion is preserved by weak-head reduction, the reduction considered by functional programming languages.


1991 ◽  
Vol 1 (3) ◽  
pp. 287-327 ◽  
Author(s):  
Ian Mason ◽  
Carolyn Talcott

AbstractTraditionally the view has been that direct expression of control and store mechanisms and clear mathematical semantics are incompatible requirements. This paper shows that adding objects with memory to the call-by-value lambda calculus results in a language with a rich equational theory, satisfying many of the usual laws. Combined with other recent work, this provides evidence that expressive, mathematically clean programming languages are indeed possible.


2021 ◽  
Vol 31 ◽  
Author(s):  
BHARGAV SHIVKUMAR ◽  
JEFFREY MURPHY ◽  
LUKASZ ZIAREK

Abstract There is a growing interest in leveraging functional programming languages in real-time and embedded contexts. Functional languages are appealing as many are strictly typed, amenable to formal methods, have limited mutation, and have simple but powerful concurrency control mechanisms. Although there have been many recent proposals for specialized domain-specific languages for embedded and real-time systems, there has been relatively little progress on adapting more general purpose functional languages for programming embedded and real-time systems. In this paper, we present our current work on leveraging Standard ML (SML) in the embedded and real-time domains. Specifically, we detail our experiences in modifying MLton, a whole-program optimizing compiler for SML, for use in such contexts. We focus primarily on the language runtime, reworking the threading subsystem, object model, and garbage collector. We provide preliminary results over a radar-based aircraft collision detector ported to SML.


Author(s):  
Инна Николаевна Заризенко ◽  
Артём Евгеньевич Перепелицын

This article has analyzed the most effective integrated development environments from leading programmable logical device (PLD) manufacturers. Heterogeneous calculations and the applicability of a general approach to the description of hardware accelerator designs are considered. An analytical review of the use of the OpenCL language in the construction of high-performance FPGA-based solutions is performed. The features of OpenCL language usage for heterogeneous computing for FPGA-based accelerators are discussed. The experience of a unified description of projects for solutions based on CPU, GPU, signal processors and FPGA is analyzed. The advantages of using such a description for tasks that perform parallel processing are shown. Differences in productivity and labor costs for developing FPHA systems with parallel data processing for hardware description languages and OpenCL language are shown. The results of comparing commercially available solutions for building services with FPGA accelerators are presented. The advantages of the Xilinx platform and tools for building an FPGA service are discussed. The stages of creating solutions based on FaaS are proposed. Some FaaS related tasks are listed and development trends are discussed. The SDAccel platform of the Xilinx SDx family is considered, as well as the possible role of these tools in creating the FPGA computing platform as a service. An example of using SDAccel to develop parallel processing based on FPGA is given. The advantages and disadvantages of the use of hardware description languages with such design automation tools are discussed. The results of comparing the performance of the simulation speed of the system described with the use of programming languages and hardware description languages are presented. The advantages of modeling complex systems are discussed, especially for testing solutions involving the processing of tens of gigabytes of data and the impossibility of creating truncated test sets. Based on practical experience, the characteristics of development environments, including undocumented ones, are formulated.


2012 ◽  
Vol 2012 ◽  
pp. 1-11 ◽  
Author(s):  
Gang Chen

Functional programming languages offer a high degree of abstractions and clean semantics, which are desirable for hardware descriptions. This short historical survey is about functional languages specifically created for hardware design and verification. It also includes those hardware languages or formalisms which are strongly influenced by functional programming style.


2008 ◽  
Vol 18 (4) ◽  
pp. 729-751 ◽  
Author(s):  
ZHAOHUI LUO

We incorporate the idea of coercive subtyping, a theory of abbreviation for dependent type theories, into the polymorphic type system in functional programming languages. The traditional type system with let-polymorphism is extended with argument coercions and function coercions, and a corresponding type inference algorithm is presented and proved to be sound and complete.


1993 ◽  
Vol 19 (1-2) ◽  
pp. 1-49
Author(s):  
Val Breazu-Tannen ◽  
Albert R. Meyer

In programming languages that feature unrestricted recursion, the equational theory corresponding to evaluation of data type expressions must be distinguished from the classical theory of the data as given by, say, algebraic specifications. Aiming to preserve classical reasoning about the underlying data types, that is, for the equational theory of the programming language to be a conservative extension of the theory given by the data type specification, we investigate, alternative computational settings given by typed lambda calculi, specifically here by the Girard-Reynolds polymorphic lambda calculus ( λ ∀ ). We prove that the addition of just the λ ∀ -constructions to arbitrary specifications, as given by algebraic theories, and even simply typed lambda theories, is conservative. This suggests that polymorphic constructs and reasoning can be superimposed on familiar data-type definition features of programming languages without changing the behavior of these features. Using purely syntactic methods, we give transformational proofs of these results for certain systems of equational reasoning. A new technique for analyzing polymorphic equational proofs is developed to this purpose. Finally, we prove, with a semantics argument, that it is possible to combine arbitrary algebraic data type specifications and the λ ∀ -constructions into functional programming languages that both conserve algebraic reasoning about data. and ensure, over arbitrary algebraically specified observables, a computing power equivalent to that of the pure λ ∀ . The corresponding problem for simply typed specifications remains open.


10.29007/22x6 ◽  
2018 ◽  
Author(s):  
Sylvia Grewe ◽  
Sebastian Erdweg ◽  
Mira Mezini

Type systems for programming languages shall detect type errors in programs before runtime. To ensure that a type system meets this requirement, its soundness must be formally verified. We aim at automating soundness proofs of type systems to facilitate the development of sound type systems for domain-specific languages.Soundness proofs for type systems typically require induction. However, many of the proofs of individual induction cases only require first-order reasoning. For the development of our workbench Veritas, we build on this observation by combining automated first-order theorem provers such as Vampire with automated proof strategies specific to type systems. In this paper, we describe how we encode type soundness proofs in first-order logic using TPTP. We show how we use Vampire to prove the soundness of type systems for the simply-typed lambda calculus and for parts of a typed SQL. We report on which parts of the proofs are handled well by Vampire, and what parts work less well with our current approach.


Author(s):  
Raghad Obeidat ◽  
Hussein Alzoubi

Curricula in computer engineering, computer science, and other related fields include several courses about hardware design. Examples of these courses are digital logic design, computer architecture, microprocessors, computer interfacing, hardware design, embedded systems, switching theorem, and others. In order for the students to realize the concepts taught in such courses, practical track should be reinforced along with the theoretical track. Many universities offer to their students labs in which they can practice hardware design. However, students need more than that: they need tools that enable them to design, model, simulate, synthesize, and implement hardware designs. Although high-level programming languages like Java and C++ could be an option, it might be a tedious task to use them for this mission. Fortunately, hardware-description languages (HDLs) have been specifically devised for this purpose. This paper shows some of the great features of HDLs and compare using them with using C++ for illustrating digital concepts through salient examples.


Sign in / Sign up

Export Citation Format

Share Document