SlideShare a Scribd company logo
7
Most read
8
Most read
18
Most read
Sanjivani Rural Education Society’s
Sanjivani College of Engineering, Kopargaon-423 603
(An Autonomous Institute, Affiliated to Savitribai Phule Pune University, Pune)
NACC ‘A’ Grade Accredited, ISO 9001:2015 Certified
Department of Computer Engineering
(NBA Accredited)
Dr. S. N. Gunjal
Assistant Professor
E-mail : gunjasanjay@sanjivani.org.in
Contact No: 91301 91301 Ext :145, 9503916876
Course- System Software
(CO313)
Structure of a Compiler, Compiler and Interpreter, Lexical Analysis: Role of the lexical
analyzer
Dr. S.N Gunjal
Compiler
Compiler is a program that can read a program in one language - the source language - and translate
it into an equivalent program in another language - the target language.
An important role of the compiler is to report any errors in the source program that it detects during
the translation process.
Compiler
Source
Program
Target
Program
Errors
Figure 1.1 : A compiler
Compiler
If the target program is an executable machine-language program, it can then be called by the user to
process inputs and produce outputs;
Target Program
Input Output
Figure 1.2: Running the target program
Interpreter
An interpreter is another common kind of language processor. Instead of producing a
target program as a translation, an interpreter appears to directly execute the operations
specified in the source program on inputs supplied by the user.
Interpreter
Input
Output
Source
Program
Figure 1.3: An interpreter
The machine-language target program produced by a compiler is usually much faster than an
interpreter at mapping inputs to outputs .
An interpreter, however, can usually give better error diagnostics than a compiler, because it
executes the source program statement by statement.
Interpreter
5
Structure of
Compiler
Structure of Compiler
Structure of a Compiler, Compiler and Interpreter, Lexical Analysis: Role of the lexical analyzer
The analysis part breaks up the source program into constituent pieces and imposes a
grammatical structure on them. It then uses this structure to create an intermediate representation of
the source program.
The analysis part also collects information about the source program and stores it in a data
structure called a symbol table, which is passed along with the intermediate representation to the
synthesis part.
Analysis and Synthesis Phase of Compiler
Analysis Phase :
Synthesis Phase
The synthesis part constructs the desired target program from the interme-diate representation and the
information in the symbol table.
The analysis part is often called the front end of the compiler; the synthesis part is the back end.
 The first phase of a compiler is called lexical analysis or scanning.
 The lexical analyzer reads the stream of characters making up the source program. and
groups the characters into meaningful sequences called lexemes.
For each lexeme, the lexical analyzer produces as output a token of the form
(token-name, attribute-value)
position = initial + rate * 60;
sequence of tokens: <id,1> <=><id,2><+><id,3><*><60><;>
Compiler Phases:
Lexical Analysis Phase :
 The second phase of the compiler is syntax analysis or parsing.
 The parser uses the first components of the tokens produced by the lexical
analyzer to create a tree-like intermediate representation that depicts the
grammatical structure of the token stream.
A typical representation is a syntax tree in which each interior node
represents an operation and the children of the node represent the arguments
of the operation.
Compiler Phases:
Syntax Analysis :
The semantic analyzer uses the syntax tree and the information in the
symbol table to check the source program for semantic consistency with the
language definition.
 It also gathers type information and saves it in either the syntax tree or the
symbol table, for subsequent use during intermediate-code generation.
Compiler Phases:
Sematic Analysis :
In the process of translating a source program into target code, a compiler
may construct one or more intermediate representations, which can have a
variety of forms.
An intermediate form called three-address code, which consists of a
sequence of assembly-like instructions with three operands per instruction.
tl = inttofloat(60)
t2 = id3 * tl
t3 = id2 + t2
id1 = t3
Compiler Phases:
Intermediate Code Generation:
The machine-independent code-optimization phase attempts to improve the
intermediate code so that better target code will result.
Compiler Phases:
Code Optimization:
The code generator takes as input an intermediate representation of the
source program and maps it into the target language.
The intermediate instructions are translated into sequences of machine
instructions that perform the same task.
Compiler Phases:
Code Generation:
Structure of a Compiler, Compiler and Interpreter, Lexical Analysis: Role of the lexical analyzer
THE ROLE OF THE LEXICALANALYZER
 The first phase of a compiler is called lexical analysis or scanning.
 The lexical analyzer reads the stream of characters making up the source
