System Software and Compiler Design (CS601) Home Assignments Assignment #1 (Assigned on 30-08-2000, Submit by 06-09-2000) q1. Write C statements to define all the data structures required in a 2-pass assembler. Give the specifications of the different operations involving these data structures. Assignment #2 (Assigned on 24-10-2000, Submit by 07-11-2000) q1. Is the language L = {a^nb^n | n >= 0} context free ? Justify. [a^n means string of a's occuring n-times.] q2. To define the syntax of a typical assembly language, which class of grammar from the Chomsky's hierarchy would you use and why ? Present the grammar using a suitalble notation. Lab Assignments Assignment #1 (Assigned on 19-09-2000, Submit by 29-09-2000) q1. For the sample assembly language described in page 93 of "Systems Programming and Operating Systems, 2e" by D M Dhamdhere - 1. Write a lexical analyser using lex. 2. Implement the part of an assembler that creates the symbol table. Assignment #2 (Assigned on 28-11-2000, to be evaluated at the end of the term) q1. Create a program using LEX and YACC to evaluate arithmatic expressions involving the operations addition, subtraction, multiplication, division and exponentiation. In addition, the unary operations sin x and cos x are also to be supported in an expression to compute the sine and cosine of a value x. An expression may also contain balanced braces to modify the precedence of operations.