Week 10/46

Exercises on optimization

  1. Consider the following two proposals for new peephole patterns. Are they sound? How would those that are sound look as C-code? Would they ever be relevant?
    • Replace
      ldc_string "..."
      dup
      ifnull L
      
      by
      ldc_string "..."
      
    • Replace
      return
      <<anything>>
      
      by
      return
      
  2. Study and discuss the contents of the WIG run-time library runwig.c.
  3. Discuss general aspects of WIG code generation.
  4. What kinds of optimizations would be relevant for WIG programs?
  5. Study the code for optimizing JOOS programs.

Maintained by Laurie J. Hendren. Last modified Fri Sep 17 07:25:13 EDT 2004. [HOME]
Compiler research projects: Soot, a Java analysis, optimization and transformation toolkit ---- abc, an AspectJ compiler.