consider range and not just absolute value for using switches
tighten switch heuristics