[deleted]
Given that psychiatric medicine was only invented in the 1960s (thorazine was the first majorly successful anti-psychotic), you're asking about basically all human time and cultures handling of mental illness before the 1960s. This is not an answerable question, at least not in the scope of a Reddit response. The treatment of the mentally ill varied dramatically by time and place.
Just as an example, in the United States in the 1900s-1930s, the basic "treatment" was to put the very mentally ill in state- or privately-run asylums. In such facilities the treatments could vary dramatically, even at the same time period, depending on the preferences of the state or (in some systems) the person who ran said asylum. Common treatments included hydrotherapy, psychotherapy, and occupational therapy. In the 1940s, electroshock and insulin shock therapy became popular treatments, and by the 1950s lobotomy was briefly in vogue.
I just give this example to show that even just on the "eve" of the psychiatric age, there were a wide variety of practices even within what we might call a "modern" mental health system. If you extend this backwards in time for centuries, and to different places, you get very different results.