param_used: store when a parameter is used so we don't pass unused info
commit6184d188761185ba65c8a1fe0edfc2ef171ddfa6
authorDan Carpenter <dan.carpenter@oracle.com>
Tue, 3 Mar 2015 11:21:37 +0000 (3 14:21 +0300)
committerDan Carpenter <dan.carpenter@oracle.com>
Tue, 3 Mar 2015 11:21:37 +0000 (3 14:21 +0300)
tree3e936ac6c293c5193198ab262d0d77978fc0da0c
parente52a7e26c8f76278c44aa25a2b67bfb60d37c823
param_used: store when a parameter is used so we don't pass unused info

I'm preparing to commit a patch which records when data is set to zero
because it is allocated with kzalloc() much more accurately.  This means
that the database gets huge.  Most of the data is unused as well.

This patch allows us to tell which parameters are unused.  If a parameter
is unused and the value is zero then I filter it out.  I could maybe filter
out all unused data, but I'm not sure enough that this code is bug free to
do that.

The way this patch works is that if we try to look up the value of a
variable using get_state() then that variable is considered used.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Makefile
check_list.h
smatch.h
smatch_estate.c
smatch_extra.c
smatch_extra.h
smatch_param_used.c [new file with mode: 0644]
smatch_states.c