SlideShare a Scribd company logo
1 of 19
Interpreter
Group E
Member Names:
Tousif Irshad 2472
Shahid Ashraf 2485
Muhammad Shoaib 2466
Ibrar Shami 2494
Salman Raza 2473
Jawad 2477
Mubashar Younus 2478
Muaz khan 2498
Interpreter
 All programming language instructions must be
expressed in binary code before the computer can
perform them.
 Computer languages can be grouped according to
which translation process is used to convert the
instructions into binary code:
◦ Assemblers
◦ Interpreters
◦ Compilers
Interpreter
Interpreter: An interpreter is a computer
program that directly executes, i.e. performs,
instructions written in a programming or scripting
language or
An interpreter translates high-level instructions into
an intermediate form, which it then executes.
Translates one line of the program into binary code
at a time:
Interpreting can be done in different ways, depending on the
setting, how much time is available, how many languages
are used, and whether or not technology is available.
Interpreter
Interpreted languages have become increasingly popular
due to demands for rapid program development
Interpreter Descriptions:
Categories of interpreter types:
* Three interpreters types of working and
performance.
* General types of Interpreter
Interpreter
Three interpreters types of working and
performance.
• MIPSI (Million instruction in per second)
• Perl
• Tcl (Tool command language)
Interpreter
MIPSI:-
• An instruction-level emulator that executes
• multithreaded processors
• as a teaching tool in architecture and operating
system classes
• initial stages of a CPU the fetch, decode and
execute stages performed
explicitly in software
Interpreter
Perl:-
• Perl is a scripting language designed for
manipulating text, data, files, and
processes. Perl supports a variety of
advanced programming abstractions useful
for string and file processing, including
regular expressions a high-level I/O
interface, automatic memory management,
and associative arrays. Perl programs are
not interpreted directly
Interpreter
TCl:-
• Tcl is an embeddable command language that allows
applications to be customized. Tcl is also used as a
stand-alone programming environment, providing a
programming language interface that includes basic
functionality comparable to that found in Perl,
• One popular extension to Tcl is the Tk toolkit
Interpreter
This table shows the slowdown of each microbenchmark relative to the
equivalent operation implemented in C
Working of Interpreter
 An instruction is fetched from the original source
code.
 The Interpreter checks the single instruction for
errors. (If an error is found, translation and execution
ceases. Otherwise…)
 The instruction is translated into binary code.
 The binary coded instruction is executed.
 The fetch and execute process repeats for the entire
program.
Interpreter
The steps to run a program via an
interpreter:
1. Edit the Program
2. Debug or Run the Program
3. This is a far faster process and it helps novice
programmers edit and test their code quicker than
using a compiler. The disadvantage is that
interpreted programs run much slower than
compiled programs. As much as 5-10 times slower
as every line of code has to be re-read, then
re-processed.
Interpreter
An interpreter generally uses one of the following
Strategies for program execution:
 parse the source code and perform its behavior
directly
 translate source code into some
efficient intermediate representation and
immediately execute this
 explicitly execute stored pr-compiled code made
by a compiler which is part of the interpreter
system
Interpreter types
 There are two main types of
interpretation:
◦ Simultaneous Interpretation
◦ Consecutive Interpretation
Interpreter types
◦ Simultaneous Interpretation
The interpreter sits in a booth, listens to the
speaker in one language through headphones,
and immediately speaks their interpretation into a
microphone in another language.
◦ Interpreters therefore take turns of about
30 minutes.
Interpreter types
◦ Consecutive Interpretation
The interpreter repeats the message after
the speaker has finished.
◦ Used for:
 Small group conferences
 Court cases
◦ Very long speeches may be broken up
into parts
Interpreter
 Computer programs are compiled or interpreted.
Languages like Assembly Language, C, C++,
Fortran, Pascal were almost always compiled into
machine code. Languages like Basic, VbScript and
JavaScript were usually interpreted.
 However, BASIC and LISP are especially
designed to be executed by an interpreter
Interpreter
Example
 Using HTML to create Web Pages
HTML (Hyper Text Markup Language): A computer
language consisting of special codes intended to
design the layout (or markup) of a Web page.
 Web browsers interpret the HTML code and
