CSE321 Programming Languages Evaluation Contexts and Abstract Machine C - PowerPoint PPT Presentation

About This Presentation
Title:

CSE321 Programming Languages Evaluation Contexts and Abstract Machine C

Description:

Reducing an expression e. Locate an appropriate ... Still Cryptic? 17. Outline. Evaluation contexts V. Abstract machine C. 18. This Rule is a Sagi. ... – PowerPoint PPT presentation

Number of Views:83
Avg rating:3.0/5.0
Slides: 26
Provided by: sungwo8
Category:

less

Transcript and Presenter's Notes

Title: CSE321 Programming Languages Evaluation Contexts and Abstract Machine C


1
CSE-321 Programming LanguagesEvaluation Contexts
and Abstract Machine C
???
  • POSTECH
  • April 12, 2006

2
Simply Typed ?-Calculus
3
18 Reduction Rules
4
Simpler?
5
Outline
  • Evaluation contexts
  • Abstract machine C

6
Reduction Rules
7
Derivation Trees
8
Reducing an expression e
  • Locate an appropriate subexpression
  • Apply a corresponding reduction rule

9
Locate and Apply
10
Decompose and Apply


11
Decompose and Apply
Expression

Subexpression to be reduced

Context to remain intact
12
Evaluation Contexts (CBV)
  • An expression with a hole in it
  • The hole indicates the position of a
    subexpression to be reduced.

13
Reduction Strategy
  • Determined by the definition of evaluation
    contexts

call-by-value
call-by-name
14
(No Transcript)
15
Reduction Rule
16
Still Cryptic?
17
Outline
  • Evaluation contexts V
  • Abstract machine C

18
This Rule is a Sagi.
19
Example
20
Abstract Machine C
  • Explicit decomposition of a given expression
  • Uses a stack of frames instead of evaluation
    contexts.
  • Each frame corresponds to a specific step in the
    decomposition.

21
State of the Machine
22
Example
23
(No Transcript)
24
Outline
  • Evaluation contexts V
  • Abstract machine C V
  • Something VERY important!

25
Midterm
  • One and half hours
  • Midterm 10 15, final 20 25
  • April 2006
  • Su Mo Tu We Th Fr Sa
  • 9 10 11 12 13 14 15
  • 16 17 18 19 20 21 22
  • 23 24 25 26 27 28 29
  • 30
Write a Comment
User Comments (0)
About PowerShow.com