Virtual Machine (Part I)

Size: px
Start display at page:

Download "Virtual Machine (Part I)"

Transcription

1 Hrvrd University CS Fll 2, Shimon Schocken Virtul Mchine (Prt I) Elements of Computing Systems Virtul Mchine I (Ch. 7) Motivtion clss clss Min Min sttic sttic x; x; function function void void min() min() // // Input Input nd nd multiply multiply 2 2 numers numers vr vr,, ; ; Keyord.redInt( Enter Keyord.redInt( Enter numer ); numer ); Keyord.redInt( Enter Keyord.redInt( Enter numer ); numer ); x x mult(,); mult(,); return; return; // // Multiplies Multiplies two two numers. numers. function function mult( mult( x, x, y) y) vr vr,, ; ; ; ; y; y; while while not( not( ) ) + + x; x; ; ; return return ; ; Ultimte gol: Compile strct progrms o executle code. Compiler M M (LOOP) (LOOP) D;JGT D;JGT MD+M MD+M ;JMP ;JMP ;JMP ;JMP Elements of Computing Systems 2 Virtul Mchine I (Ch. 7)

2 Compiltion models direct compiltion: lnguge lnguge 2 lnguge n 2-tier compiltion: lnguge lnguge 2 lnguge n ermedite lnguge hrdwre pltform hrdwre pltform 2. requires n m trnsltors hrdwre pltform m hrdwre pltform hrdwre pltform 2 requires n + m trnsltors hrdwre pltform m Two-tier compiltion: First compiltion stge depends only on the detils of the source lnguge Second compiltion stge depends only on the detils of the trget lnguge. Elements of Computing Systems 3 Virtul Mchine I (Ch. 7) The Hck/Jck pltform VM implementtion over CISC pltforms The ermedite code: Some lnguge Some compiler VM imp. over RISC pltforms Some Other lnguge Some Other compiler Intermedite code VM emultor Jck lnguge Jck compiler VM imp. over the Hck pltform The erfce etween the 2 compiltion stges Must e sufficiently strct to support mny (high-level lnguge, mchine lnguge) pirs Defines stnd-lone lnguge of n strct mchine Cn e modeled s the lnguge of n strct virtul mchine (VM). CISC mchine lnguge RISC mchine lnguge written in high-level lnguge Hck mchine lnguge CISC mchine RISC mchine other digitl pltforms, ech equipped with its VM implementtion Any computer Hck computer Elements of Computing Systems 4 Virtul Mchine I (Ch. 7)

3 A stck mchine - sed VM Stck push 8 Stck (efore) (fter) Stck pop Stck Mor dt structure Elegnt nd powerful Implementtion options. Elements of Computing Systems Virtul Mchine I (Ch. 7) Stck rithmetic 7 4 dd 7 9 Typicl opertion: Pops two rguments from the stck Adds their vlue Pushes the onto the stck. Impct: the opernds re replced with the opertion s In generl: similr impct for ll rithmetic nd Boolen opertions. Elements of Computing Systems 6 Virtul Mchine I (Ch. 7)

4 Evlution of rithmetic expressions // d(2-x)*(y+) push 2 push x su push y push dd mult pop d x y 9 Stck push 2 2 push x 2 su push y 9 push dd mult -42 pop d Stck x y 9 d -42 Elements of Computing Systems 7 Virtul Mchine I (Ch. 7) Evlution of Boolen expressions // if (x<7) or (y8) push x push 7 lt push y push 8 eq or x 2 y 8 Stck 2 2 push x push 7 lt 7 flse flse flse push y 8 push 8 eq 8 8 flse true or true Elements of Computing Systems 8 Virtul Mchine I (Ch. 7)

5 VM specifiction: dt types Our VM fetures single 6-it dt type tht cn e used s: Integer Boolen Poer Elements of Computing Systems 9 Virtul Mchine I (Ch. 7) VM specifiction: commnds Arithmetic // Boolen commnds dd dd su su neg neg eq eq This lecture gt gt lt lt nd nd or or not not ccess commnds Progrm flow flow commnds lel (declrtion) (declrtion) goto goto (lel) (lel) if-goto (lel) (lel) Next lecture Function clling commnds function (declrtion) (declrtion) cll cll ( ( function) function) return (from (from function) function) pop pop segment i push pushsegment i Elements of Computing Systems Virtul Mchine I (Ch. 7)

6 Arithmetic nd Boolen commnds Elements of Computing Systems Virtul Mchine I (Ch. 7) ccess commnds (So fr, pop/push commnds cted on glol memory. This ws conceptul simplifiction ) segments rgument: stores the current function s rguments locl: stores the function s locl vriles sttic: stores glol vriles, shred y ll functions in the sme.vm file constnt: pseudo segment holding ll the constnts in the rnge this, tht: generl-purpose segments; cn e mde to correspond to different res in the hep poer: used to lign this nd tht temp: fixed 8-entry segment tht holds temporry vriles for generl use; Shred y ll VM functions in the progrm. ccess commnds formt: pop pop memorysegment i push push memorysegment i Elements of Computing Systems 2 Virtul Mchine I (Ch. 7)

7 Motivtion VM progrmming exmples: Arithmetic tsk Arry hndling tsk Oect hndling tsk (These exmple don t elong to this lecture, nd re given here for motivtion only.) Elements of Computing Systems 3 Virtul Mchine I (Ch. 7) Arithmetic exmple High-level code function function mult(x,y) mult(x,y),, ; ; ; ; y; y; while while ~() ~() +x; -; -; return return ; ; Just fter mult(7,3) is entered: Stck rgument locl 7 Just fter mult(7,3) returns: Stck 2 3 x y sum Pseudo VM code function function mult(x,y) mult(x,y) push push pop pop push push y pop pop lel lel loop loop push push push push eq eq if-goto if-goto end end push push push push x dd dd pop pop push push push push su su pop pop goto goto loop loop lel lel end end push push return return VM code function function mult mult 2 push push constnt constnt pop pop locl locl push push rgument rgument pop pop locl locl lel lel loop loop push push locl locl push push constnt constnt eq eq if-goto if-goto end end push push locl locl push push rgument rgument dd dd pop pop locl locl push push locl locl push push constnt constnt su su pop pop locl locl goto goto loop loop lel lel end end push push locl locl return return Elements of Computing Systems 4 Virtul Mchine I (Ch. 7)

