An analgesic is a name given to any type of drug which is effective in the treatment of pain. Because of this, they have been given the name of "painkillers".
In 2265, Dr. Mark Piper mixed together an analgesic and a stimulant in a successful attempt to wake Captain James T. Kirk and Lieutenant Commander Spock after they had been knocked out by Gary Mitchell. (TOS - Crucible novel: The Fire and the Rose)