Answer:
No, not really. Penicillin (and its derivatives:Amoxicilin, Augmentin, ampicillin, etc.) is an antibiotic. It is used to clear up some kinds of bacterial infections. Some infections, such as an abscessed tooth can cause pain, and as soon as the infection is gone, so it the pain. However, it will likely take an antibiotic several days to clear up the infection.
A bona fide pain killer, such as ibuprophen (available OTC) can relieve pain in a few minutes to an hour.
Furthermore, pain relievers are to be taken only as needed (when in pain). Antibiotics, on the other hand should be taken for a specified number of days. This is because even though you may start feeling better in a day or two, the antibiotic has not yet killed off the most resistant (strongest) of the bacteria. If those bacteria survive because you stop taking the antibiotic too soon, they will pass their resistance on to the next generation and the next infection (in you or someone else) will be more difficult to defeat with antibiotics. Over time, those bacteria will be impossible to control with antibiotics, and we are headed back into the days of the Black Plague.
No, do not use penicillin as a pain reliever. I recommend Motrin 800mg 3x/day. If that does not manage your pain, see your dentist or physician.