8 Arry hndling exmple r rry High-level progrm view RAM view 7 3 following r compiltion (Actul RAM loctions of progrm vriles re run-time dependent, nd thus the ddresses shown here re ritrry exmples.) r rry /* /* Assume Assume tht tht r r is is the the first first locl locl vrile vrile declred declred in in the the high-level progrm. progrm. The The code code elow elow implements r[2]9, or or *(r+2)9. */ */ // // Get Get r's r's se se ddress: ddress: push push locl locl push push constnt constnt 2 dd dd // // Set Set tht s tht s se se to to (r+2): (r+2): pop pop poer poer push push constnt constnt 9 9 // // *(r+2)9: pop pop tht tht Virtul memory segments Just efore the r[2]9 opertion: Virtul memory segments Just fter the r[2]9 opertion: locl poer tht locl poer tht (tht is now lligned with RAM[437]) Elements of Computing Systems Virtul Mchine I (Ch. 7) Oect hndling exmple oect High level progrm view x: y: rdius: color: following compiltion (Actul RAM loctions of progrm vriles re run-time dependent, nd thus the ddresses shown here re ritrry exmples.) RAM view oect /* /* Assume Assume tht tht nd nd r were were pssed pssed to to the the function function s s its its first first two two rguments. The The following following code code implements the the opertion opertion.rdiusr. */ */ // // Get Get 's 's se se ddress: ddress: push push rgument rgument // // Po Po the the this this seg. seg. to to : : pop pop poer poer // // Get Get r's r's vlue vlue push push rgument rgument // // Set Set 's 's third third field field to to r: r: pop pop this this 2 Virtul memory segments ust efore the opertion.rdius7: rgument poer this 32 7 Virtul memory segments ust fter the opertion.rdius7: rgument poer this (this is now lligned with RAM[32]) Elements of Computing Systems 6 Virtul Mchine I (Ch. 7)

9 The VM lnguge summry Arithmetic / Boolen commnds (dd, su, eq, ) commnds (pop, push) Progrm flow commnds (lel, goto, if-goto) Function clling commnds (function, cll, return) This lecture Next lecture VM implementtion options: Softwre-sed (emultion) Hrdwre-sed (e.g. Hck) Fmous VM implementtions: JRE (runs ytecode) CLR (runs IL progrms) Elements of Computing Systems 7 Virtul Mchine I (Ch. 7) VM implementtion on the Hck pltform TEMP LCL ARG THIS THAT locl,rgument,this,tht: mpped directly on the host RAM. The se ddresses of these segments re kept in the registers lcl,arg,this,that. Access to the i-th entry of segment s in ccessing the (se + i) word in the RAM 3 Generl purpose 4 6 Sttics sttic: sttic vrile numer in VM file f is represented s the ssemly lnguge symol f Stck constnt: truly virtul segment. Access to constnt i s in supplying the constnt i 248 Hep poer,temp: see the ook. Elements of Computing Systems 8 Virtul Mchine I (Ch. 7)

10 Prser module (proposed design) Prser: Hndles the prsing of single.vm file, nd encpsultes ccess to the input code. It reds VM commnds, prses them, nd provides convenient ccess to their components. In ddition, it removes ll white spce nd comments. Routine Constructor Arguments Input file / strem Returns Function Opens the input file/strem nd gets redy to prse it. hsmorecommnds oolen Are there more commnds in the input? dvnce Reds the next commnd from the input nd mkes it the current commnd. Should e clled only if hsmorecommnds() is true. Initilly there is no current commnd. commndtype C_ARITHMETIC, C_PUSH, C_POP, C_LABEL, C_GOTO, C_IF, C_FUNCTION, C_RETURN, C_CALL Returns the type of the current VM commnd. C_ARITHMETIC is returned for ll the rithmetic commnds. rg string Returns the first rgument of the current commnd. In the cse of C_ARITHMETIC, the commnd itself (dd, su, etc.) is returned. Should not e clled if the current commnd is C_RETURN. rg2 Returns the second rgument of the current commnd. Should e clled only if the current commnd is C_PUSH, C_POP, C_FUNCTION, or C_CALL. Elements of Computing Systems 9 Virtul Mchine I (Ch. 7) CodeWriter module (proposed design) CodeWriter: Trnsltes VM commnds o Hck ssemly code. Routine Arguments Returns Function Constructor Output file / strem Opens the output file/strem nd gets redy to write o it. setfilenme filenme (string) Informs the code writer tht the trnsltion of new VM file is strted. writearithmetic commnd (string) Writes the ssemly code tht is the trnsltion of the given rithmetic commnd. WritePushPop Commnd (C_PUSH or C_POP), segment (string), Writes the ssemly code tht is the trnsltion of the given commnd, where commnd is either C_PUSH or C_POP. index () Close Closes the output file. Comment: More routines will e dded to this module in chpter 8. Elements of Computing Systems 2 Virtul Mchine I (Ch. 7)

11 The VM emultor Elements of Computing Systems 2 Virtul Mchine I (Ch. 7)

Virtual Machine I: Stack Arithmetic

Virtual Machine I: Stack Arithmetic Virtul Mchine I: Stck Arithmetic Building Modern Computer From First Principles www.nnd2tetris.org Elements of Computing Systems, Nisn & Schocken, MIT Press, www.nnd2tetris.org, Chpter 7: Virtul Mchine

More information

Virtual Machine. Part I: Stack Arithmetic. Building a Modern Computer From First Principles.

Virtual Machine. Part I: Stack Arithmetic. Building a Modern Computer From First Principles. Virtual Machine Part I: Stack Arithmetic Building a Modern Computer From First Principles www.nand2tetris.org Elements of Computing Systems, Nisan & Schocken, MIT Press, www.nand2tetris.org, Chapter 7:

More information

Outline CS 412/413. Function calls. Stack layout. Tiling a call. Two translations

Outline CS 412/413. Function calls. Stack layout. Tiling a call. Two translations CS 412/413 Introduction to Compilers nd Trnsltors Cornell University Andrew Myers Outline Implementing function clls Implementing functions Optimizing wy the pointer Dynmiclly-llocted structures strings

More information

Stack Manipulation. Other Issues. How about larger constants? Frame Pointer. PowerPC. Alternative Architectures

Stack Manipulation. Other Issues. How about larger constants? Frame Pointer. PowerPC. Alternative Architectures Other Issues Stck Mnipultion support for procedures (Refer to section 3.6), stcks, frmes, recursion mnipulting strings nd pointers linkers, loders, memory lyout Interrupts, exceptions, system clls nd conventions

More information

Sample Midterm Solutions COMS W4115 Programming Languages and Translators Monday, October 12, 2009

