CComp - Offline Compression for On-Chip RAM


Offline Compression for On-Chip RAM

News Installation Use Mailing list Publications Related projects


4/15/08 - Updated distribution and install instructions thanks to a user's bug report. Not sure how this wasn't caught earlier, at least by me. There is now a new distribution and updated instructions to go with it.
3/13/08 - Posted a pdf version of John's talk in Brisbane.
12/13/07 - The version of cXprop posted here does not work for native machines. Since compression only works for AVR machines, this should not be a big deal. However, you can visit the cXprop page to get a current working version of cXprop for multiple platforms.
11/16/07 - I updated the cil-cXprop.tgz download again. A handful of people have been wanting cXprop to dump its state at the end of an analysis. The --cxp_global_states flag in this version outputs the global state, the incoming function argument states, and the return states to a file with the *.states type
11/13/07 - Updated the cil-cXprop.tgz download to the current CVS version. The main fix is that it now compiles on new systems (including my new work machine). Thanks to Jonathan Heusser for pointing out that this needed to be updated
11/01/07 - John is going to Brisbane to give a talk about this work prior to SenSys. I added his slides in the publications section
04/26/07 - Added a lot more content to the site. The biggest additions are the actual souce files for CComp and some instructions for getting things up and running. Still feel free to email me with questions and/or comments
03/28/07 - Added link to final copy of PLDI paper
03/09/07 - Created stub for web page. Nothing here yet!



I tried to make sure these steps were simple and that they work. However, please let me know if you have any problems. Email me at coopATcsDOTutahDOTedu or email the cXprop users list.
  1. Download and install OCaml.
  2. Download and install avr-gcc (We use version that comes with TinyOS 2.0).
  3. Download our modified CIL, which includes the cXprop and CComp sources.
  4. Run the following commands:
    1. tar -xvzf cXprop-cil.tgz
    2. cd cXprop-cil
    3. configure --target=avr
    4. make
    5. export CIL_HOME=`pwd`
    6. export PATH=$CIL_HOME/bin:$PATH
You probably want to make the addition to your path permanent. You can start using CComp by using the CComp script. That script is a VERY simple wrapper around cXpropMICA2, so you eventually want to write your own scripts which call cXpropMICA2 directly (cXpropMICA2 is itself a wrapper around cilly, which is a wrapper around the CIL executable).



You need an C application to compress. Unless you have messed with the setup, it needs to be an mica2 or micaz tinyOS application. You can find the C version after you build the application in the build/mica[2|z] directory. It is called app.c. Here is an app.c that has been renamed to blink.c (since it is the blink application for the mica2 motes). To compress it, just run this command:

CComp blink.c -o blink.exe

A lot of information is printed here. You can look at the blink.cil.c file to see the compressed variable structures CComp created and how it uses them. CComp has many options that control its behavior. Most are only available through calling cXpropMICA2 or cXpropTELOSB directly, but some have been exposed through the CComp script. To see what those options are, just run this command:

CComp --help

If you would like to know more of the features of CComp or have questions about any part of it, please let me know. I would be happy to help in whatever way I can.


Mailing list

The mailing list cXprop-users for cXprop is hosted at Google. CComp will also use the same list until I see a reason to do otherwise. To subscribe, enter your email address below; you will be sent a confirmation by email.

Google Groups cXprop-users at
Browse Archives


Publications and presentations

Offline Compression for On-Chip RAM. John Regehr and Nathan Cooprider. Brisbane, Australia, November 2007.
Offline Compression for On-Chip RAM. Nathan Cooprider and John Regehr. In Proceedings of the ACM Conference on Programming Language Design and Implementation (PLDI), San Diego, California, June 2007.
Offline Compression for On-chip RAM. Nathan Cooprider and John Regehr. Poster for University of Utah School of Computing Research Day, Salt Lake City, Utah, March 2007.


Related projects



This page is maintained by