display the resulting Web pages.
 Web browser: A program that displays
information from the WWW.
 Each line of HTML is called a tag (formatting
instruction).
Difference between Compiler and interpreter

More Related Content

What's hot

Introduction to programming
Introduction to programmingIntroduction to programming
Introduction to programmingNeeru Mittal
 
Language processing activity
Language processing activityLanguage processing activity
Language processing activityDhruv Sabalpara
 
Ch 3 Assembler in System programming
Ch 3 Assembler in System programming Ch 3 Assembler in System programming
Ch 3 Assembler in System programming Bhatt Balkrishna
 
Computer Language Translator
Computer Language TranslatorComputer Language Translator
Computer Language TranslatorRanjeet Kumar
 
Language processors
Language processorsLanguage processors
Language processorseShikshak
 
High level languages representation
High level languages representationHigh level languages representation
High level languages representationgaurav jain
 
Assembly level language
Assembly level languageAssembly level language
Assembly level languagePDFSHARE
 
Lecture 01 introduction to compiler
Lecture 01 introduction to compilerLecture 01 introduction to compiler
Lecture 01 introduction to compilerIffat Anjum
 
EVOLUTION OF SYSTEM
EVOLUTION OF SYSTEM EVOLUTION OF SYSTEM
EVOLUTION OF SYSTEM Sahil Garg
 
Life cycle of a computer program
Life cycle of a computer programLife cycle of a computer program
Life cycle of a computer programAbhay Kumar
 
Single pass assembler
Single pass assemblerSingle pass assembler
Single pass assemblerBansari Shah
 
Basic programming concepts
Basic programming conceptsBasic programming concepts
Basic programming conceptssalmankhan570
 
Linker and Loader Explained
Linker and Loader  ExplainedLinker and Loader  Explained
Linker and Loader ExplainedAdarsh Kr Sinha
 

What's hot (20)

Assembler
AssemblerAssembler
Assembler
 
Introduction to programming
Introduction to programmingIntroduction to programming
Introduction to programming
 
Language processing activity
Language processing activityLanguage processing activity
Language processing activity
 
generation of programming language
generation of programming languagegeneration of programming language
generation of programming language
 
Phases of compiler
Phases of compilerPhases of compiler
Phases of compiler
 
Introduction to Compiler design
Introduction to Compiler design Introduction to Compiler design
Introduction to Compiler design
 
Ch 3 Assembler in System programming
Ch 3 Assembler in System programming Ch 3 Assembler in System programming
Ch 3 Assembler in System programming
 
Computer Language Translator
Computer Language TranslatorComputer Language Translator
Computer Language Translator
 
Language processors
Language processorsLanguage processors
Language processors
 
High level languages representation
High level languages representationHigh level languages representation
High level languages representation
 
Assembly level language
Assembly level languageAssembly level language
Assembly level language
 
Translators(Compiler, Assembler) and interpreter
Translators(Compiler, Assembler) and interpreterTranslators(Compiler, Assembler) and interpreter
Translators(Compiler, Assembler) and interpreter
 
Assembler
AssemblerAssembler
Assembler
 
Lecture 01 introduction to compiler
Lecture 01 introduction to compilerLecture 01 introduction to compiler
Lecture 01 introduction to compiler
 
Phases of Compiler
Phases of CompilerPhases of Compiler
Phases of Compiler
 
EVOLUTION OF SYSTEM
EVOLUTION OF SYSTEM EVOLUTION OF SYSTEM
EVOLUTION OF SYSTEM
 
Life cycle of a computer program
Life cycle of a computer programLife cycle of a computer program
Life cycle of a computer program
 
Single pass assembler
Single pass assemblerSingle pass assembler
Single pass assembler
 
Basic programming concepts
Basic programming conceptsBasic programming concepts
Basic programming concepts
 
Linker and Loader Explained
Linker and Loader  ExplainedLinker and Loader  Explained
Linker and Loader Explained
 

Similar to Interpreter

La 5 Pl Translator
La 5   Pl TranslatorLa 5   Pl Translator
La 5 Pl TranslatorCma Mohd
 
