Instruction Selection via Tree-Pattern Matching Comp 412

Size: px
Start display at page:

Download "Instruction Selection via Tree-Pattern Matching Comp 412"

Transcription

1 COMP FALL 017 Instruction Selection via TreePattern Matching Comp source code IR Front End Optimizer Back End IR target code Copyright 017, Keith D. Cooper & Linda Torczon, all rights reserved. Students enrolled in Comp at Rice University have explicit permission to make copies of these materials for their personal use. Faculty from other educational institutions may use these materials for nonprofit educational purposes, provided this copyright notice is preserved. Chapter 11 in EaC3e

2 Automatic Generation of Instruction Selectors We want to automate generation of instruction selectors (as with parsers & scanners) source code IR Front End Optimizer Back End IR target code machine description BackEnd Generator Tables Hardcoded Pattern Matcher Pattern Matching Engine Selector Descriptionbased retargeting COMP, Fall 017 1

3 Treepattern matching We want to match tree patterns with tree IR Goal is to tile the AST with patterns for machine operations A tiling is collection of <node, pattern > pairs node is a subtree in the tree representation of the code (AST) pattern is a tree describing an instruction sequence <node, pattern> means that pattern could implement a subtree at node A tiling implements an AST if it covers every node in the AST & the overlap between any two trees occurs at a single node <node, pattern> Î tiling means that the root of node is also covered by a leaf in another pattern tree in the tiling, unless node is the root of the AST Where two pattern trees overlap, they must be compatible; that is, they expect the value in the same location (They have the same type.) COMP, Fall 017 9

4 A Tiling of Our Example Tree (Conceptual) Each tile corresponds to a sequence of operations Tile 6 Tile 1 Tile 5 Tile Emitting those operations in an appropriate order implements the tree. Tile Tile 3 Tile numbers correspond to a postorder traversal of the AST. COMP, Fall

5 Generating Code from the Tiled Tree Once the compiler has the tiled tree, it must generate code for the tiles Postorder treewalk, with nodedependent visitation order Right child of before its left child For arithmetic, might impose most demanding subtree first rule (Sethi) Emit code sequence for tiles, in traversal order Tie boundaries together with names (e.g., VRs) Tile 6 uses registers produced by tiles 1 & 5 Code template for tile 6 is store r tile5 Þ r tile1 Can incorporate a real allocator or increment a NextRegister counter Tile 6 Tile 1 Tile 5 COMP, Fall

6 So, What s Hard About This? Finding the matches to tile the tree The compiler writer specifies a mapping from AST to operations Provide a set of rewrite rules Rewrite rules describe the AST Encode tree syntax, in linear prefix form Each rule also has a code template and a cost Tile 1 Tile 6 Tile 5 Tile Tile Tile 3 The compiler writer produces the mapping. Tools turn the mapping into a working instruction selector. Our Tiling Example apparently derived by an oracle Let s look at a set of rules to map our lowlevel AST into ILOC COMP, Fall 017

7 Building a Rule For load How do we build rules for the matcher? Consider a load from memory Tree ILOC Rule Reg load ri => rj Reg j (Reg i ) COMP, Fall 017 Rules are defined over types & operators 13

8 Building a Rule For load What about an address computation? Tree ILOC Rule loadai ri, cj => rk Reg k ((Reg i, j )) Reg The rule for loadai incorporates both the load () and the addition performed in the addressing hardware. Of course, it should have a commutative variant Reg k (( j,reg i )) COMP, Fall 017 1

9 Building a Rule For load What about an address computation? Tree ILOC Rule loadao ri, rj => rk Reg k ((Reg i,reg j )) Reg Reg The rule for loadao is similar to the rule for loadai Difference lies in the type of the operands No need for a commutative variant Reg Reg Reg The rules for loadai and loadao COMP, Fall 017 each incorporate two operators. 15

10 The Big Simplification To make the algorithm manageable, we will assume (wlog): Each rule implements at most one operator Eliminates complex rules that match multiple nodes Reg ( (Reg 1, )) cost: 1 (rule for loadai) Instead, we break such rules into single operator rules & distribute the cost Reg (T 1 ) cost: 1 T 1 (Reg 1, ) cost: 0 Could use costs of ½ & ½, or ¾ and ¼, or... Use a unique LHS or class or type to tie them together Multiple operations per rule means algorithm must look at combinations Leads to significant complications (solvable, but why bother?) Assume each operator takes 0, 1, or operands Allows us to phrase the patternmatching problem as a simple treewalk COMP, Fall 017

11 The Big Simplification To make the algorithm manageable, we will assume (wlog): Each rule implements at most one operator Eliminates complex rules that match multiple nodes Reg ( (Reg 1, )) cost: 1 (rule for loadai) Instead, we break such rules into single operator rules & distribute the cost Reg (T 1 ) cost: 1 T 1 (Reg 1, ) cost: 0 Use a unique LHS or class or type to tie them together Could use costs of ½ & ½, or ¾ and ¼, or... The Critical Point A set of single operator rules like this one achieves the same result as the multiple operator rule, given appropriate costs for the set Same cost, same result, same algorithmic choices Does increase the number of LHS names (labels) COMP, Fall

12 The Big Simplification Each rule implements at most one operator One more point: The simplification means that all tiles are small Cover a node and its children (if any) Our earlier drawings showed large tiles Tile 6 Tiles and 3 are multioperator tiles Tile has 3 operators Tile 3 has operators We can (and will) tile them with single operator tiles Tile 1 Tile Tile 5 Tile Tile 3 Our Tiling Example apparently derived by an oracle COMP, Fall

13 Rewrite rules: LL Integer AST into ILOC Rule Cost Template 0 Goal Goal Stmt 0 1 Goal Stmt 0 Stmt (Reg 1, Reg ) 1 store r Þ r 1 3 Stmt (T1, Reg ) 1 storeao r 3 Þ T1.r 1,T1.r Stmt (T, Reg ) 1 storeai r 3 Þ T.r,T.n 5 Reg (Reg 1 ) 1 load r 1 Þ r new 6 Reg (T1) 1 loadao T1.r 1,T1.r Þ r new 7 Reg (T) 1 loadai T.r,T.n Þ r new 8 Reg (Reg 1,Reg ) 1 add r 1,r Þ r new 9 Reg (Reg 1,T3 ) 1 addi r 1,T3 Þ r new 10 Reg (T3 1,Reg ) 1 addi r,t3 Þ r new 11 Reg (Reg 1,Reg ) 1 sub r 1,r Þ r new Reg (Reg 1,T3 ) 1 subi r 1,T3 Þ r new 13 Reg (T3 1,Reg ) 1 rsubi r,t3 Þ r new COMP, Fall 017 EaC3e 19

14 Rewrite rules: LL Integer AST into ILOC (part II) Rule Cost Template 1 Reg (Reg 1,Reg ) 1 mult r 1,r Þ r new 15 Reg (Reg 1,T3 ) 1 multi r 1,T3 Þ r new Reg (T3 1,Reg ) 1 multi r,t3 Þ r new 17 Reg CON 1 1 loadi C 1 Þ r new 18 Reg 1 1 loadi N 1 Þ r new 19 Reg 1 Þ r new1 loadai r Þ r new 0 Reg 1 0 // is already in a register 1 T1 (Reg 1,Reg ) 0 // reg reg for loadao T (Reg 1, T3) 0 // reg con for loadai 3 T (T3, Reg 1 ) 0 // con reg for loadai T3 1 0 // con for immed arith ops And this rule set is still overly simplistic Size of the rule set is driven primarily by the AST (not the ISA). COMP Adding, rules Fall can 017 improve the quality of the generated code, EaC3e 0

