smatch_param_limit: extra: store parameter implications in return_states
This is a re-implementation of the stuff in check_param_range.c. The
problem with that was that it added another table to the database and it
conflicted with return_states. Sometimes they would both settings and it
messed up the implications. Param_range was also sort of complicated.
The new way is more powerful because it doesn't try to parse the code, it
just uses smatch_extra.c.
The problem with the new code is that it makes that database larger and it
is a slow down. :(
The new code saves the values of the parameters down each path. If we
modify the parameter, then it preserves the original value and uses that
instead. At the end of the path it prints out the parameter value together
with the return value.
I also made the code check if the function has side effects. I'm not
ready to use that code just yet but it may be useful later... I should
hold off committing that but I am a bad and lazy person.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>