program. and groups the characters into meaningful sequences called
lexemes.
 For each lexeme, the lexical analyzer produces as output a token of the
form (token-name, attribute-value)
position = initial + rate * 60;
sequence of tokens: <id,1> <=><id,2><+><id,3><*><60><;>
The lexical analyzer is responsible for removing the white spaces and
comments from the source program.
15/06/20 DEPARTMENT OF COMPUTER ENGINEERING, Sanjivani COE, Kopargaon
THE ROLE OF THE LEXICALANALYZER
THE ROLE OF THE LEXICALANALYZER
Token: A token is a pair – a token name and an optional
token value.
A pattern is a description of the form that the lexemes of a token may take.
A lexeme is a sequence of characters in the source program that matches the
pattern for a token
A lexical error occurs when a sequence of characters does not match
the pattern of any token.
15/06/20 DEPARTMENT OF COMPUTER ENGINEERING, Sanjivani COE, Kopargaon
Attributes for tokens
• E = M * C ** 2
– <id, pointer to symbol table entry for E>
– <assign‐op>
– <id, pointer to symbol table entry for M>
– <mult‐op>
– <id, pointer to symbol table entry for C>
– <exp‐op>
– <number, integer value 2>
References
1. Alfred V.Aho,Monica S.Lam,Ravi Sethi, Jeffrey D. Ullman, “Compilers-
Principles,Techniques and Tools”, Pearson,ISBN:978-81-317-2101-8
Ad

Recommended

tL20 event handling
tL20 event handling
teach4uin
 
Introduction to Digital Forensics and Evidences Aquasation.pdf
Introduction to Digital Forensics and Evidences Aquasation.pdf
Abhijit Bodhe
 
Computer crime and Legal issues Computer crime and Legal issues
Computer crime and Legal issues Computer crime and Legal issues
Abhijit Bodhe
 
File in c
File in c
Prabhu Govind
 
String Manipulation in Python
String Manipulation in Python
Pooja B S
 
Tugas imk hta
Tugas imk hta
Ismi Islamia
 
Perbedaan arsitektur komputer dan organisasi komputer
Perbedaan arsitektur komputer dan organisasi komputer
David Rigan
 
Malware Analysis Tips and Tricks.pdf
Malware Analysis Tips and Tricks.pdf
Yushimon
 
Rumus Algebra.pdf
Rumus Algebra.pdf
Roslina Abdul Rashid
 
Metasploit
Metasploit
Parth Sahu
 
File Handling in C Programming
File Handling in C Programming
Bosco Technical Training Society, Don Bosco Technical School (Aff. GGSIP University, New Delhi)
 
C++ Programming.pdf
C++ Programming.pdf
MrRSmey
 
Exception handling c++
Exception handling c++
Jayant Dalvi
 
Recursive functions in C
Recursive functions in C
Lakshmi Sarvani Videla
 
Windows attacks - AT is the new black
Windows attacks - AT is the new black
Chris Gates
 
Memory Management C++ (Peeling operator new() and delete())
Memory Management C++ (Peeling operator new() and delete())
Sameer Rathoud
 
File handling in C++
File handling in C++
Hitesh Kumar
 
50 Shades of Sigma
50 Shades of Sigma
Florian Roth
 
Regulatory impact on banks and insurers investments
Regulatory impact on banks and insurers investments
Ageas
 
Basic Web Exploit Development
Basic Web Exploit Development
Riswanda N.S
 
Database Firewall with Snort
Database Firewall with Snort
Narudom Roongsiriwong, CISSP
 
Python Programming Essentials - M9 - String Formatting
Python Programming Essentials - M9 - String Formatting
P3 InfoTech Solutions Pvt. Ltd.
 
Plc part 2
Plc part 2
Taymoor Nazmy
 
COMPILER CONSTRUCTION KU 1.pptx
COMPILER CONSTRUCTION KU 1.pptx
Rossy719186
 
1._Introduction_.pptx
1._Introduction_.pptx
Anbarasan Radhakrishnan R
 
Compiler Design
Compiler Design
Dr. Jaydeep Patil
 
An Introduction to the Compiler Designss
An Introduction to the Compiler Designss
ElakkiaU
 
Compiler Design.pptx
Compiler Design.pptx
SouvikRoy149
 
Compier Design_Unit I.ppt
Compier Design_Unit I.ppt
sivaganesh293
 
