RE5 is better than Dead Space in some ways, like actually having locations to explore instead of a ship that generally looks the same throughout, way more enemy variety, much better replay value, better graphics.
Otoh, Dead Space plays better as in it's more fun to shoot stuff, has cooler weapons (although it needed more), has the better atmosphere (0G sections <3<3), and a more interesting plot. Probably better sound effects too.
Overall I think they're pretty close and both really good games.