fixes sv defintions; threshold checking