Optimize device messages.