15 Tiling the Tree Tile(n) if n is a leaf Match(n,) { rules that implement n} else if n is a unary node Tile(child(n)) Match(n,) Ø for each rule r where op(r) = op(n) if (child(r) & child(n) are compatible) then add r to Match(n,class(r)) else if n is a binary node Tile (left(n)) Tile (right(n)) Match(n,) Ø for each rule r where op(r) = op(n) if (left(r) & left(n) are compatible) and (right(r) & right(n) are compatible) then add r to Match(n,class(r)) Match a leaf Match unary nodes against unary rules Match binary nodes against binary rules COMP, Fall 017 1

16 Tiling the Tree Tile(n) if n is a leaf Match(n,) { rules that implement n} else if n is a unary node Tile(child(n)) Match(n,) Ø for each rule r where op(r) = op(n) if (child(r) & child(n) are compatible) then add r to Match(n,class(r)) else if n is a binary node Tile (left(n)) Tile (right(n)) Match(n,) Ø for each rule r where op(r) = op(n) if (left(r) & left(n) are compatible) and (right(r) & right(n) are compatible) then add r to Match(n,class(r)) For a leaf, Match can be precomputed: Stmt T1 T T3 Reg 18 The Match Entry for For unary or binary nodes, Tile() first recurs on the subtree(s) and then finds compatible rules. Search the rules that match op(n) Rules are compatible if the classes of the children match appropriately Accumulate matches in Match(n,) COMP, Fall 017

17 Instruction Selection via TreePattern Matching Our Example: is a leaf, and {Reg: 0} is its precomputed entry. Stmt T1 T T3 Reg No column for Goal a: at b: at 8 (call by ref) c: at COMP, Fall 017 3

18 Instruction Selection via TreePattern Matching Our Example: is a leaf, and {T3:, Reg: 18} is its precomputed entry. Stmt T1 T T3 Reg a: at b: at 8 (call by ref) c: at COMP, Fall 017

19 Instruction Selection via TreePattern Matching Our Example: Rules 8, 9, 10, 1,, & 3 implement addition. Four are compatible. 3 Stmt T1 T T3 Reg , 9 a: at b: at 8 (call by ref) c: at COMP, Fall 017 5

20 Instruction Selection via TreePattern Matching Our Example: is a leaf, and {Reg: 0} is its precomputed entry. Stmt T1 T T3 Reg , 9 0 a: at b: at 8 (call by ref) c: at COMP, Fall 017 6

21 Instruction Selection via TreePattern Matching Our Example: is a leaf, and {T3:, Reg: 18} is its precomputed entry. Stmt T1 T T3 Reg , a: at b: at 8 (call by ref) c: at 5 COMP, Fall 017 7

22 Instruction Selection via TreePattern Matching Our Example: Rules 11,, & 13 implement subtraction. 11 & match. Stmt T1 T T3 Reg , , a: at b: at 8 (call by ref) c: at 6 COMP, Fall 017 8

23 Instruction Selection via TreePattern Matching Our Example: Stmt T1 T T3 Reg Rules 5, 6, & 7 all implement. Only 5 matches , , a: at b: at 8 (call by ref) c: at COMP, Fall 017 9

24 Instruction Selection via TreePattern Matching Our Example: Rules 5, 6, & 7 all implement. Only 5 matches.. 8 Stmt T1 T T3 Reg , , a: at b: at 8 (call by ref) c: at COMP, Fall

25 Instruction Selection via TreePattern Matching Our Example: Stmt T1 T T3 Reg is a leaf, and {T3:, Reg: 8} is its precomputed entry , , a: at b: at 8 (call by ref) c: at COMP, Fall

26 Instruction Selection via TreePattern Matching Our Example: Stmt T1 T T3 Reg is a leaf, and {Reg: 19} is its precomputed entry , , a: at b: at 8 (call by ref) c: at 10 COMP, Fall 017 3

27 Instruction Selection via TreePattern Matching Our Example: is a leaf, and {T3:, Reg: 18} is its precomputed entry. a: at b: at 8 (call by ref) c: at COMP, Fall Stmt T1 T T3 Reg , ,

28 Instruction Selection via TreePattern Matching Our Example: Rules 8, 9, 10, 1,, & 3 implement addition. Four are compatible. a: at b: at 8 (call by ref) c: at COMP, Fall Stmt T1 T T3 Reg , , , 9

29 Instruction Selection via TreePattern Matching Our Example: Rules 5, 6, & 7 all implement. All three are compatible. a: at b: at 8 (call by ref) c: at COMP, Fall Stmt T1 T T3 Reg , , , , 6, 7

30 Instruction Selection via TreePattern Matching Our Example: Rules 1, 15, & all implement multiplication. Two are compatible with subtree matches. a: at b: at 8 (call by ref) c: at 1 COMP, Fall Stmt T1 T T3 Reg , , , , 6, 7 1 1,

31 Instruction Selection via TreePattern Matching Our Example: Rules 11,, & 13 all implement subtraction. Only 11 is compatible with two Reg labels. a: at b: at 8 (call by ref) c: at 15 COMP, Fall Stmt T1 T T3 Reg , , , , 6, 7 1 1, 15 11

32 Instruction Selection via TreePattern Matching Our Example: Rules, 3, & all implement. All three are compatible with matches from node 3. a: at b: at 8 (call by ref) c: at COMP, Fall 017 Stmt T1 T T3 Reg , , , , 6, 7 1 1, 15 11, 3, 38

33 Instruction Selection via TreePattern Matching 1 Code selection should be guided by costs When choice exists, take the lowcost choice 3 a: at b: at (call by ref) v: at COMP, Fall Stmt T1 T T3 Reg , , , , 6, 7 1 1, 15 11, 3, 39

34 Instruction Selection via TreePattern Matching 1 Code selection should be guided by costs When choice exists, take the lowcost choice 3 a: at b: at (call by ref) v: at COMP, Fall The lowcost choice often requires context Stmt T1 T T3 Reg , , , , 6, 7 1 1, 15 11, 3, 0

35 Instruction Selection via TreePattern Matching Focus on subtree rooted at node 13 What do the options & costs suggest? 3 1 a: at b: at (call by ref) v: at Stmt T1 T T3 Reg , , , , 6, 7 1 1, COMP, Fall 017, 3,

36 Instruction Selection via TreePattern Matching Focus on subtree rooted at node 13 What do the options & costs suggest? Rule for 13 Sequence Cost 5 <19,18,8,5> 9 5 <19,,9,5> 8 6 <19,18,1,6> 8 7 <19,,,7> 7 Stmt T1 T T3 Reg , , , , 6, 7 1 1, and COMP their, commutative Fall 017 variants, 3,

37 Instruction Selection via TreePattern Matching Focus on subtree rooted at node 13 What do the options & costs suggest? loadi loadai load 8 add loadi Rule for 13 Sequence Cost 5 <19,18,8,5> 9 5 <19,,9,5> 8 6 <19,18,1,6> 8 7 <19,,,7> 7 Generated Code for <19,18,8,5> Þ r i loadai r i, Þ r j loadi Þ r k add r j, r k Þ r m load r m Þ r n Stmt T1 T T3 Reg , , , , 6, 7 1 1, COMP, Fall 017, 3, 3

