Automatic Distribution of Object-Oriented Programs