Compiler Construction Lecture One .pptx
Compiler Construction Lecture One  .pptxCompiler Construction Lecture One  .pptx
Compiler Construction Lecture One .pptxانشال عارف
 
Compiler an overview
Compiler  an overviewCompiler  an overview
Compiler an overviewamudha arul
 
Computer assignment for grade 9
Computer assignment for grade  9Computer assignment for grade  9
Computer assignment for grade 9nahomyitbarek
 
Language processing system.pdf
Language processing system.pdfLanguage processing system.pdf
Language processing system.pdfRakibRahman19
 
Programming Languages / Translators
Programming Languages / TranslatorsProgramming Languages / Translators
Programming Languages / TranslatorsProject Student
 
Introduction to Compilers
Introduction to CompilersIntroduction to Compilers
Introduction to CompilersAkhil Kaushik
 
Compiler Design Basics
Compiler Design BasicsCompiler Design Basics
Compiler Design BasicsAkhil Kaushik
 
Programming languages,compiler,interpreter,softwares
Programming languages,compiler,interpreter,softwaresProgramming languages,compiler,interpreter,softwares
Programming languages,compiler,interpreter,softwaresNisarg Amin
 
COMPILER DESIGN OPTIONS
COMPILER DESIGN OPTIONSCOMPILER DESIGN OPTIONS
COMPILER DESIGN OPTIONSsonalikharade3
 
Programming Languages
Programming LanguagesProgramming Languages
Programming LanguagesMohamed Omar
 
Week 08_Basics of Compiler Construction.pdf
Week 08_Basics of Compiler Construction.pdfWeek 08_Basics of Compiler Construction.pdf
Week 08_Basics of Compiler Construction.pdfAnonymousQ3EMYoWNS
 
Lec21&22.pptx programing language and there study
Lec21&22.pptx programing language and there studyLec21&22.pptx programing language and there study
Lec21&22.pptx programing language and there studysamiullahamjad06
 
Introduction_to_Programming.pptx
Introduction_to_Programming.pptxIntroduction_to_Programming.pptx
Introduction_to_Programming.pptxPmarkNorcio
 

Similar to Interpreter (20)

COMPILER DESIGN.docx
COMPILER DESIGN.docxCOMPILER DESIGN.docx
COMPILER DESIGN.docx
 
La 5 Pl Translator
La 5   Pl TranslatorLa 5   Pl Translator
La 5 Pl Translator
 
Compiler Construction Lecture One .pptx
Compiler Construction Lecture One  .pptxCompiler Construction Lecture One  .pptx
Compiler Construction Lecture One .pptx
 
Compiler an overview
Compiler  an overviewCompiler  an overview
Compiler an overview
 
Language processors
Language processorsLanguage processors
Language processors
 
Computer assignment for grade 9
Computer assignment for grade  9Computer assignment for grade  9
Computer assignment for grade 9
 
Language processing system.pdf
Language processing system.pdfLanguage processing system.pdf
Language processing system.pdf
 
compiler vs interpreter
compiler vs interpretercompiler vs interpreter
compiler vs interpreter
 
Programming Languages / Translators
Programming Languages / TranslatorsProgramming Languages / Translators
Programming Languages / Translators
 
Introduction to Compilers
Introduction to CompilersIntroduction to Compilers
Introduction to Compilers
 
C_NOTES.pdf
C_NOTES.pdfC_NOTES.pdf
C_NOTES.pdf
 
Compiler Design Basics
Compiler Design BasicsCompiler Design Basics
Compiler Design Basics
 
Programming languages,compiler,interpreter,softwares
Programming languages,compiler,interpreter,softwaresProgramming languages,compiler,interpreter,softwares
Programming languages,compiler,interpreter,softwares
 
COMPILER DESIGN OPTIONS
COMPILER DESIGN OPTIONSCOMPILER DESIGN OPTIONS
COMPILER DESIGN OPTIONS
 
Cf&oa
Cf&oaCf&oa
Cf&oa
 
Programming Languages
Programming LanguagesProgramming Languages
Programming Languages
 
Week 08_Basics of Compiler Construction.pdf
Week 08_Basics of Compiler Construction.pdfWeek 08_Basics of Compiler Construction.pdf
Week 08_Basics of Compiler Construction.pdf
 
