dishwashers get very hot, which causes limescale. Unless you are lucky enough to have very soft water, or have whole-house water-softener, you need the salt to regenerate the miniature softener inside the machine. The salt does not mix with the washing or rinsing water.
Otherwise, limescale will build up, and also the detergents will not clean as effectively, and your stuff will not come out gleaming clean.
the makers usually say that if you are in an area with naturally soft water, you should put salt in the reservoir, but adjust the "hardness" regulator right down, and your salt will last a very long time before needing to be topped up.
People who have had a water softener, or lived in a soft-water area, will know how much easier it is to get things clean and streak-free, and how little soap or detergent is needed. The machine and the tablets are designed to work with softened water and will not work so well with hard water.
I have heard it said that fine wine glasses are made of a softer glass, and are attacked more by dishwashers, but I don't know if that's true. At home even cheap beer glasses go rough.
My commercial premises have a glass-washer in the bar; the machine and the detergent are much milder and faster than are used for dishwashers, and are marked as not suitable for plates or even teacups. The glasses do not go cloudy.
The commercial dishwasher in the staff kitchen uses a strong liquid detergent, which smells of bleach. It is also much faster than a domestic dishwasher.
Both these commercial machines have softeners; which the maker says are essential.