38 Instruction Selection via TreePattern Matching Focus on subtree rooted at node 13 What do the options & costs suggest? loadi loadai load addi Rule for 13 Sequence Cost 5 <19,18,8,5> 9 5 <19,,9,5> 8 6 <19,18,1,6> 8 7 <19,,,7> 7 Generated Code for <19,,9,5> Þ r i loadai r i, Þ r j addi r j, Þ r k load r k Þ r m Stmt T1 T T3 Reg , , , , 6, 7 1 1, COMP, Fall 017, 3,

39 Instruction Selection via TreePattern Matching Focus on subtree rooted at node 13 What do the options & costs suggest? loadi loadai 6 loadao loadi Rule for 13 Sequence Cost 5 <19,18,8,5> 9 5 <19,,9,5> 8 6 <19,18,1,6> 8 7 <19,,,7> 7 Generated Code for <19,18,1,6> Þ r i loadai r i, Þ r j loadi Þ r k loadao r j, r k Þ r m Stmt T1 T T3 Reg , , , , 6, 7 1 1, COMP, Fall 017, 3, 5

40 Instruction Selection via TreePattern Matching Focus on subtree rooted at node 13 What do the options & costs suggest? loadai loadi loadai Rule for 13 Sequence Cost 5 <19,18,8,5> 9 5 <19,,9,5> 8 6 <19,18,1,6> 8 7 <19,,,7> 7 Generated Code for <19,18,1,6> Þ r i loadai r i, Þ r j loadai r j, Þ r k <19,,,7> is clearly the low cost sequence. Stmt T1 T T3 Reg , , , , 6, 7 1 1, COMP, Fall 017, 3, 6

41 Instruction Selection via TreePattern Matching What about node? Same kinds of choices play out here 3 Rules for Sequence Total Cost <0,18,8,, > 5 cost(node 15) <0,,9,, > cost(node 15) 3 <0,18,1,, 3,> cost(node 15) <0,,,, > 3 cost(node 15) 15 The only option for node 15 is a REG Stmt T1 T T3 Reg , , , , 6, 7 1 1, COMP, Assumes Fall 017 node 15 is in a Reg already, 3, 7

42 Instruction Selection via TreePattern Matching What about node 1? Costs should drive selection of multi over mult The only option for node 13 is a REG Rules for 1 Sequence Total Cost 1 <18,, 1> cost(node 13) <,,> 1 cost(node 13) Assumes node 1 is in a Reg already Stmt T1 T T3 Reg , , , , 6, 7 1 1, COMP, Fall 017, 3, 8

43 Tiling the Tree Adding cost to the algorithm Tile(n) if n is a leaf Match(n,) { rules that implement n} else if n is a unary node Tile(child(n)) Match(n,) Ø for each rule r where op(r) = op(n) if (child(r) & child(n) are compatible) then add r to Match(n,class(r)) else if n is a binary node Tile (left(n)) Tile (right(n)) Match(n,) Ø for each rule r where op(r) = op(n) if (left(r) & left(n) are compatible) and (right(r) & right(n) are compatible) then add r to Match(n,class(r)) Why track all matches in a category when the algorithm will only use the lowcost match? Instead, the algorithm can test each new match against the previous lowcost match & keep the least expensive option. No accounting for costs Keeps all matches COMP, Fall 017 9

44 Tile() With Costs Keep only low cost matches in each category (LHS symbol) Keep track of both rule and cumulative cost At each possible new match, compute cost of new match and compare Simplifies data structures Two integers vs. a set Changes initializations Can precompute leaves, as before Tile(n) / n is a node in an AST / if nisaleafnodethen Match(n, ).rule { lowcost rule that matches n,ineachclass} Match(n, ).cost { corresponding cost } else if nisaunarynodethen Tile(child(n)) Match(n,).rule invalid Match(n,).cost largest integer for each rule r where operator(r) = operator(n) if (child(r), child(n)) are compatible then NewCost RuleCost(r) Match(child(n),class(child(r))).cost if (Match(n,class(r)).cost > NewCost) then Match(n,class(r)).rule r Match(n,class(r)).cost NewCost else if nisabinarynodethen Tile(left(n)) Tile(right(n)) Match(n,).rule invalid Match(n,).cost largest integer for each rule r where operator(r) = operator(n) if (left(r), left(n)) and (right(r), right(n)) are compatible then NewCost RuleCost(r) Match(left(n), class(left(r))).cost Match(right(n), class(right(r))).cost if (Match(n,class(r)).cost > NewCost) then Match(n,class(r)).rule r Match(n,class(r)).cost NewCost FIGURE 11.9 Compute LowCost Matches to Tile an AST COMP, Fall

45 Tile() With Costs We could precompute more Entire inner loop is really a lookup on operator & the table entry its children in the tree Could compute two very large tables Ops x Possible Rows Ops x Possible Rows Replace the entire inner loop(s) with table lookup and an assignment Building the tables is slow, but the resulting matcher is extremely fast Tile(n) / n is a node in an AST / if nisaleafnodethen Match(n, ).rule { lowcost rule that matches n,ineachclass} Match(n, ).cost { corresponding cost } else if nisaunarynodethen Tile(child(n)) Match(n,).rule invalid Match(n,).cost largest integer for each rule r where operator(r) = operator(n) if (child(r), child(n)) are compatible then NewCost RuleCost(r) Match(child(n),class(child(r))).cost if (Match(n,class(r)).cost > NewCost) then Match(n,class(r)).rule r Match(n,class(r)).cost NewCost else if nisabinarynodethen Tile(left(n)) Tile(right(n)) FIGURE 11.9 Match(n,).rule invalid Match(n,).cost largest integer for each rule r where operator(r) = operator(n) if (left(r), left(n)) and (right(r), right(n)) are compatible then NewCost RuleCost(r) Match(left(n), class(left(r))).cost Match(right(n), class(right(r))).cost if (Match(n,class(r)).cost > NewCost) then Match(n,class(r)).rule r Match(n,class(r)).cost NewCost Compute LowCost Matches to Tile an AST COMP, Fall Would like to shrink the tables; see [Chase, POPL 1987].

46 What Happens Next? The algorithm now computes a set of lowcost tilings The instruction selector needs to emit the assembly code, driven by the matches and their code templates At each node, it has the low cost rule for each class Two step process: mark the choices & emit the code Pass 1: Walk the tree, top to bottom, and mark choice of rules Choice of one tile often determines the choices at its subtrees Pass : Walk the tree, bottom to top, and emit code Tie together tiles with temporary register names (e.g., r new ) COMP, Fall 017 5

47 Instruction Selection via TreePattern Matching Rule Choices Only rules that produce code are shown 3 1 a: at b: at (call by ref) v: at COMP, Fall Stmt T1 T T3 Reg , , , , 6, 7 1 1, 15 11, 3, 53

48 Instruction Selection via TreePattern Matching Final Code for the Example Node Rule Emitted Code 6 subi r arp, r a 7 5 load r a r b 8 5 load r b r c r d loadai r d, r e 13 7 loadai r e, r f 1 multi r f, r g 1 a: at b: at (call by ref) v: at sub r c, r g r h storeai r h r arp, COMP, Fall 017 5

Lecture 14 Instruction Selection: Tree-pattern matching

Lecture 14 Instruction Selection: Tree-pattern matching Lecture 14 Instruction Selection: Tree-pattern matching (EaC-11.3) Copyright 2003, Keith D. Cooper, Ken Kennedy & Linda Torczon, all rights reserved. The Concept Many compilers use tree-structured IRs

More information

Compiler Optimisation

