Massachusetts Institute of Technology: S. Amarasinghe and M. Rinard's "Introduction to Computer Language Engineering"

For a definition of a compiler and some terminology, study slides 13-26. For an anatomy of a compiler see slides 27-47. For examples of optimization see slides 48-76. These slides have good examples of compiler output for a given input and a lot of examples of optimizations. A compiler translates a high-level language to a low-level language.