1.lexical analysis,which analyzes the character string presented to it and divides it up into tokens that are legal members of the vocabulary of the language in which the program is written (and may produce error messages if the character string is not parseable into a string of legal tokens);

2.syntactic analysis or parsing,which processes the sequence of tokens and produces an intermediate-level representation,such as a parse  tree or a sequential intermediate code,and a symbol  table that records the identifiers used in the program  and their attibutes.

3.checking of the program for static-semantic validity(or semantic checking),which takes as input the intermediate code and symbol table and determines whether the program satisfiers  the staic-semantic properties required by the source language.

4.code generation,which transforms the intermediate code into equivalent machine code in the form of a relocatable object module or directly runnable object code.

1.詞法分析,它分析呈現給它的字符串,並將其劃分為令牌,這些令牌是編寫程序的語言詞彙的合法成員(如果字符串不能解析成字符串,則可能產生錯誤消息。一串合法代幣);

2.語法分析或解析,它處理令牌序列並產生中間級表示,例如解析樹或順序中間代碼,以及記錄程序中使用的標識符及其屬性的符號表。

3.檢查程序的靜態語義有效性(或語義檢查),它將中間代碼和符號表作為輸入,並確定程序是否滿足源語言所需的基本語義屬性。

4.代碼生成,它以可重定位目標模塊或直接可運行目標代碼的形式將中間代碼轉換為等效的機器代碼。

High-level structure of a simple compiler高級結構的簡單編譯器的更多相关文章

  1. 浏览器的主要构成High Level Structure

    浏览器的主要组件包括: 1.     用户界面- 包括地址栏.后退/前进按钮.书签目录等,也就是你所看到的除了用来显示你所请求页面的主窗口之外的其他部分 2.     浏览器引擎- 用来查询及操作渲染 ...

  2. day20 Python 高阶函数,函数,嵌套,闭包 装饰器

    高阶函数定义 1.函数接收的参数是一个函数名 2.函数的返回值是一个函数名 3.满足上述条件任意一个都可以称之为高阶函数 一.函数的接收参数是一个函数名 import time def foo(): ...

  3. Python复习笔记(四)高阶函数/返回函数/匿名函数/偏函数/装饰器

    一.map/reduce map map()函数接收两个参数,一个是函数,一个是Iterable,map将传入的函数依次 作用到序列的每个元素,并把结果作为新的Iterator返回. reduce r ...

  4. file_get_contents高級用法

    首先解決file_get_contents的超時問題,在超時返回錯誤後就象js中的settimeout那樣進行一次嘗試,錯誤超過3次或者5次後就確認為無法連線伺服器而徹底放棄.這裡就簡單介紹兩種解決方 ...

  5. css高級技巧

    1.鼠標顯示 a:小手cursor:pointer b:默認cursor:default c:勾選文本cursor:text d:拖動cursor:move 2.css三種佈局模型 a.流動模型(默認 ...

  6. VLC祥解

    功能部份:   VLC媒體播放器的核心是libvlc ,它提供了界面,應用處理功能,如播放列表管理,音頻和視頻解碼和輸出,線程系統.所有libvlc源文件設在的/src目錄及其子目錄:   # con ...

  7. [转] 編程風格要素-The Elements of Programming Style 中文英文中英對照

    转自: http://www.loliman3000.com/tech/2fe33ce32906f0302412881.php 下面的程序風格規則提煉自Brian Kernighan和P. J. Pl ...

  8. C/C++开发工具大比拼【转】

    C/C++开发工具大比拼[转]  (http://hi.baidu.com/vipdowndown/blog/item/dcd7c1b5ad3209ef30add167.html) * NetBean ...

  9. Universal Asynchronous Receiver/Transmitter

    USART簡介與特性 NRZ標準資料格式(Mark/Space) 半雙工/全雙工 Synchronous 同步傳輸 CLOCK SKEW Asynchronous 非同步傳輸 半/全雙工.同步/非同步 ...

随机推荐

  1. 03-13_WLST导航和定位MBean

    本文重点:WLST导航和定位MBean     MBean切换图 如上:红色的字体表示切换的命令.ls和cd是在当前树下切换,其他命令是在不同树之间切换. 其中: DomainMBeanServer有 ...

  2. ScheduledThreadPoolExecutor源码解读

    1. 背景 在之前的博文--ThreadPoolExecutor源码解读已经对ThreadPoolExecutor的实现原理与源码进行了分析.ScheduledExecutorService也是我们在 ...

  3. oracle sqlplus 回退键以及上下键

    Linux中安装完Oracle后,默认的 sqlplus 上下键是不能用的,安装了 rlwrap 之后就能通过上下键翻回历史命令了 下载地址 https://github.com/hanslub42/ ...

  4. 【转】抓包工具Fiddler的使用教程(十二)下:Fiddler抓取HTTPS

    在教程十二(上),我们也了解了HTTPS协议,该教程就和大家分享Fiddler如何抓取HTTPS 抓包工具Fiddler的使用教程(十二):[转载]HTTPS协议 再次回忆一下关键内容: iddler ...

  5. 20145236《网络对抗》Exp2 后门原理与实践

    20145236<网络对抗>Exp2 后门原理与实践 目录: 一.基础问题回答 二.常用后门工具实践 2.1 Windows获得Linux Shell 2.2 Linux获得Windows ...

  6. day10,11练习

    1.执行Python脚本两种方式? 略 2.简述位.字节关系? 8位一个字节 3.简述ASCII,Unicode,utf-8,gbk关系? ascii unicode utf8 4.请写出李杰分别用u ...

  7. PAT A1074 Reversing Linked List (25 分)——链表,vector,stl里的reverse

    Given a constant K and a singly linked list L, you are supposed to reverse the links of every K elem ...

  8. docker常用命令汇总

    生成镜像docker build -t="eureka" .打标记docker tag eureka:latest 172.16.120.194:5000/eureka:lates ...

  9. python:python之禅

    最近在学python,今晚看了一个名叫“python全栈之路系列”的关于python的相关博客,其中开篇就说到了python的设计哲学:优雅,简洁... 可以在编译器里面输入如下语句来查看python ...

  10. 洛谷 P1546 最短网络 Agri-Net

    题目链接 https://www.luogu.org/problemnew/show/P1546 题目背景 农民约翰被选为他们镇的镇长!他其中一个竞选承诺就是在镇上建立起互联网,并连接到所有的农场.当 ...