| A. W. Appel and T. Jim. Continuation-passing, closurepassing style. In Sixteenth ACM Symposium on Principles of Programming Languages, pages 293--302, Austin, Jan. 1989. |
....creation, and procedure application is replaced by invocation of the code part of the closure on an actual parameter and the environment part of the closure. Alternatively, another copy of the closure can be passed instead of just the environment. This is sometimes called closure passing style [Appel and Jim 1989]. For example, we might convert let f = xy:z: x Gamma y Gamma z) g = h:h 3 in g(f 9 7) to let f = xy: ez: destr e (xy: x Gamma y Gamma z) x; y] g = h: app h 3 in g(f 9 7) where app = r: fst r) snd r) Here f takes two arguments and emits a procedure of one argument; in the ....
Appel, A. W. and Jim, T. 1989. Continuation-passing, closure-passing style. In Conference Record of 16th ACM Symposium on Principles of Programming Languages, pp. 293--302.
....has compelling advantages over a conventional untyped compiler. An optimizing compiler for a high level language such as ML may make as many as 20 passes over a single program, performing sophisticated analyses and transformations such as CPS conversion [14, 35, 2, 12, 18] closure conversion [20, 40, 19, 3, 26], unboxing [22, 28, 38] subsumption elimination [9, 11] or region inference [7] Many of these optimizations require type information in order to succeed, and even those that do not often benefit from the additional structure supplied by a typing discipline [22, 18, 28, 37] Furthermore, the ....
A. W. Appel and T. Jim. Continuation-passing, closurepassing style. In Sixteenth ACM Symposium on Principles of Programming Languages, pages 293--302, Austin, Jan. 1989.
....be stored in the list cell, rd contains the pointer to the next list cell, alloc is the address of the next free word in the allocation area, and top contains the end of the allocation area. 2. 4 Garbage collection in SML NJ The SML NJ compiler uses a simple generational copying garbage collector [Appel 1989]. Memory is divided into an old generation and an allocation area. New objects are created in the allocation area; garbage collection copies the live objects in the allocation area to the old generation, freeing up the allocation area. Generational garbage collection relies on the fact that most ....
....include inlining, passing function arguments in registers, register targeting, constant folding, code hoisting, uncurrying, and instruction scheduling. The most controversial design decision in the compiler was to allocate procedure activation records on the heap instead of the stack [Appel 1987; Appel and Jim 1989]. In principle, the presence of higher order functions means that procedure activation records must be allocated on the heap. With a suitable analysis, a stack can be used to store most activation records [Kranz et al. 1986] However, using only a heap simplifies the compiler, the run time system ....
[Article contains additional citation context not shown here]
Appel, A. W. and Jim, T. Y. 1989. Continuation-Passing, Closure-Passing Style. In Proceedings of the 16th Annual ACM Symposium on Principles of Programming Languages, Austin, Texas, pp. 293--302. ACM.
....nested functions. We therefore must convert higher order programs into equivalent first order programs without nested functions, i.e. perform closure conversion. For simplicity, we wish to express the first order programs in a strict subset of the original language, as in closure passing style (Appel and Jim, 1989), where closures are represented as ordinary records, and are constructed and accessed using ordinary record operators. In particular, this would allow us to optimize closure manipulation operations using ordinary record optimizations. However, we would also like the closure converted program to ....
Appel, A. W. and Jim, T. (1989). Continuation-passing, closure-passing style. In Sixteenth ACM Symp. on Principles of Programming Languages, pages 293--302, New York. ACM Press.
....a closed program and its compilation evaluate to the same result. Due to a lack of space, the proofs of correctness are omitted here. However, full details are given in the companion technical report [22] Closure conversion is discussed in descriptions of various functional language compilers [35, 16, 3, 2, 31]. It is closely related to lifting [14] in that it eliminates free variables in the bodies of abstractions but differs by making the representation of the environment explicit as a data structure. Making the environment explicit is important because it exposes environment construction and ....
A. W. Appel and T. Jim. Continuation-passing, closurepassing style. In ACM Symp. on Principles of Programming Languages, 1989.
....procedure application is replaced by invocation of the code part of the closure on an actual parameter and the environment part of the closure. Alternatively, another copy of the closure can be passed instead of just the environment. This strategy is sometimes called closure passing style [Appel and Jim 1989]. For example, we might convert let f = x:y: x Gamma y) g = h:h 3 in g (f 9) to let f = e; x: e 0 ; y: let x = #1 e 0 ) in x Gamma y) x] g = e 00 ; h: app h 3) in app g (app f 9) where app is a combinator, defined as r: #1 r) #2 r) which applies the code part ....
Appel, A. W. and Jim, T. 1989. Continuation-passing, closure-passing style. In Conference Record of the 16th ACM Symposium on Principles of Programming Languages. ACM, New York, 293--302.
....procedure application is replaced by invocation of the code part of the closure on an actual parameter and the environment part of the closure. Alternatively, another copy of the closure can be passed instead of just the environment. This strategy is sometimes called closure passing style [Appel and Jim 1989]. For example, we might convert let f = x:y: x Gamma y) g = h:h 3 in g (f 9) to let f = e; x: e 0 ; y: let x = #1 e 0 ) in x Gamma y) x] g = e 00 ; h: app h 3) in app g (app f 9) where app is a combinator, defined as r: #1 r) #2 r) which applies the code part ....
Appel, A. W. and Jim, T. 1989. Continuation-passing, closure-passing style. In Conference Record of the 16th ACM Symposium on Principles of Programming Languages. ACM, New York, 293--302.
....that a closed program and its translation evaluate to the same result. Due to lack of space, we omit the proofs of correctness here. However, full details may be found in the companion technical report [21] Closure conversion is discussed in descriptions of various functional language compilers [34, 17, 2, 1, 30]. It is similar to lifting [15] in that it eliminates free variables in the bodies of abstractions but differs by making the representation of the environment explicit as a data structure. Making the environment explicit is important because it exposes environment construction and variable ....
A. W. Appel and T. Jim. Continuation-passing, closurepassing style. In ACM Symp. on Principles of Programming Languages, 1989.
....has compelling advantages over a conventional untyped compiler. An optimizing compiler for a high level language such as ML may make as many as 20 passes over a single program, performing sophisticated analyses and transformations such as CPS conversion [14, 35, 2, 12, 18] closure conversion [20, 40, 19, 3, 26], unboxing [22, 28, 38] subsumption elimination [9, 11] or region inference [7] Many of these optimizations require type information in order to succeed, and even those that do not often benefit from the additional structure supplied by a typing discipline [22, 18, 28, 37] Furthermore, the ....
A. W. Appel and T. Jim. Continuation-passing, closurepassing style. In Sixteenth ACM Symposium on Principles of Programming Languages, pages 293--302, Austin, Jan. 1989.
....CPS language correspond directly to registers or to memory locations (fields of closures) and the optimizer can tell which is which, enabling more intelligent decisions about program transformations. The transformational compiler of Kelsey and Hudak[15] and the Standard ML of New Jersey compiler[4, 3], refine this notion further so that the abstract optimizer can control representation decisions while still staying within the original, semantically clean and powerful Continuation Passing Style. Our claim is that the functional style of CPS can simply and powerfully express the low level ....
....closures, as will be explained below) val w = offset(i,v) binds w to a record similar to the record value v, except that the jth field of w is the same as the (i j)th field of v. Continuation passing style has several advantages as an intermediate rep resentation for an optimizing compiler [20, 16, 4]. Because it has simple static scope, in line expansion of functions (S reduction) is very simple to express as are constant folding and other partial evaluations, commonsubexpression elimination, dead variable elimination, loop optimizations, and function calling sequence specialization. An ....
[Article contains additional citation context not shown here]
Appel, Andrew W. and Jim, Trevor. Continuation-passing, closurepassing style. In Sixteenth ACM Symp. on Principles of Programming Languages, ACM Press, New York (1989) 293 302.
....to check for stack overflow; but since overflow is so rare, this can usually be done at no cost using an inaccessible virtual memory page. Allocating a heap frame is more complicated: 1. Heap overflow must be checked. As explained by Appel and Li (1991) and contrary to the silly ideas of Appel (1989), this should not be done by a virtual memory fault: 1) operating system fault handling is too expensive, 2) heap overflow is unrelated to locality of reference, and (3) the technique is almost impossible on machines without precise interrupts. Thus, a comparison and a conditional branch are ....
....arena is the same size as the secondary cache. This provides empirical evidence for the claim that sizing the allocation space to fit into cache can improve performance. Reppy, 1994) Unfortunately, the measurements in our current paper were made using the older two generation collector (Appel, 1989). Small Caches For small (e.g. primary) caches whose size is less than 100 kbytes, it is impractical to keep the youngest generation in the cache; doing so would cause garbage collections to be too frequent, and this would be expensive. 6 This is a slight oversimplification. 10 ANDREW W. APPEL ....
[Article contains additional citation context not shown here]
Appel, Andrew W. and Trevor Jim. 1989. Continuation-passing, closure-passing style. In Sixteenth ACM Symp. on Principles of Programming Languages, pages 293--302, New York. ACM Press.
....CPS language correspond directly to registers or to memory locations (fields of closures) and the optimizer can tell which is which, enabling more intelligent decisions about program transformations. The transformational compiler of Kelsey and Hudak[15] and the Standard ML of New Jersey compiler[4, 3], refine this notion further so that the abstract optimizer can control representation decisions while still staying within the original, semantically clean and powerful Continuation Passing Style. Our claim is that the functional style of CPS can simply and powerfully express the low level ....
....as will be explained below) val w = offset(i; v) binds w to a record similar to the record value v, except that the j th field of w is the same as the (i j) th field of v. Continuation passing style has several advantages as an intermediate representation for an optimizing compiler [20, 16, 4]. Because it has simple static scope, in line expansion of functions (fi reduction) is very simple to express as are constant folding and other partial evaluations, commonsubexpression elimination, dead variable elimination, loop optimizations, and function calling sequence specialization. An ....
[Article contains additional citation context not shown here]
Appel, Andrew W. and Jim, Trevor. Continuation-passing, closurepassing style. In Sixteenth ACM Symp. on Principles of Programming Languages, ACM Press, New York (1989) 293--302.
No context found.
A. W. Appel and T. Jim. Continuation-passing, closurepassing style. In Sixteenth ACM Symposium on Principles of Programming Languages, pages 293--302, Austin, Jan. 1989.
No context found.
Appel, Andrew W. and Jim, Trevor. Continuation-passing, closurepassing style. In Sixteenth ACM Symposium on Principles of Programming Languages (1989) 293--302.
No context found.
A. W. Appel and T. Jim. Continuation-passing, closurepassing style. In Sixteenth ACM Symposium on Principles of Programming Languages, pages 293--302, Austin, Jan. 1989.
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