Compier Design_Unit I.ppt
Compier Design_Unit I.ppt
sivaganesh293
 

More Related Content

What's hot (14)

Rumus Algebra.pdf
Rumus Algebra.pdf
Roslina Abdul Rashid
 
Metasploit
Metasploit
Parth Sahu
 
File Handling in C Programming
File Handling in C Programming
Bosco Technical Training Society, Don Bosco Technical School (Aff. GGSIP University, New Delhi)
 
C++ Programming.pdf
C++ Programming.pdf
MrRSmey
 
Exception handling c++
Exception handling c++
Jayant Dalvi
 
Recursive functions in C
Recursive functions in C
Lakshmi Sarvani Videla
 
Windows attacks - AT is the new black
Windows attacks - AT is the new black
Chris Gates
 
Memory Management C++ (Peeling operator new() and delete())
Memory Management C++ (Peeling operator new() and delete())
Sameer Rathoud
 
File handling in C++
File handling in C++
Hitesh Kumar
 
50 Shades of Sigma
50 Shades of Sigma
Florian Roth
 
Regulatory impact on banks and insurers investments
Regulatory impact on banks and insurers investments
Ageas
 
Basic Web Exploit Development
Basic Web Exploit Development
Riswanda N.S
 
Database Firewall with Snort
Database Firewall with Snort
Narudom Roongsiriwong, CISSP
 
Python Programming Essentials - M9 - String Formatting
Python Programming Essentials - M9 - String Formatting
P3 InfoTech Solutions Pvt. Ltd.
 

Similar to Structure of a Compiler, Compiler and Interpreter, Lexical Analysis: Role of the lexical analyzer (20)

Plc part 2
Plc part 2
Taymoor Nazmy
 
COMPILER CONSTRUCTION KU 1.pptx
COMPILER CONSTRUCTION KU 1.pptx
Rossy719186
 
1._Introduction_.pptx
1._Introduction_.pptx
Anbarasan Radhakrishnan R
 
Compiler Design
Compiler Design
Dr. Jaydeep Patil
 
An Introduction to the Compiler Designss
An Introduction to the Compiler Designss
ElakkiaU
 
Compiler Design.pptx
Compiler Design.pptx
SouvikRoy149
 
Compier Design_Unit I.ppt
Compier Design_Unit I.ppt
sivaganesh293
 
Compier Design_Unit I.ppt
Compier Design_Unit I.ppt
sivaganesh293
 
2-Design Issues, Patterns, Lexemes, Tokens-28-04-2023.docx
2-Design Issues, Patterns, Lexemes, Tokens-28-04-2023.docx
venkatapranaykumarGa
 
Ss ui lecture 2
Ss ui lecture 2
Avinash Kapse
 
Compiler Design Introduction With Design
Compiler Design Introduction With Design
rashmishekhar81
 
11700220036.pdf
11700220036.pdf
SouvikRoy149
 
compiler.pdfljdvgepitju4io3elkhldhyreyio4uw
compiler.pdfljdvgepitju4io3elkhldhyreyio4uw
abhinandpk2405
 
Chapter#01 cc
Chapter#01 cc
abdulbaki3
 
Compiler Design
Compiler Design
Anujashejwal
 
ppt_cd.pptx ppt on phases of compiler of jntuk syllabus
ppt_cd.pptx ppt on phases of compiler of jntuk syllabus
padmajagrandhe1
 
Compiler
Compiler
Md. Sumon Fakir
 
Structure of the compiler
Structure of the compiler
Sudhaa Ravi
 
Principles of Compiler Design
Principles of Compiler Design
Marimuthu M
 
Cs6660 compiler design
Cs6660 compiler design
hari2010
 
COMPILER CONSTRUCTION KU 1.pptx
COMPILER CONSTRUCTION KU 1.pptx
Rossy719186
 
An Introduction to the Compiler Designss
An Introduction to the Compiler Designss
ElakkiaU
 
Compiler Design.pptx
Compiler Design.pptx
SouvikRoy149
 
Compier Design_Unit I.ppt
Compier Design_Unit I.ppt
sivaganesh293
 
Compier Design_Unit I.ppt
Compier Design_Unit I.ppt
sivaganesh293
 
2-Design Issues, Patterns, Lexemes, Tokens-28-04-2023.docx
2-Design Issues, Patterns, Lexemes, Tokens-28-04-2023.docx
venkatapranaykumarGa
 
