California State University Stanislaus

CS 4300: Compiler Theory

Fall 2008

MWF (4300 & 4302) 2:30 pm - 3:28 pm, P 114,  Dr. Melanie Martin

[Basic Information]         [Announcements]         [Calendar/Assignments]         [Useful Links]

Welcome to CS 4300, Compiler Theory

Course Description

This course will introduce you to the principles of the design, evaluation, and implementation of compiler theory. This includes lexical, syntactic, and semantic analyses and syntax directed translation of programming languages, symbol table construction, error diagnostics, and code generation. In addition to learning the theory, students will construct a compiler for a subset of the C++ programming language.

Announcements and Upcoming Events


Welcome to CS 4300!

I have added a Mac Executable version of the quadruples virtual machine below
You are welcome to work fully on the Macs if you prefer
When you download the executable vmq, you will need to modify the permissions to run it:
        chmod 755 vmq
Wednesday and Thursday Office Hours this week are cancelled due to RSCA Week - please contact me for an appointment if you need to see me.
Come see the posters at the event center on Wednesday and Thursday!
Wrap-up Schedule:
  • On Friday 12/12 at 2:00 pm:
    • Demo
    • Final Group Report to be uploaded to submission system
      • What does and doesn't work
      • Limitations
      • What needs to be done
    • Individual Reports (email to me, confidential). About one single spaced page each analyzing:
      • Your contribution
      • Other team members contribution
      • How group worked

Basic Information

Textbooks are Compilers: Principles, Techniques, and Tools, by Aho, Sethi, and Ullman ( known as the dragon book)
                          lex & yacc by Levine, Mason, and Brown (O'Reilly)

Instructor: Dr. Melanie Martin                                  Office: Demergasso-Bava Hall 276

Email:                               Office Phone: (209) 667-3787

Web Page:

Office Hours: 

Monday                  12:15 – 1:00 PM  and 4:35 – 5:35 PM
Wednesday              4:35 – 5:35 PM
Thursday                 6:00 – 6:30 PM
Friday                     12:15 – 1:00 PM
and by appointment.

Best way to contact Dr. Martin:  Email  Please put "CS4300" in the subject line of the email.

Prerequisite: CS 4100
Corequisite: CS 4302

Warning: I reserve the right to make changes to the syllabus at any time during the term by announcing them in class and on my web page.

Course Email list: There is an email list set up for this course. Please join it at your earliest convenience, since class announcements and discussion may take place on the list.
To sign up, go to:
Enter your email address and cs4300-1 as the name of the list.

Grading and Policies

Final grades will be based on a term project and an exam. A plus and minus grading scale will be used to assign final grades.

Term Project:  Seventy percent of your grade will be determined by the compiler project. The grade will be composed of a team grade (50%), which will be the same for all team members, and an individual grade (50%), which will be determined by your fellow team members and the instructor, based on your individual contribution to the overall team effort. Additional information about the project requirements in available in the project handout. Project materials were developed by Dr. Ray Zarling (used with permission).

Additional project materials:
Target Language Syntax

Sample flex/bison/make applications (tar-gnuzip archives: use 'tar xzf archive.tgz to unpack) Sample code:
Virtual Machine for Quadruples

Exams: There will be one comprehensive exam given near the end of the semester, which will be due by the scheduled final exam time. The exam will account for 30% of your final grade.

Academic Honesty: The work you do for this course will be your own, unless otherwise specified. You are not to submit other people's work and represent it as your own. I consider academic honesty to be at the core of the University's activities in education and research. Academic honesty is expected at all times in this course.

Cell Phone Policy: During class time, your cell phone is to be turned off and out of sight. Any use of a cell phone during class will result in confiscation of the phone until that day's class has ended or your removal from the class for that day. If you attempt to use your cell phone or leave it on during an exam, you will be considered to have finished your test, and I will collect your exam at that time.  Exceptions may be made only if you discuss your situation with me prior to the start of that day's class, in this case, your cell phone must be set to vibrate/silence.

Important dates:

(See Schedule of Courses or Academic Calendar)

Last day to add a class:                     

Sept 17;

Last day to drop a class:

Oct 1;

Last day to change grade options (CR/NC): 
Nov 22;

No classes:

Oct 13, Nov 11, Nov 27, Nov 28, Dec 10.