often you can use some parameter transformation to make sure the optimisert passes aren't wasted. for example, if a>=0, b>=0, a+b<=1 you can define, 0<=x<=1, 0<=y<=1, a=x, b = (1-x)*y.
You can apply the same logic in more complex non-linear cases.
The point is:
1) If you can simplify the...