| Jay, C. and Sekanina, M. Shape checking of array programs. no. 96.09, School of Computer Sciences, University of Technology, Sydney, Australia, 1996. |
....The symbolic cost analysis requires the symbolic size of all vectors. This information is inferred by the size analysis. In order to do so, the size of a vector should not depend on scalar values but only on constants or parameter sizes. A program observing this condition is called ishapelyj [JS97] For example, a skeleton f ilter p producing a vector made only of the elements of its vector argument satisfying the predicate p cannot be allowed. It would produce vectors whose size is unpredictable. ffl Restricted conditionals. One cannot associate an accurate cost to conditionals whose ....
C. B. Jay and M. Sekanina. Shape checking of array programs. In Computing: the Australasian Theory Seminar, Australian Computer Science Communications, pages 113121, 1997.
....type system that distinguishes between compile time and runtime values [27] Xi and Pfenning [32] use dependent types and perform type checking modulo constraint satisfaction. Singleton types enable the generation of lists of a particular size, dependent on integer values. Jay and Sekanina [23] describe type checking in a language VEC on vectors, which distinguishes between so called shapely types and nonshapely types. They distinguish two kinds of conditionals. The shapely conditional, which requires the condition to be of shapely type, is used to analyze recursive size functions but ....
....fail but the program may still be typable. In all other static approaches whichwe are aware of size inference is decidable. Chin and Khoo [6] Fradet and Mallet [12] and Xi and Pfenning [32] use linear inequalities for constraints, i.e. Presburger arithmetic. Bell and Moggi [2] Jay and Sekanina [23] and Hofmann [21] achieve the decidability through their type system. Limitation to Presburger arithmetic already rules out the following simple function # which is likely to appear in an # body computation: # takes a list of size # as input and produces a list that contains all element pairs and ....
C. Barry Jay and Milan Sekanina. Shape checking of array programs. In J. Harland, editor, Proc. Australasian Theory Seminar on Computing,volume 19 of Australian Computer Science Communications, pages 113121, 1997.
....from HML (see [17] and few inductive types at compile time from type theory (e.g. see [19, 5] There are also analogies with work on partial evaluation, in particular 2 level lambda calculi for binding time analysis (see [18, 6] None of these calculi make use of dependent types. Also [16] deals with shape checking of array programs, but without going through an intermediate language. The translation of NSC into S2 has several analogies with that considered in [8] to give a type theoretic account of higher order modules, and has been strongly influenced by ideas from shape theory ....
....of an intermediate language S2. This avoids two major problems: a programmer does not have to deal with dependent type directly, decidability of type checking in S2 does not rely on strong normalization of run time expressions (since dependent types are confined to the compile time part of S2) [16] introduces a simply typed language for vectors with an operator #: # to extract shape information from terms. The type # is like our c , while the term #e performs the translation e c lazily. Our approach gains in clarity and generality by separating the programming language from the ....
C.B. Jay and M. Sekanina. Shape checking of array programs. Technical Report 96.09, University of Technology, Sydney, 1996.
....from HML (see [17] and few inductive types at compile time from type theory (e.g. see [19, 5] There are also analogies with work on partial evaluation, in particular 2 level lambda calculi for binding time analysis (see [18, 6] None of these calculi make use of dependent types. Also [16] deals with shape checking of array programs, but without going through an intermediate language. The translation of NSC into S2 has several analogies with that considered in [8] to give a type theoretic account of higher order modules, and has been strongly influenced by ideas from shape theory ....
....of an intermediate language S2. This avoids two major problems: a programmer does not have to deal with dependent type directly, decidability of type checking in S2 does not rely on strong normalization of run time expressions (since dependent types are confined to the compile time part of S2) [16] introduces a simply typed language for vectors with an operator # : # to extract shape information from terms. The type # is like our c , whereas the term #e performs the translation e c lazily. Our approach gains in clarity and generality by separating the programming language from ....
C.B. Jay and M. Sekanina. Shape checking of array programs. In Computing: the Australasian Theory Seminar, Proceedings, 1997, 1997. accepted for publication.
....modeled in terms of a constraint based approach. In the following we give applications for the use of such index systems. 3 Arrays We apply an index system to an array calculus in order to perform array bounds checking. Our development of arrays is similar to previous approaches [Zen98a, XP98, JS96] but we rely on a constraint based approach. First, we have to choose an appropriate representation for arrays. We assume that arrays are represented as a special form of records. For instance, we treat the array [ b ; d ; x ] as a short hand for the record ffirst = b ; second = d ; third ....
....types. Hence, we can retain decidability. Another examles involve solving of equations and similar problems. We leave it to future investigations to study the connection to [Jay98] Jay s approach also allows poly dimensional arrays. Such a treatment can not be found in [Zen98a, XP98, JS96] 4 Algebraic data types We apply the labeled index system in combination with a record calculus to encode algebraic data types. The basic idea is that we consider data types as a form of a labeled data structure. Consider a data type declaration where we have different value constructors: D ....
C.B. Jay and M. Sekanina. Shape checking of array programs. Technical Report 96.09, University of Technology, Sydney, 1996.
....systems. This embedding translates programing language constructs into type theoretic expressions, which is a rather involved task requiring complex reasoning about the resulting expressions. We believe that our approach could be used to check some of these properties. Jay and Sekanina [7] have introduced a technique for array bounds checking based on the notion of shape types. Shape checking is a kind of partial evaluation and has very different characteristics and source language when compared to DML(C) where C consists of linear integer equality and inequality constraints. We ....
Jay, C. and Sekanina, M. Shape checking of array programs. no. 96.09, School of Computer Sciences, University of Technology, Sydney, Australia, 1996.
....and Sabry 1996) is too restrictive for general programming since the type system there can only handle (a minor variation) of primitive recursion. On the other hand, the use of sized types in the correctness proofs of reactive systems cannot be achieved in DML at this moment. Jay and Sekanina (Jay and Sekanina 1996) have introduced a technique for array bounds checking based on the notion of shape types. Shape checking is a kind of partial evaluation and has very different characteristics and source language when compared to DML(C) where constraints are linear inequalities on integers. We feel that their ....
Jay, C. and M. Sekanina (1996). Shape checking of array programs.
....systems. This embedding translates programing language constructs into type theoretic expressions, which is a rather involved task requiring complex reasoning about the resulting expressions. We believe that our approach could be used to check some of these properties. Jay and Sekanina [7] have introduced a technique for array bounds checking based on the notion of shape types. Shape checking is a kind of partial evaluation and has very different characteristics and source language when compared to DML(C) where C consists of linear integer equality and inequality constraints. ....
Jay, C. and Sekanina, M. Shape checking of array programs. no. 96.09, School of Computer Sciences, University of Technology, Sydney, Australia, 1996.
....into two components: its shape consisting of a description of the locations in which the data is stored, typically as a tree or graph, and; a list of the data stored in the shape. This division has a clear, formal semantics [Jay95] and is the basis for a number of initiatives in programming style [BJM96, JS97, JCSS97, PJ97], of which FISh is one. By determining the shapes in advance, the storage requirements can be determined, which makes boxing unnecessary. Also, sophisticated garbage collection techniques such as region analysis [TT94] are not required, since FISh supports a clear stack discipline. Another benefit ....
....as mapping and reducing, which were previous only definable by pattern matching on, say, lists. The shift from vector types (one dimensional arrays) to array types of arbitrary finite dimension in FISh version 0. 4 has provoked a thorough review of the language syntax, compared to earlier versions [JS97], so it is worth reviewing the language here. 2.1 FISh types ffi : int j bool j float j : ff : X j ffi j [ff] oe : ffi j #ff : ff j oe : V j #V j exp j var ff j comm j OE : j 8 ff X:OE j 8 V:OE shp V = #V shp (#V ) #V shp (exp ff) exp #ff shp (exp oe) ....
C.B. Jay and M. Sekanina. Shape checking of array programs. In Computing: the Australasian Theory Seminar, Proceedings, 1997, volume 19 of Australian Computer Science Communications, pages 113-- 121, 1997.
....is independent of the choice of functor, i.e. which support parametric functorial polymorphism. The rst such algo Functorial ML 3 rithms for (polymorphic folding) were produced for a small experimental language P2 (Jay, 1995a) Polymorphic mapping for the covariant type system is developed in (Jay, 1997). This paper presents an extension of Hindley Milner called Functorial ML, or FML, which supports parametric functorial polymorphism. For example, it supports: map f (cons h t) cons (f h) map f t) map f (leaf x) leaf (f x) where cons is the usual list constructor, and leaf is the leaf ....
....Here, distinguishing between types and functors is crucial. Another possibility is to add additional base functors that are not inductive, e.g. arrays. This would allow for types such as trees whose nodes support arrays, as appeared in (Wu et al. 1997) and connect to research on shape analysis (Jay Sekanina, 1997; Jay et al. 1997; Jay Steckler, 1998) Finally, it remains to implement FML as an extension of an existing programming language, so that its merits can be tested by the community of programmers. ....
[Article contains additional citation context not shown here]
Jay, C.B., & Sekanina, M. (1997). Shape checking of array programs. Pages 113-121 of: Computing: the Australasian theory seminar, proceedings, 1997. Australian Computer Science Communications, vol. 19.
....The Vec language will introduce type based restrictions to discriminate among these examples. 3 The Vec language The Vec language is a simply typed lambda calculus with products, a unit type, and a vector type constructor. The language as presented here is a variant of that presented in [JS97] The types are given by D : nat j bool j : D j sz j un j Theta j vec : j Theta j : D ranges over datum types whose shapes are trivial. ranges over data types. They include the datum types, the type sz of sizes, and are closed under finite products and vectors. ....
C.B. Jay and M. Sekanina. Shape checking of array programs. In Computing: the Australasian Theory Seminar, Proceedings, 1997, volume 19 of Australian Computer Science Communications, pages 113--121, 1997.
....with the speed of simple imperative programming. Version 1 is available over the internet. Key words: poly dimensional arrays, FISh, shape analysis 1 Introduction FISh is the first language to support a polymorphic type constructor for regular arrays (after our experimental language Vec [Jay and Sekanina, 1997]) Typical imperative languages such as C, and also Algol like languages [Reynolds, 1981; O Hearn and Tennent, 1997] support regular arrays with types such as int[2] 3] which are fixed as to dimension, size in each dimension, and entry type. Typical functional languages, such as O Caml and ....
....have the same shape. Thus a regular array is a hypercube of entries that all have the same shape [Jay, 1994] This dependence on shape leads to shape theory, which has a well developed formal semantics [Jay, 1995] and is the basis for a number of initiatives in programming [Bell e et al. 1996; Jay et al. 1997; Palsberg and Jay, 1997] of which FISh is one. Regularity in FISh is enforced by shape analysis. Its key purpose is to ensure that in each assignment x: e the shapes of x and e agree. Since the shape of an array is not allowed to change during execution, the same storage can be used ....
[Article contains additional citation context not shown here]
Jay, C.B. and Sekanina, M. (1997). Shape checking of array programs. In Computing: the Australasian Theory Seminar, Proceedings, 1997, volume 19 of Australian Computer Science Communications, pages 113--121.
....number of additional benefits over a comparable dynamic analysis. First, many program errors, such as attempting to multiply matrices whose sizes do not match, show up as compiletime shape errors. The basic techniques of static shape analysis were developed in the purely functional language Vec [JS97a] Its shape analyser is able to detect all array bound errors statically, at the cost of unrolling all loops. FiSh takes a more pragmatic approach: array indices are treated as integers, not sizes, and so some array bound errors escape detection. However, combinations of functions which are free ....
C.B. Jay and M. Sekanina. Shape checking of array programs. In Computing: the Australasian Theory Seminar, Proceedings, 1997, volume 19 of Australian Computer Science Communications, pages 113--121, 1997.
....its algorithms. Another application is to shape analysis. Whereas shape polymorphism tries to delay commitment to a choice of shape, shape analysis tries to infer shapes as soon as possible, preferably during compilation. Its most obvious application is to the detection of array bound errors; Vec[JS96] is an experimental functional language in which all array bound errors are detected statically. Deeper applications are concerned with memory management, especially as it applies to parallel programming. It can be used with a cost monad to estimate parallel execution times [JCSS97] Future work ....
C.B. Jay and M. Sekanina. Shape checking of array programs. Technical Report 96.09, University of Technology, Sydney, 1996.
No context found.
Jay, C. and Sekanina, M. Shape checking of array programs. no. 96.09, School of Computer Sciences, University of Technology, Sydney, Australia, 1996.
No context found.
Jay, C. and Sekanina, M. Shape checking of array programs. no. 96.09, School of Computer Sciences, University of Technology, Sydney, Australia, 1996.
No context found.
Jay, C. and M. Sekanina (1996). Shape checking of array programs. Technical Report 96.09, University of Technology, Sydney, Australia.
No context found.
C. Barry Jay and Milan Sekanina. Shape checking of array programs. In J. Harland, editor, Proc. Australasian Theory Seminar on Computing, volume 19 of Australian Computer Science Communications, pages 113121, 1997.
Online articles have much greater impact More about CiteSeer.IST Add search form to your site Submit documents Feedback
CiteSeer.IST - Copyright Penn State and NEC