ChiselBench is a suite of 10 programs (and counting) from GNU packages including GNU Core Utilities. These programs were chosen since they are open-source and widely used. More interestingly, their manually-reduced implementations are available in BusyBox, a lightweight UNIX utility package for embedded Linux.
The main objective of designing ChiselBench is to pave the path for researchers to explore program debloating.
Program | LOC | #Functions | #Statements |
---|---|---|---|
bzip-1.05 | 18688 | 108 | 6532 |
chown-8.2 | 69894 | 757 | 24792 |
date-8.21 | 75898 | 878 | 26147 |
grep-2.19 | 49011 | 432 | 12138 |
gzip-1.2.4 | 13223 | 93 | 4118 |
mkdir-5.2.1 | 28202 | 263 | 10679 |
rm-8.4 | 89694 | 764 | 27695 |
sort-8.16 | 71315 | 753 | 24890 |
tar-1.14 | 45778 | 502 | 13227 |
uniq-8.16 | 64915 | 665 | 22086 |
Test specifications are written as bash scripts that specify the sets of desired and undesired program functionalities. Each time the script is executed, all the desired and undesired functionalities are run with the following Clang Sanitizers.
The list of sanitizers that are used by test scripts can be modified in the test-base.
Besides sanitizers, corner-case environment conditions including memory exhaustion and stream errors are simulated via statically-linked libraries. The list of these libraries can be modified in the test-base.ChiselBench contains three main elements for each program:
*.origin.c
which is the original program (before reduction).test.sh
) which specifies the desired and undesired features as well as all the Clang Sanitizers
and corner-case environment simulators against which the user might want to test the program.Makefile
for automating the process of reduction.