Skip to content

Category Archives: Compiler Design

The code optimization in the synthesis phase is a program transformation technique, which tries to improve the intermediate code by making it consume fewer resources… Read More
1. What will be the output of the following code?   C #include <stdio.h> #include <stdlib.h>   int main() {     union test {         int i;         float… Read More
As it is known that Lexical Analysis is the first phase of compiler also known as scanner. It converts the input program into a sequence… Read More
In this article we are discussing the SLR parser, CLR parser and LALR parser which are the parts of Bottom Up parser. SLR Parser The SLR… Read More
In this article, we are discussing the Bottom Up parser. Bottom Up Parsers / Shift Reduce Parsers Build the parse tree from leaves to root.… Read More
In this article, we will study various types of parses. It is one of the most important topics in Compiler from a GATE point of… Read More
In the analysis-synthesis model of a compiler, the front end of a compiler translates a source program into an independent intermediate code, then the back… Read More
A translation needs to relate the static source text of a program to the dynamic actions that must occur at runtime to implement the program.… Read More
Parser uses a CFG(Context-free-Grammar) to validate the input string and produce output for the next phase of the compiler. Output could be either a parse… Read More
You can also read our previously discussed article on the Classification of Context-Free Grammar.   Context Free Grammars(CFGs) are classified based on: Number of Derivation trees… Read More
Context Free Grammars (CFG) can be classified on the basis of following two properties:  1) Based on number of strings it generates. If CFG is… Read More
We have discussed the following topics on Syntax Analysis.  Introduction to Syntax Analysis Why FIRST and FOLLOW? FIRST Set in Syntax Analysis   FOLLOW set is a concept… Read More
FIRST(X) for a grammar symbol X is the set of terminals that begin the strings derivable from X.  FIRST set is a concept used in… Read More
Why FIRST? We saw the need of backtrack in the previous article of on Introduction to Syntax Analysis, which is really a complex process to… Read More
When an input string (source code or a program in some language) is given to a compiler, the compiler processes it in several phases, starting… Read More

Start Your Coding Journey Now!