Lec21&22.pptx programing language and there study
Lec21&22.pptx programing language and there studyLec21&22.pptx programing language and there study
Lec21&22.pptx programing language and there study
 
Introduction_to_Programming.pptx
Introduction_to_Programming.pptxIntroduction_to_Programming.pptx
Introduction_to_Programming.pptx
 
Lesson 2.pptx
Lesson 2.pptxLesson 2.pptx
Lesson 2.pptx
 

More from IGZ Software house (20)

Window server 2008
Window server 2008Window server 2008
Window server 2008
 
Types of server
Types of serverTypes of server
Types of server
 
Types of network
Types of networkTypes of network
Types of network
 
Ip address and subnetting
Ip address and subnettingIp address and subnetting
Ip address and subnetting
 
Group policy management window server 2008r2
Group policy management window server 2008r2Group policy management window server 2008r2
Group policy management window server 2008r2
 
FSMO
FSMO FSMO
FSMO
 
Active directory domain services
Active directory domain servicesActive directory domain services
Active directory domain services
 
17 roles of window server 2008 r2
17 roles of window server 2008 r217 roles of window server 2008 r2
17 roles of window server 2008 r2
 
Raid and its levels
Raid and its levelsRaid and its levels
Raid and its levels
 
Introduction Network security
Introduction Network securityIntroduction Network security
Introduction Network security
 
Firewalls
FirewallsFirewalls
Firewalls
 
Encryption
EncryptionEncryption
Encryption
 
Cryptography
CryptographyCryptography
Cryptography
 
Authentication techniques
Authentication techniquesAuthentication techniques
Authentication techniques
 
X86 Architecture
X86 Architecture X86 Architecture
X86 Architecture
 
Window architecture
Window architecture Window architecture
Window architecture
 
What is-32-bit-and-64-bit
What is-32-bit-and-64-bitWhat is-32-bit-and-64-bit
What is-32-bit-and-64-bit
 
Virtual machine
Virtual machineVirtual machine
Virtual machine
 
Compiler
Compiler Compiler
Compiler
 
Competitor analaysis
Competitor analaysisCompetitor analaysis
Competitor analaysis
 

Recently uploaded

MICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxMICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxabhijeetpadhi001
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxthorishapillay1
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfSumit Tiwari
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxAvyJaneVismanos
 
CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxJiesonDelaCerna
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfMr Bounab Samir
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Jisc
 
Pharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfPharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfMahmoud M. Sallam
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxOH TEIK BIN
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Celine George
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxpboyjonauth
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
MARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupMARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupJonathanParaisoCruz
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Educationpboyjonauth
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...JhezDiaz1
 

Recently uploaded (20)

MICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptxMICROBIOLOGY biochemical test detailed.pptx
MICROBIOLOGY biochemical test detailed.pptx
 
Proudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptxProudly South Africa powerpoint Thorisha.pptx
Proudly South Africa powerpoint Thorisha.pptx
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
 
Final demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptxFinal demo Grade 9 for demo Plan dessert.pptx
Final demo Grade 9 for demo Plan dessert.pptx
 
CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptx
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdfLike-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
Like-prefer-love -hate+verb+ing & silent letters & citizenship text.pdf
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...Procuring digital preservation CAN be quick and painless with our new dynamic...
Procuring digital preservation CAN be quick and painless with our new dynamic...
 
Pharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfPharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdf
 
Solving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptxSolving Puzzles Benefits Everyone (English).pptx
Solving Puzzles Benefits Everyone (English).pptx
 
Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17Difference Between Search & Browse Methods in Odoo 17
Difference Between Search & Browse Methods in Odoo 17
 
Introduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptxIntroduction to AI in Higher Education_draft.pptx
Introduction to AI in Higher Education_draft.pptx
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
MARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupMARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized Group
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
Introduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher EducationIntroduction to ArtificiaI Intelligence in Higher Education
Introduction to ArtificiaI Intelligence in Higher Education
 
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
ENGLISH 7_Q4_LESSON 2_ Employing a Variety of Strategies for Effective Interp...
 

