Results 1 -
6 of
6
Efficient Closure Utilisation by Higher-Order Inheritance Analysis
- In Static Analysis Symposium (SAS'95
, 1995
"... . Higher-order functions and the ability to create new functions at runtime, either by partial application or -abstraction of existing functions, are important features of functional languages. Since these runtimecreated functions may outlive their creating functions, it is necessary to represent al ..."
Abstract
-
Cited by 7 (4 self)
- Add to MetaCart
. Higher-order functions and the ability to create new functions at runtime, either by partial application or -abstraction of existing functions, are important features of functional languages. Since these runtimecreated functions may outlive their creating functions, it is necessary to represent all functional parameters by closures in a memory area which is not affected by the termination of function calls, i.e. in a heap component. Such a closure contains the original function, which may be a closure again, and the bindings of the parameters used (by the partial application) . It many cases, however, it is possible to avoid this expensive heap allocation and use the run-time stack or even statically allocated closures. Often a closure created for a partial application is used only locally and will never be part of the result of the creating function. In these cases, the closure may be allocated on the stack. This approach is feasible in eager and lazy languages. If we can additional...
Exploiting Purely Functional Programming to Obtain Bounded Resource Behaviour: the Hume Approach
- In Central European Summer School on Functional Programming
, 2005
"... Abstract. This chapter describes Hume: a functionally-based language for programming with bounded resource usage, including time and space properties. The purpose of the Hume language design is to explore the expressibility/costability spectrum in resource-constrained systems, such as real-time embe ..."
Abstract
-
Cited by 6 (5 self)
- Add to MetaCart
Abstract. This chapter describes Hume: a functionally-based language for programming with bounded resource usage, including time and space properties. The purpose of the Hume language design is to explore the expressibility/costability spectrum in resource-constrained systems, such as real-time embedded or control systems. It is unusual in being based on a combination of λ-calculus and finite state machine notions, rather than the more usual propositional logic, or flat finite-state-machine models. The use of a strict, purely functional programming notation allows the construction of a strong cost model for expressions, which can then be embedded into a simple cost model for processes. In this chapter, we introduce Hume, describe the Hume Abstract Machine implementation, and show how a high-level cost model can be constructed that relates costs from the abstract machine to Hume source programs. We illustrate our approach with an example adapted from the literature: a simple vending machine controller. 1
Worst-Case Execution Times for a Purely Functional Language
- In 18th IFL 2006
, 2007
"... Abstract. This paper provides guaranteed bounds on worst-case execution times for a strict, purely functional programming notation. Our approach involves combining time information obtained using a low-level commercial analyser with a high-level source-derived model to give worstcase execution time ..."
Abstract
-
Cited by 6 (3 self)
- Add to MetaCart
Abstract. This paper provides guaranteed bounds on worst-case execution times for a strict, purely functional programming notation. Our approach involves combining time information obtained using a low-level commercial analyser with a high-level source-derived model to give worstcase execution time information. We validate our results using concrete timing information obtained using machine code fragments executing on a Renesas M32C/85 microcontroller development board. Our results conrm experimentally that our worst-case execution time model is a good predictor of execution times. 1
A Chemical Abstract Machine for Graph Reduction
, 1992
"... Graph reduction is an implementation technique for the lazy l-calculus. It has been used to implement many non-strict functional languages, such as lazy ML, Gofer and Miranda. Parallel graph reduction allows for concurrent evaluation. In this paper, we present parallel graph reduction as a Chemical ..."
Abstract
-
Cited by 5 (1 self)
- Add to MetaCart
Graph reduction is an implementation technique for the lazy l-calculus. It has been used to implement many non-strict functional languages, such as lazy ML, Gofer and Miranda. Parallel graph reduction allows for concurrent evaluation. In this paper, we present parallel graph reduction as a Chemical Abstract Machine, and show that the resulting testing semantics is adequate wrt testing equivalence for the lazy l-calculus. We also present a π-calculus implementation of the graph reduction machine, and show that the resulting testing semantics is also adequate.
CASE - A Lazy Version of an SECD Machine with a Flat Environment
- in Proceedings TENCON '89
, 1990
"... Graph reduction has been the basis of most fast running implementations of functional languages, with little attention being paid recently to Landin's SECD approach. CASE is an abstract machine which supports applicative programming and is a variation of Landin's classical SECD machine. Its environm ..."
Abstract
-
Cited by 2 (1 self)
- Add to MetaCart
Graph reduction has been the basis of most fast running implementations of functional languages, with little attention being paid recently to Landin's SECD approach. CASE is an abstract machine which supports applicative programming and is a variation of Landin's classical SECD machine. Its environment is organized in a novel way which makes variable access more efficient by removing the overhead of following a static chain or of setting up a display as in more conventional stack architectures. The CASE machine also has features allowing the execution of code to reflect lazy evaluation semantics. We describe the architecture of the machine, its operational semantics, and code generated by a typical compiler for some sample programs. We also discuss some optimisations made to facilitate efficient code generation on real hardware and give some measurements of the efficiency of the machine. 1 Introduction Much current research on graph reduction for applicative programming is centred ro...
Functional specification of imperative programs: An alternative point of view of functional languages
, 1995
"... In this paper we will show how to embed functional concepts in an imperative host language in a natural way. This is achieved by interpreting functional programs as specifications of imperative programs. We will introduce a refined notion of laziness, which allows us to interpret lazy computations a ..."
Abstract
- Add to MetaCart
In this paper we will show how to embed functional concepts in an imperative host language in a natural way. This is achieved by interpreting functional programs as specifications of imperative programs. We will introduce a refined notion of laziness, which allows us to interpret lazy computations as special constructors, which encapsulate the suspended computation. Even higher-order concepts can be represented efficiently, if we restrict the possibility to use partial applications. Essentially, we disallow the use of sequences of partial applications as hidden data structures. By considering a setting in which the unit of translation is a module, this approach is the key to an integration of the functional programming paradigm and the imperative programming paradigm on a module level. Functional components of the resulting hybrid module architectures may use and may be used by imperative components without need for special interlanguage interfaces. Beside the `best of both worlds', this concept ooeers the possibility to migrate `module by module' from purely imperative systems to hybrid systems and to do rapid prototyping using functional modules. Experimental results with a prototype version of a translator will show that we can compete with traditional functional languages like Haskell.