Sample Midterm Solutions COMS W4115 Programming Languages and Translators Monday, October 12, 2009 Deprtment of Computer cience Columbi University mple Midterm olutions COM W4115 Progrmming Lnguges nd Trnsltors Mondy, October 12, 2009 Closed book, no ids. ch question is worth 20 points. Question 5(c)

More information

Outline. Tiling, formally. Expression tile as rule. Statement tiles as rules. Function calls. CS 412 Introduction to Compilers

Outline. Tiling, formally. Expression tile as rule. Statement tiles as rules. Function calls. CS 412 Introduction to Compilers CS 412 Introduction to Compilers Andrew Myers Cornell University Lectur8 Finishing genertion 9 Mr 01 Outline Tiling s syntx-directed trnsltion Implementing function clls Implementing functions Optimizing

More information

From Dependencies to Evaluation Strategies

From Dependencies to Evaluation Strategies From Dependencies to Evlution Strtegies Possile strtegies: 1 let the user define the evlution order 2 utomtic strtegy sed on the dependencies: use locl dependencies to determine which ttriutes to compute

More information

cisc1110 fall 2010 lecture VI.2 call by value function parameters another call by value example:

cisc1110 fall 2010 lecture VI.2 call by value function parameters another call by value example: cisc1110 fll 2010 lecture VI.2 cll y vlue function prmeters more on functions more on cll y vlue nd cll y reference pssing strings to functions returning strings from functions vrile scope glol vriles

More information

CS321 Languages and Compiler Design I. Winter 2012 Lecture 5