Interpreter

  • 2. Group E Member Names: Tousif Irshad 2472 Shahid Ashraf 2485 Muhammad Shoaib 2466 Ibrar Shami 2494 Salman Raza 2473 Jawad 2477 Mubashar Younus 2478 Muaz khan 2498
  • 3. Interpreter  All programming language instructions must be expressed in binary code before the computer can perform them.  Computer languages can be grouped according to which translation process is used to convert the instructions into binary code: ◦ Assemblers ◦ Interpreters ◦ Compilers
  • 4. Interpreter Interpreter: An interpreter is a computer program that directly executes, i.e. performs, instructions written in a programming or scripting language or An interpreter translates high-level instructions into an intermediate form, which it then executes. Translates one line of the program into binary code at a time: Interpreting can be done in different ways, depending on the setting, how much time is available, how many languages are used, and whether or not technology is available.
  • 5. Interpreter Interpreted languages have become increasingly popular due to demands for rapid program development Interpreter Descriptions: Categories of interpreter types: * Three interpreters types of working and performance. * General types of Interpreter
  • 6. Interpreter Three interpreters types of working and performance. • MIPSI (Million instruction in per second) • Perl • Tcl (Tool command language)
  • 7. Interpreter MIPSI:- • An instruction-level emulator that executes • multithreaded processors • as a teaching tool in architecture and operating system classes • initial stages of a CPU the fetch, decode and execute stages performed explicitly in software
  • 8. Interpreter Perl:- • Perl is a scripting language designed for manipulating text, data, files, and processes. Perl supports a variety of advanced programming abstractions useful for string and file processing, including regular expressions a high-level I/O interface, automatic memory management, and associative arrays. Perl programs are not interpreted directly
  • 9. Interpreter TCl:- • Tcl is an embeddable command language that allows applications to be customized. Tcl is also used as a stand-alone programming environment, providing a programming language interface that includes basic functionality comparable to that found in Perl, • One popular extension to Tcl is the Tk toolkit
  • 10. Interpreter This table shows the slowdown of each microbenchmark relative to the equivalent operation implemented in C
  • 11. Working of Interpreter  An instruction is fetched from the original source code.  The Interpreter checks the single instruction for errors. (If an error is found, translation and execution ceases. Otherwise…)  The instruction is translated into binary code.  The binary coded instruction is executed.  The fetch and execute process repeats for the entire program.
  • 12. Interpreter The steps to run a program via an interpreter: 1. Edit the Program 2. Debug or Run the Program 3. This is a far faster process and it helps novice programmers edit and test their code quicker than using a compiler. The disadvantage is that interpreted programs run much slower than compiled programs. As much as 5-10 times slower as every line of code has to be re-read, then re-processed.
  • 13. Interpreter An interpreter generally uses one of the following Strategies for program execution:  parse the source code and perform its behavior directly  translate source code into some efficient intermediate representation and immediately execute this  explicitly execute stored pr-compiled code made by a compiler which is part of the interpreter system
  • 14. Interpreter types  There are two main types of interpretation: ◦ Simultaneous Interpretation ◦ Consecutive Interpretation
  • 15. Interpreter types ◦ Simultaneous Interpretation The interpreter sits in a booth, listens to the speaker in one language through headphones, and immediately speaks their interpretation into a microphone in another language. ◦ Interpreters therefore take turns of about 30 minutes.
  • 16. Interpreter types ◦ Consecutive Interpretation The interpreter repeats the message after the speaker has finished. ◦ Used for:  Small group conferences  Court cases ◦ Very long speeches may be broken up into parts
  • 17. Interpreter  Computer programs are compiled or interpreted. Languages like Assembly Language, C, C++, Fortran, Pascal were almost always compiled into machine code. Languages like Basic, VbScript and JavaScript were usually interpreted.  However, BASIC and LISP are especially designed to be executed by an interpreter
  • 18. Interpreter Example  Using HTML to create Web Pages HTML (Hyper Text Markup Language): A computer language consisting of special codes intended to design the layout (or markup) of a Web page.  Web browsers interpret the HTML code and display the resulting Web pages.  Web browser: A program that displays information from the WWW.  Each line of HTML is called a tag (formatting instruction).
  • 19. Difference between Compiler and interpreter