Presentation is loading. Please wait.

Presentation is loading. Please wait.

1 Languages and Compilers (SProg og Oversættere) Bent Thomsen Department of Computer Science Aalborg University With acknowledgement to Hanne Riis Nielson.

Similar presentations


Presentation on theme: "1 Languages and Compilers (SProg og Oversættere) Bent Thomsen Department of Computer Science Aalborg University With acknowledgement to Hanne Riis Nielson."— Presentation transcript:

1 1 Languages and Compilers (SProg og Oversættere) Bent Thomsen Department of Computer Science Aalborg University With acknowledgement to Hanne Riis Nielson and Flemming Nielson whose book this lecture is based on.

2 2 The missing link The connection Between Syntax and Semantics And Languages and Compilers

3 3 The Language While The Language While can be considered mini version of Mini-Triangle While is almost the same as the BIMS language

4 4 Single step operational semantics for While

5 5 A stack based virtual machine - AM States: Transitions:

6 6 Operational semantics for AM

7 7 Translation of While to AM Note similarity with code generation templates for Mini-Triangle

8 8 Example

9 9 Correctness Proof

10 10 Soundness and completeness

11 11 Getting closer to TAM

12 12 And closer

13 13 Conclusion With a bit of hard work it is possible to connect –The high level operational semantics for a language –With the low level implementation –And prove correctness of the translation This is called: Provably correct implementations For more information read –Semantics with applications, –Hanne Riis Nielson and Flemming Nielson –Wiley 1992, ISBN 0 471 92980 8


Download ppt "1 Languages and Compilers (SProg og Oversættere) Bent Thomsen Department of Computer Science Aalborg University With acknowledgement to Hanne Riis Nielson."

Similar presentations


Ads by Google