Week1 Lecture1
The steps of Compilation:
1.Lexical Analysis(词法分析):
divide sequence of characters into tokens, such as variable names,operators, labels. In a natural language tokens are strings of consecutive letters (easy to recognize)
2.Parse Tree:
identify relationships between tokens
parse tree or parsing tree or derivation tree or concrete syntax tree is an ordered,rooted tree that represents the syntactic structure of a string according tosome context-free grammar.
3.Code generation:
is part of the process chain of a compiler and convertsintermediate representation of source code into a°form (e.g.,machine code)that can be readily executed by the target system.
4.Code optimization:
is the process of modifying a software system to make someaspect of it work more efficiently or use fewer resources. In general, a computerprogram may be optimized so that it executes more rapidly,or to make itcapable of operating with less memory storage or other resources, or draw lesspower.
Automata:
An automaton is an abstract model of a digital computer
Week1 Tutorial1
Mathematical preliminaries:数学初步 回顾一些基本的数学定义
1.Set 集合
A set is a collection of well-defined objects.
2.Graph