I would recommend you see 2 to 3 different BMW dealerships (work one against the other) and let them know that you will check with others, this way they will sharpen there pencil and give you a good trade in and perhaps a discount. Do tell them your intentions of getting into a M5 ... In the end you will be ahead since you only pay tax on the difference of cash (new car less trade in as you well know).
You will save yourself the tire kicking fellows and lowballs. Good luck