CS321 Languages and Compiler Design I. Winter 2012 Lecture 5 CS321 Lnguges nd Compiler Design I Winter 2012 Lecture 5 1 FINITE AUTOMATA A non-deterministic finite utomton (NFA) consists of: An input lphet Σ, e.g. Σ =,. A set of sttes S, e.g. S = {1, 3, 5, 7, 11,

More information

Scope, Functions, and Storage Management

Scope, Functions, and Storage Management Scope, Functions, nd Storge Mngement Block-structured lnguges nd stck storge In-le Blocks (previous set of overheds) ctivtion records storge for locl, glol vriles First-order functions (previous set of

More information

CSc 453. Compilers and Systems Software. 4 : Lexical Analysis II. Department of Computer Science University of Arizona

CSc 453. Compilers and Systems Software. 4 : Lexical Analysis II. Department of Computer Science University of Arizona CSc 453 Compilers nd Systems Softwre 4 : Lexicl Anlysis II Deprtment of Computer Science University of Arizon collerg@gmil.com Copyright c 2009 Christin Collerg Implementing Automt NFAs nd DFAs cn e hrd-coded

More information

Implementing Automata. CSc 453. Compilers and Systems Software. 4 : Lexical Analysis II. Department of Computer Science University of Arizona

Implementing Automata. CSc 453. Compilers and Systems Software. 4 : Lexical Analysis II. Department of Computer Science University of Arizona Implementing utomt Sc 5 ompilers nd Systems Softwre : Lexicl nlysis II Deprtment of omputer Science University of rizon collerg@gmil.com opyright c 009 hristin ollerg NFs nd DFs cn e hrd-coded using this

More information

box Boxes and Arrows 3 true 7.59 'X' An object is drawn as a box that contains its data members, for example:

box Boxes and Arrows 3 true 7.59 'X' An object is drawn as a box that contains its data members, for example: Boxes nd Arrows There re two kinds of vriles in Jv: those tht store primitive vlues nd those tht store references. Primitive vlues re vlues of type long, int, short, chr, yte, oolen, doule, nd flot. References

More information

Systems I. Logic Design I. Topics Digital logic Logic gates Simple combinational logic circuits

Systems I. Logic Design I. Topics Digital logic Logic gates Simple combinational logic circuits Systems I Logic Design I Topics Digitl logic Logic gtes Simple comintionl logic circuits Simple C sttement.. C = + ; Wht pieces of hrdwre do you think you might need? Storge - for vlues,, C Computtion

More information

Basics of Logic Design Arithmetic Logic Unit (ALU)

Basics of Logic Design Arithmetic Logic Unit (ALU) Bsics of Logic Design Arithmetic Logic Unit (ALU) CPS 4 Lecture 9 Tody s Lecture Homework #3 Assigned Due Mrch 3 Project Groups ssigned & posted to lckord. Project Specifiction is on We Due April 9 Building

More information

CS201 Discussion 10 DRAWTREE + TRIES

CS201 Discussion 10 DRAWTREE + TRIES CS201 Discussion 10 DRAWTREE + TRIES DrwTree First instinct: recursion As very generic structure, we could tckle this problem s follows: drw(): Find the root drw(root) drw(root): Write the line for the

More information

CS 430 Spring Mike Lam, Professor. Parsing

CS 430 Spring Mike Lam, Professor. Parsing CS 430 Spring 2015 Mike Lm, Professor Prsing Syntx Anlysis We cn now formlly descrie lnguge's syntx Using regulr expressions nd BNF grmmrs How does tht help us? Syntx Anlysis We cn now formlly descrie

More information

Pointers and Arrays. More Pointer Examples. Pointers CS 217

Pointers and Arrays. More Pointer Examples. Pointers CS 217 Pointers nd Arrs CS 21 1 2 Pointers More Pointer Emples Wht is pointer A vrile whose vlue is the ddress of nother vrile p is pointer to vrile v Opertions &: ddress of (reference) *: indirection (dereference)

More information

Agenda & Reading. Class Exercise. COMPSCI 105 SS 2012 Principles of Computer Science. Arrays

Agenda & Reading. Class Exercise. COMPSCI 105 SS 2012 Principles of Computer Science. Arrays COMPSCI 5 SS Principles of Computer Science Arrys & Multidimensionl Arrys Agend & Reding Agend Arrys Creting & Using Primitive & Reference Types Assignments & Equlity Pss y Vlue & Pss y Reference Copying

More information

Today s Lecture. Basics of Logic Design: Boolean Algebra, Logic Gates. Recursive Example. Review: The C / C++ code. Recursive Example (Continued)

Today s Lecture. Basics of Logic Design: Boolean Algebra, Logic Gates. Recursive Example. Review: The C / C++ code. Recursive Example (Continued) Tod s Lecture Bsics of Logic Design: Boolen Alger, Logic Gtes Alvin R. Leeck CPS 4 Lecture 8 Homework #2 Due Ferur 3 Outline Review (sseml recursion) Building the uilding locks Logic Design Truth tles,

More information

George Boole. IT 3123 Hardware and Software Concepts. Switching Algebra. Boolean Functions. Boolean Functions. Truth Tables

George Boole. IT 3123 Hardware and Software Concepts. Switching Algebra. Boolean Functions. Boolean Functions. Truth Tables George Boole IT 3123 Hrdwre nd Softwre Concepts My 28 Digitl Logic The Little Mn Computer 1815 1864 British mthemticin nd philosopher Mny contriutions to mthemtics. Boolen lger: n lger over finite sets

More information

Introduction To Files In Pascal

Introduction To Files In Pascal Why other With Files? Introduction To Files In Pscl Too much informtion to input ll t once The informtion must be persistent (RAM is voltile) Etc. In this section of notes you will lern how to red from

More information

Lexical Analysis. Amitabha Sanyal. (www.cse.iitb.ac.in/ as) Department of Computer Science and Engineering, Indian Institute of Technology, Bombay

Lexical Analysis. Amitabha Sanyal. (www.cse.iitb.ac.in/ as) Department of Computer Science and Engineering, Indian Institute of Technology, Bombay Lexicl Anlysis Amith Snyl (www.cse.iit.c.in/ s) Deprtment of Computer Science nd Engineering, Indin Institute of Technology, Bomy Septemer 27 College of Engineering, Pune Lexicl Anlysis: 2/6 Recp The input

More information

Some Thoughts on Grad School. Undergraduate Compilers Review and Intro to MJC. Structure of a Typical Compiler. Lexing and Parsing

Some Thoughts on Grad School. Undergraduate Compilers Review and Intro to MJC. Structure of a Typical Compiler. Lexing and Parsing Undergrdute Compilers Review nd Intro to MJC Announcements Miling list is in full swing Tody Some thoughts on grd school Finish prsing Semntic nlysis Visitor pttern for bstrct syntx trees Some Thoughts

More information

Should be done. Do Soon. Structure of a Typical Compiler. Plan for Today. Lab hours and Office hours. Quiz 1 is due tonight, was posted Tuesday night

Should be done. Do Soon. Structure of a Typical Compiler. Plan for Today. Lab hours and Office hours. Quiz 1 is due tonight, was posted Tuesday night Should e done L hours nd Office hours Sign up for the miling list t, strting to send importnt info to list http://groups.google.com/group/cs453-spring-2011 Red Ch 1 nd skim Ch 2 through 2.6, red 3.3 nd

More information

Virtual Machine Where we are at: Part I: Stack Arithmetic. Motivation. Compilation models. direct compilation:... 2-tier compilation:

Virtual Machine Where we are at: Part I: Stack Arithmetic. Motivation. Compilation models. direct compilation:... 2-tier compilation: Where we are at: Virtual Machine Part I: Stack Arithmetic Human Thought Abstract design Chapters 9, 12 H.L. Language & Operating Sys. Compiler Chapters 10-11 Virtual Machine Software hierarchy Translator

More information

CMPSC 470: Compiler Construction

CMPSC 470: Compiler Construction CMPSC 47: Compiler Construction Plese complete the following: Midterm (Type A) Nme Instruction: Mke sure you hve ll pges including this cover nd lnk pge t the end. Answer ech question in the spce provided.

More information

Symbol Table management

Symbol Table management TDDD Compilers nd interpreters TDDB44 Compiler Construction Symol Tles Symol Tles in the Compiler Symol Tle mngement source progrm Leicl nlysis Syntctic nlysis Semntic nlysis nd Intermedite code gen Code

More information

CSE 401 Midterm Exam 11/5/10 Sample Solution

CSE 401 Midterm Exam 11/5/10 Sample Solution Question 1. egulr expressions (20 points) In the Ad Progrmming lnguge n integer constnt contins one or more digits, but it my lso contin embedded underscores. Any underscores must be preceded nd followed

More information

ΕΠΛ323 - Θεωρία και Πρακτική Μεταγλωττιστών

ΕΠΛ323 - Θεωρία και Πρακτική Μεταγλωττιστών ΕΠΛ323 - Θωρία και Πρακτική Μταγλωττιστών Lecture 3 Lexicl Anlysis Elis Athnsopoulos elisthn@cs.ucy.c.cy Recognition of Tokens if expressions nd reltionl opertors if è if then è then else è else relop

More information

Fig.25: the Role of LEX

Fig.25: the Role of LEX The Lnguge for Specifying Lexicl Anlyzer We shll now study how to uild lexicl nlyzer from specifiction of tokens in the form of list of regulr expressions The discussion centers round the design of n existing

More information

CPSC 213. Polymorphism. Introduction to Computer Systems. Readings for Next Two Lectures. Back to Procedure Calls

CPSC 213. Polymorphism. Introduction to Computer Systems. Readings for Next Two Lectures. Back to Procedure Calls Redings for Next Two Lectures Text CPSC 213 Switch Sttements, Understnding Pointers - 2nd ed: 3.6.7, 3.10-1st ed: 3.6.6, 3.11 Introduction to Computer Systems Unit 1f Dynmic Control Flow Polymorphism nd

More information

Compiler Construction D7011E

Compiler Construction D7011E Compiler Construction D7011E Lecture 3: Lexer genertors Viktor Leijon Slides lrgely y John Nordlnder with mteril generously provided y Mrk P. Jones. 1 Recp: Hndwritten Lexers: Don t require sophisticted

More information

Stack. A list whose end points are pointed by top and bottom

Stack. A list whose end points are pointed by top and bottom 4. Stck Stck A list whose end points re pointed by top nd bottom Insertion nd deletion tke plce t the top (cf: Wht is the difference between Stck nd Arry?) Bottom is constnt, but top grows nd shrinks!

More information

Topic 2: Lexing and Flexing

Topic 2: Lexing and Flexing Topic 2: Lexing nd Flexing COS 320 Compiling Techniques Princeton University Spring 2016 Lennrt Beringer 1 2 The Compiler Lexicl Anlysis Gol: rek strem of ASCII chrcters (source/input) into sequence of

More information

Languages. L((a (b)(c))*) = { ε,a,bc,aa,abc,bca,... } εw = wε = w. εabba = abbaε = abba. (a (b)(c)) *

Languages. L((a (b)(c))*) = { ε,a,bc,aa,abc,bca,... } εw = wε = w. εabba = abbaε = abba. (a (b)(c)) * Pln for Tody nd Beginning Next week Interpreter nd Compiler Structure, or Softwre Architecture Overview of Progrmming Assignments The MeggyJv compiler we will e uilding. Regulr Expressions Finite Stte

More information

COMP 423 lecture 11 Jan. 28, 2008

COMP 423 lecture 11 Jan. 28, 2008 COMP 423 lecture 11 Jn. 28, 2008 Up to now, we hve looked t how some symols in n lphet occur more frequently thn others nd how we cn sve its y using code such tht the codewords for more frequently occuring

More information

Functor (1A) Young Won Lim 10/5/17

Functor (1A) Young Won Lim 10/5/17 Copyright (c) 2016-2017 Young W. Lim. Permission is grnted to copy, distribute nd/or modify this document under the terms of the GNU Free Documenttion License, Version 1.2 or ny lter version published

More information

Lexical analysis, scanners. Construction of a scanner

Lexical analysis, scanners. Construction of a scanner Lexicl nlysis scnners (NB. Pges 4-5 re for those who need to refresh their knowledge of DFAs nd NFAs. These re not presented during the lectures) Construction of scnner Tools: stte utomt nd trnsition digrms.

More information

MIPS I/O and Interrupt

MIPS I/O and Interrupt MIPS I/O nd Interrupt Review Floting point instructions re crried out on seprte chip clled coprocessor 1 You hve to move dt to/from coprocessor 1 to do most common opertions such s printing, clling functions,

More information

CS 241. Fall 2017 Midterm Review Solutions. October 24, Bits and Bytes 1. 3 MIPS Assembler 6. 4 Regular Languages 7.

CS 241. Fall 2017 Midterm Review Solutions. October 24, Bits and Bytes 1. 3 MIPS Assembler 6. 4 Regular Languages 7. CS 241 Fll 2017 Midterm Review Solutions Octoer 24, 2017 Contents 1 Bits nd Bytes 1 2 MIPS Assemly Lnguge Progrmming 2 3 MIPS Assemler 6 4 Regulr Lnguges 7 5 Scnning 9 1 Bits nd Bytes 1. Give two s complement

More information

Functor (1A) Young Won Lim 8/2/17

Functor (1A) Young Won Lim 8/2/17 Copyright (c) 2016-2017 Young W. Lim. Permission is grnted to copy, distribute nd/or modify this document under the terms of the GNU Free Documenttion License, Version 1.2 or ny lter version published

More information

CSCI 3130: Formal Languages and Automata Theory Lecture 12 The Chinese University of Hong Kong, Fall 2011

CSCI 3130: Formal Languages and Automata Theory Lecture 12 The Chinese University of Hong Kong, Fall 2011 CSCI 3130: Forml Lnguges nd utomt Theory Lecture 12 The Chinese University of Hong Kong, Fll 2011 ndrej Bogdnov In progrmming lnguges, uilding prse trees is significnt tsk ecuse prse trees tell us the

More information

6/23/2011. Review: IEEE-754. CSE 2021: Computer Organization. Exercises. Examples. Shakil M. Khan (adapted from Profs. Roumani & Asif)

6/23/2011. Review: IEEE-754. CSE 2021: Computer Organization. Exercises. Examples. Shakil M. Khan (adapted from Profs. Roumani & Asif) 6/23/2 CSE 22: Computer Orgniztion Lecture-8() Floting point computing (IEEE 754) Review: IEEE-754 single: 8 its doule: its single: 23 its doule: 52 its S Exponent Frction S x ( ) ( Frction) 2 (Exponent

More information

ASTs, Regex, Parsing, and Pretty Printing

ASTs, Regex, Parsing, and Pretty Printing ASTs, Regex, Prsing, nd Pretty Printing CS 2112 Fll 2016 1 Algeric Expressions To strt, consider integer rithmetic. Suppose we hve the following 1. The lphet we will use is the digits {0, 1, 2, 3, 4, 5,

More information

Discussion 1 Recap. COP4600 Discussion 2 OS concepts, System call, and Assignment 1. Questions. Questions. Outline. Outline 10/24/2010

Discussion 1 Recap. COP4600 Discussion 2 OS concepts, System call, and Assignment 1. Questions. Questions. Outline. Outline 10/24/2010 COP4600 Discussion 2 OS concepts, System cll, nd Assignment 1 TA: Hufeng Jin hj0@cise.ufl.edu Discussion 1 Recp Introduction to C C Bsic Types (chr, int, long, flot, doule, ) C Preprocessors (#include,

More information

Presentation Martin Randers

Presentation Martin Randers Presenttion Mrtin Rnders Outline Introduction Algorithms Implementtion nd experiments Memory consumption Summry Introduction Introduction Evolution of species cn e modelled in trees Trees consist of nodes

More information

Engineer To Engineer Note

Engineer To Engineer Note Engineer To Engineer Note EE-188 Technicl Notes on using Anlog Devices' DSP components nd development tools Contct our technicl support by phone: (800) ANALOG-D or e-mil: dsp.support@nlog.com Or visit

More information

Lexical Analysis: Constructing a Scanner from Regular Expressions

Lexical Analysis: Constructing a Scanner from Regular Expressions Lexicl Anlysis: Constructing Scnner from Regulr Expressions Gol Show how to construct FA to recognize ny RE This Lecture Convert RE to n nondeterministic finite utomton (NFA) Use Thompson s construction

More information

Introduction to Computer Science, Shimon Schocken, IDC Herzliya. Lecture Writing Classes

Introduction to Computer Science, Shimon Schocken, IDC Herzliya. Lecture Writing Classes Introduction to Computer Science, Shimon Schocken, IDC Herzliy Lecture 5.1-5.2 Writing Clsses Writing Clsses, Shimon Schocken IDC Herzliy, www.ro2cs.com slide 1 Clsses Two viewpos on es: Client view: how

More information

Geometric transformations

Geometric transformations Geometric trnsformtions Computer Grphics Some slides re bsed on Shy Shlom slides from TAU mn n n m m T A,,,,,, 2 1 2 22 12 1 21 11 Rows become columns nd columns become rows nm n n m m A,,,,,, 1 1 2 22

More information

Reducing a DFA to a Minimal DFA

Reducing a DFA to a Minimal DFA Lexicl Anlysis - Prt 4 Reducing DFA to Miniml DFA Input: DFA IN Assume DFA IN never gets stuck (dd ded stte if necessry) Output: DFA MIN An equivlent DFA with the minimum numer of sttes. Hrry H. Porter,

More information

LR Parsing, Part 2. Constructing Parse Tables. Need to Automatically Construct LR Parse Tables: Action and GOTO Table

LR Parsing, Part 2. Constructing Parse Tables. Need to Automatically Construct LR Parse Tables: Action and GOTO Table TDDD55 Compilers nd Interpreters TDDB44 Compiler Construction LR Prsing, Prt 2 Constructing Prse Tles Prse tle construction Grmmr conflict hndling Ctegories of LR Grmmrs nd Prsers Peter Fritzson, Christoph

More information

Data Flow on a Queue Machine. Bruno R. Preiss. Copyright (c) 1987 by Bruno R. Preiss, P.Eng. All rights reserved.

Data Flow on a Queue Machine. Bruno R. Preiss. Copyright (c) 1987 by Bruno R. Preiss, P.Eng. All rights reserved. Dt Flow on Queue Mchine Bruno R. Preiss 2 Outline Genesis of dt-flow rchitectures Sttic vs. dynmic dt-flow rchitectures Pseudo-sttic dt-flow execution model Some dt-flow mchines Simple queue mchine Prioritized

More information

CS 340, Fall 2014 Dec 11 th /13 th Final Exam Note: in all questions, the special symbol ɛ (epsilon) is used to indicate the empty string.

CS 340, Fall 2014 Dec 11 th /13 th Final Exam Note: in all questions, the special symbol ɛ (epsilon) is used to indicate the empty string. CS 340, Fll 2014 Dec 11 th /13 th Finl Exm Nme: Note: in ll questions, the specil symol ɛ (epsilon) is used to indicte the empty string. Question 1. [5 points] Consider the following regulr expression;

More information

Lecture Overview. Knowledge-based systems in Bioinformatics, 1MB602. Procedural abstraction. The sum procedure. Integration as a procedure

Lecture Overview. Knowledge-based systems in Bioinformatics, 1MB602. Procedural abstraction. The sum procedure. Integration as a procedure Lecture Overview Knowledge-bsed systems in Bioinformtics, MB6 Scheme lecture Procedurl bstrction Higher order procedures Procedures s rguments Procedures s returned vlues Locl vribles Dt bstrction Compound

More information

Chapter 8: Virtual Machine II: Program Control

Chapter 8: Virtual Machine II: Program Control Elements of Computing Systems, Nisan & Schocken, MIT Press, 2005 Chapter 8: Virtual Machine II: Program Control www.idc.ac.il/tecs Usage and Copyright Notice: Copyright 2005 Noam Nisan and Shimon Schocken

More information

CS 314 Principles of Programming Languages

CS 314 Principles of Programming Languages CS 314 Principles of Progrmming Lnguges Lecure 10: Synx Direced Trnslion Zheng (Eddy) Zhng Rugers Universiy Februry 19, 2018 Clss Informion Homework 2 is sill being grded. Projec 1 nd homework 4 will be

More information

CMSC 331 First Midterm Exam

CMSC 331 First Midterm Exam 0 00/ 1 20/ 2 05/ 3 15/ 4 15/ 5 15/ 6 20/ 7 30/ 8 30/ 150/ 331 First Midterm Exm 7 October 2003 CMC 331 First Midterm Exm Nme: mple Answers tudent ID#: You will hve seventy-five (75) minutes to complete

More information

Engineer To Engineer Note

Engineer To Engineer Note Engineer To Engineer Note EE-186 Technicl Notes on using Anlog Devices' DSP components nd development tools Contct our technicl support by phone: (800) ANALOG-D or e-mil: dsp.support@nlog.com Or visit

More information

Computer Arithmetic Logical, Integer Addition & Subtraction Chapter

Computer Arithmetic Logical, Integer Addition & Subtraction Chapter Computer Arithmetic Logicl, Integer Addition & Sutrction Chpter 3.-3.3 3.3 EEC7 FQ 25 MIPS Integer Representtion -it signed integers,, e.g., for numeric opertions 2 s s complement: one representtion for

More information

ΕΠΛ323 - Θεωρία και Πρακτική Μεταγλωττιστών. Lecture 3b Lexical Analysis Elias Athanasopoulos

ΕΠΛ323 - Θεωρία και Πρακτική Μεταγλωττιστών. Lecture 3b Lexical Analysis Elias Athanasopoulos ΕΠΛ323 - Θωρία και Πρακτική Μταγλωττιστών Lecture 3 Lexicl Anlysis Elis Athnsopoulos elisthn@cs.ucy.c.cy RecogniNon of Tokens if expressions nd relnonl opertors if è if then è then else è else relop è

More information

Slides for Data Mining by I. H. Witten and E. Frank

Slides for Data Mining by I. H. Witten and E. Frank Slides for Dt Mining y I. H. Witten nd E. Frnk Simplicity first Simple lgorithms often work very well! There re mny kinds of simple structure, eg: One ttriute does ll the work All ttriutes contriute eqully

More information

Mid-term exam. Scores. Fall term 2012 KAIST EE209 Programming Structures for EE. Thursday Oct 25, Student's name: Student ID:

Mid-term exam. Scores. Fall term 2012 KAIST EE209 Programming Structures for EE. Thursday Oct 25, Student's name: Student ID: Fll term 2012 KAIST EE209 Progrmming Structures for EE Mid-term exm Thursdy Oct 25, 2012 Student's nme: Student ID: The exm is closed book nd notes. Red the questions crefully nd focus your nswers on wht

More information

Motivation. Compiler. Our ultimate goal: Hack code. Jack code (example) Translate high-level programs into executable code. return; } } return

Motivation. Compiler. Our ultimate goal: Hack code. Jack code (example) Translate high-level programs into executable code. return; } } return Motivation Jack code (example) class class Main Main { { static static int int x; x; function function void void main() main() { { Inputs Inputs and and multiplies multiplies two two numbers numbers var

More information

12 <= rm <digit> 2 <= rm <no> 2 <= rm <no> <digit> <= rm <no> <= rm <number>

12 <= rm <digit> 2 <= rm <no> 2 <= rm <no> <digit> <= rm <no> <= rm <number> DDD16 Compilers nd Interpreters DDB44 Compiler Construction R Prsing Prt 1 R prsing concept Using prser genertor Prse ree Genertion Wht is R-prsing? eft-to-right scnning R Rigthmost derivtion in reverse

More information

Quiz2 45mins. Personal Number: Problem 1. (20pts) Here is an Table of Perl Regular Ex

Quiz2 45mins. Personal Number: Problem 1. (20pts) Here is an Table of Perl Regular Ex Long Quiz2 45mins Nme: Personl Numer: Prolem. (20pts) Here is n Tle of Perl Regulr Ex Chrcter Description. single chrcter \s whitespce chrcter (spce, t, newline) \S non-whitespce chrcter \d digit (0-9)

More information

CIS 1068 Program Design and Abstraction Spring2015 Midterm Exam 1. Name SOLUTION

CIS 1068 Program Design and Abstraction Spring2015 Midterm Exam 1. Name SOLUTION CIS 1068 Progrm Design nd Astrction Spring2015 Midterm Exm 1 Nme SOLUTION Pge Points Score 2 15 3 8 4 18 5 10 6 7 7 7 8 14 9 11 10 10 Totl 100 1 P ge 1. Progrm Trces (41 points, 50 minutes) Answer the

More information

CS412/413. Introduction to Compilers Tim Teitelbaum. Lecture 4: Lexical Analyzers 28 Jan 08

CS412/413. Introduction to Compilers Tim Teitelbaum. Lecture 4: Lexical Analyzers 28 Jan 08 CS412/413 Introduction to Compilers Tim Teitelum Lecture 4: Lexicl Anlyzers 28 Jn 08 Outline DFA stte minimiztion Lexicl nlyzers Automting lexicl nlysis Jlex lexicl nlyzer genertor CS 412/413 Spring 2008

More information

Tries. Yufei Tao KAIST. April 9, Y. Tao, April 9, 2013 Tries

Tries. Yufei Tao KAIST. April 9, Y. Tao, April 9, 2013 Tries Tries Yufei To KAIST April 9, 2013 Y. To, April 9, 2013 Tries In this lecture, we will discuss the following exct mtching prolem on strings. Prolem Let S e set of strings, ech of which hs unique integer

More information

Memory Management Functions

Memory Management Functions Meory Mngeent Functions Chpter 9 Meory Mngeent Process of binding vlues to eory loctions Vlues y be sttic or dynic Vlues re ssigned t different plces Sttic eory Run-tie stck Hep 1 Meory Mngeent Sttic Meory

More information

EECS150 - Digital Design Lecture 23 - High-level Design and Optimization 3, Parallelism and Pipelining

EECS150 - Digital Design Lecture 23 - High-level Design and Optimization 3, Parallelism and Pipelining EECS150 - Digitl Design Lecture 23 - High-level Design nd Optimiztion 3, Prllelism nd Pipelining Nov 12, 2002 John Wwrzynek Fll 2002 EECS150 - Lec23-HL3 Pge 1 Prllelism Prllelism is the ct of doing more

More information

COMPUTER SCIENCE 123. Foundations of Computer Science. 6. Tuples

COMPUTER SCIENCE 123. Foundations of Computer Science. 6. Tuples COMPUTER SCIENCE 123 Foundtions of Computer Science 6. Tuples Summry: This lecture introduces tuples in Hskell. Reference: Thompson Sections 5.1 2 R.L. While, 2000 3 Tuples Most dt comes with structure

More information

CS 321 Programming Languages and Compilers. Bottom Up Parsing

CS 321 Programming Languages and Compilers. Bottom Up Parsing CS 321 Progrmming nguges nd Compilers Bottom Up Prsing Bottom-up Prsing: Shift-reduce prsing Grmmr H: fi ; fi b Input: ;;b hs prse tree ; ; b 2 Dt for Shift-reduce Prser Input string: sequence of tokens

More information

Zenoss Core Installation Guide

Zenoss Core Installation Guide Zenoss Core Instlltion Guide Relese 5.2.1 Zenoss, Inc. www.zenoss.com Zenoss Core Instlltion Guide Copyright 2017 Zenoss, Inc. All rights reserved. Zenoss nd the Zenoss logo re trdemrks or registered trdemrks

More information

10/12/17. Motivating Example. Lexical and Syntax Analysis (2) Recursive-Descent Parsing. Recursive-Descent Parsing. Recursive-Descent Parsing

10/12/17. Motivating Example. Lexical and Syntax Analysis (2) Recursive-Descent Parsing. Recursive-Descent Parsing. Recursive-Descent Parsing Motivting Exmple Lexicl nd yntx Anlysis (2) In Text: Chpter 4 Consider the grmmr -> cad A -> b Input string: w = cd How to build prse tree top-down? 2 Initilly crete tree contining single node (the strt

More information

COMMON HALF YEARLY EXAMINATION DECEMBER 2018

COMMON HALF YEARLY EXAMINATION DECEMBER 2018 li.net i.net li.net i.net li.net i.net li.net i.net li.net i.net li.net i.net li.net i.net li.net i.net li.net i.net.pds.pds COMMON HALF YEARLY EXAMINATION DECEMBER 2018 STD : XI SUBJECT: COMPUTER SCIENCE

More information

2 Computing all Intersections of a Set of Segments Line Segment Intersection

2 Computing all Intersections of a Set of Segments Line Segment Intersection 15-451/651: Design & Anlysis of Algorithms Novemer 14, 2016 Lecture #21 Sweep-Line nd Segment Intersection lst chnged: Novemer 8, 2017 1 Preliminries The sweep-line prdigm is very powerful lgorithmic design

More information

Reference types and their characteristics Class Definition Constructors and Object Creation Special objects: Strings and Arrays

Reference types and their characteristics Class Definition Constructors and Object Creation Special objects: Strings and Arrays Objects nd Clsses Reference types nd their chrcteristics Clss Definition Constructors nd Object Cretion Specil objects: Strings nd Arrys OOAD 1999/2000 Cludi Niederée, Jochim W. Schmidt Softwre Systems

More information

Lists in Lisp and Scheme

Lists in Lisp and Scheme Lists in Lisp nd Scheme Lists in Lisp nd Scheme Lists re Lisp s fundmentl dt structures, ut there re others Arrys, chrcters, strings, etc. Common Lisp hs moved on from eing merely LISt Processor However,

More information

XML Document Parsing: Operational and Performance Characteristics

XML Document Parsing: Operational and Performance Characteristics C O M P U T I N G P R A C T I C E S XML Document Prsing: Opertionl nd Performnce Chrcteristics Prsing is n expensive opertion tht cn degrde XML processing performnce. A survey of four representtive XML

More information

CSCE 531, Spring 2017, Midterm Exam Answer Key

CSCE 531, Spring 2017, Midterm Exam Answer Key CCE 531, pring 2017, Midterm Exm Answer Key 1. (15 points) Using the method descried in the ook or in clss, convert the following regulr expression into n equivlent (nondeterministic) finite utomton: (

More information

McAfee Network Security Platform

McAfee Network Security Platform NTBA Applince T-200 nd T-500 Quick Strt Guide Revision B McAfee Network Security Pltform 1 Instll the mounting rils Position the mounting rils correctly nd instll them t sme levels. At the front of the

More information

16 Bit Software Tools ADDU-21xx-PC-1 Code Generation and Simulation

16 Bit Software Tools ADDU-21xx-PC-1 Code Generation and Simulation 16 Bit Softwre Tools ADDU-21xx-PC-1 Code Genertion nd Simultion ADDS-21xx-PC-1 Version 6.1 Contents The entire softwre cretion tool chin in one pckge System Builder Assembler C Compiler Linker Softwre

More information

! Smaller, simpler, subcomponent of program! Provides abstraction. n hide low-level details, give high-level structure

! Smaller, simpler, subcomponent of program! Provides abstraction. n hide low-level details, give high-level structure Function Chpte 1 Functions Oiginl slides fom Gegoy Byd, Noth Colin Stte Univesity Modified slides by Chis Wilcox, Colodo Stte Univesity! Smlle, simple, subcomponent of pogm! Povides bstction n hide lo-level

More information

CSEP 573 Artificial Intelligence Winter 2016

CSEP 573 Artificial Intelligence Winter 2016 CSEP 573 Artificil Intelligence Winter 2016 Luke Zettlemoyer Problem Spces nd Serch slides from Dn Klein, Sturt Russell, Andrew Moore, Dn Weld, Pieter Abbeel, Ali Frhdi Outline Agents tht Pln Ahed Serch

More information

Control-Flow Analysis and Loop Detection

Control-Flow Analysis and Loop Detection ! Control-Flow Anlysis nd Loop Detection!Lst time! PRE!Tody! Control-flow nlysis! Loops! Identifying loops using domintors! Reducibility! Using loop identifiction to identify induction vribles CS553 Lecture

More information

A Tautology Checker loosely related to Stålmarck s Algorithm by Martin Richards

A Tautology Checker loosely related to Stålmarck s Algorithm by Martin Richards A Tutology Checker loosely relted to Stålmrck s Algorithm y Mrtin Richrds mr@cl.cm.c.uk http://www.cl.cm.c.uk/users/mr/ University Computer Lortory New Museum Site Pemroke Street Cmridge, CB2 3QG Mrtin

More information

P(r)dr = probability of generating a random number in the interval dr near r. For this probability idea to make sense we must have

P(r)dr = probability of generating a random number in the interval dr near r. For this probability idea to make sense we must have Rndom Numers nd Monte Crlo Methods Rndom Numer Methods The integrtion methods discussed so fr ll re sed upon mking polynomil pproximtions to the integrnd. Another clss of numericl methods relies upon using

More information

COMPUTER EDUCATION TECHNIQUES, INC. (MS_W2K3_SERVER ) SA:

COMPUTER EDUCATION TECHNIQUES, INC. (MS_W2K3_SERVER ) SA: In order to lern which questions hve een nswered correctly: 1. Print these pges. 2. Answer the questions. 3. Send this ssessment with the nswers vi:. FAX to (212) 967-3498. Or. Mil the nswers to the following

More information

Coprocessor memory definition. Loic Pallardy / Arnaud Pouliquen

Coprocessor memory definition. Loic Pallardy / Arnaud Pouliquen Coprocessor memory definition Loic Pllrdy / Arnud Pouliquen Objective 2 The gol of following slides is to sum up on-going discussion in OpenAP weekly bout Remoteproc/Rpmsg memory lloction. Following proposl

More information

ITEC2620 Introduction to Data Structures

ITEC2620 Introduction to Data Structures ITEC0 Introduction to Dt Structures Lecture 7 Queues, Priority Queues Queues I A queue is First-In, First-Out = FIFO uffer e.g. line-ups People enter from the ck of the line People re served (exit) from

More information

Engineer To Engineer Note

Engineer To Engineer Note Engineer To Engineer Note EE-167 Technicl Notes on using Anlog Devices' DSP components nd development tools Contct our technicl support by phone: (800) ANALOG-D or e-mil: dsp.support@nlog.com Or visit

More information

Compilers Spring 2013 PRACTICE Midterm Exam

Compilers Spring 2013 PRACTICE Midterm Exam Compilers Spring 2013 PRACTICE Midterm Exm This is full length prctice midterm exm. If you wnt to tke it t exm pce, give yourself 7 minutes to tke the entire test. Just like the rel exm, ech question hs

More information

Dr. D.M. Akbar Hussain

Dr. D.M. Akbar Hussain Dr. D.M. Akr Hussin Lexicl Anlysis. Bsic Ide: Red the source code nd generte tokens, it is similr wht humns will do to red in; just tking on the input nd reking it down in pieces. Ech token is sequence

More information

Midterm 2 Sample solution

Midterm 2 Sample solution Nme: Instructions Midterm 2 Smple solution CMSC 430 Introduction to Compilers Fll 2012 November 28, 2012 This exm contins 9 pges, including this one. Mke sure you hve ll the pges. Write your nme on the

More information

Scanner Termination. Multi Character Lookahead. to its physical end. Most parsers require an end of file token. Lex and Jlex automatically create an

Scanner Termination. Multi Character Lookahead. to its physical end. Most parsers require an end of file token. Lex and Jlex automatically create an Scnner Termintion A scnner reds input chrcters nd prtitions them into tokens. Wht hppens when the end of the input file is reched? It my be useful to crete n Eof pseudo-chrcter when this occurs. In Jv,

More information

Lecture 10 Evolutionary Computation: Evolution strategies and genetic programming

Lecture 10 Evolutionary Computation: Evolution strategies and genetic programming Lecture 10 Evolutionry Computtion: Evolution strtegies nd genetic progrmming Evolution strtegies Genetic progrmming Summry Negnevitsky, Person Eduction, 2011 1 Evolution Strtegies Another pproch to simulting

More information

Virtual Machine. Part II: Program Control. Building a Modern Computer From First Principles.

Virtual Machine. Part II: Program Control. Building a Modern Computer From First Principles. Virtual Machine Part II: Program Control Building a Modern Computer From First Principles www.nand2tetris.org Elements of Computing Systems, Nisan & Schocken, MIT Press, www.nand2tetris.org, Chapter 8:

More information

10/9/2012. Operator is an operation performed over data at runtime. Arithmetic, Logical, Comparison, Assignment, Etc. Operators have precedence

10/9/2012. Operator is an operation performed over data at runtime. Arithmetic, Logical, Comparison, Assignment, Etc. Operators have precedence /9/22 P f Performing i Si Simple l Clcultions C l l ti with ith C#. Opertors in C# nd Opertor Precedence 2. Arithmetic Opertors 3. Logicl Opertors 4. Bitwise Opertors 5. Comprison Opertors 6. Assignment

More information