I'm going to be very frank here, hopefully this will not come back to bite me should I choose to someday run for public office...
I used to play a jazz gig. Ocassionally if I had a bit of a headache before the gig I would take a couple of Excedrine (which contains quite a bit of caffeine...part of the reason for it's effectiveness). I eventually figured out that, on those occasions, I seemed to be able to play faster and with greater clarity (in terms of my thought process for jazz solos). So I began to always take Excedrine before my gigs (I don't like coffee). Unfortunately once you start doing this you develop a tolerance, so you need more and more. This eventually resulted in "rebound" headaches; a problem I suffered from for many years until a doctor finally got me to stop using caffeine and began to treat me properly for (what I now know are) migraine headaches. So I think some performance enhancement is possible but, like all things, there is a cost. It's a downward spiral.
I don't like the effect of alcohol, but I have smoked pot since I was a kid. There is no question in my mind, based on numerous personal, private recordings I've made, that I've given some of my best performances while a little bit high. Why is that? My belief is that I have a hard time shutting out all of the distractions of life, technique, etc during my "straight" performance. For some reason if I've got a buzz I'm able to experience the music I'm playing AS A LISTENER...IOW without "losing the forest for the trees". However I'm positive that drugs are NOT necessary to achieve this state. I just haven't developed the mental discipline to do it (all the time) without. I would strongly recommend Kenny Werner's book "Effortless Mastery" which discusses this very subject in depth. There are numerous examples of brilliant musicians who perform at the highest level without any use of drugs. So it is possible, and should be your goal.
Smoking some pot, then playing the piano at home is one thing. But it's not really practical, in fact it's a terrible idea, if you're playing in public. My experience is that if ANYTHING goes wrong or unexpected, you will not be able to adapt. Plus it's just irresponsible, and certainly not professional. I would never show up at a gig or recording session in any other condition that completely STRAIGHT.
Many musicians use beta blockers to "calm nerves". I've used them, but I don't think the effect is significant. I suspect it's more of a placebo effect, but it's possible it can be helpful. If you've really got anxiety issues you should probably seek a therapist. A drug like Xanax is much more effective against anxiety, but it's addictive and could inhibit your performance if you're not familiar with it's effects.
Bottom line: stay away from any drug use if you can. Train yourself to mentally prepare for the performance in the same way you train yourself physically to give the performance...by practicing. Meditate, perhaps. Learn relaxation techniques. If you can do it without using any drugs, you remove the burden of needing some artificial means to generate a good performance. It's one less thing you'll have to worry about, and you'll feel better about yourself and your playing in the long run.