Compiler Optimisation Compiler Optimisation 6 Instruction Scheduling Hugh Leather IF 1.18a hleather@inf.ed.ac.uk Institute for Computing Systems Architecture School of Informatics University of Edinburgh 2018 Introduction This

More information

A New High Speed Low Power Performance of 8- Bit Parallel Multiplier-Accumulator Using Modified Radix-2 Booth Encoded Algorithm

A New High Speed Low Power Performance of 8- Bit Parallel Multiplier-Accumulator Using Modified Radix-2 Booth Encoded Algorithm A New High Speed Low Power Performance of 8- Bit Parallel Multiplier-Accumulator Using Modified Radix-2 Booth Encoded Algorithm V.Sandeep Kumar Assistant Professor, Indur Institute Of Engineering & Technology,Siddipet

More information

CSI33 Data Structures

CSI33 Data Structures Department of Mathematics and Computer Science Bronx Community College Outline Chapter 7: Trees 1 Chapter 7: Trees Uses Of Trees Chapter 7: Trees Taxonomies animal vertebrate invertebrate fish mammal reptile

More information

Module 3 Greedy Strategy

Module 3 Greedy Strategy Module 3 Greedy Strategy Dr. Natarajan Meghanathan Professor of Computer Science Jackson State University Jackson, MS 39217 E-mail: natarajan.meghanathan@jsums.edu Introduction to Greedy Technique Main

More information

Problem A. Worst Locations