Compiler Design Introduction With Design
Compiler Design Introduction With Design
rashmishekhar81
 
compiler.pdfljdvgepitju4io3elkhldhyreyio4uw
compiler.pdfljdvgepitju4io3elkhldhyreyio4uw
abhinandpk2405
 
ppt_cd.pptx ppt on phases of compiler of jntuk syllabus
ppt_cd.pptx ppt on phases of compiler of jntuk syllabus
padmajagrandhe1
 
Structure of the compiler
Structure of the compiler
Sudhaa Ravi
 
Principles of Compiler Design
Principles of Compiler Design
Marimuthu M
 
Cs6660 compiler design
Cs6660 compiler design
hari2010
 
Ad

Recently uploaded (20)

Gladiolous Cultivation practices by AKL.pdf
Gladiolous Cultivation practices by AKL.pdf
kushallamichhame
 
Wage and Salary Computation.ppt.......,x
Wage and Salary Computation.ppt.......,x
JosalitoPalacio
 
SCHIZOPHRENIA OTHER PSYCHOTIC DISORDER LIKE Persistent delusion/Capgras syndr...
SCHIZOPHRENIA OTHER PSYCHOTIC DISORDER LIKE Persistent delusion/Capgras syndr...
parmarjuli1412
 
Hurricane Helene Application Documents Checklists
Hurricane Helene Application Documents Checklists
Mebane Rash
 
Aprendendo Arquitetura Framework Salesforce - Dia 02
Aprendendo Arquitetura Framework Salesforce - Dia 02
Mauricio Alexandre Silva
 
Photo chemistry Power Point Presentation
Photo chemistry Power Point Presentation
mprpgcwa2024
 
CRYPTO TRADING COURSE BY FINANCEWORLD.IO
CRYPTO TRADING COURSE BY FINANCEWORLD.IO
AndrewBorisenko3
 
Public Health For The 21st Century 1st Edition Judy Orme Jane Powell
Public Health For The 21st Century 1st Edition Judy Orme Jane Powell
trjnesjnqg7801
 
LAZY SUNDAY QUIZ "A GENERAL QUIZ" JUNE 2025 SMC QUIZ CLUB, SILCHAR MEDICAL CO...
LAZY SUNDAY QUIZ "A GENERAL QUIZ" JUNE 2025 SMC QUIZ CLUB, SILCHAR MEDICAL CO...
Ultimatewinner0342
 
List View Components in Odoo 18 - Odoo Slides
List View Components in Odoo 18 - Odoo Slides
Celine George
 
University of Ghana Cracks Down on Misconduct: Over 100 Students Sanctioned
University of Ghana Cracks Down on Misconduct: Over 100 Students Sanctioned
Kweku Zurek
 
Pests of Maize: An comprehensive overview.pptx
Pests of Maize: An comprehensive overview.pptx
Arshad Shaikh
 
Filipino 9 Maikling Kwento Ang Ama Panitikang Asiyano
Filipino 9 Maikling Kwento Ang Ama Panitikang Asiyano
sumadsadjelly121997
 
INDUCTIVE EFFECT slide for first prof pharamacy students
INDUCTIVE EFFECT slide for first prof pharamacy students
SHABNAM FAIZ
 
Great Governors' Send-Off Quiz 2025 Prelims IIT KGP
Great Governors' Send-Off Quiz 2025 Prelims IIT KGP
IIT Kharagpur Quiz Club
 
English 3 Quarter 1_LEwithLAS_Week 1.pdf
English 3 Quarter 1_LEwithLAS_Week 1.pdf
DeAsisAlyanajaneH
 
YSPH VMOC Special Report - Measles Outbreak Southwest US 6-14-2025.pptx
YSPH VMOC Special Report - Measles Outbreak Southwest US 6-14-2025.pptx
Yale School of Public Health - The Virtual Medical Operations Center (VMOC)
 
Tanja Vujicic - PISA for Schools contact Info
Tanja Vujicic - PISA for Schools contact Info
EduSkills OECD
 
2025 June Year 9 Presentation: Subject selection.pptx
2025 June Year 9 Presentation: Subject selection.pptx
mansk2
 
Birnagar High School Platinum Jubilee Quiz.pptx
Birnagar High School Platinum Jubilee Quiz.pptx
Sourav Kr Podder
 
