In big enough projects this is the job of a civil engineer. The architect vs engineer fight that ensues is widely memed. This is of course mostly an issue in one-off projects with ambitious architects.