The purpose of the SAFECode project is to enable program safety without garbage collection and with minimal run-time checks using static analysis when possible and run-time checks when necessary. SAFECode defines a code representation with minimal semantic restrictions designed to enable static enforcement of safety, using aggressive compiler techniques developed in this project.

SAFECode is designed to provide the following safety guarantees:

  • Array bounds checking (prevents pointers from overflowing from one memory object into another)
  • Loads and stores only access valid memory objects
  • Type safety for a subset of memory objects proven to be type-safe
  • Sound operational semantics in the face of dangling pointer errors (i.e., all safety guarantees hold even when dangling pointers are dereferenced).
  • Optional dangling pointer detection (induces more overhead)

The SAFECode and SVA research is funded by grants from AFRL Contract #FA8650-10-C-7022, the National Science Foundation, the DoD Multi-disciplinary University Research Initiative (MURI), Apple Computer, Inc., and the University of Illinois.