next up previous
Next: About this document ... Up: No Title Previous: Question 2

Question 3

Flow graph: number of BBs = 6, number of IRs = 31
BB1: number of IRs = 5, branch to BB2, follow to BB3
         <OP_LD, TEMP1, x>
         <OP_LD, TEMP2, y>
         <OP_EQ, TEMP3, TEMP1, TEMP2>
         <OP_NOT, TEMP4, TEMP3>
         <OP_BRF, -, TEMP4>
BB2: number of IRs = 2
         <OP_LD, TEMP30, x>
         <OP_RET, -, TEMP30>
BB3: number of IRs = 4, branch to BB4, follow to BB5
         <OP_LD, TEMP5, x>
         <OP_LD, TEMP6, y>
         <OP_GT, TEMP7, TEMP5, TEMP6>
         <OP_BRT, -, TEMP7>
BB4: number of IRs = 10, branch to BB2, follow to BB1
         <OP_LD, TEMP8, x>
         <OP_LD, TEMP9, y>
         <OP_SUB, TEMP10, TEMP8, TEMP9>
         <OP_ST, x, TEMP10>
         <OP_LD, TEMP11, x>
         <OP_LD, TEMP12, y>
         <OP_SET, TEMP13, 5>
         <OP_MUL, TEMP14, TEMP12, TEMP13>
         <OP_EQ, TEMP15, TEMP11, TEMP14>
         <OP_BRT, -, TEMP15>
BB5: number of IRs = 6, branch to BB1, follow to BB6
         <OP_LD, TEMP19, y>
         <OP_LD, TEMP20, x>
         <OP_SET, TEMP21, 5>
         <OP_MUL, TEMP22, TEMP20, TEMP21>
         <OP_EQ, TEMP23, TEMP19, TEMP22>
         <OP_BRT, -, TEMP23>
BB6: number of IRs = 4, follow to BB1
         <OP_LD, TEMP27, y>
         <OP_LD, TEMP28, x>
         <OP_SUB, TEMP29, TEMP27, TEMP28>
         <OP_ST, y, TEMP29>



Chito
1999-07-06