move some common functions to common.cpp and add some functions in c...

review at https://rbcommons.com/s/OpenH264/r/252/
1. move series of SAD functions to common module, which are used in encoder/vp module.
2. keep pred function in vp/common module