正在加载图片...
Lecture Outline We shall look at a simple programming language and describe the initial phases of compilation. We start off by creating a simple'syntax directed translator that maps infix arithmetic to postfix arithmetic. This translator is then extended to cater for more elaborate programs such as (check page 39 Aho) -While (true){x=a[i];a[i]=a[j];a[j]=x; Which generates simplified intermediate code (as on pg40 Aho) CS308 Compiler Theory 2Lecture Outline • We shall look at a simple programming language and describe the initial ph f il i ases of compilation. • We start off by creating a ‘simple’ syntax directed translator that maps infix arithmetic to postfix arithmetic. • This translator is then extended to cater for more elaborate programs such as (check page 39 Aho) such as (check page 39 Aho) – While (true) { x=a[i]; a[i]=a[j]; a[j]=x; } • Which generates simplified intermediate code (as on pg40 Aho) CS308 Compiler Theory 2
<<向上翻页向下翻页>>
©2008-现在 cucdc.com 高等教育资讯网 版权所有