Loop optimization, constant folding, common subexpression elimination. 6. Target Code Generator
| Parser | Power | Table Size | GATE Frequency | |--------|-------|-------------|----------------| | LL(1) | Least | Small | Moderate | | SLR(1) | More | Medium | High | | CLR(1) | Most | Large | Low (theoretical) | | LALR(1)| Same as CLR but smaller table | Medium | High | compiler design gate smashers
Note that LL parsers can loop infinitely if left recursion is present. Use the formula: cap A right arrow cap A alpha divides beta cap A right arrow beta cap A prime cap A prime right arrow alpha cap A prime divides epsilon For Question 8: Use the formula: cap A right arrow cap
Maps the optimized intermediate code to the actual target machine language or assembly code. It handles register allocation and assignment. compiler design gate smashers