distributed code to modules