Gladiolous Cultivation practices by AKL.pdf
Gladiolous Cultivation practices by AKL.pdf
kushallamichhame
 
Wage and Salary Computation.ppt.......,x
Wage and Salary Computation.ppt.......,x
JosalitoPalacio
 
SCHIZOPHRENIA OTHER PSYCHOTIC DISORDER LIKE Persistent delusion/Capgras syndr...
SCHIZOPHRENIA OTHER PSYCHOTIC DISORDER LIKE Persistent delusion/Capgras syndr...
parmarjuli1412
 
Hurricane Helene Application Documents Checklists
Hurricane Helene Application Documents Checklists
Mebane Rash
 
Aprendendo Arquitetura Framework Salesforce - Dia 02
Aprendendo Arquitetura Framework Salesforce - Dia 02
Mauricio Alexandre Silva
 
Photo chemistry Power Point Presentation
Photo chemistry Power Point Presentation
mprpgcwa2024
 
CRYPTO TRADING COURSE BY FINANCEWORLD.IO
CRYPTO TRADING COURSE BY FINANCEWORLD.IO
AndrewBorisenko3
 
Public Health For The 21st Century 1st Edition Judy Orme Jane Powell
Public Health For The 21st Century 1st Edition Judy Orme Jane Powell
trjnesjnqg7801
 
LAZY SUNDAY QUIZ "A GENERAL QUIZ" JUNE 2025 SMC QUIZ CLUB, SILCHAR MEDICAL CO...
LAZY SUNDAY QUIZ "A GENERAL QUIZ" JUNE 2025 SMC QUIZ CLUB, SILCHAR MEDICAL CO...
Ultimatewinner0342
 
List View Components in Odoo 18 - Odoo Slides
List View Components in Odoo 18 - Odoo Slides
Celine George
 
University of Ghana Cracks Down on Misconduct: Over 100 Students Sanctioned
University of Ghana Cracks Down on Misconduct: Over 100 Students Sanctioned
Kweku Zurek
 
Pests of Maize: An comprehensive overview.pptx
Pests of Maize: An comprehensive overview.pptx
Arshad Shaikh
 
Filipino 9 Maikling Kwento Ang Ama Panitikang Asiyano
Filipino 9 Maikling Kwento Ang Ama Panitikang Asiyano
sumadsadjelly121997
 
INDUCTIVE EFFECT slide for first prof pharamacy students
INDUCTIVE EFFECT slide for first prof pharamacy students
SHABNAM FAIZ
 
Great Governors' Send-Off Quiz 2025 Prelims IIT KGP
Great Governors' Send-Off Quiz 2025 Prelims IIT KGP
IIT Kharagpur Quiz Club
 
English 3 Quarter 1_LEwithLAS_Week 1.pdf
English 3 Quarter 1_LEwithLAS_Week 1.pdf
DeAsisAlyanajaneH
 
Tanja Vujicic - PISA for Schools contact Info
Tanja Vujicic - PISA for Schools contact Info
EduSkills OECD
 
2025 June Year 9 Presentation: Subject selection.pptx
2025 June Year 9 Presentation: Subject selection.pptx
mansk2
 
Birnagar High School Platinum Jubilee Quiz.pptx
Birnagar High School Platinum Jubilee Quiz.pptx
Sourav Kr Podder
 
Ad