Problem A. Worst Locations Problem A Worst Locations Two pandas A and B like each other. They have been placed in a bamboo jungle (which can be seen as a perfect binary tree graph of 2 N -1 vertices and 2 N -2 edges whose leaves

More information

Module 3 Greedy Strategy

Module 3 Greedy Strategy Module 3 Greedy Strategy Dr. Natarajan Meghanathan Professor of Computer Science Jackson State University Jackson, MS 39217 E-mail: natarajan.meghanathan@jsums.edu Introduction to Greedy Technique Main

More information

Greedy Algorithms. Kleinberg and Tardos, Chapter 4

Greedy Algorithms. Kleinberg and Tardos, Chapter 4 Greedy Algorithms Kleinberg and Tardos, Chapter 4 1 Selecting gas stations Road trip from Fort Collins to Durango on a given route with length L, and fuel stations at positions b i. Fuel capacity = C miles.

More information

Adversary Search. Ref: Chapter 5

Adversary Search. Ref: Chapter 5 Adversary Search Ref: Chapter 5 1 Games & A.I. Easy to measure success Easy to represent states Small number of operators Comparison against humans is possible. Many games can be modeled very easily, although

More information

Lecture5: Lossless Compression Techniques

Lecture5: Lossless Compression Techniques Fixed to fixed mapping: we encoded source symbols of fixed length into fixed length code sequences Fixed to variable mapping: we encoded source symbols of fixed length into variable length code sequences

More information

Chapter 4: The Building Blocks: Binary Numbers, Boolean Logic, and Gates

Chapter 4: The Building Blocks: Binary Numbers, Boolean Logic, and Gates Chapter 4: The Building Blocks: Binary Numbers, Boolean Logic, and Gates Objectives In this chapter, you will learn about The binary numbering system Boolean logic and gates Building computer circuits

More information

1 This work was partially supported by NSF Grant No. CCR , and by the URI International Engineering Program.

1 This work was partially supported by NSF Grant No. CCR , and by the URI International Engineering Program. Combined Error Correcting and Compressing Codes Extended Summary Thomas Wenisch Peter F. Swaszek Augustus K. Uht 1 University of Rhode Island, Kingston RI Submitted to International Symposium on Information

More information

2004 Denison Spring Programming Contest 1

2004 Denison Spring Programming Contest 1 24 Denison Spring Programming Contest 1 Problem : 4 Square It s been known for over 2 years that every positive integer can be written in the form x 2 + y 2 + z 2 + w 2, for x,y,z,w non-negative integers.

More information

Huffman Coding - A Greedy Algorithm. Slides based on Kevin Wayne / Pearson-Addison Wesley

Huffman Coding - A Greedy Algorithm. Slides based on Kevin Wayne / Pearson-Addison Wesley - A Greedy Algorithm Slides based on Kevin Wayne / Pearson-Addison Wesley Greedy Algorithms Greedy Algorithms Build up solutions in small steps Make local decisions Previous decisions are never reconsidered

More information

ARTIFICIAL INTELLIGENCE (CS 370D)

ARTIFICIAL INTELLIGENCE (CS 370D) Princess Nora University Faculty of Computer & Information Systems ARTIFICIAL INTELLIGENCE (CS 370D) (CHAPTER-5) ADVERSARIAL SEARCH ADVERSARIAL SEARCH Optimal decisions Min algorithm α-β pruning Imperfect,

More information

CHAPTER 1 INTRODUCTION

CHAPTER 1 INTRODUCTION CHAPTER 1 INTRODUCTION 1.1 Project Background High speed multiplication is another critical function in a range of very large scale integration (VLSI) applications. Multiplications are expensive and slow

More information

: Principles of Automated Reasoning and Decision Making Midterm

: Principles of Automated Reasoning and Decision Making Midterm 16.410-13: Principles of Automated Reasoning and Decision Making Midterm October 20 th, 2003 Name E-mail Note: Budget your time wisely. Some parts of this quiz could take you much longer than others. Move

More information

IJCSIET--International Journal of Computer Science information and Engg., Technologies ISSN

IJCSIET--International Journal of Computer Science information and Engg., Technologies ISSN An efficient add multiplier operator design using modified Booth recoder 1 I.K.RAMANI, 2 V L N PHANI PONNAPALLI 2 Assistant Professor 1,2 PYDAH COLLEGE OF ENGINEERING & TECHNOLOGY, Visakhapatnam,AP, India.

More information

Register Allocation by Puzzle Solving

Register Allocation by Puzzle Solving Register Allocation by Puzzle Solving EECS 322: Compiler Construction Simone Campanoni Robby Findler 4/19/2016 Materials Research paper: Authors: Fernando Magno Quintao Pereira, Jens Palsberg Title: Register

More information

The Theory Behind the z/architecture Sort Assist Instructions

The Theory Behind the z/architecture Sort Assist Instructions The Theory Behind the z/architecture Sort Assist Instructions SHARE in San Jose August 10-15, 2008 Session 8121 Michael Stack NEON Enterprise Software, Inc. 1 Outline A Brief Overview of Sorting Tournament

More information

Introduction to. Algorithms. Lecture 10. Prof. Constantinos Daskalakis CLRS

Introduction to. Algorithms. Lecture 10. Prof. Constantinos Daskalakis CLRS 6.006- Introduction to Algorithms Lecture 10 Prof. Constantinos Daskalakis CLRS 8.1-8.4 Menu Show that Θ(n lg n) is the best possible running time for a sorting algorithm. Design an algorithm that sorts

More information

Computer Science 246. Advanced Computer Architecture. Spring 2010 Harvard University. Instructor: Prof. David Brooks

Computer Science 246. Advanced Computer Architecture. Spring 2010 Harvard University. Instructor: Prof. David Brooks Advanced Computer Architecture Spring 2010 Harvard University Instructor: Prof. dbrooks@eecs.harvard.edu Lecture Outline Instruction-Level Parallelism Scoreboarding (A.8) Instruction Level Parallelism

More information

Games and Adversarial Search II

Games and Adversarial Search II Games and Adversarial Search II Alpha-Beta Pruning (AIMA 5.3) Some slides adapted from Richard Lathrop, USC/ISI, CS 271 Review: The Minimax Rule Idea: Make the best move for MAX assuming that MIN always

More information

Instruction Level Parallelism Part II - Scoreboard

Instruction Level Parallelism Part II - Scoreboard Course on: Advanced Computer Architectures Instruction Level Parallelism Part II - Scoreboard Prof. Cristina Silvano Politecnico di Milano email: cristina.silvano@polimi.it 1 Basic Assumptions We consider

More information

Spring 06 Assignment 2: Constraint Satisfaction Problems

Spring 06 Assignment 2: Constraint Satisfaction Problems 15-381 Spring 06 Assignment 2: Constraint Satisfaction Problems Questions to Vaibhav Mehta(vaibhav@cs.cmu.edu) Out: 2/07/06 Due: 2/21/06 Name: Andrew ID: Please turn in your answers on this assignment

More information

Balanced Trees. Balanced Trees Tree. 2-3 Tree. 2 Node. Binary search trees are not guaranteed to be balanced given random inserts and deletes

Balanced Trees. Balanced Trees Tree. 2-3 Tree. 2 Node. Binary search trees are not guaranteed to be balanced given random inserts and deletes Balanced Trees Balanced Trees 23 Tree Binary search trees are not guaranteed to be balanced given random inserts and deletes! Tree could degrade to O(n) operations Balanced search trees! Operations maintain

More information

UNIVERSITY OF MASSACHUSETTS Dept. of Electrical & Computer Engineering. Digital Computer Arithmetic ECE 666

UNIVERSITY OF MASSACHUSETTS Dept. of Electrical & Computer Engineering. Digital Computer Arithmetic ECE 666 UNIVERSITY OF MASSACHUSETTS Dept. of Electrical & Computer Engineering Digital Computer Arithmetic ECE 666 Part 6a High-Speed Multiplication - I Israel Koren ECE666/Koren Part.6a.1 Speeding Up Multiplication

More information

Raster Based Region Growing

Raster Based Region Growing 6th New Zealand Image Processing Workshop (August 99) Raster Based Region Growing Donald G. Bailey Image Analysis Unit Massey University Palmerston North ABSTRACT In some image segmentation applications,

More information

Self-Adjusting Binary Search Trees. Andrei Pârvu

Self-Adjusting Binary Search Trees. Andrei Pârvu Self-Adjusting Binary Search Trees Andrei Pârvu Andrei Pârvu 13-05-2015 1 Motivation Andrei Pârvu 13-05-2015 2 Motivation: Find Andrei Pârvu 13-05-2015 3 Motivation: Insert Andrei Pârvu 13-05-2015 4 Motivation:

More information

Mahendra Engineering College, Namakkal, Tamilnadu, India.

Mahendra Engineering College, Namakkal, Tamilnadu, India. Implementation of Modified Booth Algorithm for Parallel MAC Stephen 1, Ravikumar. M 2 1 PG Scholar, ME (VLSI DESIGN), 2 Assistant Professor, Department ECE Mahendra Engineering College, Namakkal, Tamilnadu,

More information

The Eighth Annual Student Programming Contest. of the CCSC Southeastern Region. Saturday, November 3, :00 A.M. 12:00 P.M.

The Eighth Annual Student Programming Contest. of the CCSC Southeastern Region. Saturday, November 3, :00 A.M. 12:00 P.M. C C S C S E Eighth Annual Student Programming Contest of the CCSC Southeastern Region Saturday, November 3, 8: A.M. : P.M. L i p s c o m b U n i v e r s i t y P R O B L E M O N E What the Hail re is an

More information

Interpolation Error in Waveform Table Lookup

Interpolation Error in Waveform Table Lookup Carnegie Mellon University Research Showcase @ CMU Computer Science Department School of Computer Science 1998 Interpolation Error in Waveform Table Lookup Roger B. Dannenberg Carnegie Mellon University

More information

Embedded Systems CSEE W4840. Design Document. Hardware implementation of connected component labelling

Embedded Systems CSEE W4840. Design Document. Hardware implementation of connected component labelling Embedded Systems CSEE W4840 Design Document Hardware implementation of connected component labelling Avinash Nair ASN2129 Jerry Barona JAB2397 Manushree Gangwar MG3631 Spring 2016 Table of Contents TABLE

More information

Multiplier Design and Performance Estimation with Distributed Arithmetic Algorithm

Multiplier Design and Performance Estimation with Distributed Arithmetic Algorithm Multiplier Design and Performance Estimation with Distributed Arithmetic Algorithm M. Suhasini, K. Prabhu Kumar & P. Srinivas Department of Electronics & Comm. Engineering, Nimra College of Engineering

More information

Game Theory and Randomized Algorithms

Game Theory and Randomized Algorithms Game Theory and Randomized Algorithms Guy Aridor Game theory is a set of tools that allow us to understand how decisionmakers interact with each other. It has practical applications in economics, international

More information

The Problem. Tom Davis December 19, 2016

The Problem. Tom Davis  December 19, 2016 The 1 2 3 4 Problem Tom Davis tomrdavis@earthlink.net http://www.geometer.org/mathcircles December 19, 2016 Abstract The first paragraph in the main part of this article poses a problem that can be approached

More information

Digital Integrated CircuitDesign

Digital Integrated CircuitDesign Digital Integrated CircuitDesign Lecture 13 Building Blocks (Multipliers) Register Adder Shift Register Adib Abrishamifar EE Department IUST Acknowledgement This lecture note has been summarized and categorized

More information

Logical Trunked. Radio (LTR) Theory of Operation

Logical Trunked. Radio (LTR) Theory of Operation Logical Trunked Radio (LTR) Theory of Operation An Introduction to the Logical Trunking Radio Protocol on the Motorola Commercial and Professional Series Radios Contents 1. Introduction...2 1.1 Logical

More information

CHAPTER 5 PAPR REDUCTION USING HUFFMAN AND ADAPTIVE HUFFMAN CODES

CHAPTER 5 PAPR REDUCTION USING HUFFMAN AND ADAPTIVE HUFFMAN CODES 119 CHAPTER 5 PAPR REDUCTION USING HUFFMAN AND ADAPTIVE HUFFMAN CODES 5.1 INTRODUCTION In this work the peak powers of the OFDM signal is reduced by applying Adaptive Huffman Codes (AHC). First the encoding

More information

Alexandre Fréchette, Neil Newman, Kevin Leyton-Brown

Alexandre Fréchette, Neil Newman, Kevin Leyton-Brown Solving the Station Repacking Problem Alexandre Fréchette, Neil Newman, Kevin Leyton-Brown Agenda Background Problem Novel Approach Experimental Results Background A Brief History Spectrum rights have

More information

EECS 583 Class 7 Classic Code Optimization cont d

EECS 583 Class 7 Classic Code Optimization cont d EECS 583 Class 7 Classic Code Optimization cont d University of Michigan October 2, 2016 Global Constant Propagation Consider 2 ops, X and Y in different BBs» 1. X is a move» 2. src1(x) is a literal» 3.

More information

mywbut.com Two agent games : alpha beta pruning

mywbut.com Two agent games : alpha beta pruning Two agent games : alpha beta pruning 1 3.5 Alpha-Beta Pruning ALPHA-BETA pruning is a method that reduces the number of nodes explored in Minimax strategy. It reduces the time required for the search and

More information

Minimax Trees: Utility Evaluation, Tree Evaluation, Pruning

Minimax Trees: Utility Evaluation, Tree Evaluation, Pruning Minimax Trees: Utility Evaluation, Tree Evaluation, Pruning CSCE 315 Programming Studio Fall 2017 Project 2, Lecture 2 Adapted from slides of Yoonsuck Choe, John Keyser Two-Person Perfect Information Deterministic

More information

Spring 06 Assignment 2: Constraint Satisfaction Problems

Spring 06 Assignment 2: Constraint Satisfaction Problems 15-381 Spring 06 Assignment 2: Constraint Satisfaction Problems Questions to Vaibhav Mehta(vaibhav@cs.cmu.edu) Out: 2/07/06 Due: 2/21/06 Name: Andrew ID: Please turn in your answers on this assignment

More information

CS 473G: Combinatorial Algorithms, Fall 2005 Homework 0. I understand the Homework Instructions and FAQ.

CS 473G: Combinatorial Algorithms, Fall 2005 Homework 0. I understand the Homework Instructions and FAQ. CS 473G: Combinatorial lgorithms, Fall 2005 Homework 0 Due Thursday, September 1, 2005, at the beginning of class (12:30pm CDT) Name: Net ID: lias: I understand the Homework Instructions and FQ. Neatly

More information

Tomasolu s s Algorithm

Tomasolu s s Algorithm omasolu s s Algorithm Fall 2007 Prof. homas Wenisch http://www.eecs.umich.edu/courses/eecs4 70 Floating Point Buffers (FLB) ag ag ag Storage Bus Floating Point 4 3 Buffers FLB 6 5 5 4 Control 2 1 1 Result

More information

CSS 343 Data Structures, Algorithms, and Discrete Math II. Balanced Search Trees. Yusuf Pisan

CSS 343 Data Structures, Algorithms, and Discrete Math II. Balanced Search Trees. Yusuf Pisan CSS 343 Data Structures, Algorithms, and Discrete Math II Balanced Search Trees Yusuf Pisan Height Height of a tree impacts how long it takes to find an item Balanced tree O(log n) vs Degenerate tree O(n)

More information

Simplifying Non-perfect Square Roots. Arlena Miller. Sullivan County. 9/Algebra 1

Simplifying Non-perfect Square Roots. Arlena Miller. Sullivan County. 9/Algebra 1 Simplifying Non-perfect Square Roots Arlena Miller Sullivan County 9/Algebra 1 Lesson Title: Simplifying Non-perfect Square Roots Grade: 9(Algebra I) Alignment with state standards: CLE 3102.2.1 Understand

More information

Instruction Level Parallelism. Data Dependence Static Scheduling

Instruction Level Parallelism. Data Dependence Static Scheduling Instruction Level Parallelism Data Dependence Static Scheduling Basic Block A straight line code sequence with no branches in except to the entry and no branches out except at the exit Loop: L.D ADD.D

More information

Contents. MA 327/ECO 327 Introduction to Game Theory Fall 2017 Notes. 1 Wednesday, August Friday, August Monday, August 28 6

Contents. MA 327/ECO 327 Introduction to Game Theory Fall 2017 Notes. 1 Wednesday, August Friday, August Monday, August 28 6 MA 327/ECO 327 Introduction to Game Theory Fall 2017 Notes Contents 1 Wednesday, August 23 4 2 Friday, August 25 5 3 Monday, August 28 6 4 Wednesday, August 30 8 5 Friday, September 1 9 6 Wednesday, September

More information

Chapter 16 - Instruction-Level Parallelism and Superscalar Processors

Chapter 16 - Instruction-Level Parallelism and Superscalar Processors Chapter 16 - Instruction-Level Parallelism and Superscalar Processors Luis Tarrataca luis.tarrataca@gmail.com CEFET-RJ L. Tarrataca Chapter 16 - Superscalar Processors 1 / 78 Table of Contents I 1 Overview

More information

Topic 23 Red Black Trees

Topic 23 Red Black Trees Topic 23 "People in every direction No words exchanged No time to exchange And all the little ants are marching Red and Black antennas waving" -Ants Marching, Dave Matthew's Band "Welcome to L.A.'s Automated

More information

CSE 100: RED-BLACK TREES

CSE 100: RED-BLACK TREES 1 CSE 100: RED-BLACK TREES 2 Red-Black Trees 1 70 10 20 60 8 6 80 90 40 1. Nodes are either red or black 2. Root is always black 3. If a node is red, all it s children must be black 4. For every node X,

More information

EECS 470. Tomasulo s Algorithm. Lecture 4 Winter 2018

EECS 470. Tomasulo s Algorithm. Lecture 4 Winter 2018 omasulo s Algorithm Winter 2018 Slides developed in part by Profs. Austin, Brehob, Falsafi, Hill, Hoe, Lipasti, Martin, Roth, Shen, Smith, Sohi, yson, Vijaykumar, and Wenisch of Carnegie Mellon University,

More information

Playing Games. Henry Z. Lo. June 23, We consider writing AI to play games with the following properties:

Playing Games. Henry Z. Lo. June 23, We consider writing AI to play games with the following properties: Playing Games Henry Z. Lo June 23, 2014 1 Games We consider writing AI to play games with the following properties: Two players. Determinism: no chance is involved; game state based purely on decisions

More information

MATH 211 FINAL EXAM REVIEW PROBLEMS with ANSWERS

MATH 211 FINAL EXAM REVIEW PROBLEMS with ANSWERS MATH 211 FINAL EXAM REVIEW PROBLEMS with ANSWERS 1. 32 4 in the sharing interpretation of division, base ten pieces: Share among 4 groups there are 8 in each group so 32 4 = 8. 2. 32 4 in the measurement

More information

International Journal of Digital Application & Contemporary research Website: (Volume 1, Issue 7, February 2013)

International Journal of Digital Application & Contemporary research Website:   (Volume 1, Issue 7, February 2013) Performance Analysis of OFDM under DWT, DCT based Image Processing Anshul Soni soni.anshulec14@gmail.com Ashok Chandra Tiwari Abstract In this paper, the performance of conventional discrete cosine transform

More information

Pipelined Processor Design

Pipelined Processor Design Pipelined Processor Design COE 38 Computer Architecture Prof. Muhamed Mudawar Computer Engineering Department King Fahd University of Petroleum and Minerals Presentation Outline Pipelining versus Serial

More information

Wednesday, February 1, 2017

Wednesday, February 1, 2017 Wednesday, February 1, 2017 Topics for today Encoding game positions Constructing variable-length codes Huffman codes Encoding Game positions Some programs that play two-player games (e.g., tic-tac-toe,

More information

Using Fictitious Play to Find Pseudo-Optimal Solutions for Full-Scale Poker

Using Fictitious Play to Find Pseudo-Optimal Solutions for Full-Scale Poker Using Fictitious Play to Find Pseudo-Optimal Solutions for Full-Scale Poker William Dudziak Department of Computer Science, University of Akron Akron, Ohio 44325-4003 Abstract A pseudo-optimal solution

More information

10/5/2015. Constraint Satisfaction Problems. Example: Cryptarithmetic. Example: Map-coloring. Example: Map-coloring. Constraint Satisfaction Problems

10/5/2015. Constraint Satisfaction Problems. Example: Cryptarithmetic. Example: Map-coloring. Example: Map-coloring. Constraint Satisfaction Problems 0/5/05 Constraint Satisfaction Problems Constraint Satisfaction Problems AIMA: Chapter 6 A CSP consists of: Finite set of X, X,, X n Nonempty domain of possible values for each variable D, D, D n where

More information

Monday, February 2, Is assigned today. Answers due by noon on Monday, February 9, 2015.

Monday, February 2, Is assigned today. Answers due by noon on Monday, February 9, 2015. Monday, February 2, 2015 Topics for today Homework #1 Encoding checkers and chess positions Constructing variable-length codes Huffman codes Homework #1 Is assigned today. Answers due by noon on Monday,

More information

Suggested Readings! Lecture 12" Introduction to Pipelining! Example: We have to build x cars...! ...Each car takes 6 steps to build...! ! Readings!

Suggested Readings! Lecture 12 Introduction to Pipelining! Example: We have to build x cars...! ...Each car takes 6 steps to build...! ! Readings! 1! CSE 30321 Lecture 12 Introduction to Pipelining! CSE 30321 Lecture 12 Introduction to Pipelining! 2! Suggested Readings!! Readings!! H&P: Chapter 4.5-4.7!! (Over the next 3-4 lectures)! Lecture 12"

More information

FMP For More Practice

FMP For More Practice FP 6.-6 For ore Practice Labeling Pipeline Diagrams with 6.5 [2] < 6.3> To understand how pipeline works, let s consider these five instructions going through the pipeline: lw $, 2($) sub $, $2, $3 and

More information

Computational aspects of two-player zero-sum games Course notes for Computational Game Theory Section 3 Fall 2010

Computational aspects of two-player zero-sum games Course notes for Computational Game Theory Section 3 Fall 2010 Computational aspects of two-player zero-sum games Course notes for Computational Game Theory Section 3 Fall 21 Peter Bro Miltersen November 1, 21 Version 1.3 3 Extensive form games (Game Trees, Kuhn Trees)

More information

EECS 470 Lecture 5. Intro to Dynamic Scheduling (Scoreboarding) Fall 2018 Jon Beaumont

EECS 470 Lecture 5. Intro to Dynamic Scheduling (Scoreboarding) Fall 2018 Jon Beaumont Intro to Dynamic Scheduling (Scoreboarding) Fall 2018 Jon Beaumont http://www.eecs.umich.edu/courses/eecs470 Many thanks to Prof. Martin and Roth of University of Pennsylvania for most of these slides.

More information

MATH 211 FINAL EXAM REVIEW PROBLEMS. c. Illustrating 12-7 for the take away concept of subtraction

MATH 211 FINAL EXAM REVIEW PROBLEMS. c. Illustrating 12-7 for the take away concept of subtraction MATH 211 FINAL EXAM REVIEW PROBLEMS 1. 32 4 in the sharing interpretation of division, base ten pieces 2. 32 4 in the measurement interpretation of division, base ten pieces 3. Write a short and simple

More information

A Memory Efficient Anti-Collision Protocol to Identify Memoryless RFID Tags

A Memory Efficient Anti-Collision Protocol to Identify Memoryless RFID Tags J Inf Process Syst, Vol., No., pp.95~3, March 25 http://dx.doi.org/.3745/jips.3. ISSN 976-93X (Print) ISSN 292-85X (Electronic) A Memory Efficient Anti-Collision Protocol to Identify Memoryless RFID Tags

More information

Design of Area and Power Efficient FIR Filter Using Truncated Multiplier Technique

Design of Area and Power Efficient FIR Filter Using Truncated Multiplier Technique Design of Area and Power Efficient FIR Filter Using Truncated Multiplier Technique TALLURI ANUSHA *1, and D.DAYAKAR RAO #2 * Student (Dept of ECE-VLSI), Sree Vahini Institute of Science and Technology,

More information

Design of Parallel Algorithms. Communication Algorithms

Design of Parallel Algorithms. Communication Algorithms + Design of Parallel Algorithms Communication Algorithms + Topic Overview n One-to-All Broadcast and All-to-One Reduction n All-to-All Broadcast and Reduction n All-Reduce and Prefix-Sum Operations n Scatter

More information

Design and Characterization of 16 Bit Multiplier Accumulator Based on Radix-2 Modified Booth Algorithm

Design and Characterization of 16 Bit Multiplier Accumulator Based on Radix-2 Modified Booth Algorithm Design and Characterization of 16 Bit Multiplier Accumulator Based on Radix-2 Modified Booth Algorithm Vijay Dhar Maurya 1, Imran Ullah Khan 2 1 M.Tech Scholar, 2 Associate Professor (J), Department of

More information

Problem 1: Map Check A B C D E F D A E. B D. E B. D E. E C. D E F C F F F. C. yes

Problem 1: Map Check A B C D E F D A E. B D. E B. D E. E C. D E F C F F F. C. yes Problem 1: Map Check Great County Comprehensive Internet Services (GCCIS), a leading local provider of information technology, is planning a new network. Each server will be connected to a certain number

More information

Some material adapted from Mohamed Younis, UMBC CMSC 611 Spr 2003 course slides Some material adapted from Hennessy & Patterson / 2003 Elsevier

Some material adapted from Mohamed Younis, UMBC CMSC 611 Spr 2003 course slides Some material adapted from Hennessy & Patterson / 2003 Elsevier Some material adapted from Mohamed Younis, UMBC CMSC 611 Spr 2003 course slides Some material adapted from Hennessy & Patterson / 2003 Elsevier Science !!! Basic MIPS integer pipeline Branches with one

More information

Project 5: Optimizer Jason Ansel

Project 5: Optimizer Jason Ansel Project 5: Optimizer Jason Ansel Overview Project guidelines Benchmarking Library OoO CPUs Project Guidelines Use optimizations from lectures as your arsenal If you decide to implement one, look at Whale

More information

CS521 CSE IITG 11/23/2012

CS521 CSE IITG 11/23/2012 Parallel Decoding and issue Parallel execution Preserving the sequential consistency of execution and exception processing 1 slide 2 Decode/issue data Issue bound fetch Dispatch bound fetch RS RS RS RS

More information

Stack permutations and an order relation for binary trees

Stack permutations and an order relation for binary trees University of Wollongong Research Online Department of Computing Science Working Paper Series Faculty of Engineering and Information Sciences 1982 Stack permutations and an order relation for binary trees

More information

DECISION TREE TUTORIAL

DECISION TREE TUTORIAL Kardi Teknomo DECISION TREE TUTORIAL Revoledu.com Decision Tree Tutorial by Kardi Teknomo Copyright 2008-2012 by Kardi Teknomo Published by Revoledu.com Online edition is available at Revoledu.com Last

More information

Multiple Reference Clock Generator

Multiple Reference Clock Generator A White Paper Presented by IPextreme Multiple Reference Clock Generator Digitial IP for Clock Synthesis August 2007 IPextreme, Inc. This paper explains the concept behind the Multiple Reference Clock Generator

More information

Coding for Efficiency

Coding for Efficiency Let s suppose that, over some channel, we want to transmit text containing only 4 symbols, a, b, c, and d. Further, let s suppose they have a probability of occurrence in any block of text we send as follows

More information

Graphs of Tilings. Patrick Callahan, University of California Office of the President, Oakland, CA

Graphs of Tilings. Patrick Callahan, University of California Office of the President, Oakland, CA Graphs of Tilings Patrick Callahan, University of California Office of the President, Oakland, CA Phyllis Chinn, Department of Mathematics Humboldt State University, Arcata, CA Silvia Heubach, Department

More information

Lecture 14. Questions? Friday, February 10 CS 430 Artificial Intelligence - Lecture 14 1

Lecture 14. Questions? Friday, February 10 CS 430 Artificial Intelligence - Lecture 14 1 Lecture 14 Questions? Friday, February 10 CS 430 Artificial Intelligence - Lecture 14 1 Outline Chapter 5 - Adversarial Search Alpha-Beta Pruning Imperfect Real-Time Decisions Stochastic Games Friday,

More information

Search then involves moving from state-to-state in the problem space to find a goal (or to terminate without finding a goal).

Search then involves moving from state-to-state in the problem space to find a goal (or to terminate without finding a goal). Search Can often solve a problem using search. Two requirements to use search: Goal Formulation. Need goals to limit search and allow termination. Problem formulation. Compact representation of problem

More information

3G TR 25.xxx V0.0.1 ( )

3G TR 25.xxx V0.0.1 ( ) (Proposed Technical Report) 3rd Generation Partnership Project; Technical Specification Group Radio Access Network; DSCH power control improvement in soft handover (Release 2000) The present document has

More information

Excel Module 2: Working with Formulas and Functions

Excel Module 2: Working with Formulas and Functions 1. An Excel complex formula uses more than one arithmetic operator. a. True b. False True QUESTION TYPE: True / False LEARNING OBJECTIVES: ENHE.REDI.16.018 - Create a complex formula by pointing 2. According

More information

PROJECT 5: DESIGNING A VOICE MODEM. Instructor: Amir Asif

PROJECT 5: DESIGNING A VOICE MODEM. Instructor: Amir Asif PROJECT 5: DESIGNING A VOICE MODEM Instructor: Amir Asif CSE4214: Digital Communications (Fall 2012) Computer Science and Engineering, York University 1. PURPOSE In this laboratory project, you will design

More information

Conversion Masters in IT (MIT) AI as Representation and Search. (Representation and Search Strategies) Lecture 002. Sandro Spina

Conversion Masters in IT (MIT) AI as Representation and Search. (Representation and Search Strategies) Lecture 002. Sandro Spina Conversion Masters in IT (MIT) AI as Representation and Search (Representation and Search Strategies) Lecture 002 Sandro Spina Physical Symbol System Hypothesis Intelligent Activity is achieved through

More information

DIGITAL DESIGN WITH SM CHARTS

DIGITAL DESIGN WITH SM CHARTS DIGITAL DESIGN WITH SM CHARTS By: Dr K S Gurumurthy, UVCE, Bangalore e-notes for the lectures VTU EDUSAT Programme Dr. K S Gurumurthy, UVCE, Blore Page 1 19/04/2005 DIGITAL DESIGN WITH SM CHARTS The utility

More information

2 person perfect information

2 person perfect information Why Study Games? Games offer: Intellectual Engagement Abstraction Representability Performance Measure Not all games are suitable for AI research. We will restrict ourselves to 2 person perfect information

More information

CHAPTER 4 ANALYSIS OF LOW POWER, AREA EFFICIENT AND HIGH SPEED MULTIPLIER TOPOLOGIES

CHAPTER 4 ANALYSIS OF LOW POWER, AREA EFFICIENT AND HIGH SPEED MULTIPLIER TOPOLOGIES 69 CHAPTER 4 ANALYSIS OF LOW POWER, AREA EFFICIENT AND HIGH SPEED MULTIPLIER TOPOLOGIES 4.1 INTRODUCTION Multiplication is one of the basic functions used in digital signal processing. It requires more

More information

Digital Imaging Rochester Institute of Technology

Digital Imaging Rochester Institute of Technology Digital Imaging 1999 Rochester Institute of Technology So Far... camera AgX film processing image AgX photographic film captures image formed by the optical elements (lens). Unfortunately, the processing

More information

AUGMENTED REALITY FOR COLLABORATIVE EXPLORATION OF UNFAMILIAR ENVIRONMENTS

AUGMENTED REALITY FOR COLLABORATIVE EXPLORATION OF UNFAMILIAR ENVIRONMENTS NSF Lake Tahoe Workshop on Collaborative Virtual Reality and Visualization (CVRV 2003), October 26 28, 2003 AUGMENTED REALITY FOR COLLABORATIVE EXPLORATION OF UNFAMILIAR ENVIRONMENTS B. Bell and S. Feiner

More information

Solutions to Assignment-2 MOOC-Information Theory

Solutions to Assignment-2 MOOC-Information Theory Solutions to Assignment-2 MOOC-Information Theory 1. Which of the following is a prefix-free code? a) 01, 10, 101, 00, 11 b) 0, 11, 01 c) 01, 10, 11, 00 Solution:- The codewords of (a) are not prefix-free