Structure of a Compiler, Compiler and Interpreter, Lexical Analysis: Role of the lexical analyzer

  • 1. Sanjivani Rural Education Society’s Sanjivani College of Engineering, Kopargaon-423 603 (An Autonomous Institute, Affiliated to Savitribai Phule Pune University, Pune) NACC ‘A’ Grade Accredited, ISO 9001:2015 Certified Department of Computer Engineering (NBA Accredited) Dr. S. N. Gunjal Assistant Professor E-mail : [email protected] Contact No: 91301 91301 Ext :145, 9503916876 Course- System Software (CO313) Structure of a Compiler, Compiler and Interpreter, Lexical Analysis: Role of the lexical analyzer Dr. S.N Gunjal
  • 2. Compiler Compiler is a program that can read a program in one language - the source language - and translate it into an equivalent program in another language - the target language. An important role of the compiler is to report any errors in the source program that it detects during the translation process. Compiler Source Program Target Program Errors Figure 1.1 : A compiler
  • 3. Compiler If the target program is an executable machine-language program, it can then be called by the user to process inputs and produce outputs; Target Program Input Output Figure 1.2: Running the target program
  • 4. Interpreter An interpreter is another common kind of language processor. Instead of producing a target program as a translation, an interpreter appears to directly execute the operations specified in the source program on inputs supplied by the user. Interpreter Input Output Source Program Figure 1.3: An interpreter
  • 5. The machine-language target program produced by a compiler is usually much faster than an interpreter at mapping inputs to outputs . An interpreter, however, can usually give better error diagnostics than a compiler, because it executes the source program statement by statement. Interpreter
  • 9. The analysis part breaks up the source program into constituent pieces and imposes a grammatical structure on them. It then uses this structure to create an intermediate representation of the source program. The analysis part also collects information about the source program and stores it in a data structure called a symbol table, which is passed along with the intermediate representation to the synthesis part. Analysis and Synthesis Phase of Compiler Analysis Phase :
  • 10. Synthesis Phase The synthesis part constructs the desired target program from the interme-diate representation and the information in the symbol table. The analysis part is often called the front end of the compiler; the synthesis part is the back end.
  • 11.  The first phase of a compiler is called lexical analysis or scanning.  The lexical analyzer reads the stream of characters making up the source program. and groups the characters into meaningful sequences called lexemes. For each lexeme, the lexical analyzer produces as output a token of the form (token-name, attribute-value) position = initial + rate * 60; sequence of tokens: <id,1> <=><id,2><+><id,3><*><60><;> Compiler Phases: Lexical Analysis Phase :
  • 12.  The second phase of the compiler is syntax analysis or parsing.  The parser uses the first components of the tokens produced by the lexical analyzer to create a tree-like intermediate representation that depicts the grammatical structure of the token stream. A typical representation is a syntax tree in which each interior node represents an operation and the children of the node represent the arguments of the operation. Compiler Phases: Syntax Analysis :
  • 13. The semantic analyzer uses the syntax tree and the information in the symbol table to check the source program for semantic consistency with the language definition.  It also gathers type information and saves it in either the syntax tree or the symbol table, for subsequent use during intermediate-code generation. Compiler Phases: Sematic Analysis :
  • 14. In the process of translating a source program into target code, a compiler may construct one or more intermediate representations, which can have a variety of forms. An intermediate form called three-address code, which consists of a sequence of assembly-like instructions with three operands per instruction. tl = inttofloat(60) t2 = id3 * tl t3 = id2 + t2 id1 = t3 Compiler Phases: Intermediate Code Generation:
  • 15. The machine-independent code-optimization phase attempts to improve the intermediate code so that better target code will result. Compiler Phases: Code Optimization:
  • 16. The code generator takes as input an intermediate representation of the source program and maps it into the target language. The intermediate instructions are translated into sequences of machine instructions that perform the same task. Compiler Phases: Code Generation:
  • 18. THE ROLE OF THE LEXICALANALYZER  The first phase of a compiler is called lexical analysis or scanning.  The lexical analyzer reads the stream of characters making up the source program. and groups the characters into meaningful sequences called lexemes.  For each lexeme, the lexical analyzer produces as output a token of the form (token-name, attribute-value) position = initial + rate * 60; sequence of tokens: <id,1> <=><id,2><+><id,3><*><60><;> The lexical analyzer is responsible for removing the white spaces and comments from the source program.
  • 19. 15/06/20 DEPARTMENT OF COMPUTER ENGINEERING, Sanjivani COE, Kopargaon THE ROLE OF THE LEXICALANALYZER
  • 20. THE ROLE OF THE LEXICALANALYZER Token: A token is a pair – a token name and an optional token value. A pattern is a description of the form that the lexemes of a token may take. A lexeme is a sequence of characters in the source program that matches the pattern for a token A lexical error occurs when a sequence of characters does not match the pattern of any token.
  • 21. 15/06/20 DEPARTMENT OF COMPUTER ENGINEERING, Sanjivani COE, Kopargaon Attributes for tokens • E = M * C ** 2 – <id, pointer to symbol table entry for E> – <assign‐op> – <id, pointer to symbol table entry for M> – <mult‐op> – <id, pointer to symbol table entry for C> – <exp‐op> – <number, integer value 2>
  • 22. References 1. Alfred V.Aho,Monica S.Lam,Ravi Sethi, Jeffrey D. Ullman, “Compilers- Principles,Techniques and Tools”, Pearson,ISBN:978-81-317-2101-8