More information

Maximum Likelihood Sequence Detection (MLSD) and the utilization of the Viterbi Algorithm

Maximum Likelihood Sequence Detection (MLSD) and the utilization of the Viterbi Algorithm Maximum Likelihood Sequence Detection (MLSD) and the utilization of the Viterbi Algorithm Presented to Dr. Tareq Al-Naffouri By Mohamed Samir Mazloum Omar Diaa Shawky Abstract Signaling schemes with memory

More information

Grading Delays. We don t have permission to grade you (yet) We re working with tstaff on a solution We ll get grades back to you as soon as we can

Grading Delays. We don t have permission to grade you (yet) We re working with tstaff on a solution We ll get grades back to you as soon as we can Grading Delays We don t have permission to grade you (yet) We re working with tstaff on a solution We ll get grades back to you as soon as we can Due next week: warmup2 retries dungeon_crawler1 extra retries

More information

Twenty-fourth Annual UNC Math Contest Final Round Solutions Jan 2016 [(3!)!] 4

Twenty-fourth Annual UNC Math Contest Final Round Solutions Jan 2016 [(3!)!] 4 Twenty-fourth Annual UNC Math Contest Final Round Solutions Jan 206 Rules: Three hours; no electronic devices. The positive integers are, 2, 3, 4,.... Pythagorean Triplet The sum of the lengths of the

More information

A Taxonomy of Parallel Prefix Networks

A Taxonomy of Parallel Prefix Networks A Taxonomy of Parallel Prefix Networks David Harris Harvey Mudd College / Sun Microsystems Laboratories 31 E. Twelfth St. Claremont, CA 91711 David_Harris@hmc.edu Abstract - Parallel prefix networks are

More information

AwesomeMath Admission Test A

AwesomeMath Admission Test A 1 (Before beginning, I d like to thank USAMTS for the template, which I modified to get this template) It would be beneficial to assign each square a value, and then make a few equalities. a b 3 c d e

More information

Introduction to. Algorithms. Lecture 10. Prof. Piotr Indyk

Introduction to. Algorithms. Lecture 10. Prof. Piotr Indyk 6.006- Introduction to Algorithms Lecture 10 Prof. Piotr Indyk Quiz Rules Do not open this quiz booklet until directed to do so. Read all the instructions on this page When the quiz begins, write your

More information

AutoBench 1.1. software benchmark data book.

AutoBench 1.1. software benchmark data book. AutoBench 1.1 software benchmark data book Table of Contents Angle to Time Conversion...2 Basic Integer and Floating Point...4 Bit Manipulation...5 Cache Buster...6 CAN Remote Data Request...7 Fast Fourier

More information

High performance Radix-16 Booth Partial Product Generator for 64-bit Binary Multipliers

High performance Radix-16 Booth Partial Product Generator for 64-bit Binary Multipliers High performance Radix-16 Booth Partial Product Generator for 64-bit Binary Multipliers Dharmapuri Ranga Rajini 1 M.Ramana Reddy 2 rangarajini.d@gmail.com 1 ramanareddy055@gmail.com 2 1 PG Scholar, Dept

More information